Completely disable the internet and other services, only allowing whitelists through.
pip install darklock
Import into your application at the top of the main entry file (e.g. main.py
).
Install the darklock for the service you want to restrict.
import darklock
darklock.network.install()
darklock.os.install()
Uninstall the darklock for the service you no longer want to restrict.
import darklock
darklock.network.uninstall()
darklock.os.uninstall()
python -m unittest discover -s tests