mirror of
https://github.com/iio612/DEFENDER.git
synced 2026-02-13 11:14:23 +00:00
@@ -81,7 +81,7 @@ class Loader:
|
|||||||
|
|
||||||
self.PFactory: factory.ProtocolFactorty = factory.ProtocolFactorty(self)
|
self.PFactory: factory.ProtocolFactorty = factory.ProtocolFactorty(self)
|
||||||
|
|
||||||
self.RpcServer: rpc_mod.JSonRpcServer = rpc_mod.JSonRpcServer(self)
|
self.RpcServer: rpc_mod.JSonRpcServer = rpc_mod.JSonRpcServer(self, hostname='0.0.0.0')
|
||||||
|
|
||||||
self.Logs.debug(self.Utils.tr("Loader %s success", __name__))
|
self.Logs.debug(self.Utils.tr("Loader %s success", __name__))
|
||||||
|
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ async def coro_cloudfilt_scan(uplink: 'Defender'):
|
|||||||
while uplink.cloudfilt_isRunning:
|
while uplink.cloudfilt_isRunning:
|
||||||
list_to_remove:list = []
|
list_to_remove:list = []
|
||||||
for user in uplink.Schemas.DB_CLOUDFILT_USERS:
|
for user in uplink.Schemas.DB_CLOUDFILT_USERS:
|
||||||
uplink.mod_utils.action_scan_client_with_cloudfilt(uplink, user)
|
await uplink.mod_utils.action_scan_client_with_cloudfilt(uplink, user)
|
||||||
list_to_remove.append(user)
|
list_to_remove.append(user)
|
||||||
await asyncio.sleep(1)
|
await asyncio.sleep(1)
|
||||||
|
|
||||||
@@ -30,7 +30,7 @@ async def coro_freeipapi_scan(uplink: 'Defender'):
|
|||||||
|
|
||||||
list_to_remove: list = []
|
list_to_remove: list = []
|
||||||
for user in uplink.Schemas.DB_FREEIPAPI_USERS:
|
for user in uplink.Schemas.DB_FREEIPAPI_USERS:
|
||||||
uplink.mod_utils.action_scan_client_with_freeipapi(uplink, user)
|
await uplink.mod_utils.action_scan_client_with_freeipapi(uplink, user)
|
||||||
list_to_remove.append(user)
|
list_to_remove.append(user)
|
||||||
await asyncio.sleep(1)
|
await asyncio.sleep(1)
|
||||||
|
|
||||||
@@ -44,11 +44,13 @@ async def coro_abuseipdb_scan(uplink: 'Defender'):
|
|||||||
while uplink.abuseipdb_isRunning:
|
while uplink.abuseipdb_isRunning:
|
||||||
|
|
||||||
list_to_remove: list = []
|
list_to_remove: list = []
|
||||||
|
print(uplink.Schemas.DB_ABUSEIPDB_USERS)
|
||||||
for user in uplink.Schemas.DB_ABUSEIPDB_USERS:
|
for user in uplink.Schemas.DB_ABUSEIPDB_USERS:
|
||||||
uplink.mod_utils.action_scan_client_with_abuseipdb(uplink, user)
|
await uplink.mod_utils.action_scan_client_with_abuseipdb(uplink, user)
|
||||||
list_to_remove.append(user)
|
list_to_remove.append(user)
|
||||||
await asyncio.sleep(1)
|
await asyncio.sleep(1)
|
||||||
|
|
||||||
|
print(list_to_remove)
|
||||||
for user_model in list_to_remove:
|
for user_model in list_to_remove:
|
||||||
uplink.Schemas.DB_ABUSEIPDB_USERS.remove(user_model)
|
uplink.Schemas.DB_ABUSEIPDB_USERS.remove(user_model)
|
||||||
|
|
||||||
@@ -59,7 +61,7 @@ async def coro_local_scan(uplink: 'Defender'):
|
|||||||
while uplink.localscan_isRunning:
|
while uplink.localscan_isRunning:
|
||||||
list_to_remove:list = []
|
list_to_remove:list = []
|
||||||
for user in uplink.Schemas.DB_LOCALSCAN_USERS:
|
for user in uplink.Schemas.DB_LOCALSCAN_USERS:
|
||||||
uplink.mod_utils.action_scan_client_with_local_socket(uplink, user)
|
await uplink.mod_utils.action_scan_client_with_local_socket(uplink, user)
|
||||||
list_to_remove.append(user)
|
list_to_remove.append(user)
|
||||||
await asyncio.sleep(1)
|
await asyncio.sleep(1)
|
||||||
|
|
||||||
@@ -74,7 +76,7 @@ async def coro_psutil_scan(uplink: 'Defender'):
|
|||||||
|
|
||||||
list_to_remove:list = []
|
list_to_remove:list = []
|
||||||
for user in uplink.Schemas.DB_PSUTIL_USERS:
|
for user in uplink.Schemas.DB_PSUTIL_USERS:
|
||||||
uplink.mod_utils.action_scan_client_with_psutil(uplink, user)
|
await uplink.mod_utils.action_scan_client_with_psutil(uplink, user)
|
||||||
list_to_remove.append(user)
|
list_to_remove.append(user)
|
||||||
await asyncio.sleep(1)
|
await asyncio.sleep(1)
|
||||||
|
|
||||||
|
|||||||
@@ -84,7 +84,7 @@ class Jsonrpc(IModule):
|
|||||||
await self.sync_db()
|
await self.sync_db()
|
||||||
|
|
||||||
if self.ctx.Config.SERVEUR_PROTOCOL.lower() != 'unreal6':
|
if self.ctx.Config.SERVEUR_PROTOCOL.lower() != 'unreal6':
|
||||||
self.ctx.ModuleUtils.unload_one_module(self.module_name, False)
|
await self.ctx.ModuleUtils.unload_one_module(self.module_name, False)
|
||||||
return None
|
return None
|
||||||
|
|
||||||
# Is RPC Active?
|
# Is RPC Active?
|
||||||
|
|||||||
@@ -3,6 +3,6 @@ psutil==7.1.2
|
|||||||
PyYAML==6.0.3
|
PyYAML==6.0.3
|
||||||
requests==2.32.5
|
requests==2.32.5
|
||||||
SQLAlchemy==2.0.44
|
SQLAlchemy==2.0.44
|
||||||
unrealircd_rpc_py==3.0.2
|
unrealircd_rpc_py==3.0.4
|
||||||
starlette==0.50.0
|
starlette==0.50.0
|
||||||
uvicorn==0.38.0
|
uvicorn==0.38.0
|
||||||
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
"requests": "2.32.5",
|
"requests": "2.32.5",
|
||||||
"psutil": "7.1.2",
|
"psutil": "7.1.2",
|
||||||
"unrealircd_rpc_py": "3.0.3",
|
"unrealircd_rpc_py": "3.0.4",
|
||||||
"sqlalchemy": "2.0.44",
|
"sqlalchemy": "2.0.44",
|
||||||
"faker": "37.12.0",
|
"faker": "37.12.0",
|
||||||
"pyyaml": "6.0.3",
|
"pyyaml": "6.0.3",
|
||||||
|
|||||||
Reference in New Issue
Block a user