---
id: "CVE-2026-113872"
kind: "vulnerability"
aliases: ["CVE-2026-113872", "GHSA-q7qp-rjg7-q26m"]
title: "multer vulnerable to Denial of Service via a pending asynchronous fileFilter after request teardown"
severity: "high"
cvss: 7.5
epss: 0.00441
exploited: false
status: "open"
category: "package"
products: [{"name": "multer", "fixed": ["2.5.0"], "affected": ">= 2.0.0, < 2.5.0", "ecosystem": "npm"}]
ecosystems: ["npm"]
tags: ["cwe-248", "cwe-404", "express", "multer", "node.js", "package", "self-hosted"]
not_affected_if: ["sync-filefilter", "version-outside-range"]
published_at: "2026-10-22T15:17:05+00:00"
first_seen_at: "2026-10-23T21:57:31+00:00"
updated_at: "2026-10-25T03:15:10+00:00"
sources: [{"source": "nvd", "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-113872", "first_seen_at": "2026-10-23T21:57:31+00:00"}, {"source": "ghsa", "url": "https://github.com/advisories/GHSA-q7qp-rjg7-q26m", "first_seen_at": "2026-10-23T22:15:56+00:00"}, {"source": "epss", "url": "https://api.first.org/data/v1/epss?cve=CVE-2026-113872", "first_seen_at": "2026-10-24T07:15:51+00:00"}]
---

# multer vulnerable to Denial of Service via a pending asynchronous fileFilter after request teardown

multer, a Node.js middleware for multipart uploads, crashes the whole process when a request is aborted while an asynchronous fileFilter is still pending. A single unauthenticated request is enough to take the application down repeatedly.

_Summary, check and fix written by a model from the sources; labelled as such._

## Affected

- npm:multer affected >= 2.0.0, < 2.5.0 fixed 2.5.0

## How to check

- Run `npm ls multer` to see the installed version.
- Search the code for `fileFilter` and check whether the function is async (returns a promise or uses a callback that runs later).

## Fix

- Upgrade `multer` to `2.5.0` or later.
- Workaround until upgrade: switch the `fileFilter` to a synchronous function.

## Timeline

- 2026-10-23T21:57:31+00:00 nvd https://nvd.nist.gov/vuln/detail/CVE-2026-113872
- 2026-10-23T22:15:56+00:00 ghsa https://github.com/advisories/GHSA-q7qp-rjg7-q26m
- 2026-10-24T07:15:51+00:00 epss https://api.first.org/data/v1/epss?cve=CVE-2026-113872

## From the sources

multer is a middleware for Node.js that handles multipart/form-data file uploads. In versions from 2.0.0 before 2.5.0, when multer is configured with an asynchronous fileFilter, a single request can crash the Node.js process. If the request is aborted while one file's asynchronous fileFilter is still pending, the pending callback later resumes a parsing stream that multer has already torn down, and the underlying parser emits an error on a stream that no longer has an error listener, which Node raises as an unhandled error event so the process exits. Any application using multer with an asynchronous fileFilter is affected regardless of storage engine, while uploads using a synchronous fileFilter are not affected. The issue is fixed in multer 2.5.0, and users should upgrade to 2.5.0 or later. As a workaround, use a synchronous fileFilter.

---

_Free to read at a human pace. An API with keys and an MCP server are in preparation; early access: hello@infrastack.ai_
