T1087.001
Local Account
Adversaries may attempt to get a listing of local system accounts to aid in follow-on behavior such as privilege escalation, lateral movement, or credential access. On Windows, commands such as net user and net localgroup are commonly used. On Linux and macOS, commands such as id, groups, cat /etc/passwd, and dscl . list /Users enumerate local accounts. On ESXi, esxcli system account list retrieves local accounts. This information helps adversaries understand the account landscape, identify high-value targets like local administrators, and plan further attack steps.
Microsoft Sentinel / Defender
kusto
let AccountEnumCommands = dynamic([
"net user", "net localgroup", "net accounts",
"Get-LocalUser", "Get-LocalGroup", "Get-LocalGroupMember",
"query user", "query session",
"wmic useraccount", "wmic path win32_useraccount",
"dsquery user", "lusrmgr"
]);
DeviceProcessEvents
| where Timestamp > ago(24h)
| where (
(FileName =~ "net.exe" or FileName =~ "net1.exe") and
(ProcessCommandLine has "user" or ProcessCommandLine has "localgroup" or ProcessCommandLine has "accounts")
) or
(
FileName =~ "powershell.exe" and
ProcessCommandLine has_any ("Get-LocalUser", "Get-LocalGroup", "Get-LocalGroupMember", "Get-WmiObject Win32_UserAccount", "Get-CimInstance Win32_UserAccount")
) or
(
FileName =~ "wmic.exe" and
(ProcessCommandLine has "useraccount" or ProcessCommandLine has "win32_useraccount")
) or
(
FileName =~ "query.exe" and
(ProcessCommandLine has "user" or ProcessCommandLine has "session")
)
| extend EnumerationMethod = case(
FileName =~ "net.exe" or FileName =~ "net1.exe", "net.exe/net1.exe",
FileName =~ "powershell.exe", "PowerShell Cmdlet",
FileName =~ "wmic.exe", "WMIC",
FileName =~ "query.exe", "query.exe",
"Other"
)
| extend IsSuspiciousParent = InitiatingProcessFileName in~ (
"cmd.exe", "powershell.exe", "pwsh.exe", "wscript.exe", "cscript.exe",
"mshta.exe", "rundll32.exe", "regsvr32.exe", "svchost.exe"
)
| project Timestamp, DeviceName, AccountName, FileName, ProcessCommandLine,
InitiatingProcessFileName, InitiatingProcessCommandLine,
EnumerationMethod, IsSuspiciousParent
| sort by Timestamp desc medium severity
high confidence
Data Sources
Process: Process Creation Command: Command Execution Microsoft Defender for Endpoint
Required Tables
DeviceProcessEvents
False Positives
- IT administrators running net user or net localgroup for routine account auditing and inventory
- Security monitoring tools and vulnerability scanners (Tenable, Qualys, CrowdStrike) that enumerate accounts during assessments
- Software installation and configuration management tools (SCCM, Ansible, Puppet) that validate account configurations
- Helpdesk personnel running query user to check active sessions before performing maintenance
- User provisioning automation scripts that verify account existence before creating or modifying accounts
Last updated: 2026-04-13 Research depth: deep
References (14)
- https://attack.mitre.org/techniques/T1087/001/
- https://linux.die.net/man/1/id
- https://linux.die.net/man/1/groups
- https://www.fireeye.com/content/dam/fireeye-www/services/pdfs/mandiant-apt1-report.pdf
- https://www.crowdstrike.com/en-us/blog/hypervisor-jackpotting-ecrime-actors-increase-targeting-of-esxi-servers/
- https://www.elastic.co/security-labs/embracing-offensive-tooling-building-detections-against-koadic-using-eql
- https://learn.microsoft.com/en-us/windows-server/administration/windows-commands/net-user
- https://learn.microsoft.com/en-us/windows/security/threat-protection/auditing/event-4798
- https://learn.microsoft.com/en-us/windows/security/threat-protection/auditing/event-4799
- https://github.com/redcanaryco/atomic-red-team/blob/master/atomics/T1087.001/T1087.001.md
- https://github.com/SigmaHQ/sigma/tree/master/rules/windows/process_creation
- https://www.trendmicro.com/en_us/research/20/e/tropic-trooper-s-back-usbferry-attack-targets-air-gapped-environments.html
- https://symantec-enterprise-blogs.security.com/blogs/threat-intelligence/orangeworm-targets-healthcare-us-europe-asia
- https://www.mandiant.com/resources/operation-ke3chang-targeted-attacks-against-ministries-of-foreign-affairs
Unlock Pro Content
Get the full detection package for T1087.001 including response playbook, investigation guide, and atomic red team tests.
Response PlaybookInvestigation GuideHunting QueriesAtomic Red Team TestsTuning Guidance