-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrun.py
More file actions
45 lines (38 loc) · 1.76 KB
/
run.py
File metadata and controls
45 lines (38 loc) · 1.76 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#!/usr/bin/env python3
"""
iSpy C2 Server
Entry point
"""
from app import create_app, socketio
from app.config import get_config
config = get_config()
app = create_app()
def print_banner():
"""Print startup banner"""
print("\n" + "=" * 55)
print(" ██╗███████╗██████╗ ██╗ ██╗ ██████╗██████╗ ")
print(" ██║██╔════╝██╔══██╗╚██╗ ██╔╝ ██╔════╝╚════██╗")
print(" ██║███████╗██████╔╝ ╚████╔╝ ██║ █████╔╝")
print(" ██║╚════██║██╔═══╝ ╚██╔╝ ██║ ██╔═══╝ ")
print(" ██║███████║██║ ██║ ╚██████╗███████╗")
print(" ╚═╝╚══════╝╚═╝ ╚═╝ ╚═════╝╚══════╝")
print("=" * 55)
print(f" Admin Panel : http://localhost:{config.PORT}/admin")
print(f" API Endpoint : http://localhost:{config.PORT}/api")
print(f" WebSocket : ws://localhost:{config.PORT}")
print(f" Health Check : http://localhost:{config.PORT}/api/health")
print("=" * 55)
print(f" Environment : {config.FLASK_ENV}")
print(f" JWT Expiry : {config.JWT_EXPIRY_HOURS} hours")
print(f" Rate Limit : {config.RATE_LIMIT_PER_MINUTE}/min")
print("=" * 55)
print("=" * 55 + "\n")
if __name__ == '__main__':
print_banner()
socketio.run(
app,
host=config.HOST,
port=config.PORT,
debug=config.DEBUG,
allow_unsafe_werkzeug=True
)