Suspicious Print Spooler File Deletion

Detects deletion of print driver files by an unusual process. This may indicate a clean up attempt post successful privilege escalation via Print Spooler service related vulnerabilities.

Elastic rule (View on GitHub)

 1[metadata]
 2creation_date = "2021/07/06"
 3integration = ["endpoint", "windows"]
 4maturity = "production"
 5updated_date = "2024/05/21"
 6
 7[rule]
 8author = ["Elastic"]
 9description = """
10Detects deletion of print driver files by an unusual process. This may indicate a clean up attempt post successful
11privilege escalation via Print Spooler service related vulnerabilities.
12"""
13false_positives = [
14    """
15    Uninstall or manual deletion of a legitimate printing driver files. Verify the printer file metadata such as
16    manufacturer and signature information.
17    """,
18]
19from = "now-9m"
20index = ["winlogbeat-*", "logs-endpoint.events.file-*", "logs-windows.sysmon_operational-*", "endgame-*"]
21language = "eql"
22license = "Elastic License v2"
23name = "Suspicious Print Spooler File Deletion"
24references = ["https://msrc.microsoft.com/update-guide/vulnerability/CVE-2021-34527"]
25risk_score = 47
26rule_id = "c4818812-d44f-47be-aaef-4cfb2f9cc799"
27setup = """## Setup
28
29If enabling an EQL rule on a non-elastic-agent index (such as beats) for versions <8.2,
30events will not define `event.ingested` and default fallback for EQL rules was not added until version 8.2.
31Hence for this rule to work effectively, users will need to add a custom ingest pipeline to populate
32`event.ingested` to @timestamp.
33For more details on adding a custom ingest pipeline refer - https://www.elastic.co/guide/en/fleet/current/data-streams-pipeline-tutorial.html
34"""
35severity = "medium"
36tags = [
37    "Domain: Endpoint",
38    "OS: Windows",
39    "Use Case: Threat Detection",
40    "Tactic: Privilege Escalation",
41    "Data Source: Elastic Endgame",
42    "Use Case: Vulnerability",
43    "Data Source: Elastic Defend",
44    "Data Source: Sysmon",
45]
46timestamp_override = "event.ingested"
47type = "eql"
48
49query = '''
50file where host.os.type == "windows" and event.type : "deletion" and
51 not process.name : ("spoolsv.exe", "dllhost.exe", "explorer.exe") and
52 file.path : "?:\\Windows\\System32\\spool\\drivers\\x64\\3\\*.dll"
53'''
54
55
56[[rule.threat]]
57framework = "MITRE ATT&CK"
58[[rule.threat.technique]]
59id = "T1068"
60name = "Exploitation for Privilege Escalation"
61reference = "https://attack.mitre.org/techniques/T1068/"
62
63
64[rule.threat.tactic]
65id = "TA0004"
66name = "Privilege Escalation"
67reference = "https://attack.mitre.org/tactics/TA0004/"

References

Related rules

to-top