def rule(event):
    if all(
        [
            "Disable-WindowsOptionalFeature" in event.deep_get("ScriptBlockText", default=""),
            "-Online" in event.deep_get("ScriptBlockText", default=""),
            "-FeatureName" in event.deep_get("ScriptBlockText", default=""),
            any(
                [
                    "Windows-Defender-Gui" in event.deep_get("ScriptBlockText", default=""),
                    "Windows-Defender-Features" in event.deep_get("ScriptBlockText", default=""),
                    "Windows-Defender" in event.deep_get("ScriptBlockText", default=""),
                    "Windows-Defender-ApplicationGuard"
                    in event.deep_get("ScriptBlockText", default=""),
                ]
            ),
        ]
    ):
        return True
    return False
