Onionr/src/bigbrother/ministry/ofdisk.py

19 lines
482 B
Python
Raw Normal View History

2020-03-31 05:15:24 +00:00
from utils.identifyhome import identify_home
import logger
def detect_disk_access(info):
if type(info[0]) is int: return
if '/dev/null' == info[0]: return
whitelist = [identify_home(), 'onionr/src/', '/site-packages/', '/usr/lib64/']
for item in whitelist:
if item in info[0]:
return
if identify_home() not in info[0]:
2020-07-31 01:15:36 +00:00
if 'proc' not in info[0]: # if it is, it is onionr stats
2020-03-31 05:15:24 +00:00
logger.warn(f'[DISK MINISTRY] {info}')