|
| 1 | +[metadata] |
| 2 | +creation_date = "2022/05/11" |
| 3 | +maturity = "production" |
| 4 | +updated_date = "2022/05/11" |
| 5 | + |
| 6 | +[rule] |
| 7 | +author = ["Elastic"] |
| 8 | +description = """ |
| 9 | +Identifies the remote update to a computer account's DnsHostName attribute. If the new value set is a valid domain |
| 10 | +controller DNS hostname and the subject computer name is not a domain controller, then it's highly likely a preparation |
| 11 | +step to exploit CVE-2022-26923 in an attempt to elevate privileges from a standard domain user to domain admin privileges. |
| 12 | +""" |
| 13 | +from = "now-9m" |
| 14 | +index = ["winlogbeat-*", "logs-system.*"] |
| 15 | +language = "eql" |
| 16 | +license = "Elastic License v2" |
| 17 | +name = "Remote Computer Account DnsHostName Update" |
| 18 | +references = [ |
| 19 | + "https://research.ifcr.dk/certifried-active-directory-domain-privilege-escalation-cve-2022-26923-9e098fe298f4", |
| 20 | + "https://portal.msrc.microsoft.com/en-US/security-guidance/advisory/CVE-2022-26923", |
| 21 | +] |
| 22 | +risk_score = 73 |
| 23 | +rule_id = "6bed021a-0afb-461c-acbe-ffdb9574d3f3" |
| 24 | +severity = "high" |
| 25 | +tags = ["Elastic", "Host", "Windows", "Threat Detection", "Privilege Escalation", "Active Directory"] |
| 26 | +type = "eql" |
| 27 | + |
| 28 | +query = ''' |
| 29 | +sequence by host.id with maxspan=5m |
| 30 | +
|
| 31 | + [authentication where event.action == "logged-in" and |
| 32 | + winlog.logon.type == "Network" and event.outcome == "success" and |
| 33 | + not user.name == "ANONYMOUS LOGON" and not winlog.event_data.SubjectUserName : "*$" and |
| 34 | + not user.domain == "NT AUTHORITY" and source.ip != "127.0.0.1" and source.ip !="::1"] by winlog.event_data.TargetLogonId |
| 35 | +
|
| 36 | + [iam where event.action == "changed-computer-account" and |
| 37 | +
|
| 38 | + /* if DnsHostName value equal a DC DNS hostname then it's highly suspicious */ |
| 39 | + winlog.event_data.DnsHostName : "??*"] by winlog.event_data.SubjectLogonId |
| 40 | +''' |
| 41 | + |
| 42 | + |
| 43 | +[[rule.threat]] |
| 44 | +framework = "MITRE ATT&CK" |
| 45 | +[[rule.threat.technique]] |
| 46 | +id = "T1068" |
| 47 | +name = "Exploitation for Privilege Escalation" |
| 48 | +reference = "https://attack.mitre.org/techniques/T1068/" |
| 49 | + |
| 50 | +[[rule.threat.technique]] |
| 51 | +id = "T1078" |
| 52 | +name = "Valid Accounts" |
| 53 | +reference = "https://attack.mitre.org/techniques/T1078/" |
| 54 | +[[rule.threat.technique.subtechnique]] |
| 55 | +id = "T1078.002" |
| 56 | +name = "Domain Accounts" |
| 57 | +reference = "https://attack.mitre.org/techniques/T1078/002/" |
| 58 | + |
| 59 | + |
| 60 | + |
| 61 | +[rule.threat.tactic] |
| 62 | +id = "TA0004" |
| 63 | +name = "Privilege Escalation" |
| 64 | +reference = "https://attack.mitre.org/tactics/TA0004/" |
| 65 | + |
0 commit comments