T1078.003 Splunk · SPL

Detect Local Accounts in Splunk

Adversaries may obtain and abuse credentials of a local account as a means of gaining Initial Access, Persistence, Privilege Escalation, or Defense Evasion. Local accounts are those configured by an organization for use by users, remote support, services, or for administration on a single system or service. Adversaries may target dormant local accounts, brute-force local admin credentials, create new local accounts, or reuse harvested credentials across multiple systems. This technique is commonly observed in ransomware operations, APT lateral movement, and post-exploitation frameworks such as Cobalt Strike.

MITRE ATT&CK

Tactic
Defense Evasion Persistence Privilege Escalation Initial Access
Technique
T1078 Valid Accounts
Sub-technique
T1078.003 Local Accounts
Canonical reference
https://attack.mitre.org/techniques/T1078/003/

SPL Detection Query

Splunk (SPL)
spl
| union
[
  search index=wineventlog sourcetype="WinEventLog:Security" (EventCode=4720 OR EventCode=4722 OR EventCode=4732 OR EventCode=4624 OR EventCode=4625 OR EventCode=4648)
]
| eval TargetDomainName=coalesce(TargetDomainName, Target_Domain_Name, "")
| eval Computer=coalesce(ComputerName, host)
| eval TargetUserName=coalesce(TargetUserName, Target_Account_Name, "")
| eval SubjectUserName=coalesce(SubjectUserName, Subject_Account_Name, "")
| eval LogonType=coalesce(LogonType, Logon_Type, "")
| eval IpAddress=coalesce(IpAddress, Source_Network_Address, "")
// Determine if account is local (domain matches computer name or is ".")
| eval IsLocalAccount=if(TargetDomainName="." OR lower(TargetDomainName)=lower(Computer) OR TargetDomainName="", 1, 0)
| where IsLocalAccount=1
// Filter built-in noise
| where NOT (TargetUserName IN ("ANONYMOUS LOGON","LOCAL SERVICE","NETWORK SERVICE","SYSTEM","DWM-1","DWM-2","DWM-3","UMFD-0","UMFD-1") OR TargetUserName="")
// Classify events
| eval EventType=case(
    EventCode=4720, "LocalAccountCreated",
    EventCode=4722, "LocalAccountEnabled",
    EventCode=4732, "AddedToAdministrators",
    EventCode=4624 AND (LogonType="3" OR LogonType="10") AND NOT (IpAddress="127.0.0.1" OR IpAddress="::1" OR IpAddress="-"), "NetworkLogonLocalAccount",
    EventCode=4625, "FailedLogonLocalAccount",
    EventCode=4648, "ExplicitCredentialUseLocalAccount",
    true(), "OtherLocalAccountEvent"
)
| where EventType!="OtherLocalAccountEvent"
// Assign risk scores
| eval RiskScore=case(
    EventCode=4720, 3,
    EventCode=4722, 2,
    EventCode=4732, 4,
    EventCode=4624, 2,
    EventCode=4625, 1,
    EventCode=4648, 3,
    true(), 1
)
// Detect brute force: 10+ failures per host per 10-minute window
| eval _timebucket=strftime(round(_time/600)*600, "%Y-%m-%dT%H:%M:%S")
| eventstats count(eval(EventCode=4625)) AS FailCount by Computer, _timebucket
| eval RiskScore=if(EventCode=4625 AND FailCount>=10, 5, RiskScore)
| eval EventType=if(EventCode=4625 AND FailCount>=10, "BruteForceLocalAccount", EventType)
| table _time, Computer, EventType, EventCode, RiskScore, TargetUserName, SubjectUserName, LogonType, IpAddress, FailCount
| sort - _time - RiskScore
high severity medium confidence

Detects suspicious local account activity using Windows Security Event logs in Splunk. Classifies events by type (creation, enabling, group addition, network logon, brute force, explicit credential use) and assigns risk scores. Identifies local accounts by matching TargetDomainName to the computer name or '.' (local machine indicator). Includes brute-force detection via event counting in rolling 10-minute windows. Filters known service identities and loopback addresses to reduce noise.

Data Sources

Logon: LogonUser Account: User Account CreationUser Account: User Account ModificationWindows Security Event Log

Required Sourcetypes

WinEventLog:Security

False Positives & Tuning

  • IT helpdesk creating local accounts for break-glass or emergency access scenarios (expected during documented maintenance windows)
  • Software installation procedures that create local service accounts (e.g., SQL Server, antivirus agents, monitoring tools installing their own local accounts)
  • Remote management tools (e.g., LAPS, PDQ Deploy, SCCM) authenticating to endpoints using the local administrator account for legitimate patching or management tasks
  • Developers or QA engineers logging into test machines with local credentials instead of domain accounts
  • Backup agents or monitoring services that authenticate via local accounts from internal management servers
Download portable Sigma rule (.yml)

Other platforms for T1078.003


Testing Methodology

Validate this detection against 5 adversary techniques from Atomic Red Team. Each test below lists the behaviour to exercise and the telemetry you should expect to see. Executable commands and cleanup steps are available with Pro.

  1. Test 1Create Backdoor Local Admin Account

    Expected signal: Security EventID 4720: New local account 'argus_test_backdoor' created (TargetDomainName will match ComputerName). Security EventID 4732: Account added to Administrators group (TargetUserName=Administrators). Security EventID 4722: Account enabled. Process creation events for net.exe and net1.exe (Sysmon EventID 1 or Security EventID 4688).

  2. Test 2Brute Force Local Administrator Account

    Expected signal: 15x Security EventID 4625 (logon failure) with TargetUserName=Administrator, LogonType=3, IpAddress=127.0.0.1. Failure reason 0xC000006D (wrong password) or 0xC000006A. SubStatus 0xC0000064 or 0xC000006A. Events will appear in rapid succession within a 1-minute window.

  3. Test 3Pass-the-Hash Style Lateral Movement Using Local Account Credentials

    Expected signal: Security EventID 4648 (explicit credentials used) on the initiating host with TargetUserName=Administrator, TargetDomainName=<COMPUTERNAME>. Security EventID 4624 (LogonType=3) on the target with TargetUserName=Administrator, TargetDomainName=<COMPUTERNAME>, IpAddress of initiating host. Sysmon EventID 3: network connection to destination port 445.

  4. Test 4Enable and Use Disabled Built-in Administrator Account via Registry

    Expected signal: Security EventID 4722 (local account enabled) with TargetUserName=Administrator. Security EventID 4723 or 4724 (password change/reset) for the Administrator account. Process creation events for net.exe (Sysmon EventID 1). If the account is then used for logon, EventID 4624 with TargetUserName=Administrator and LogonType matching the access method.

  5. Test 5Linux Local Account Abuse — Create Privileged User and Switch Context

    Expected signal: Syslog/auth.log: useradd command execution, new user creation entry. /var/log/auth.log or /var/log/secure: PAM authentication events for su session. auditd (if configured): syscall audit records for useradd (execve), usermod (execve), write to /etc/passwd and /etc/shadow. Sysmon for Linux (if deployed): process creation events for useradd, usermod, chpasswd, su.

Unlock Pro Content

Get the full detection package for T1078.003 including response playbook, investigation guide, and atomic red team tests.

Response PlaybookInvestigation GuideHunting QueriesAtomic Red Team TestsTuning Guidance

Related Detections