def rule(event):
    if all(
        [
            any(
                [
                    "\\Microsoft\\Windows\\CurrentVersion\\AppModelUnlock"
                    in event.deep_get("TargetObject", default=""),
                    "\\Policies\\Microsoft\\Windows\\Appx\\"
                    in event.deep_get("TargetObject", default=""),
                ]
            ),
            any(
                [
                    event.deep_get("TargetObject", default="").endswith("\\AllowAllTrustedApps"),
                    event.deep_get("TargetObject", default="").endswith(
                        "\\AllowDevelopmentWithoutDevLicense"
                    ),
                ]
            ),
            event.deep_get("Details", default="") == "DWORD (0x00000001)",
        ]
    ):
        return True
    return False
