created a new WAF script for powerful firewall (mybb plugin issue #142)

This commit is contained in:
ekultek 2017-11-14 12:53:54 -06:00
parent 55b1285809
commit 885fe2e43f

17
lib/firewall/powerful.py Normal file
View file

@ -0,0 +1,17 @@
import re
__item__ = "Powerful Firewall (MyBB plugin)"
def detect(content, **kwargs):
status = kwargs.get("status", None)
detection_schema = (
re.compile(r"Powerful Firewall", re.I),
re.compile(r"http(s)?...tiny.cc.powerful.firewall", re.I)
)
if status is not None:
if status == 403:
for detection in detection_schema:
if detection.search(content) is not None:
return True