CVE-2026-136921 in nconfinfo

Summary

by MITRE • 11/25/2026

nconf through 1.0.0-beta.2 contains a prototype pollution vulnerability in the Memory store merge() function in lib/nconf/stores/memory.js that lacks __proto__ key rejection. Attackers controlling merge keys like '__proto__:isAdmin' or nested __proto__ properties can inject properties into Object.prototype, altering application logic or causing errors.

If you want to get best quality of vulnerability data, you may have to visit VulDB.

Analysis

by VulDB Data Team • 11/25/2026

The vulnerability identified in nconf versions through 1.0.0-beta.2 represents a critical Prototype Pollution flaw located within the Memory store implementation of the library. Specifically, the issue resides in the merge() function found in lib/nconf/stores/memory.js. This component is responsible for combining configuration objects, but it fails to implement necessary safeguards against malicious input structures that target JavaScript's prototype chain. In modern JavaScript engines, all objects inherit from Object.prototype by default. When a library processes user-controlled or untrusted data without validating the keys being merged, an attacker can inject properties directly into this global prototype object. The specific failure here is the lack of rejection for the _proto_ key, which allows direct manipulation of the prototype chain during the merging process.

From a technical perspective, JavaScript objects are dynamic and allow property assignment at runtime. When the merge() function encounters a key named _proto_, it does not treat it as a regular configuration parameter but instead uses it to set properties on the base Object.prototype. This means that any subsequent object created in the application environment will inherit these injected properties. For example, if an attacker injects '_proto_:isAdmin' with a value of true, every new object instantiated after this operation will possess an isAdmin property set to true by default. Similarly, injecting nested _proto_ structures can lead to deeper levels of prototype pollution, potentially affecting built-in methods or other libraries that rely on standard object behaviors. This mechanism bypasses normal scope and isolation boundaries within the JavaScript runtime environment.

The operational impact of this vulnerability is severe because it allows for arbitrary code execution logic alteration or denial of service conditions without requiring direct access to execute system commands. By polluting Object.prototype, an attacker can alter application logic in ways that were not intended by the developers. For instance, if the application uses property checks like 'if (user.isAdmin)' to determine authorization levels, prototype pollution could grant unauthorized administrative privileges to any user who triggers this vulnerability. Furthermore, injecting non-serializable or complex objects into Object.prototype can cause runtime errors when other parts of the application attempt to iterate over object properties using methods such as for...in loops or JSON.stringify(). This leads to instability and potential crashes in production environments where configuration data is frequently loaded and merged.

This flaw aligns with CWE-1325, which covers Prototype Pollution vulnerabilities resulting from improper validation of input keys during object merging operations. It also maps to the MITRE ATT&CK technique T1078, specifically related to valid accounts or privilege escalation if the pollution affects authentication logic. Additionally, it relates to CWE-94 regarding Improper Control of Generation of Code (Code Injection) in scenarios where the polluted prototype leads to unintended code paths being executed due to altered object states. The vulnerability highlights a common pitfall in JavaScript configuration management libraries that prioritize convenience over strict input sanitization during deep merge operations.

To mitigate this risk, developers should immediately upgrade nconf to version 1.0.0-beta.3 or later, where the prototype pollution vector has been addressed by implementing proper key validation and rejection of _proto_ keys. For applications unable to upgrade immediately, a temporary workaround involves manually sanitizing configuration inputs before passing them to the merge function. This can be achieved by filtering out any keys that match '_proto_', 'constructor', or 'prototype' strings. Additionally, using Object.freeze() on critical objects or employing libraries with built-in protection against prototype pollution can provide an additional layer of defense. It is also recommended to review all instances where user-controlled data influences configuration merging and ensure that deep merge operations are performed safely by checking for dangerous keys before assignment.

Responsible

VulnCheck

Reservation

11/25/2026

Disclosure

11/25/2026

Moderation

accepted

CPE

ready

EPSS

0.00595

KEV

no

Activities

very low

Sources

Do you want to use VulDB in your project?

Use the official API to access entries easily!