def rule(event):
    if all(
        [
            any(
                [
                    all(
                        [
                            event.deep_get("Image", default="").endswith("\\reg.exe"),
                            "query" in event.deep_get("CommandLine", default=""),
                            any(
                                [
                                    "-v" in event.deep_get("CommandLine", default=""),
                                    "/v" in event.deep_get("CommandLine", default=""),
                                    "–v" in event.deep_get("CommandLine", default=""),
                                    "—v" in event.deep_get("CommandLine", default=""),
                                    "―v" in event.deep_get("CommandLine", default=""),
                                ]
                            ),
                        ]
                    ),
                    all(
                        [
                            any(
                                [
                                    event.deep_get("Image", default="").endswith(
                                        "\\powershell.exe"
                                    ),
                                    event.deep_get("Image", default="").endswith("\\pwsh.exe"),
                                ]
                            ),
                            any(
                                [
                                    "Get-ItemPropertyValue"
                                    in event.deep_get("CommandLine", default=""),
                                    "gpv" in event.deep_get("CommandLine", default=""),
                                ]
                            ),
                        ]
                    ),
                ]
            ),
            any(
                [
                    "\\SOFTWARE\\Microsoft\\Windows Defender"
                    in event.deep_get("CommandLine", default=""),
                    "\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion"
                    in event.deep_get("CommandLine", default=""),
                    "\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Uninstall"
                    in event.deep_get("CommandLine", default=""),
                    "\\SYSTEM\\CurrentControlSet\\Control\\TimeZoneInformation"
                    in event.deep_get("CommandLine", default=""),
                    "\\SYSTEM\\CurrentControlSet\\Services"
                    in event.deep_get("CommandLine", default=""),
                ]
            ),
        ]
    ):
        return True
    return False
