logger.warning("Exception '%s' during fetching instances (fetch_cs) from blocked='%s'", type(exception), blocked)
instances.set_last_error(blocked, exception)
- if blocks.is_instance_blocked(blocker, blocked, block_level):
+ if not domain_helper.is_wanted(blocked):
+ logger.warning("blocked='%s' is not wanted - SKIPPED!", blocked)
+ continue
+ elif not domain_helper.is_wanted(blocker):
+ logger.warning("blocker='%s' is not wanted - SKIPPED!", blocker)
+ continue
+ elif blocks.is_instance_blocked(blocker, blocked, block_level):
logger.debug("blocked='%s',block_level='%s' is already blocked - SKIPPED!", blocked, block_level)
continue
logger.debug("blocked='%s' was deobfuscated to blocked='%s'", block["blocked"], blocked)
obfuscated = obfuscated - 1
- if blocks.is_instance_blocked(row["domain"], blocked):
- logger.debug("blocked='%s' is already blocked by domain='%s' - SKIPPED!", blocked, row["domain"])
- continue
- elif blacklist.is_blacklisted(blocked):
+ if blacklist.is_blacklisted(blocked):
logger.debug("blocked='%s' is blacklisted - SKIPPED!", blocked)
continue
+ elif blacklist.is_blacklisted(row["domain"]):
+ logger.debug("row[domain]='%s' is blacklisted - SKIPPED!", row["domain"])
+ continue
+ elif blocks.is_instance_blocked(row["domain"], blocked):
+ logger.debug("blocked='%s' is already blocked by domain='%s' - SKIPPED!", blocked, row["domain"])
+ continue
block["block_level"] = blocks.alias_block_level(block["block_level"])