[metadata]
creation_date = "2020/11/19"
maturity = "production"
updated_date = "2020/11/19"

[rule]
author = ["Elastic"]
description = """
Identifies suspicious Image Loading of the Remote Desktop Services ActiveX Client (mstscax), this may indicate the presence
of RDP lateral movement capability.
"""
from = "now-9m"
index = ["logs-endpoint.events.*", "winlogbeat-*"]
language = "eql"
license = "Elastic License"
name = "Suspicious RDP ActiveX Client Loaded"
references = ["https://posts.specterops.io/revisiting-remote-desktop-lateral-movement-8fb905cb46c3"]
risk_score = 47
rule_id = "71c5cb27-eca5-4151-bb47-64bc3f883270"
severity = "medium"
tags = ["Elastic", "Host", "Windows", "Threat Detection", "Lateral Movement"]
type = "eql"

query = '''
library where file.name == "mstscax.dll" and
   /* depending on noise in your env add here extra paths  */
   wildcard(process.executable, "C:\\Windows\\*",
                                "C:\\Users\\Public\\*",
                                "C:\\Users\\Default\\*",
                                "C:\\Intel\\*",
                                "C:\\PerfLogs\\*",
                                "C:\\ProgramData\\*",
                                "\\Device\\Mup\\*",
                                "\\\\*") and
    /* add here FPs */
   not process.executable in ("C:\\Windows\\System32\\mstsc.exe", "C:\\Windows\\SysWOW64\\mstsc.exe")
'''


[[rule.threat]]
framework = "MITRE ATT&CK"
[[rule.threat.technique]]
id = "T1021"
name = "Remote Services"
reference = "https://attack.mitre.org/techniques/T1021/"


[rule.threat.tactic]
id = "TA0008"
name = "Lateral Movement"
reference = "https://attack.mitre.org/tactics/TA0008/"
