What Is a Brute Force Attack? Prevention, and Methods

A brute force attack is a cyberattack that guesses passwords using trial-and-error to gain unauthorized access to accounts and systems.
Published on
Sunday, August 16, 2026
Updated on
August 16, 2026

What Is a Brute Force Attack?

A brute force attack is a trial-and-error method used to discover a password, login credential, encryption key, or other secret by testing possible values until a match is found. Think of a thief facing a four-digit combination lock with no clue about the code: they start at 0-0-0-0, move to 0-0-0-1, then 0-0-0-2, and keep going until the lock opens. Brute force applies the same logic digitally, with software performing the guesses instead of a person turning the dial.

Whether brute force is practical comes down mostly to the size and predictability of the search space. Short passwords, common phrases, and familiar number patterns shrink the number of plausible guesses; automation cuts the time needed to test them. Brute force also extends beyond repeated login attempts: MITRE ATT&CK includes password guessing against live authentication services and offline cracking against acquired password hashes within its brute-force taxonomy.

Cryptographic keys show where the method hits its limit. In Applied Cryptography, Bruce Schneier explained that exhaustive guessing against a properly generated 256-bit key runs into fundamental physical constraints, not merely the speed of current computers. Trial and error may be simple in principle, but the size and unpredictability of the secret determine whether exhaustive guessing is realistic.

How Does a Brute Force Attack Work?

Four-digit PINs create 10,000 possible values, from 0000 through 9999. During a brute force attack, software works through this set—or a prioritized portion of it—and checks each value against a mechanism capable of confirming a match. Passwords create far more possibilities because length, character variety, and human password habits all influence how much must be searched.

  1. Generate possible values: Software enumerates passwords, PINs, or other secrets from the available search space.
  2. Verify each guess: Online guessing submits a credential to a live authentication service, which validates it against the account's stored credential record. Offline cracking processes a proposed password with the relevant hashing parameters and compares the output with an acquired password hash.
  3. Use the result: A failed login or hash mismatch moves testing to the next value. Successful authentication or a matching hash confirms the correct secret.
  4. End the loop: Testing stops after a match, once the available set is exhausted, or if defensive controls or computational cost make further attempts impractical.
online vs offline password cracking
Mode How a Guess Is Verified What Limits Repeated Testing
Online The authentication service accepts or rejects each credential attempt Rate limits, delays, account lockouts, MFA, and monitoring
Offline A calculated password hash is compared with the acquired hash Password strength, hashing design, work factor, and computing cost

Who controls verification separates the two modes. Organizations can restrict checks performed through their authentication systems, whereas offline password cracking occurs outside the login flow and is unaffected by throttling or account lockouts.

What Types of Brute Force Attacks Exist?

Brute force variants differ by what information is available before testing begins and how the effort is organized. Some exhaust possible values, others concentrate on likely human choices, while several redistribute guesses across accounts, reuse exposed credentials, or work from previously calculated hash data.

seven types of brute force attacks

1. Simple Brute Force Attack

With no useful clue about the secret, simple brute force systematically works through possible values until a match appears. Password length and character variety determine how quickly the number of possibilities grows, making short or predictable secrets easier to exhaust than long, random values.

A Glance issue publicly reported in June 2026 and later assigned CVE-2026-63770 showed why retry restrictions matter. Spoofing X-Forwarded-For could bypass the normal limit of five failed attempts per five minutes per IP, allowing password guessing to continue without the intended per-IP restriction.

2. Dictionary Attack

People rarely choose passwords at random, and a dictionary attack uses that predictability to prioritize common passwords, names, words, phrases, dates, and other likely choices instead of searching every mathematically possible value.

A word such as summer would appear far earlier in such a list than an arbitrary string like q7B!m2Zp. The password remains unknown, but human behavior gives the guessing process a more efficient order.

Weak password storage makes this technique more practical after hashes are stolen. TP-Link disclosed CVE-2026-5040 on July 14, 2026, involving weak password hashing in Deco M5 v1. TP-Link said possession of a password hash could permit brute-force or dictionary attacks and rated the issue 7.1 / High under CVSS 4.0.

3. Hybrid Brute Force Attack

A memorable word may not satisfy a site's password requirements until someone adds a capital letter, number, or symbol. Hybrid brute force follows the same habit by starting with likely base words and generating structured variations around them.

Current 2026 guidance from Hong Kong's Digital Policy Office describes modifications such as:

  • appending a birth year or another meaningful number;
  • changing capitalization;
  • replacing characters with familiar numbers or symbols;
  • extending a dictionary word with predictable additions.

A base word such as summer might therefore produce Summer, summer2026, or another familiar variation. Rather than exploring every combination evenly, hybrid guessing spends more effort on recognizable ways people modify passwords.

4. Reverse Brute Force Attack

Sometimes the password is already known and the matching username is not. Reverse brute force takes a known, leaked, or commonly used password and checks it against different accounts to find a valid match.

Hong Kong government guidance from 2026 describes the relationship clearly:

  • Traditional brute force: a specific account → many password guesses.
  • Reverse brute force: a known or likely password → many usernames.

For instance, Welcome123 might be checked against a collection of usernames rather than sending hundreds of different passwords to the same account. The objective shifts from discovering a secret for a known user to finding the account associated with a password already in hand.

5. Credential Stuffing

Credential stuffing begins with username-password pairs exposed through an earlier breach or leak. Those combinations are tested against other websites or applications to find places where the same person reused them.

Chick-fil-A faced credential-stuffing attacks against its website and mobile app from June 17–19, 2026, using credentials obtained from third-party sources. Subsequent reporting based on breach filings put the number of affected people at 13,322.

Unlike password guessing, credential stuffing does not need to discover an unknown password if the exposed pair still works. It succeeds because people sometimes reuse the same credentials across separate services.

6. Password Spraying

Hundreds of failures against the same username can quickly attract attention or trigger restrictions. Password spraying takes a different route by distributing a small set of commonly used passwords across many accounts. Microsoft's Defender XDR guidance, updated June 15, 2026, describes the technique as trying a limited set of common passwords against a broad account population.

Its authentication footprint may include:

  • attempts against many usernames;
  • the same small set of passwords;
  • relatively few failures for each individual account.

Spreading the guesses this way avoids the concentrated failure history associated with account-focused password guessing.

7. Rainbow Table Attack

Work completed before a password database is obtained can shorten offline recovery. A rainbow table attack uses precomputed relationships between possible passwords and hash values, reducing the need to calculate every value from scratch after the hashes are acquired.

CVE-2026-45027 documented WeGIA versions before 3.7.3 storing passwords as unsalted SHA-256 hashes. Identical passwords therefore produced identical hashes, leaving the database vulnerable to reuse of a single precomputed rainbow-table lookup.

Unique salts undermine that advantage because each credential record produces a different stored result, even where two people choose the same password. Previously calculated hash relationships become far less reusable once every record incorporates its own salt.

What separates these methods is the attacker's starting material and verification path. Those differences also shape which authentication records defenders see and which safeguards have the greatest effect.

How Can You Detect a Brute Force Attack?

An isolated password failure is ordinary; relationships among accounts, sources, timing, failure volume, lockouts, and later successes are more revealing. Authentication records become useful once defenders examine those events together rather than treating each rejection as an isolated incident.

Repeated Login Failures

A burst of rejected sign-ins against the same account is consistent with password guessing, particularly if attempts continue from the same source or arrive at a pace unlike normal user mistakes. A narrow time window, recurring source, and sustained failures provide evidence than an isolated count by itself.

Distributed Failures

Password spraying leaves a broader footprint because only a few guesses may reach each username. Per-account thresholds can miss the behavior; correlating many usernames with shared sources, timing, or similar sign-in sequences exposes a pattern that looks harmless if each account is reviewed separately.

Failure-to-Success Sequence

A successful sign-in immediately after repeated rejections deserves investigation because it may mark the guess that worked. Review the failed attempts and later success as a continuous sequence, then compare source, device, MFA result, location, and recent account history to determine whether the session fits the legitimate user's normal behavior.

Account Lockouts

A sudden increase in locked accounts may reflect sustained guessing or the defensive effect of an active attempt. Several unrelated accounts reaching their threshold during the same period becomes more significant if the preceding failures also share sources or timing.

Authentication Spikes

Abnormal sign-in volume from a particular IP address, a narrow source range, or several sources behaving similarly can expose automated guessing. High volume is not required, though; low-and-slow attempts spread across time may stay below basic rate thresholds, making correlation across accounts, sources, timing, and outcomes important.

OWASP recommends logging authentication failures, password failures, and account lockouts and reviewing them for credential attacks. No universal failure count proves brute force because normal login volume and attacker pacing vary by environment. A case comes from the relationship between who was tested, where the requests originated, how frequently they occurred, and whether any later succeeded.

What Can Happen After a Brute Force Attack Succeeds?

Valid credentials can move an intrusion beyond the authentication stage, although what follows varies with the account's permissions and the resources tied to that identity. In an advisory revised April 17, 2026, CISA and partner agencies reported that Russian GRU Unit 26165 used password guessing and spraying to gain entry into Western logistics and technology organizations. The actors later established persistence, altered mailbox permissions, retrieved sensitive information from email servers, and exfiltrated collected data.

what a cracked password unlocks
  • Account takeover: A valid password may give the intruder the permissions already assigned to the affected user account.
  • Sensitive data exposure: Email, files, customer records, or other protected information available to the identity becomes exposed to unauthorized use.
  • Privilege abuse and lateral movement: Higher-privilege credentials open additional accounts, applications, or parts of the environment to follow-on activity.
  • Fraud, disruption, or further attacks: A trusted identity can be used to send deceptive messages, alter data, interfere with business processes, or support another stage of an intrusion.

Successful guessing does not automatically mean the entire environment is compromised. The extent of the damage comes down to the account's privileges, what it can reach, and which additional safeguards stand between the initial login and more sensitive resources.

How Can Organizations Prevent Brute Force Attacks?

Prevention has two distinct jobs: constrain repeated guessing against live authentication services and make stolen password hashes expensive to crack offline. Enhanced authentication also limits the value of a correct password if guessing eventually succeeds. 

A full breakdown of both control sets, including where each one fails and the order to deploy them in, is covered in our guide on how to prevent brute force attacks.

1. Add MFA or Passkeys

Prioritize administrator, remote-work, and internet-facing accounts, then extend additional authentication across other supported applications. 

MFA requires another proof of identity after the password, while passkeys can remove reusable passwords from supported sign-in flows. A correct password alone is no longer sufficient to complete those logins.

2. Throttle Failed Attempts

Rate limits should account for the username, request source, and time window rather than permitting unlimited retries at full speed. Progressive delays can lengthen the interval after successive failures, while request limits cap how many attempts reach an account or authentication endpoint during a defined period. Set thresholds against normal sign-in traffic instead of copying a universal number.

3. Design Lockouts Around Abuse

Temporary lockouts work best when they interrupt concentrated guessing without giving outsiders an easy way to disable legitimate accounts. Use short lock periods, progressive delays, user notifications, and source correlation instead of relying on a rigid failure count or permanent lock.

4. Screen Passwords Before Acceptance

Password creation and reset flows should compare proposed values against known exposed and commonly used passwords before storing them. Reject matches, enforce an appropriate minimum length, and encourage a unique password for each service. Screening removes many of the values most useful to dictionary attacks and password spraying before they ever become valid credentials.

5. Make Offline Guessing Expensive

Store passwords with a modern password-hashing scheme, assign a unique salt to every credential record, and tune the work factor according to current security guidance and acceptable system performance. 

Each guess then carries a meaningful computational cost, while unique salts prevent the same precomputed result from being reused across multiple records. Login throttling no longer offers protection after hashes leave the authentication environment, so storage design becomes critical.

6. Challenge Suspicious Automation

Use CAPTCHA or additional verification after risk indicators appear, such as repeated failures, unusual request volume, or abnormal source behavior, rather than placing the same challenge on every sign-in. Selective checks add friction to automated guessing without creating unnecessary interruption for ordinary users.

7. Connect Authentication Events

Detection logic should correlate failed sign-ins, lockouts, source addresses, usernames, timestamps, MFA results, and later successful sessions. Look for concentrated failures against the same account, a handful of guesses distributed across many users, or a successful login immediately after repeated rejections. Reviewing the sequence as a whole gives defenders a better chance to interrupt active guessing before it spreads.

8. Act on Exposed Credentials

A leaked credential should trigger investigation before someone reuses it against a company account. CloudSEK XVigil monitors external sources for organization-specific credential exposure, giving security teams information they can use to identify affected accounts, rotate credentials where appropriate, and review related sign-in records. 

XVigil does not enforce MFA, throttle requests, or inspect internal authentication logs; those functions remain with the organization's identity and security tooling.

Conclusion

Brute force is ultimately a question of economics: how many possibilities exist, how quickly they can be checked, and what an attacker gains after finding the correct password. Online and offline attacks change those variables in different ways, so relying on a single defensive measure cannot address every form of credential guessing or cracking.

Effective protection comes from restricting the guessing loop and keeping offline password verification expensive. If valid credentials still surface, additional authentication and timely investigation can limit the follow-on activity.

Related Posts
How to Check If AI API Keys Have Been Leaked
After the 2026 LiteLLM supply chain breach, here's how to check if your AI API keys leaked, and what to do if they did.
Did the LiteLLM Breach Affect Indian Companies? What the Exposure Data Shows 
CloudSEK's data links 7 Indian organizations to the LiteLLM supply chain incident. See what the exposure data shows, and what it doesn't confirm.
Attack Surface Management vs Vulnerability Management
Attack surface management vs. vulnerability management learn how ASM identifies assets and VM fixes security weaknesses.

Start your demo now!

Schedule a Demo
Free 7-day trial
No Commitments
100% value guaranteed

Related Knowledge Base Articles

No items found.