Intel

AIKIDO-2026-179881

@orpc/json-schema is vulnerable to Prototype Pollution

Prototype PollutionGHSA-4h5r-cv8j-4456 Published 6 days ago

65

Medium Risk

This Affects:

JS@orpc/json-schema
0.0.0 - 1.14.8
Fixed in 1.14.9
Are you affected? Scan for Free

TL;DR

JsonSchemaCoercer in the smart coercion plugin coerces request input before schema validation and mishandles object keys that name Object.prototype members. An attacker who can reach a procedure whose input schema contains an object can send keys such as __proto__ or constructor to replace the prototype of the coerced input object or make inherited members pass the coercer's satisfaction check. The effect is scoped to the single coerced value returned for that request rather than the global Object.prototype, but a handler that reads inherited properties can act on data the client never legitimately supplied. The fix collects coerced properties into a null-prototype object and restricts sub-schema lookups to own properties via Object.hasOwn.

Who does this affect?

You are affected if you are using a version that falls within the vulnerable range and your server installs the SmartCoercionPlugin with at least one procedure whose input schema contains an object.

Background info

@orpc/json-schema is vulnerable to Prototype Pollution in versions 0.0.0 - 1.14.8.

How to fix this

Upgrade the @orpc/json-schema library to the patch version.