Skip to content

Prototype Pollution leading to Remote Code Execution in superjson

Critical severity GitHub Reviewed Published Feb 9, 2022 in blitz-js/superjson • Updated Nov 1, 2023

Package

npm blitz (npm)

Affected versions

< 0.45.3

Patched versions

0.45.3
npm superjson (npm)
< 1.8.1
1.8.1

Description

Impact

This is critical vulnerability, as it allows to run arbitrary code on any server using superjson input, including a Blitz.js server, without prior authentication or knowledge. Attackers gain full control over the server so they could steal and manipulate data or attack further systems. The only requirement is that the server implements at least one endpoint which uses superjson during request processing. In the case of Blitz.js, it would be at least one RPC call.

Patches

This has been patched in superjson 1.8.1 and Blitz.js 0.45.3.

If you are unable to upgrade to Blitz.js 0.45.3 in a timely manner, you can instead upgrade only superjson to version 1.8.1 using yarn resolutions are similar. Blitz versions < 0.45.3 are only affected because they used superjson versions < 1.8.1.

Workarounds

None

For more information

If you have any questions or comments about this advisory:

References

References

@flybayer flybayer published to blitz-js/superjson Feb 9, 2022
Published by the National Vulnerability Database Feb 9, 2022
Published to the GitHub Advisory Database Feb 9, 2022
Reviewed Feb 9, 2022
Last updated Nov 1, 2023

Severity

Critical
9.1
/ 10

CVSS base metrics

Attack vector
Network
Attack complexity
High
Privileges required
None
User interaction
None
Scope
Changed
Confidentiality
High
Integrity
High
Availability
High
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:H/I:H/A:H

CVE ID

CVE-2022-23631

GHSA ID

GHSA-5888-ffcr-r425

Source code

Credits

Checking history
See something to contribute? Suggest improvements for this vulnerability.