def rule(event):
    if all(
        [
            any(
                [
                    event.deep_get("TargetFilename", default="").endswith("WsmPty.xsl"),
                    event.deep_get("TargetFilename", default="").endswith("WsmTxt.xsl"),
                ]
            ),
            not any(
                [
                    event.deep_get("TargetFilename", default="").startswith(
                        "C:\\Windows\\System32\\"
                    ),
                    event.deep_get("TargetFilename", default="").startswith(
                        "C:\\Windows\\SysWOW64\\"
                    ),
                ]
            ),
        ]
    ):
        return True
    return False
