import ipaddress


def rule(event):
    if not any(
        [
            ipaddress.ip_address(event.deep_get("id", "orig_h", default=""))
            in ipaddress.ip_network("::1/128"),
            ipaddress.ip_address(event.deep_get("id", "orig_h", default=""))
            in ipaddress.ip_network("10.0.0.0/8"),
            ipaddress.ip_address(event.deep_get("id", "orig_h", default=""))
            in ipaddress.ip_network("127.0.0.0/8"),
            ipaddress.ip_address(event.deep_get("id", "orig_h", default=""))
            in ipaddress.ip_network("172.16.0.0/12"),
            ipaddress.ip_address(event.deep_get("id", "orig_h", default=""))
            in ipaddress.ip_network("192.168.0.0/16"),
            ipaddress.ip_address(event.deep_get("id", "orig_h", default=""))
            in ipaddress.ip_network("169.254.0.0/16"),
            ipaddress.ip_address(event.deep_get("id", "orig_h", default=""))
            in ipaddress.ip_network("2620:83:8000::/48"),
            ipaddress.ip_address(event.deep_get("id", "orig_h", default=""))
            in ipaddress.ip_network("fc00::/7"),
            ipaddress.ip_address(event.deep_get("id", "orig_h", default=""))
            in ipaddress.ip_network("fe80::/10"),
        ]
    ):
        return True
    return False
