blob: 60e80e72c044186c26088b3948b08f26149627c1 [file] [log] [blame]
awlane1cec2332025-04-24 17:24:47 -05001from enum import Enum
2
3class Config:
4 AUTH_FILE = "/tmp/ndnplay-auth"
5 PLAY_URL = "https://play.ndn.today"
6 SERVER_HOST = "0.0.0.0"
7 SERVER_HOST_URL = "127.0.0.1"
8 SERVER_PORT = 8765
9 PCAP_CHUNK_SIZE = 512
10
11# MessagePack Keys
12class WSKeys(str, Enum):
13 MSG_KEY_FUN = 'F'
14 MSG_KEY_ID = 'I'
15 MSG_KEY_RESULT = 'R'
16 MSG_KEY_ARGS = 'A'
17
18class WSFunctions(str, Enum):
19 GET_TOPO = 'get_topo'
20 OPEN_ALL_PTYS = 'open_all_ptys'
21 DEL_LINK = 'del_link'
22 ADD_LINK = 'add_link'
23 UPD_LINK = 'upd_link'
24 DEL_NODE = 'del_node'
25 ADD_NODE = 'add_node'
26 GET_FIB = 'get_fib'
27 GET_PCAP = 'get_pcap'
28 GET_PCAP_WIRE = 'get_pcap_wire'
29 PTY_IN = 'pty_in'
30 PTY_OUT = 'pty_out'
31 PTY_RESIZE = 'pty_resize'
32 OPEN_TERMINAL = 'open_term'
33 CLOSE_TERMINAL = 'close_term'
34 MONITOR_COUNTS = 'monitor_counts'