]> git.mxchange.org Git - fba.git/commitdiff
Continued:
authorRoland Häder <roland@mxchange.org>
Thu, 22 Jun 2023 04:52:35 +0000 (06:52 +0200)
committerRoland Häder <roland@mxchange.org>
Thu, 22 Jun 2023 04:52:35 +0000 (06:52 +0200)
- don't check blacklist for (maybe) obsfucated domains,
  domain.is_domain_wanted() does this

fba/networks/mastodon.py
fba/networks/pleroma.py

index 686ae9d67f21f502da459b6cd9f63dfc0db2ee8d..ad3e913aa3c467f0bbcf3bfb26f9aa168ca34dde 100644 (file)
@@ -280,9 +280,6 @@ def fetch_blocks(domain: str, origin: str, nodeinfo_url: str):
                 if not utils.is_domain_wanted(blocked):
                     logger.debug("blocked='%s' is not wanted - SKIPPED!", blocked)
                     continue
-                elif blacklist.is_blacklisted(blocked):
-                    logger.debug("blocked='%s' is blacklisted - SKIPPED!", blocked)
-                    continue
                 elif not instances.is_registered(blocked):
                     logger.debug(f"Domain blocked='%s' wasn't found, adding ..., domain='%s',origin='%s',nodeinfo_url='%s'", blocked, domain, origin, nodeinfo_url)
                     instances.add(blocked, domain, inspect.currentframe().f_code.co_name, nodeinfo_url)
index bfd41f667119095ced3efd0c27fc0de716a6a98b..390b01e064c0f93bfe7195a39f779a57922c89c0 100644 (file)
@@ -116,9 +116,6 @@ def fetch_blocks(domain: str, origin: str, nodeinfo_url: str):
                     elif blocked.endswith(".tld"):
                         logger.debug("blocked='%s' is a fake domain - SKIPPED!", blocked)
                         continue
-                    elif blacklist.is_blacklisted(blocked):
-                        logger.debug("blocked='%s' is blacklisted - SKIPPED!", blocked)
-                        continue
                     elif blocked.count("*") > 0:
                         # Obscured domain name with no hash
                         row = instances.deobscure("*", blocked)
@@ -190,9 +187,6 @@ def fetch_blocks(domain: str, origin: str, nodeinfo_url: str):
             elif blocked.endswith(".tld"):
                 logger.debug("blocked='%s' is a fake domain - SKIPPED!", blocked)
                 continue
-            elif blacklist.is_blacklisted(blocked):
-                logger.debug("blocked='%s' is blacklisted - SKIPPED!", blocked)
-                continue
             elif blocked.count("*") > 0:
                 # Obscured domain name with no hash
                 row = instances.deobscure("*", blocked)
@@ -292,9 +286,6 @@ def fetch_blocks(domain: str, origin: str, nodeinfo_url: str):
                 if blocked == "":
                     logger.warning("blocked is empty after tidyup.domain():", domain, block_level)
                     continue
-                elif blacklist.is_blacklisted(blocked):
-                    logger.debug("blocked='%s' is blacklisted - SKIPPED!", blocked)
-                    continue
                 elif blocked.count("*") > 0:
                     # Obscured domain name with no hash
                     row = instances.deobscure("*", blocked)
@@ -361,9 +352,6 @@ def fetch_blocks(domain: str, origin: str, nodeinfo_url: str):
             if blocked == "":
                 logger.warning("blocked is empty after tidyup.domain():", domain, block_level)
                 continue
-            elif blacklist.is_blacklisted(blocked):
-                logger.debug("blocked='%s' is blacklisted - SKIPPED!", blocked)
-                continue
             elif blocked.count("*") > 0:
                 # Obscured domain name with no hash
                 row = instances.deobscure("*", blocked)
@@ -431,9 +419,6 @@ def fetch_blocks(domain: str, origin: str, nodeinfo_url: str):
                     if blocked == "":
                         logger.warning("blocked is empty after tidyup.domain():", domain, block_level)
                         continue
-                    elif blacklist.is_blacklisted(blocked):
-                        logger.debug("blocked='%s' is blacklisted - SKIPPED!", blocked)
-                        continue
                     elif blocked.count("*") > 0:
                         # Obscured domain name with no hash
                         row = instances.deobscure("*", blocked)