---
title: "CWE-405: Asymmetric Resource Consumption (Amplification)"
url: https://radicalnotion.ai/cwe/cwe-405
type: cwe
description: "The product does not properly control situations in which an adversary can cause the product to consume or produce excessive resources without requiring the adversary to invest equivalent work or otherwise prove authorization, i.e., the adversary's influence is \"asymmetric.\""
updated: 2026-11-10
source: RadicalNotion.AI
license: CC BY-NC 4.0 (https://creativecommons.org/licenses/by-nc/4.0/)
---

# CWE-405: Asymmetric Resource Consumption (Amplification)

- **Abstraction:** Class
- **Structure:** Simple
- **Status:** Incomplete
- **CVEs with this as primary weakness:** 66
- **Of those, in CISA KEV:** 0
- **New in 2026:** 37
- **CWE catalog version:** 4.21

## Description

The product does not properly control situations in which an adversary can cause the product to consume or produce excessive resources without requiring the adversary to invest equivalent work or otherwise prove authorization, i.e., the adversary's influence is "asymmetric."

## Modes of introduction

| Phase | Note |
| --- | --- |
| Architecture and Design | - |
| Implementation | - |
| Operation | - |

## Applicable platforms

**Technologies:** Client Server (Undetermined)

## Common consequences

| Scope | Impact | Note |
| --- | --- | --- |
| Availability | DoS: Amplification, DoS: Resource Consumption (CPU), DoS: Resource Consumption (Memory), DoS: Resource Consumption (Other) | This can lead to poor performance due to "amplification" of resource consumption, typically in a non-linear fashion. This situation is worsened if the product allows malicious users or attackers to consume more resources than their access level permits. Sometimes this is a factor in "flood" attacks, but other types of amplification exist. |

## Potential mitigations

### Architecture and Design

An application must make resources available to a client commensurate with the client's access level.

### Architecture and Design

An application must, at all times, keep track of allocated resources and meter their usage appropriately.

### System Configuration

Consider disabling resource-intensive algorithms on the server side, such as Diffie-Hellman key exchange.

Effectiveness: High. Business requirements may prevent disabling resource-intensive algorithms.

## Demonstrative examples

### Example 1

This code listens on a port for DNS requests and sends the result to the requesting address.

Bad code:

```python
sock = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
sock.bind( (UDP_IP,UDP_PORT) )
while true:
    data = sock.recvfrom(1024)
    if not data:
        break

    (requestIP, nameToResolve) = parseUDPpacket(data)
    record = resolveName(nameToResolve)
    sendResponse(requestIP,record)
```

This code sends a DNS record to a requesting IP address. UDP allows the source IP address to be easily changed ('spoofed'), thus allowing an attacker to redirect responses to a target, which may be then be overwhelmed by the network traffic.

### Example 2

This function prints the contents of a specified file requested by a user.

Bad code:

```php
function printFile($username,$filename){

    //read file into string
    $file = file_get_contents($filename);
    if ($file && isOwnerOf($username,$filename)){
        echo $file;
        return true;
    }
    else{
        echo 'You are not authorized to view this file';
    }
    return false;
}
```

This code first reads a specified file into memory, then prints the file if the user is authorized to see its contents. The read of the file into memory may be resource intensive and is unnecessary if the user is not allowed to see the file anyway.

### Example 3

The DTD and the very brief XML below illustrate what is meant by an XML bomb. The ZERO entity contains one character, the letter A. The choice of entity name ZERO is being used to indicate length equivalent to that exponent on two, that is, the length of ZERO is 2^0. Similarly, ONE refers to ZERO twice, therefore the XML parser will expand ONE to a length of 2, or 2^1. Ultimately, we reach entity THIRTYTWO, which will expand to 2^32 characters in length, or 4 GB, probably consuming far more data than expected.

Attack code:

```xml
<?xml version="1.0"?>
<!DOCTYPE MaliciousDTD [
<!ENTITY ZERO "A">
<!ENTITY ONE "&ZERO;&ZERO;">
<!ENTITY TWO "&ONE;&ONE;">
...
<!ENTITY THIRTYTWO "&THIRTYONE;&THIRTYONE;">
]>
<data>&THIRTYTWO;</data>
```

### Example 4

This example attempts to check if an input string is a "sentence" \[REF-1164\].

Bad code:

```javascript
var test_string = "Bad characters: $@#";
var bad_pattern  = /^(\w+\s?)*$/i;
var result = test_string.search(bad_pattern);
```

Good code:

```javascript
var test_string = "Bad characters: $@#";
var good_pattern  = /^((?=(\w+))\2\s?)*$/i;
var result = test_string.search(good_pattern);
```

### Example 5

An adversary can cause significant resource consumption on a server by filtering the cryptographic algorithms offered by the client to the ones that are the most resource-intensive on the server side. After discovering which cryptographic algorithms are supported by the server, a malicious client can send the initial cryptographic handshake messages that contain only the resource-intensive algorithms. For some cryptographic protocols, these messages can be completely prefabricated, as the resource-intensive part of the handshake happens on the server-side first (such as TLS), rather than on the client side. In the case of cryptographic protocols where the resource-intensive part should happen on the client-side first (such as SSH), a malicious client can send a forged/precalculated computation result, which seems correct to the server, so the resource-intensive part of the handshake is going to happen on the server side. A malicious client is required to send only the initial messages of a cryptographic handshake to initiate the resource-consuming part of the cryptographic handshake. These messages are usually small, and generating them requires minimal computational effort, enabling a denial-of-service attack. An additional risk is the fact that higher key size increases the effectiveness of the attack. Cryptographic protocols where the clients have influence over the size of the used key (such as TLS 1.3 or SSH) are most at risk, as the client can enforce the highest key size supported by the server.

## Observed examples

| CVE | Description |
| --- | --- |
| CVE-1999-0513 | Classic "Smurf" attack, using spoofed ICMP packets to broadcast addresses. |
| CVE-2003-1564 | Parsing library allows XML bomb |
| CVE-2004-2458 | Tool creates directories before authenticating user. |
| CVE-2020-10735 | Python has "quadratic complexity" issue when converting string to int with many digits in unexpected bases |
| CVE-2020-5243 | server allows ReDOS with crafted User-Agent strings, due to overlapping capture groups that cause excessive backtracking. |
| CVE-2013-5211 | composite: NTP feature generates large responses (high amplification factor) with spoofed UDP source addresses. |
| CVE-2002-20001 | Diffie-Hellman (DHE) Key Agreement Protocol allows attackers to send arbitrary numbers that are not public keys, which causes the server to perform expensive, unnecessary computation of modular exponentiation. |
| CVE-2022-40735 | The Diffie-Hellman Key Agreement Protocol allows use of long exponents, which are more computationally expensive than using certain "short exponents" with particular properties. |

## Real CVEs with this weakness (sample of 12 of 66)

| CVE | Title | Severity | CVSS | EPSS | CISA KEV | Published |
| --- | --- | --- | --- | --- | --- | --- |
| CVE-2026-104817 | Misskey: Lack of rate limiting and size restrictions in RSS fetching API | high | 8.7 | - | No | 2026-10-13 |
| CVE-2026-104431 | Zebra before 6.0.0 Denial of Service via Synchronous Script FFI Verification | high | 8.7 | - | No | 2026-10-02 |
| CVE-2026-104423 | Zebra before 6.2.1 Denial of Service via Uncapped V6 Shielded Proof Verification | high | 8.7 | - | No | 2026-10-02 |
| CVE-2026-25611 | Pre-Authentication Memory Exhaustion Denial of Service in MongoDB Server | high | 8.7 | - | No | 2026-02-10 |
| CVE-2025-53633 | Chall-Manager's scenario decoding process does not check for zip bombs | high | 8.7 | - | No | 2025-07-10 |
| CVE-2025-30204 | jwt-go allows excessive memory allocation during header parsing | high | 8.7 | - | No | 2025-03-21 |
| CVE-2024-45338 | Non-linear parsing of case-insensitive content in golang.org/x/net/html | high | 8.7 | - | No | 2024-12-18 |
| CVE-2024-45590 | body-parser vulnerable to denial of service when url encoding is enabled | high | 8.7 | - | No | 2024-09-10 |
| CVE-2021-38447 | OCI OpenDDS Secure Amplification | high | 8.6 | - | No | 2022-05-05 |
| CVE-2025-22166 | - | high | 8.3 | - | No | 2025-10-21 |
| CVE-2025-42874 | Denial of service (DOS) in SAP NetWeaver (remote service for Xcelsius) | high | 7.9 | - | No | 2025-12-09 |
| CVE-2026-125327 | pgEdge RAG Server unbounded corpus read allows resource exhaustion from unauthenticated requests | high | 7.5 | - | No | 2026-11-10 |

## Related weaknesses

| Relationship | CWE | Name |
| --- | --- | --- |
| Parent | [CWE-400](https://radicalnotion.ai/cwe/cwe-400) | Uncontrolled Resource Consumption |
| Child | [CWE-406](https://radicalnotion.ai/cwe/cwe-406) | Insufficient Control of Network Message Volume (Network Amplification) |
| Child | [CWE-407](https://radicalnotion.ai/cwe/cwe-407) | Inefficient Algorithmic Complexity |
| Child | [CWE-408](https://radicalnotion.ai/cwe/cwe-408) | Incorrect Behavior Order: Early Amplification |
| Child | [CWE-409](https://radicalnotion.ai/cwe/cwe-409) | Improper Handling of Highly Compressed Data (Data Amplification) |
| Child | [CWE-776](https://radicalnotion.ai/cwe/cwe-776) | Improper Restriction of Recursive Entity References in DTDs |
| Child | [CWE-1050](https://radicalnotion.ai/cwe/cwe-1050) | Excessive Platform Resource Consumption within a Loop |
| Child | [CWE-1072](https://radicalnotion.ai/cwe/cwe-1072) | Data Resource Access without Use of Connection Pooling |
| Child | [CWE-1073](https://radicalnotion.ai/cwe/cwe-1073) | Non-SQL Invokable Control Element with Excessive Number of Data Resource Accesses |
| Child | [CWE-1084](https://radicalnotion.ai/cwe/cwe-1084) | Invokable Control Element with Excessive File or Data Access Operations |
| Child | [CWE-1089](https://radicalnotion.ai/cwe/cwe-1089) | Large Data Table with Excessive Number of Indices |
| Child | [CWE-1094](https://radicalnotion.ai/cwe/cwe-1094) | Excessive Index Range Scan for a Data Resource |
| Child | [CWE-1176](https://radicalnotion.ai/cwe/cwe-1176) | Inefficient CPU Computation |
| Peer | [CWE-404](https://radicalnotion.ai/cwe/cwe-404) | Improper Resource Shutdown or Release |

## Taxonomy mappings

| Taxonomy | Entry | Id | Fit |
| --- | --- | --- | --- |
| PLOVER | Asymmetric resource consumption (amplification) | - | - |
| OWASP Top Ten 2004 | Denial of Service | A9 | CWE More Specific |
| WASC | XML Attribute Blowup | 41 | - |
| The CERT Oracle Secure Coding Standard for Java (2011) | Use thread pools to enable graceful degradation of service during traffic bursts | TPS00-J | - |
| The CERT Oracle Secure Coding Standard for Java (2011) | Release resources when they are no longer needed | FIO04-J | - |

## Frequently asked questions

### What is CWE-405?

The product does not properly control situations in which an adversary can cause the product to consume or produce excessive resources without requiring the adversary to invest equivalent work or otherwise prove authorization, i.e., the adversary's influence is "asymmetric."

### What CVEs are caused by CWE-405?

66 recorded CVEs are attributed to CWE-405, including CVE-2026-104817, CVE-2026-104431 and CVE-2026-104423.

### Is CWE-405 part of the OWASP Top 10?

CWE-405 maps to OWASP Top Ten 2004: Denial of Service (A9) in the OWASP security taxonomy.

### How do you prevent CWE-405?

An application must make resources available to a client commensurate with the client's access level.

### What are the consequences of CWE-405?

Exploiting CWE-405 can lead to: DoS: Amplification, DoS: Resource Consumption (CPU), DoS: Resource Consumption (Memory), DoS: Resource Consumption (Other).

### Is CWE-405 actively exploited?

66 recorded CVEs are caused by CWE-405; none are currently in CISA's KEV catalog of actively exploited flaws.

Primary source: [MITRE CWE](https://cwe.mitre.org/data/definitions/405.html)

---

Source: [RadicalNotion.AI](https://radicalnotion.ai/cwe/cwe-405). Licensed CC BY-NC 4.0; attribute RadicalNotion.AI and link the source page when you reuse this data.
