From: Roland Häder Date: Sat, 20 Jul 2024 18:29:23 +0000 (+0200) Subject: Continued: X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=69c2a6a270cea8d30f637f79184cc27cfe243c07;p=fba.git Continued: - don't reduce counter for obfuscated domains, keep it at original value - some more debug messages added --- diff --git a/fba/commands.py b/fba/commands.py index b33145a..f97ad8f 100644 --- a/fba/commands.py +++ b/fba/commands.py @@ -389,7 +389,7 @@ def fetch_blocks(args: argparse.Namespace) -> int: logger.debug("block[blocked]='%s' is a fake domain - SKIPPED!", block["blocked"]) continue elif block["blocked"].find("*") >= 0: - logger.debug("blocker='%s' uses obfuscated domains", blocker) + logger.debug("blocker='%s' uses '*' for obfuscating domains", blocker) instances.set_has_obfuscation(blocker, True) obfuscated = obfuscated + 1 @@ -406,7 +406,7 @@ def fetch_blocks(args: argparse.Namespace) -> int: origin = row["origin"] nodeinfo_url = row["nodeinfo_url"] elif block["blocked"].find("?") >= 0: - logger.debug("blocker='%s' uses obfuscated domains", blocker) + logger.debug("blocker='%s' uses '?' for obfuscating domains", blocker) instances.set_has_obfuscation(blocker, True) obfuscated = obfuscated + 1 @@ -457,7 +457,9 @@ def fetch_blocks(args: argparse.Namespace) -> int: logger.debug("Hash wasn't found, adding: block[blocked]'%s',blocker='%s'", block["blocked"], blocker) federation.fetch_instances(block["blocked"], blocker, None, inspect.currentframe().f_code.co_name) + logger.debug("Invoking blocks.alias_block_level('%s') ... - BEFORE!", block["block_level"]) block["block_level"] = blocks.alias_block_level(block["block_level"]) + logger.debug("block[block_level]='%s' - AFTER!", block["block_level"]) if processing.block(blocker, block["blocked"], block["reason"], block["block_level"]) and block["block_level"] in ["reject", "suspend"] and config.get("bot_enabled"): logger.debug("Appending block[blocked]'%s',reason='%s' for blocker='%s' ...", block["blocked"], block["block_level"], blocker) @@ -1433,7 +1435,6 @@ def recheck_obfuscation(args: argparse.Namespace) -> int: logger.debug("blocked[%s]='%s',block[blocked]='%s'", type(blocked), blocked, block["blocked"]) if blocked is not None and blocked != block["blocked"]: logger.debug("blocked='%s' was deobfuscated to blocked='%s'", block["blocked"], blocked) - obfuscated = obfuscated - 1 if blacklist.is_blacklisted(blocked): logger.debug("blocked='%s' is blacklisted - SKIPPED!", blocked)