Skip to content

OWASP Top 10: the main flaws in web applications

Industry consensus on where applications fail most often. Use it as a risk map, not as a substitute for testing.

Reading time
10 min
Published

The OWASP Top 10 is the best-known list of security risks in web applications. It is maintained by OWASP, an open nonprofit community, and it sums up the ten categories of flaws that appear most often and cause the most impact. It is not a standard or a certification. It reflects industry consensus and is a starting point for anyone who develops, tests or commissions software security assessments.

Each of the ten categories in the 2021 edition appears here in defensive terms, with what the risk means and how to mitigate it. The idea is to have a map for prioritizing, not a magic checklist. Going through every item in the Top 10 reduces risk, but it does not replace manual testing of the application, which finds logic flaws no generic list anticipates.

What the OWASP Top 10 is and what it is not

The Top 10 is a list of risk categories. It does not point to specific vulnerabilities: each item groups several related flaws under one theme. The list is revised periodically based on real data from analyzed applications, so it works as a snapshot of where risk tends to concentrate. It also gives development, security and management teams a common language.

What the Top 10 does not offer is a guarantee of complete coverage. An application can clear all ten themes and still have a serious business logic flaw that only shows up when someone analyzes the context (a discount that can be applied twice, for example). That is why the list works best as a basis for awareness and as part of a larger application security program, with code review, automated testing and penetration testing.

Categories one to five

  • Broken access control: users can see data or perform actions beyond what they should. It is the most common risk on the list. The defense is to check authorization on the server, deny by default and test access across different user roles.
  • Cryptographic failures: sensitive data is exposed because encryption is missing or was used the wrong way. The fix involves encrypting in transit and at rest, using current algorithms and managing keys and secrets carefully.
  • Injection: unvalidated input changes the meaning of a query or command, as in SQL injection. To prevent it, use parameterized queries, validate input and prefer safe libraries.
  • Insecure design: the flaw originates in the architecture, before implementation. The remedy here is threat modeling, secure design patterns and security requirements from the start of the project.
  • Security misconfiguration: exposed services, overly broad permissions and insecure defaults left as they came. Mitigation comes from hardening baselines, configuration review and removing what is not used.

Categories six to ten

  • Vulnerable and outdated components: libraries and dependencies with known flaws. To reduce this risk, keep an inventory of dependencies, use software composition analysis and update continuously.
  • Identification and authentication failures: poorly protected sessions and credentials. The defenses are a second factor, a sensible password policy, brute-force protection and secure session management.
  • Software and data integrity failures: updates and data accepted without anyone verifying where they came from. Signing, integrity checks and care with the software supply chain reduce this risk.
  • Security logging and monitoring failures: the attack goes by without leaving a trace or triggering an alert. The answer is relevant, centralized logs and detection use cases.
  • Server-side request forgery (SSRF): the server is tricked into accessing internal destinations it should not reach. Mitigation combines destination validation, allowlists and network segmentation.

The order of the categories combines frequency, ease of exploitation and impact. Broken access control leads because it appears in many applications and grants improper access to data and functions. That helps with prioritization: on a first pass, access control, cryptography and injection are usually the areas that deserve the most attention.

Prevention in practice, by risk class

The categories become more concrete when they turn into coding decisions. The following examples are defensive: they show the secure pattern without describing the attack. The idea is for the right choice to become a habit, so the flaw never gets written in the first place.

Injection: parameterized queries

Injection happens when user data gets mixed into the command. The defense is to keep the two apart with parameterized queries, where input is always treated as data and never interpreted as part of the instruction. In code, it looks like this:

Parameterized query instead of concatenated input
# Avoid: building the query by concatenating user input# Prefer: bound parameters, always treated as datacursor.execute(    "SELECT id, name FROM users WHERE email = %s",    (submitted_email,),)

Access control: deny by default

Broken access control usually comes from checking permissions in the wrong place or assuming that hiding a button in the interface is enough. The defense is to verify authorization on the server, on every request: deny by default and allow only what the rule permits. In the example, the document is returned only if it belongs to the person who requested it:

Authorization checked on the server, with deny by default
# Does the resource belong to the requester? Always check on the server.def open_document(user, document_id):    doc = repository.find(document_id)    if doc is None or doc.owner_id != user.id:        raise AccessDenied()  # deny by default    return doc

Security headers and configuration

Part of the misconfiguration problem can be solved with response headers that tell the browser to protect itself. They reduce the surface for attacks such as content injection and misuse of the site inside third-party frames. Note that they are an extra layer: the fix in the code is still necessary. For example:

Response headers that strengthen defenses in the browser
Content-Security-Policy: default-src 'self'X-Content-Type-Options: nosniffStrict-Transport-Security: max-age=63072000; includeSubDomainsReferrer-Policy: no-referrer

How to use the Top 10 in practice

The Top 10 pays off more when it becomes part of the development cycle than when it only shows up in an isolated audit at the end. It can guide security requirements, code reviews and the configuration of testing tools. When teams know the categories, many flaws are never created, because the secure decision becomes part of the application's design.

  • Use the categories as security requirements during development
  • Configure SAST, SCA and DAST tools in line with the Top 10
  • Prioritize access control, cryptography and injection on a first pass
  • Add threat modeling to address insecure design
  • Use penetration testing to validate what tools and lists cannot reach

What lies beyond the Top 10

The Top 10 is the entry point. OWASP itself maintains deeper projects for the moment when awareness needs to become a verifiable requirement, and knowing them keeps you from stopping at a list of ten themes.

  • ASVS (Application Security Verification Standard): a standard of application security requirements, useful for defining the expected level of rigor and guiding tests
  • Cheat Sheets: concise guides on how to implement each defense correctly
  • Testing guides: a methodology for assessing applications in a structured way
  • API Security Top 10: a list dedicated to risks specific to APIs

The Top 10 tells you where risk tends to be; the ASVS tells you what to require and how to verify it. More mature teams use the list for awareness and the ASVS to turn security into acceptance criteria, which fits well with automated verification in the pipeline.

Practical checklist

  • Check authorization on the server for every sensitive action
  • Encrypt in transit and at rest with managed keys
  • Use parameterized queries and validate input
  • Include security requirements in the application design
  • Apply a hardening baseline and review configuration
  • Inventory dependencies and update vulnerable components
  • Protect authentication with a second factor and session management
  • Verify the integrity of updates and the software supply chain
  • Generate relevant logs and detection use cases
  • Validate request destinations to prevent SSRF
  • Send security headers in responses to the browser
  • Define verifiable security requirements, for example with the ASVS

Best practices

  • Use the Top 10 as a risk map, knowing it does not guarantee complete coverage
  • Bring the categories into the development cycle from the start
  • Prioritize access control, the most common risk on the list
  • Combine SAST, SCA and DAST with human review
  • Use threat modeling to address insecure design
  • Turn the categories into verifiable requirements that go beyond warnings
  • Use penetration testing to validate the logic flaws the list does not anticipate

Common mistakes

Treating the Top 10 as a checklist that guarantees security
It creates a false sense of coverage while logic flaws remain open.
Relying only on automated tools
Authorization and business logic flaws go by without anyone testing them.
Leaving security for the end of development
Fixes become expensive and design flaws become hard to reverse.
Ignoring dependencies and outdated components
Old libraries leave known vulnerabilities exposed.
Stopping at the Top 10 and never maturing into requirements
Security stays at the awareness level and never becomes testable acceptance criteria.

Authorship and review

Cesar Gargiulo

CEO and founder of GUARDIASEC. Technical and editorial lead for the content published in this library.

Published on . Found a technical error? Write to [email protected] and we will correct it and keep a record of the change.

Frequently asked questions

What is the OWASP Top 10?
The OWASP Top 10 is a list, published by the OWASP Foundation, of the most critical risk categories in web applications, built from testing data and community contributions. It is an awareness reference and a starting point for review and testing, not a complete security standard.
Is the OWASP Top 10 a standard or a certification?
Neither. The OWASP Top 10 is a reference list maintained by the OWASP community that summarizes the most common risk categories in web applications. It does not impose mandatory requirements or offer certification. Its role is to capture industry consensus and give you a starting point for guiding development, testing and the commissioning of software security assessments.
Does covering the whole OWASP Top 10 make an application secure?
It reduces risk, but it does not guarantee security. The list covers common categories, and an application can address all of them and still have a serious business logic flaw that only shows up with contextual analysis. So the Top 10 works best as the basis of a larger program, with code review, automated testing and penetration testing with manual validation.
Which OWASP Top 10 category is the most common?
In the 2021 edition, broken access control tops the list. It occurs when a user can access data or perform actions beyond what their permissions should allow. To mitigate it, check authorization on the server, deny by default and test access across different user roles. Relying only on hiding buttons in the interface does not solve it.
How often is the OWASP Top 10 updated?
OWASP revises the list periodically, based on data from analyzed applications and on community input. There is no short, fixed schedule, and a few years pass between editions. This guide uses the 2021 edition as its reference. The list's value lies in its guidance on priorities more than in the edition date: from one version to the next, the order and grouping of categories usually change, while the defensive nature of each theme stays the same.
What is the difference between the OWASP Top 10 and the ASVS?
The Top 10 is an awareness list that points to where risk tends to concentrate. The ASVS is an application security requirements standard, built to define and verify the expected level of rigor. The first helps you raise awareness and prioritize; the second turns security into testable acceptance criteria. More mature teams use both: the Top 10 for awareness and the ASVS to require and validate.
Does the OWASP Top 10 apply to APIs?
Partly. Many categories, such as broken access control and injection, also affect APIs. But APIs have their own object-level and function-level authorization risks, which OWASP covers in a separate project, the API Security Top 10. If you expose APIs, use both lists together, because the web application list alone does not cover everything an API needs.

When to bring in specialist help

GUARDIASEC's Application Security service assesses web applications against the OWASP Top 10 categories and goes beyond them, with manual testing to find business logic flaws. Findings come with risk-based prioritization and clear remediation recommendations.