[metadata] creation_date = "2022/09/01" maturity = "production" min_stack_comments = "New fields added: required_fields, related_integrations, setup" min_stack_version = "8.3.0" updated_date = "2022/09/01" [rule] author = ["Elastic"] description = """ Identifies the manual reading of the /etc/shadow file via the commandline using standard system utilities. Threat actors will attempt to read this file, after elevating their privileges to root, in order to gain valid credentials they can utilize to move laterally undetected and access additional resources. """ from = "now-9m" index = ["auditbeat-*", "logs-endpoint.events.*"] language = "eql" license = "Elastic License v2" name = "Shadow File Read via Command Line Utilities" risk_score = 47 rule_id = "9a3a3689-8ed1-4cdb-83fb-9506db54c61f" severity = "medium" tags = ["Elastic", "Host", "Linux", "Threat Detection", "Privilege Escalation"] timestamp_override = "event.ingested" type = "eql" query = ''' process where event.type == "start" and event.action == "exec" and user.name == "root" and process.args : "/etc/shadow" and not process.executable: ("/usr/bin/find", "/usr/bin/cmp", "/bin/ls", "/usr/sbin/restorecon", "/usr/bin/uniq") and not process.parent.executable: "/bin/dracut" ''' [[rule.threat]] framework = "MITRE ATT&CK" [[rule.threat.technique]] id = "T1068" name = "Exploitation for Privilege Escalation" reference = "https://attack.mitre.org/techniques/T1068/" [rule.threat.tactic] id = "TA0004" name = "Privilege Escalation" reference = "https://attack.mitre.org/tactics/TA0004/"