-
Notifications
You must be signed in to change notification settings - Fork 2
/
config.py
executable file
·66 lines (51 loc) · 1.04 KB
/
config.py
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
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
#!/usr/bin/env python
# -*- coding: UTF-8 -*-
__author__ = 'Tzury Bar Yochay'
__version__ = '0.1'
__license__ = 'GPLv3'
import license
from utils import Storage
from logger import log
#60 Seconds
CLIENT_EXPIRE = 60
RTP_EXPIRE = 20
EMPTY_CTX = (0,) #'\x00'*16
NUM_OF_USERS = license.NUM_OF_USERS
CONCURRENT_SESSIONS = license.CONCURRENT_SESSIONS
Codecs = Storage (
PCMA='\x01',
PCMU='\x02',
G723='\x03',
ILBC='\x04',
SPEEX='\x05',
SNAP='\x07',
)
CallTypes = Storage (
ViaProxy=1,
Direct=2,
)
Errors = Storage (
#general
Unknown = '\xff\x00',
UknownClient = '\xff\x01',
ServerOverloaded = '\xff\x02',
#login
LoginFailure = '\x01\x01',
#keep-alive
KeepAlive = '\x02\x02',
#invite
CalleeNotFound = '\x03\x01',
CalleeUnavailable = '\x03\x02',
CodecMismatch = '\x03\x03'
)
ClientStatus = Storage (
Unknown = '\xff',
Active = '\x00',
Busy = '\x01',
Ringing = '\x02',
Away = '\x03'
)
Listeners = (
('udp', 50009),
('tcp', 50009),
)