protobufjs
Affected
- introduced
0, fixed7.5.6(semver)
Fixed versions
7.5.6
Fix
- Fixed version
7.5.6npm install [email protected]
Advisory
Also known as: CVE-2026-44292
protobuf.js: Prototype injection in generated message constructors
Summary
protobufjs generated message constructors copied enumerable properties from a provided properties object without filtering the __proto__ key. If an application constructed a message from an attacker-controlled plain object, an own enumerable __proto__ property could alter the prototype of that individual message instance.
Impact
An attacker who can control the properties object passed to a generated protobufjs message constructor or creation helper may be able to modify the prototype chain of the resulting message instance.
This is a per-instance prototype injection issue. It does not pollute Object.prototype or other global prototypes. The impact depends on downstream application behavior, such as relying on inherited properties, prototype methods, or instanceof checks for message objects.
Applications that only decode binary protobuf data, or that construct messages from trusted application-defined objects, are not directly affected by this issue.
Preconditions
__proto__ property, for example from parsed JSON input.Workarounds
Do not pass attacker-controlled plain objects directly to generated message constructors with affected versions. If untrusted JSON input must be accepted, validate or sanitize object keys before constructing messages, and reject __proto__ properties.
Medium Basis: The source's own band: MODERATE
0, fixed 7.5.6 (semver)7.5.6
7.5.6npm install [email protected]8.0.0, fixed 8.0.2 (semver)8.0.2
8.0.2npm install [email protected]Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.
Check your own computer: guard packages check
Source: GitHub Advisory Database (reviewed advisories) · CC BY 4.0