def rule(event):
    if any(
        [
            any(
                [
                    "\\TrolleyExpress 7" in event.deep_get("CommandLine", default=""),
                    "\\TrolleyExpress 8" in event.deep_get("CommandLine", default=""),
                    "\\TrolleyExpress 9" in event.deep_get("CommandLine", default=""),
                    "\\TrolleyExpress.exe 7" in event.deep_get("CommandLine", default=""),
                    "\\TrolleyExpress.exe 8" in event.deep_get("CommandLine", default=""),
                    "\\TrolleyExpress.exe 9" in event.deep_get("CommandLine", default=""),
                    "\\TrolleyExpress.exe -ma " in event.deep_get("CommandLine", default=""),
                ]
            ),
            all(
                [
                    event.deep_get("Image", default="").endswith("\\TrolleyExpress.exe"),
                    not any(
                        [
                            "CtxInstall" in event.deep_get("OriginalFileName", default=""),
                            event.deep_get("OriginalFileName", default="") == "",
                        ]
                    ),
                ]
            ),
        ]
    ):
        return True
    return False
