Event ID 4625 is the Windows Security log entry for a failed logon. Every wrong password, every guess at a username that does not exist, every attempt to use a disabled account – each one writes a 4625. If your server faces the internet, Event ID 4625 is the most useful entry in the Security log, because a pattern of 4625s is what a brute-force attack looks like from the inside.
The event packs a lot of information into an intimidating wall of fields. This guide breaks down how to find these events, what each field means, and – the part most references skip – how to read the status codes and patterns that tell you whether you are looking at a typo or an attack.
Where to Find 4625 Events
Open Event Viewer > Windows Logs > Security, click Filter Current Log, and enter 4625 in the Event IDs box. Or pull the last 24 hours in PowerShell:
(Get-WinEvent -FilterHashtable @{LogName='Security'; Id=4625; StartTime=(Get-Date).AddHours(-24)} -ErrorAction SilentlyContinue | Measure-Object).Count
The -ErrorAction SilentlyContinue matters: without it, Get-WinEvent stops with “No events were found that match the specified selection criteria” when there are none, instead of printing 0.
Logon auditing, success and failure, is on by default on Windows Server and on Windows 10 version 1809 and later (Microsoft audit policy recommendations). So a count of 0 on a server usually means no failed sign-ins reached it, for example because Remote Desktop is not open to the internet. It can also mean someone changed the audit policy, often through Group Policy. To rule that out, run auditpol /get /subcategory:"Logon" and check that it reads “Success and Failure”. Our audit policy baseline covers the rest.
The Fields That Matter
A 4625 event has five fields that carry almost all of the meaning:
- Account Name (under “Account For Which Logon Failed”) – who the attempt was made against. Watch for “Administrator”, “admin”, and misspellings of real usernames.
- Source Network Address – the IP the attempt came from. An address you do not recognise changes the meaning of everything else.
- Logon Type – how the logon was attempted (table below).
- Status / Sub Status – the precise reason it failed (table below). This is where the real diagnosis lives.
- Workstation Name – the name of the machine that made the attempt. Attack tools often report generic or random names that match nothing in your office. Microsoft documents every field in its Event 4625 reference.
Logon Types: How They Tried to Get In
- Type 2 – Interactive. At the keyboard, physically or via console.
- Type 3 – Network. Access to a shared folder or service over the network. Also what many RDP attempts look like when NLA is enabled, since NLA authenticates before the session starts.
- Type 4 – Batch. Scheduled tasks.
- Type 5 – Service. A Windows service starting with stored credentials. Failures here usually mean a password changed and a service was not updated.
- Type 7 – Unlock. Wrong password at the lock screen.
- Type 8 – NetworkCleartext. Credentials sent in clear text – rare, worth investigating on sight.
- Type 10 – RemoteInteractive. A classic RDP logon attempt.
- Type 11 – CachedInteractive. Logon using cached domain credentials, typically a laptop away from the network.
For attack detection, types 3 and 10 from external IP addresses are the ones to watch: they are the signatures of brute-force attempts against RDP and network services.
Status Codes: Why It Failed
The Status and Sub Status fields hold hexadecimal codes that tell you exactly why the logon failed. The important ones:
- 0xC0000064 – the username does not exist. A flood of these means someone is guessing usernames.
- 0xC000006A – correct username, wrong password. The classic password-guessing signature.
- 0xC000006D – generic logon failure (bad name or password); often the top-level Status with one of the codes above as Sub Status.
- 0xC0000234 – the account is locked out. Your lockout policy fired; Event ID 4740 records the lockout itself. On Windows 11 22H2 and later, and on new installs that include the October 2022 updates, Microsoft’s default policy locks an account after 10 failures in 10 minutes, for 10 minutes (KB5020282). Older servers often have no lockout at all, and the built-in Administrator is exempt unless “Allow Administrator account lockout” is enabled.
- 0xC0000072 – the account is disabled. Attempts against disabled accounts are a strong signal, since legitimate users rarely try them.
- 0xC0000071 – expired password.
- 0xC000006F – logon outside permitted hours.
- 0xC0000070 – workstation restriction violated.
- 0xC0000193 – the account has expired.
- 0xC0000133 – clock skew between machines (a config problem, not an attack).
- 0xC000015B – the user has not been granted this type of logon on this machine. The usual Remote Desktop failure for a staff member who is not in the Remote Desktop Users group: a support call, not an attack.
- 0xC0000224 – the user must change their password at next logon. Common right after you reset a staff member’s password.
Reading Patterns, Not Events
A single 4625 is a typo. The meaning is in the pattern:
- Many failures, one account, one or few IPs – a brute-force attack in progress. Expect 0xC000006A repeating.
- One failure each across many accounts, same IP – password spraying: one common password tried everywhere, deliberately staying under your lockout threshold.
- Floods of 0xC0000064 – username enumeration; the attacker is building a list of which accounts exist before the real attack.
- Slow drip around the clock – a patient bot staying under lockout and alert limits. Invisible event by event; obvious when you count a whole day or week. Our guide to brute force attacks explains these low-and-slow campaigns and how to stop them.
- 4625s that suddenly stop, followed by a 4624 – the worst pattern: failures ending in a success. Check that 4624 immediately: same IP, odd hour, unexpected account means you may have an intruder, not an attempt.
To see which IPs are hitting you hardest today, this extracts and counts source addresses from the last day of 4625s:
Get-WinEvent -FilterHashtable @{LogName='Security'; Id=4625; StartTime=(Get-Date).AddDays(-1)} -ErrorAction SilentlyContinue |
ForEach-Object { ([xml]$_.ToXml()).Event.EventData.Data | Where-Object Name -eq 'IpAddress' } |
Group-Object '#text' | Sort-Object Count -Descending | Select-Object Count, Name -First 10
From Reading to Being Told
Everything above works, and it is worth doing once just to see what your server actually experiences in a day. But nobody reads the Security log daily, and the patterns that matter (the slow drip, the spray, the failure followed by a success) only show up when something counts events across hours and days. If you are new to the logs themselves, start with our introduction to Windows event logs.
Our guide to brute-force detection without a SIEM covers the do-it-yourself route with a full PowerShell script. Prixl Warden does it as a service: it watches every failed sign-in, tracks failures per IP address and per account to catch fast floods and slow, low-and-slow campaigns, and emails you with a plain-English explanation when it sees one. Better still, stop most 4625s arriving at all by taking Remote Desktop off the internet; our guide to restricting RDP access explains how, including with Prixl Guard.
The event log already sees every attack; the only question is whether anything is reading it. Start your 30-day free trial and see your own 4625 traffic.
