def rule(event):
    if all(
        [
            "SYSTEM\\" in event.deep_get("TargetObject", default=""),
            "ControlSet" in event.deep_get("TargetObject", default=""),
            "\\Control\\Lsa" in event.deep_get("TargetObject", default=""),
            any(
                [
                    all(
                        [
                            event.deep_get("TargetObject", default="").endswith(
                                "\\lmcompatibilitylevel"
                            ),
                            event.deep_get("Details", default="")
                            in ["DWORD (0x00000000)", "DWORD (0x00000001)", "DWORD (0x00000002)"],
                        ]
                    ),
                    all(
                        [
                            event.deep_get("TargetObject", default="").endswith(
                                "\\NtlmMinClientSec"
                            ),
                            event.deep_get("Details", default="")
                            in [
                                "DWORD (0x00000000)",
                                "DWORD (0x00000010)",
                                "DWORD (0x00000020)",
                                "DWORD (0x00000030)",
                            ],
                        ]
                    ),
                    event.deep_get("TargetObject", default="").endswith(
                        "\\RestrictSendingNTLMTraffic"
                    ),
                ]
            ),
        ]
    ):
        return True
    return False
