Detection rules › Splunk
Hidden User Created - Windows (Sysmon)
Adversaries may hide user accounts in Windows by setting the HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon\SpecialAccounts\UserList Registry key value to 0 for a specific user to prevent that user from being listed on the logon screen
MITRE ATT&CK coverage
| Tactic | Techniques |
|---|---|
| Stealth | T1564.002 Hide Artifacts: Hidden Users |
References
Event coverage
| Provider | Event | Title |
|---|---|---|
| Sysmon | Event ID 1 | Process creation |
| Sysmon | Event ID 12 | RegistryEvent (Object create and delete) |
| Sysmon | Event ID 13 | RegistryEvent (Value Set) |
Rule body yaml
id: '13615.19725'
title: Hidden User Created - Windows
description: 'Adversaries may hide user accounts in Windows by setting the HKLM\SOFTWARE\Microsoft\Windows
NT\CurrentVersion\Winlogon\SpecialAccounts\UserList Registry key value to 0 for
a specific user to prevent that user from being listed on the logon screen. -- Threat
Actor Association: Unfading Sea Haze - Software Association: Dagon Locker, IcedID
-- Atomics T1564.002 Test #3'
logic_format: Splunk
logic: '`get_endpoint_data` `get_endpoint_data_sysmon` (TERM(EventCode=1) OR "<EventID>1<"
OR TERM(EventCode=12) OR "<EventID>12<" OR TERM(EventCode=13) OR "<EventID>13<")
(TERM(ADD) AND "UserList" AND "/d" AND "0") OR (HKLM\Software\Microsoft\Windows
NT\CurrentVersion\Winlogon\SpecialAccounts\Userlist) | table _time, host, user signature_id,
process, process_*, parent_*, signature, user_id | bin span=1s | stats values(*)
as * by _time, host | where match(process, "(?i)(\s+ADD\s+.*\/d.*0)") OR match(signature_id,
"12") OR match(signature_id, "13") '
techniques:
- defense-evasion:hide artifacts:hidden users
- defense-evasion:hide artifacts
technique_id:
- T1564.002
- T1564
data_category:
- Process command-line parameters
- Windows Sysmon
references:
- https://thedfirreport.com/2022/07/11/select-xmrig-from-sqlserver/
- https://github.com/redcanaryco/atomic-red-team/blob/master/atomics/T1564.002/T1564.002.md#atomic-test-3---create-hidden-user-in-registry
Stages and Predicates
Stage 1: search
`get_endpoint_data` `get_endpoint_data_sysmon` (TERM(EventCode=1) OR "<EventID>1<" OR TERM(EventCode=12) OR "<EventID>12<" OR TERM(EventCode=13) OR "<EventID>13<") (TERM(ADD) AND "UserList" AND "/d" AND "0") OR (HKLM\Software\Microsoft\Windows NT\CurrentVersion\Winlogon\SpecialAccounts\Userlist)
Stage 2: table
| table _time, host, user signature_id, process, process_*, parent_*, signature, user_id
Stage 3: bucket
| bin span=1s
Stage 4: stats
| stats values(*) as * by _time, host
Stage 5: where
| where match(process, "(?i)(\s+ADD\s+.*\/d.*0)") OR match(signature_id, "12") OR match(signature_id, "13")
Indicators
Each row is a field, operator, and value that the rule matches. The corpus column counts how many other rules in the catalog look for the same combination: high numbers point to widely-used, community-vetted indicators. Blank or 1 shows that the indicator is specific to this rule.
| Field | Kind | Values |
|---|---|---|
EventCode | eq |
|
process | match |
|
signature_id | match |
|
Search terms
Bare-string tokens in the SPL search body. Splunk matches each token against _raw (the untyped raw event text) anywhere it appears, not against a specific field. These don't surface in the Indicators table because they aren't predicates on a known field.
| Stage | Term |
|---|---|
| 1 | TERM |
| 1 | "<EventID>1<" |
| 1 | TERM |
| 1 | "<EventID>12<" |
| 1 | TERM |
| 1 | "<EventID>13<" |
| 1 | TERM |
| 1 | ADD |
| 1 | "UserList" |
| 1 | "/d" |
| 1 | "0" |
| 1 | HKLM\Software\Microsoft\Windows |
| 1 | NT\CurrentVersion\Winlogon\SpecialAccounts\Userlist |