import json


def rule(event):
    if any(
        [
            "AccessDeniedException" in json.dumps(event.to_dict()),
            "CsrfException" in json.dumps(event.to_dict()),
            "InvalidCsrfTokenException" in json.dumps(event.to_dict()),
            "MissingCsrfTokenException" in json.dumps(event.to_dict()),
            "CookieTheftException" in json.dumps(event.to_dict()),
            "InvalidCookieException" in json.dumps(event.to_dict()),
            "RequestRejectedException" in json.dumps(event.to_dict()),
        ]
    ):
        return True
    return False
