Unusual File Modification by dns.exe
Identifies an unexpected file being modified by dns.exe, the process responsible for Windows DNS Server services, which may indicate activity related to remote code execution or other forms of exploitation.
Elastic rule (View on GitHub)
1[metadata]
2creation_date = "2020/07/16"
3integration = ["endpoint", "windows"]
4maturity = "production"
5updated_date = "2024/10/15"
6min_stack_version = "8.14.0"
7min_stack_comments = "Breaking change at 8.14.0 for the Windows Integration."
8
9[rule]
10author = ["Elastic"]
11description = """
12Identifies an unexpected file being modified by dns.exe, the process responsible for Windows DNS Server services, which
13may indicate activity related to remote code execution or other forms of exploitation.
14"""
15from = "now-9m"
16index = ["winlogbeat-*", "logs-endpoint.events.file-*", "logs-windows.sysmon_operational-*", "endgame-*"]
17language = "eql"
18license = "Elastic License v2"
19name = "Unusual File Modification by dns.exe"
20note = """## Triage and analysis
21
22### Investigating Unusual File Write
23Detection alerts from this rule indicate potential unusual/abnormal file writes from the DNS Server service process (`dns.exe`) after exploitation from CVE-2020-1350 (SigRed) has occurred. Here are some possible avenues of investigation:
24- Post-exploitation, adversaries may write additional files or payloads to the system as additional discovery/exploitation/persistence mechanisms.
25- Any suspicious or abnormal files written from `dns.exe` should be reviewed and investigated with care.
26"""
27references = [
28 "https://research.checkpoint.com/2020/resolving-your-way-into-domain-admin-exploiting-a-17-year-old-bug-in-windows-dns-servers/",
29 "https://msrc-blog.microsoft.com/2020/07/14/july-2020-security-update-cve-2020-1350-vulnerability-in-windows-domain-name-system-dns-server/",
30 "https://www.elastic.co/security-labs/detection-rules-for-sigred-vulnerability",
31]
32risk_score = 73
33rule_id = "c7ce36c0-32ff-4f9a-bfc2-dcb242bf99f9"
34severity = "high"
35tags = [
36 "Domain: Endpoint",
37 "OS: Windows",
38 "Use Case: Threat Detection",
39 "Tactic: Lateral Movement",
40 "Data Source: Elastic Endgame",
41 "Use Case: Vulnerability",
42 "Data Source: Elastic Defend",
43 "Data Source: Sysmon",
44]
45timestamp_override = "event.ingested"
46type = "eql"
47
48query = '''
49file where host.os.type == "windows" and process.name : "dns.exe" and event.type in ("creation", "deletion", "change") and
50 not file.name : "dns.log" and not
51 (file.extension : ("old", "temp", "bak", "dns", "arpa") and file.path : "C:\\Windows\\System32\\dns\\*") and
52
53 /* DNS logs with custom names, header converts to "DNS Server log" */
54 not ?file.Ext.header_bytes : "444e5320536572766572206c6f67*"
55'''
56
57
58[[rule.threat]]
59framework = "MITRE ATT&CK"
60[[rule.threat.technique]]
61id = "T1210"
62name = "Exploitation of Remote Services"
63reference = "https://attack.mitre.org/techniques/T1210/"
64
65
66[rule.threat.tactic]
67id = "TA0008"
68name = "Lateral Movement"
69reference = "https://attack.mitre.org/tactics/TA0008/"
Triage and analysis
Investigating Unusual File Write
Detection alerts from this rule indicate potential unusual/abnormal file writes from the DNS Server service process (dns.exe
) after exploitation from CVE-2020-1350 (SigRed) has occurred. Here are some possible avenues of investigation:
- Post-exploitation, adversaries may write additional files or payloads to the system as additional discovery/exploitation/persistence mechanisms.
- Any suspicious or abnormal files written from
dns.exe
should be reviewed and investigated with care.
References
Related rules
- Microsoft Exchange Server UM Writing Suspicious Files
- Lateral Movement via Startup Folder
- Local Account TokenFilter Policy Disabled
- NullSessionPipe Registry Modification
- Potential Remote Desktop Shadowing Activity