def rule(event):
    if all(
        [
            event.deep_get("ParentImage", default="").endswith("\\taskmgr.exe"),
            not any(
                [
                    event.deep_get("Image", default="").endswith(":\\Windows\\System32\\mmc.exe"),
                    event.deep_get("Image", default="").endswith(
                        ":\\Windows\\System32\\resmon.exe"
                    ),
                    event.deep_get("Image", default="").endswith(
                        ":\\Windows\\System32\\Taskmgr.exe"
                    ),
                ]
            ),
        ]
    ):
        return True
    return False
