def rule(event):
    if all(
        [
            ":\\Windows\\System32\\CodeIntegrity\\" in event.deep_get("TargetFilename", default=""),
            any(
                [
                    event.deep_get("TargetFilename", default="").endswith(".cip"),
                    event.deep_get("TargetFilename", default="").endswith(".p7b"),
                ]
            ),
            event.deep_get("IntegrityLevel", default="") == "High",
        ]
    ):
        return True
    return False
