|
| 1 | +name: Windows Suspicious Driver Loaded Path |
| 2 | +id: 2ca1c4a1-8342-4750-9363-905650e0c933 |
| 3 | +version: 1 |
| 4 | +date: '2025-02-03' |
| 5 | +author: Teoderick Contreras, Splunk |
| 6 | +status: production |
| 7 | +type: TTP |
| 8 | +description: The following analytic detects the loading of drivers from suspicious |
| 9 | + paths, which is a technique often used by malicious software such as coin miners |
| 10 | + (e.g., xmrig). It leverages Sysmon EventCode 6 to identify drivers loaded from non-standard |
| 11 | + directories. This activity is significant because legitimate drivers typically reside |
| 12 | + in specific system directories, and deviations may indicate malicious activity. |
| 13 | + If confirmed malicious, this could allow an attacker to execute code at the kernel |
| 14 | + level, potentially leading to privilege escalation, persistence, or further system |
| 15 | + compromise. |
| 16 | +data_source: |
| 17 | +- Sysmon EventID 6 |
| 18 | +search: '`sysmon` EventCode=6 ImageLoaded = "*.sys" NOT (ImageLoaded IN("*\\WINDOWS\\inf","*\\WINDOWS\\System32\\drivers\\*", |
| 19 | + "*\\WINDOWS\\System32\\DriverStore\\FileRepository\\*","*:\Windows\\WinSxS\\*","*\\ProgramData\\Microsoft\\Windows Defender\\Definition Updates\\*")) | stats min(_time) as |
| 20 | + firstTime max(_time) as lastTime count by dest ImageLoaded Hashes IMPHASH Signature |
| 21 | + Signed| rename ImageLoaded as file_name | `security_content_ctime(firstTime)` | |
| 22 | + `security_content_ctime(lastTime)` | `windows_suspicious_driver_loaded_path_filter`' |
| 23 | +how_to_implement: To successfully implement this search, you need to be ingesting |
| 24 | + logs with the driver loaded and Signature from your endpoints. If you are using |
| 25 | + Sysmon, you must have at least version 6.0.4 of the Sysmon TA. |
| 26 | +known_false_positives: Limited false positives will be present. Some applications |
| 27 | + do load drivers |
| 28 | +references: |
| 29 | +- https://www.trendmicro.com/vinfo/hk/threat-encyclopedia/malware/trojan.ps1.powtran.a/ |
| 30 | +- https://redcanary.com/blog/tracking-driver-inventory-to-expose-rootkits/ |
| 31 | +drilldown_searches: |
| 32 | +- name: View the detection results for - "$dest$" |
| 33 | + search: '%original_detection_search% | search dest = "$dest$"' |
| 34 | + earliest_offset: $info_min_time$ |
| 35 | + latest_offset: $info_max_time$ |
| 36 | +- name: View risk events for the last 7 days for - "$dest$" |
| 37 | + search: '| from datamodel Risk.All_Risk | search normalized_risk_object IN ("$dest$") |
| 38 | + starthoursago=168 | stats count min(_time) as firstTime max(_time) as lastTime |
| 39 | + values(search_name) as "Search Name" values(risk_message) as "Risk Message" values(analyticstories) |
| 40 | + as "Analytic Stories" values(annotations._all) as "Annotations" values(annotations.mitre_attack.mitre_tactic) |
| 41 | + as "ATT&CK Tactics" by normalized_risk_object | `security_content_ctime(firstTime)` |
| 42 | + | `security_content_ctime(lastTime)`' |
| 43 | + earliest_offset: $info_min_time$ |
| 44 | + latest_offset: $info_max_time$ |
| 45 | +rba: |
| 46 | + message: Suspicious driver $file_name$ on $dest$ |
| 47 | + risk_objects: |
| 48 | + - field: dest |
| 49 | + type: system |
| 50 | + score: 60 |
| 51 | + threat_objects: |
| 52 | + - field: file_name |
| 53 | + type: file_name |
| 54 | +tags: |
| 55 | + analytic_story: |
| 56 | + - XMRig |
| 57 | + - CISA AA22-320A |
| 58 | + - AgentTesla |
| 59 | + - BlackByte Ransomware |
| 60 | + - Snake Keylogger |
| 61 | + asset_type: Endpoint |
| 62 | + mitre_attack_id: |
| 63 | + - T1543.003 |
| 64 | + - T1543 |
| 65 | + product: |
| 66 | + - Splunk Enterprise |
| 67 | + - Splunk Enterprise Security |
| 68 | + - Splunk Cloud |
| 69 | + security_domain: endpoint |
| 70 | +tests: |
| 71 | +- name: True Positive Test |
| 72 | + attack_data: |
| 73 | + - data: |
| 74 | + https://media.githubusercontent.com/media/splunk/attack_data/master/datasets/malware/xmrig_miner/windows-sysmon.log |
| 75 | + source: XmlWinEventLog:Microsoft-Windows-Sysmon/Operational |
| 76 | + sourcetype: XmlWinEventLog |
0 commit comments