High

AdonisJS vulnerable to Denial of Service (DoS) via Unrestricted Memory Buffering in PartHandler during File Type Detection

  • Disclosed: 06.02.2026
  • Updated: 11.10.2026 10:22

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:

Affected software

Click a technology to see all vulnerabilities affecting it.

PlatformPackageVulnerable versionsFixed in
npm package @adonisjs/bodyparser < 10.1.3, >= 11.0.0-next.0, < 11.0.0-next.9 10.1.3, 11.0.0-next.9

References

CVSS score 7.5/10
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
Weakness (CWE)
CWE-400, CWE-770
Platform
npm
Package
@adonisjs/bodyparser
Disclosed
06.02.2026
Updated
11.10.2026 10:22

Sources and licenses

OSV / GitHub Advisory Database - GHSA-xx9g-fh25-4q64 - CC BY 4.0

Vulnerability history: @adonisjs/bodyparser

All published vulnerabilities of this package (npm package), newest first. Shows whether this is a one-off slip or a package that needs watching.

Total entries
4
First → latest
01.2026 06.2026
Without a fix
0
Exploited in attacks
0

Severity breakdown

  • Critical 1
  • High 3

Disclosures per year

  1. 2026: 4
  1. High · 8.6 CVE-2026-48795 >= 10.1.3, < 10.1.5, >= 11.0.0-next.9, < 11.0.3 10.1.5, 11.0.3
  2. AdonisJS vulnerable to Denial of Service (DoS) via Unrestricted Memory Buffering in PartHandler during File Type Detection this entry
    High · 7.5 CVE-2026-25762 < 10.1.3, >= 11.0.0-next.0, < 11.0.0-next.9 10.1.3, 11.0.0-next.9
  3. High · 7.2 CVE-2026-25754 < 10.1.3, >= 11.0.0-next.0, < 11.0.0-next.9 10.1.3, 11.0.0-next.9
  4. Critical CVE-2026-21440 < 10.1.2, >= 11.0.0-next.0, < 11.0.0-next.6 10.1.2, 11.0.0-next.6

Know which vulnerabilities affect your application

With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.

Connect your application
DockRay newsletter

Application security in your inbox

Important vulnerabilities, actionable guidance and practical advice for your applications. Choose your technologies and follow what matters to your project.

  • A daily digest of new vulnerabilities, critical ones included.
  • Notifications about important updates.
  • Practical advice on application security and monitoring.

Leave empty to receive updates for every technology.

Free to subscribe. Unsubscribe with one click in any email.