CWE Top 25 Most Dangerous Software Weaknesses (2025 List), Explained

Laptop screen displaying colourful source code

The CWE Top 25 is MITRE’s yearly ranking of the software weaknesses behind the most common and most damaging vulnerabilities. The latest edition, published in December 2025 with CISA, is based on 39,080 CVE records. Cross-site scripting is still number one, missing authorization jumped into the top five, and classic buffer overflows came back in force.

This guide lists the full 2025 ranking, explains what changed, and sets out what development and security teams should do with it.

What the CWE Top 25 measures

A CVE is one specific vulnerability in one product. A CWE (Common Weakness Enumeration) is the underlying type of mistake that caused it, such as failing to check whether a user is allowed to perform an action. MITRE maps recent CVEs to their CWEs and scores each weakness on how often it appears and how severe the resulting vulnerabilities are. The result shows where coding mistakes most often turn into real risk.

The 2025 CWE Top 25

Rank Weakness CWE Change from 2024
1 Cross-site scripting (XSS) CWE-79 no change
2 SQL injection CWE-89 up 1
3 Cross-site request forgery (CSRF) CWE-352 up 1
4 Missing authorization CWE-862 up 5
5 Out-of-bounds write CWE-787 down 3
6 Path traversal CWE-22 down 1
7 Use after free CWE-416 up 1
8 Out-of-bounds read CWE-125 down 2
9 OS command injection CWE-78 down 2
10 Code injection CWE-94 up 1
11 Classic buffer overflow CWE-120 new
12 Unrestricted upload of dangerous file types CWE-434 down 2
13 NULL pointer dereference CWE-476 up 8
14 Stack-based buffer overflow CWE-121 new
15 Deserialization of untrusted data CWE-502 up 1
16 Heap-based buffer overflow CWE-122 new
17 Incorrect authorization CWE-863 up 1
18 Improper input validation CWE-20 down 6
19 Improper access control CWE-284 new
20 Exposure of sensitive information CWE-200 down 3
21 Missing authentication for a critical function CWE-306 up 4
22 Server-side request forgery (SSRF) CWE-918 down 3
23 Command injection CWE-77 down 10
24 Authorization bypass through user-controlled key (IDOR) CWE-639 up 6
25 Allocation of resources without limits CWE-770 up 1

Source: MITRE, 2025 CWE Top 25.

Three trends that stand out

1. Access control is the fastest-growing problem

Five of the 25 entries are about deciding who may do what: missing authorization (#4), incorrect authorization (#17), improper access control (#19, new), missing authentication (#21) and authorization bypass through user-controlled keys (#24). These flaws are rarely caught by scanners, because the code works exactly as written. It just never asks whether this user should be allowed to see this record or run this action. APIs and multi-tenant SaaS apps are especially exposed.

2. Memory-safety bugs are back near the top

Three buffer overflow variants entered the list at once (#11, #14, #16), and NULL pointer dereference rose eight places. Part of this reflects MITRE’s push for more precise mapping. In its key insights, MITRE notes that vague “discouraged” CWE mappings fell to 5.42% from 10.19%, so bugs once filed under broad categories now show up under their specific names. Either way, the message matches years of guidance from CISA and the NSA: code written in C and C++ keeps producing the same classes of serious bugs.

3. The web basics still haven’t been solved

XSS, SQL injection and CSRF hold the top three spots, and all three have well-known fixes. MITRE says CWE-79 alone gained more than 3,000 CVE records year over year. These persist because new code keeps being written outside safe frameworks, and because old applications are rarely revisited.

What development teams should do

  • Make the safe path the default. Use frameworks that escape output automatically (stopping most XSS) and parameterized queries or an ORM for every database call (stopping SQL injection). Ban string-built SQL and raw HTML output in code review.
  • Centralize authorization. Put every access decision through one policy layer that denies by default, rather than scattering checks across controllers. Write tests that try to read or change another user’s data by swapping IDs, which covers CWE-639 and CWE-862.
  • Protect state-changing requests. Use anti-CSRF tokens and set session cookies to SameSite=Lax or Strict.
  • Choose memory-safe languages for new components such as Rust, Go, C#, Java or Swift. For existing C and C++ code, compile with hardening flags and run fuzzing in CI.
  • Never trust uploads or serialized data. Check file types on the server, store uploads outside the web root, and avoid deserializing untrusted input with formats that can create arbitrary objects.
  • Map your findings to CWEs. Tag every finding from scanners, pen tests and bug bounties with its CWE. After a few months you will see your own top 10, which matters more for your training budget than the global list.

What security and procurement teams should do

When you buy software, ask vendors how their development process prevents the Top 25 classes, especially authorization flaws, which automated tools miss. Secure development evidence is still a fair thing to ask for even though U.S. federal attestation rules have loosened. We explain those changes in Secure Software Attestation After M-26-05.

The bottom line

The CWE Top 25 changes slowly because the mistakes behind it are deeply habitual. The 2025 edition carries two clear warnings: authorization logic is now one of the biggest sources of serious vulnerabilities, and memory-unsafe code continues to produce the same bugs it always has. Teams that design those two problems out at the framework and language level will remove a large share of their risk.

Leave a Reply

Your email address will not be published. Required fields are marked *

Newsletter

Get the WWCN brief

The week’s most important cybersecurity stories and practical guides, explained in plain English.

No spam. Unsubscribe at any time.

Latest

Sections

More from World Wide Cyber News

World Wide Cyber News is published by VisualNest, a web, SEO and cybersecurity studio.