def rule(event):
    if all(
        [
            any(
                [
                    event.deep_get("TargetFilename", default="").endswith(".cpl"),
                    event.deep_get("TargetFilename", default="").endswith(".hta"),
                    event.deep_get("TargetFilename", default="").endswith(".iso"),
                    event.deep_get("TargetFilename", default="").endswith(".rdp"),
                    event.deep_get("TargetFilename", default="").endswith(".svg"),
                    event.deep_get("TargetFilename", default="").endswith(".vba"),
                    event.deep_get("TargetFilename", default="").endswith(".vbe"),
                    event.deep_get("TargetFilename", default="").endswith(".vbs"),
                ]
            ),
            any(
                [
                    any(
                        [
                            "\\AppData\\Local\\Packages\\Microsoft.Outlook_"
                            in event.deep_get("TargetFilename", default=""),
                            "\\AppData\\Local\\Microsoft\\Olk\\Attachments\\"
                            in event.deep_get("TargetFilename", default=""),
                        ]
                    ),
                    all(
                        [
                            "\\AppData\\Local\\Microsoft\\Windows\\"
                            in event.deep_get("TargetFilename", default=""),
                            "\\Content.Outlook\\" in event.deep_get("TargetFilename", default=""),
                        ]
                    ),
                ]
            ),
        ]
    ):
        return True
    return False
