Update modules/botnet_protect.py

This commit is contained in:
Nova Cat 2025-01-11 00:53:53 -08:00
parent fd5c004ff1
commit d0935eb702

View file

@ -21,7 +21,7 @@ class IRCatModule:
raise Exception("Botnet detected!") raise Exception("Botnet detected!")
def onSocket(self, ip, socket, value, cachedNick=None, validated=False): def onSocket(self, ip, socket, value, cachedNick=None, validated=False):
if cachedNick != None: if cachedNick != None:
if cachedNick + "|" + ip in self.memory and self.memory[cachedNick + "|" + ip] != 0: if not (cachedNick + "|" + ip in self.memory and self.memory[cachedNick + "|" + ip] == 0):
print(value) print(value)
if "JOIN" in value: if "JOIN" in value:
target = value.split(" ")[1] target = value.split(" ")[1]