CVE-2026-25762: @adonisjs/bodyparser Denial of Service Vulnerability

HIGH
Advisory Identifier: GHSA-xx9g-fh25-4q64
CVSS 7.5
CWE-400 CWE-770
Published
Advisory Summary

CVE-2026-25762 is a HIGH (CVSS 7.5) denial of service vulnerability (CWE-400: Uncontrolled Resource Consumption) affecting @adonisjs/bodyparser libraries in the npm ecosystem. The issue involves adonisjs vulnerable to denial of service (dos) via unrestricted memory buffering in parthandler during file type detection. Remediation is available by upgrading affected packages to version 10.1.3, 11.0.0-next.9.

CVE-2026-25762 at a Glance

CVE Identifier CVE-2026-25762
GHSA Identifier GHSA-xx9g-fh25-4q64
Severity HIGH
CVSS v3.1 Base Score 7.5
CWE Classification CWE-400: Uncontrolled Resource Consumption
Affected Product @adonisjs/bodyparser
Package Ecosystem npm
Published Date
Last Updated

Security Impact

CVSS: 7.5

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required None (PR:N)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality None (C:N)
Integrity None (I:N)
Availability High (A:H)

How to Fix CVE-2026-25762

To remediate this vulnerability, upgrade all affected @adonisjs/bodyparser dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

@adonisjs/bodyparser fixed: 10.1.3
npm install @adonisjs/bodyparser@10.1.3
@adonisjs/bodyparser fixed: 11.0.0-next.9
npm install @adonisjs/bodyparser@11.0.0-next.9
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

npm ls @adonisjs/bodyparser

How to Check if You Are Affected

To determine whether your Node.js application is affected by CVE-2026-25762, inspect your project dependencies using npm:

npm ls @adonisjs/bodyparser

Analyze the terminal output to locate any version of @adonisjs/bodyparser in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 10.1.3), your application is affected.

Note: The npm ls @adonisjs/bodyparser command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-400: Uncontrolled Resource Consumption, where the product does not properly control the allocation and maintenance of a limited resource. In @adonisjs/bodyparser, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Summary A Denial of Service (DoS) vulnerability (CWE-400) exists in the multipart file handling logic of `@adonisjs/bodyparser`. When processing file uploads, the multipart parser may accumulate an unbounded amount of data in memory while attempting to detect file types, potentially leading to excessive memory consumption and process termination. This issue affects applications that accept `multipart/form-data` uploads using affected versions of `@adonisjs/bodyparser`. ### Details AdonisJS parses `multipart/form-data` requests using the BodyParser package. During file uploads, the multipart parser attempts to detect the uploaded file type by accumulating incoming chunks in an internal buffer to perform magic number detection. The internal buffer used for this detection does not enforce a maximum size and is not protected by a timeout or early termination condition. If the uploaded data does not match any supported file signatures, the buffer continues to grow as more chunks are received. When certain configurations are used, such as deferred validations or permissive file size limits, this buffering behavior may persist for the duration of the upload stream. ### Impact Exploitation requires a reachable endpoint that accepts multipart file uploads. An attacker can send a specially crafted multipart request containing a large or unbounded stream of data that does not match known file signatures. This may cause the server to continuously allocate memory until the Node.js process exhausts available RAM and terminates due to an out-of-memory condition. This results in a Denial of Service, making the application unavailable to legitimate users. Authentication is not required if the upload endpoint is publicly accessible. ### Patches Fixes targeting v6 and v7 have been published below. Users should upgrade to a version that includes the following fix: - https://github.com/adonisjs/bodyparser/releases/tag/v10.1.3 - https://github.com/adonisjs/bodyparser/releases/tag/v11.0.0-next.9

CVE-2026-25762 Affected @adonisjs/bodyparser Versions

2 component(s)
Fixed Versions:
10.1.311.0.0-next.9
Product / Package Ecosystem Affected Versions Fixed Version
@adonisjs/bodyparser
npm
< 10.1.3
10.1.3
@adonisjs/bodyparser
npm
≥ 11.0.0-next.0
< 11.0.0-next.9
11.0.0-next.9

References

Frequently Asked Questions

What is CVE-2026-25762?
CVE-2026-25762 is a security vulnerability in @adonisjs/bodyparser involving AdonisJS vulnerable to Denial of Service (DoS) via Unrestricted Memory Buffering in PartHandler during File Type Detection under CWE-400: Uncontrolled Resource Consumption.
Which @adonisjs/bodyparser versions are affected?
Affected versions include releases prior to 10.1.3, 11.0.0-next.9 across affected packages: @adonisjs/bodyparser.
What version fixes CVE-2026-25762?
Upgrading to 10.1.3, 11.0.0-next.9 (or the latest patched release for your respective branch) resolves the vulnerability.
Is @adonisjs/bodyparser affected?
Yes, @adonisjs/bodyparser is affected in releases prior to 10.1.3, 11.0.0-next.9. Upgrade your dependency to 10.1.3, 11.0.0-next.9 or later.
What is the CVSS score of CVE-2026-25762?
CVE-2026-25762 has a CVSS v3.1 base score of 7.5 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H.
What CWE is associated with CVE-2026-25762?
CVE-2026-25762 is classified under CWE-400: Uncontrolled Resource Consumption (The product does not properly control the allocation and maintenance of a limited resource.).
How can I check npm dependencies for CVE-2026-25762?
Run the dependency tree command: 'npm ls @adonisjs/bodyparser'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-xx9g-fh25-4q64",
  "modified" : "2026-02-07T00:33:34Z",
  "published" : "2026-02-06T19:53:55Z",
  "aliases" : [ "CVE-2026-25762" ],
  "summary" : "AdonisJS vulnerable to Denial of Service (DoS) via Unrestricted Memory Buffering in PartHandler during File Type Detection",
  "details" : "### Summary\n\nA Denial of Service (DoS) vulnerability (CWE-400) exists in the multipart file handling logic of `@adonisjs/bodyparser`. When processing file uploads, the multipart parser may accumulate an unbounded amount of data in memory while attempting to detect file types, potentially leading to excessive memory consumption and process termination.\n\nThis issue affects applications that accept `multipart/form-data` uploads using affected versions of `@adonisjs/bodyparser`.\n\n### Details\n\nAdonisJS parses `multipart/form-data` requests using the BodyParser package. During file uploads, the multipart parser attempts to detect the uploaded file type by accumulating incoming chunks in an internal buffer to perform magic number detection.\n\nThe internal buffer used for this detection does not enforce a maximum size and is not protected by a timeout or early termination condition. If the uploaded data does not match any supported file signatures, the buffer continues to grow as more chunks are received.\n\nWhen certain configurations are used, such as deferred validations or permissive file size limits, this buffering behavior may persist for the duration of the upload stream.\n\n### Impact\n\nExploitation requires a reachable endpoint that accepts multipart file uploads.\n\nAn attacker can send a specially crafted multipart request containing a large or unbounded stream of data that does not match known file signatures. This may cause the server to continuously allocate memory until the Node.js process exhausts available RAM and terminates due to an out-of-memory condition.\n\nThis results in a Denial of Service, making the application unavailable to legitimate users. Authentication is not required if the upload endpoint is publicly accessible.\n\n### Patches\n\nFixes targeting v6 and v7 have been published below.\n\nUsers should upgrade to a version that includes the following fix:\n- https://github.com/adonisjs/bodyparser/releases/tag/v10.1.3\n- https://github.com/adonisjs/bodyparser/releases/tag/v11.0.0-next.9",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "npm",
      "name" : "@adonisjs/bodyparser"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "10.1.3"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 10.1.2"
    }
  }, {
    "package" : {
      "ecosystem" : "npm",
      "name" : "@adonisjs/bodyparser"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "11.0.0-next.0"
      }, {
        "fixed" : "11.0.0-next.9"
      } ]
    } ],
    "database_specific" : {
      "last_known_affected_version_range" : "<= 11.0.0-next.8"
    }
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/adonisjs/core/security/advisories/GHSA-xx9g-fh25-4q64"
  }, {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2026-25762"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/adonisjs/bodyparser/releases/tag/v10.1.3"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/adonisjs/bodyparser/releases/tag/v11.0.0-next.9"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/adonisjs/core"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-400", "CWE-770" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-02-06T19:53:55Z",
    "nvd_published_at" : "2026-02-06T23:15:54Z"
  }
}