Password policy was checked. SubjectUserName and Workstation are key.
Password spraying tools may call this API to determine password policies (lockout threshold, complexity) before launching spray attacks.
Alert: high volume calls from non-domain-joined or unexpected hosts. Unusual process making calls outside of normal admin tools.
SubjectUserNameTargetUserNameLogonTypeIpAddressWorkstationName | Tactic | Technique |
|---|---|
| Credential Access | Password Policy Discovery (T1201) |
Starting points — adapt the log source, projected fields and thresholds for your environment.
SecurityEvent
| where EventID == 4793 // The Password Policy Checking API was called
| project TimeGenerated, Computer, SubjectUserName, TargetUserName, LogonType, IpAddress, WorkstationName
| sort by TimeGenerated desc
index=* sourcetype="WinEventLog:Security" EventCode=4793
| stats count earliest(_time) as first_seen latest(_time) as last_seen by ComputerName
| sort - count `# The Password Policy Checking API was called — add EventData fields: SubjectUserName, TargetUserName, LogonType, IpAddress`
The Password Policy Checking API was called. Password policy was checked. SubjectUserName and Workstation are key.
Event 4793 is written to the Security channel by Microsoft-Windows-Security-Auditing. Advanced Audit Policy — enable the 'Account Management' subcategory (Success and/or Failure).
Event 4793 is associated with: Password Policy Discovery (T1201).
Alert: high volume calls from non-domain-joined or unexpected hosts. Unusual process making calls outside of normal admin tools.