CVE-2026-82417: qs Denial of Service via Attacker Controlled isBuffer
Summary
CVE-2026-82417: qs: Denial of Service via Attacker Controlled isBuffer. Affects qs versions >= 2.2.5, < 6.16.0. Fixed in 6.16.0. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
The 'qs' package is a widely used library in the Node.js ecosystem for parsing and stringifying query strings. It provides a simple API for converting objects to query strings and vice versa, making it essential for handling URL parameters in web applications. However, a vulnerability has been identified that allows an attacker to exploit the 'isBuffer' function, leading to potential denial of service (DoS) conditions.
Vulnerability Detail
The vulnerability arises from the way 'qs.stringify()' interacts with 'utils.isBuffer()'. The 'isBuffer()' function calls 'obj.constructor.isBuffer(obj)' without verifying if 'constructor.isBuffer' is callable. If an attacker can manipulate the input to 'qs.parse' with options 'plainObjects: true' or 'allowPrototypes: true', they can create an object where 'constructor.isBuffer' is a non-function. This results in 'qs.stringify' throwing a TypeError during serialization, which can lead to application crashes or unhandled exceptions, degrading service availability.
How To Fix
Latest published version: 6.16.1 as of 22 Oct 2026
npm install qs@6.16.1
Upgrading to it may include breaking changes; the version below is the minimum fixed release for this vulnerability.
If you need the minimum change
6.16.0
This is the first release that contains the fix.
npm install qs@6.16.0
Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →
Workaround
If you cannot immediately update the package, consider implementing a check before calling 'qs.stringify' to ensure that the input does not contain any maliciously crafted objects. For example:
if (typeof obj.constructor.isBuffer === 'function') {
qs.stringify(obj);
} else {
console.error('Invalid object structure');
}
Conclusion
CVE-2026-82417 is a significant vulnerability in the 'qs' package that can lead to denial of service through improper handling of input objects. It is crucial for developers using this package to update to the patched version and implement necessary checks to ensure application stability.
See every vulnerability recorded for qs →
FAQ
The impact includes potential denial of service, where an attacker can cause the application to throw unhandled exceptions, leading to crashes and service unavailability.
You can use Vulert to monitor and alert for open-source vulnerabilities in your software. Visit Vulert Scanner to check if your application is affected without requiring any signup.
The recommended action is to update the 'qs' package to version 6.16.0 or later, which contains the necessary fixes for this vulnerability.
If immediate updates are not possible, implement input validation to ensure that objects passed to 'qs.stringify' do not contain malicious structures.
The CVSS score for this vulnerability is 5.3, indicating a moderate severity level.
References
Related vulnerabilities
Recent vulnerabilities recorded for qs.