Vulnerabilities in pkg:npm/convict
PACKAGECVE-2026-33864 is a CRITICAL convict has prototype pollution vulnerability (CWE-1321: Improperly Controlled Modification of Object Prototype Attributes ('Prototype Pollution')) affecting Convict libraries in the npm ecosystem. The issue involves convict has prototype pollution via startswith() function. Remediation is available by upgrading affected packages to version 6.2.5.
pkg:npm/convict
Vulnerability advisories affecting package pkg:npm/convict. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-44fc-8fm5-q62h | CVE-2026-33864 | CRITICAL | Convict has Prototype Pollution via startsWith() function |
| GHSA-hf2r-9gf9-rwch | CVE-2026-33863 | CRITICAL | Convict has prototype pollution via load(), loadFile(), and schema initialization |
| GHSA-4jrm-c32x-w4jf | CVE-2023-0163 | HIGH | convict vulnerable to Prototype Pollution |
| GHSA-x2w5-725j-gf2g | CVE-2022-22143 | HIGH | Prototype Pollution in convict |
| GHSA-jjf5-wx3j-3fv7 | CVE-2022-21190 | CRITICAL | Prototype Pollution in convict |
CVE-2026-33864 at a Glance
How to Fix CVE-2026-33864
To remediate this vulnerability, upgrade all affected Convict dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
npm install convict@6.2.5
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls convict
How to Check if You Are Affected
To determine whether your Node.js application is affected by CVE-2026-33864, inspect your project dependencies using npm:
npm ls convict
Analyze the terminal output to locate any version of Convict in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 6.2.5), your application is affected.
Note: The npm ls convict 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-1321: Improperly Controlled Modification of Object Prototype Attributes ('Prototype Pollution'), where the product receives input from an upstream component that specifies attributes that are to be initialized or updated in an object, but it does not properly control modifications of attributes of the object prototype. In Convict, 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
CVE-2026-33864 Affected Convict Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
convict
|
npm |
< 6.2.5
|
6.2.5
|
References
Frequently Asked Questions
What is CVE-2026-33864?
Which Convict versions are affected?
What version fixes CVE-2026-33864?
Is convict affected?
What CWE is associated with CVE-2026-33864?
How can I check npm dependencies for CVE-2026-33864?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-44fc-8fm5-q62h",
"modified" : "2026-03-26T18:55:41Z",
"published" : "2026-03-26T18:55:41Z",
"aliases" : [ "CVE-2026-33864" ],
"summary" : "Convict has Prototype Pollution via startsWith() function",
"details" : "### Summary\nA prototype pollution vulnerability exists in the latest version of the convict npm package (6.2.4). Despite a previous fix that attempted to mitigate prototype pollution by checking whether user input started with a forbidden key, it is still possible to pollute `Object.prototype` via a crafted input using `String.prototype`. \n\n### Details\nThe vulnerability resides in line 564 of https://github.com/mozilla/node-convict/blob/master/packages/convict/src/main.js where `startsWith()` function is used to check whether user provided input contain forbidden strings. \n\n### PoC\n#### Steps to reproduce\n1. Install latest version of convict using `npm install` or cloning from git\n2. Run the following code snippet:\n\n```javascript\nString.prototype.startsWith = () => false; \nconst convict = require('convict');\nlet obj = {};\nconst config = convict(obj);\nconsole.log({}.polluted);\nconfig.set('constructor.prototype.polluted', 'yes');\nconsole.log({}.polluted); // prints yes -> the patch is bypassed and prototype pollution occurred\n```\n\n#### Expected behavior\nPrototype pollution should be prevented and {} should not gain new properties.\nThis should be printed on the console:\n```\nundefined\nundefined OR throw an Error\n```\n\n#### Actual behavior\n`Object.prototype` is polluted \nThis is printed on the console:\n```\nundefined \nyes\n```\n\n### Impact\nThis is a prototype pollution vulnerability, which can have severe security implications depending on how convict is used by downstream applications. Any application that processes attacker-controlled input using `convict.set` may be affected.\nIt could potentially lead to the following problems:\n\n1. Authentication bypass\n2. Denial of service\n3. Remote code execution (if polluted property is passed to sinks like eval or child_process)",
"severity" : [ {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "convict"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "6.2.5"
} ]
} ],
"database_specific" : {
"last_known_affected_version_range" : "<= 6.2.4"
}
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/mozilla/node-convict/security/advisories/GHSA-44fc-8fm5-q62h"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/mozilla/node-convict"
}, {
"type" : "WEB",
"url" : "https://github.com/mozilla/node-convict/blob/master/packages/convict/src/main.js"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-1321" ],
"severity" : "CRITICAL",
"github_reviewed" : true,
"github_reviewed_at" : "2026-03-26T18:55:41Z",
"nvd_published_at" : null
}
}