extras/lambda_waf_domain_blacklist.py
Avoid deeply nested control flow statements. Open
Open
if re.search(regex, results[ip]) or results[ip] == dom:
print("Blocking IP "+ip+". Request from '"+results[ip]+"' matched blacklist entry. LB log was: "+key)
addIPToWAFBlacklist(ip)
return True