-
Notifications
You must be signed in to change notification settings - Fork 15
/
config.py
57 lines (44 loc) · 1.37 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
"""
Yeahh config!!
"""
class Config:
"""
You can set the stuff below yourself
Don't forget to restart afterwards
"""
ca_name = "aparoid.mitm.com"
cert_directory = "certs"
cert_auto_recreate = False
# you can also use /tmp/cert_cache for automatic cleanup
cert_cache_directory = "cache"
# dynamic use cert (point this to burp if you are not using the embedded proxy)
cert_location = "certs/mitmproxy-ca-cert.pem"
# use kafka for the http collector and frida
use_kafka = False
kafka_servers = ["localhost:9092"]
# hard-coded adb location (default: use from PATH)
adb_path = None
# Use this as proxy port (for use with third-party proxy servers)
proxy_port = 8088
# Proxy listen host (pls do not expose)
proxy_host = "127.0.0.1"
# database connection string
database_connector = "sqlite:///aparoid.db"
# database_connector = "postgresql+psycopg2://aparoid:aparoid@localhost/aparoid"
def get_key(self, key, default=None):
"""
Get config entry
Return default if not found
:param key:
:param default:
:return:
"""
return getattr(self, key, default)
def set_key(self, key, value):
"""
Temporary key override
:param key:
:param value:
:return:
"""
return setattr(self, key, value)