Vulnerabilities/

protobuf.js: Code injection through bytes field defaults in generated toObject code

Severity:
High

Description

protobufjs generated JavaScript for toObject conversion could include an unsafe expression derived from a schema-controlled bytes field default value. A crafted descriptor with a non-string default value for a bytes field could cause attacker-controlled code to be emitted into the generated conversion function.

Recommendation

Update the protobufjs package to the latest compatible version. Followings are version details:

References

Related Issues

Tags:
npm
protobufjs
Anything's wrong? Let us know Last updated on May 12, 2026