3. You should generate a certificate to `mdmaug/cert-mdmaug.pem`, at least a self-signed one (non recommended): `openssl req -new -x509 -keyout cert-mdmaug.pem -out cert-mdmaug.pem -days 365 -nodes`
3. You should generate a certificate to `mdmaug/cert-mdmaug.pem`, at least a self-signed one (non recommended): `openssl req -x509 -newkey rsa:4096 -nodes -out cert-mdmaug.pem -keyout key-mdmaug.pem`
6. Launch under newly created `mdmaug` user: `su - mdmaug -c 'python3 -m mdmaug'`
...
...
@@ -20,6 +20,10 @@ Scans a website for a sign of a parasite hosts or commands.
* You may put ```03 1,7,13,19 * * * ~/mdmaug-launch``` in ```crontab -e``` of user mdmaug.
* We are using Python3.6+
## Tips
* You may use /static/demopage.html as a testing page.
### Troubleshooting
* Analysis stopped working after restart? Maybe you need to launch `xhost +local:mdmaug` command from a common user shell after every system restart :( I'm not sure.
lock=threading.RLock()# doufam, ze kdyz je lock tady, ze je funknci. Closure...? XX nejak otestovat
db:MySQLDatabase=None
lock=threading.RLock()
THUMBNAIL_SIZE=640,640
MAX_WHOIS_DOMAIN_THREADS=10# spusti maximalne 10 threadu doraz, jednou mi to totiz preteklo (kazda domena spusti jeste tolik threadu, kolik ma IP, ale tech byva jen par)
MAX_BROWSER_RUN_TIME=25# maximum time for a browser to run
MAX_BROWSER_EXPIRATION=15# seconds that we wait before killing the browser (waiting for the files to be written)
EXPORT_NOTBLOCK_TLD=".cz"# lowercase; this TLD is ignored in the export
CRAWL_FILE="analysis.json"
@staticmethod
defconnect():
# XX resim problem peewee.OperationalError: (2006, "MySQL server has gone away (BrokenPipeError(32, 'Broken pipe'))") po 7 hodinach timeoutu
# XX kupodivu pripojeni nemuze byt v dbp DBModel.connect. Prestoze type je pak spravne (MySQLDatabase), nic udelat nejde a pokusy o select konci NoneType.