Workstation unlocked. Off-hours unlocks on sensitive systems warrant review.
Alert on off-hours unlocks on server or admin workstations.
Alert: 4801 at unusual hours (2–5 AM) for sensitive workstations. Correlate with physical access logs.
SubjectUserNameTargetUserNameLogonTypeIpAddressWorkstationName Starting points — adapt the log source, projected fields and thresholds for your environment.
SecurityEvent
| where EventID == 4801 // The workstation was unlocked
| project TimeGenerated, Computer, SubjectUserName, TargetUserName, LogonType, IpAddress, WorkstationName
| sort by TimeGenerated desc
index=* sourcetype="WinEventLog:Security" EventCode=4801
| stats count earliest(_time) as first_seen latest(_time) as last_seen by ComputerName
| sort - count `# The workstation was unlocked — add EventData fields: SubjectUserName, TargetUserName, LogonType, IpAddress`
The workstation was unlocked. Workstation unlocked. Off-hours unlocks on sensitive systems warrant review.
Event 4801 is written to the Security channel by Microsoft-Windows-Security-Auditing. Advanced Audit Policy — enable the 'Logon/Logoff' subcategory (Success and/or Failure).
Alert: 4801 at unusual hours (2–5 AM) for sensitive workstations. Correlate with physical access logs.