CVE-2022-37617: thlorenz browserify-shim prototype pollution in resolveShims

CVE-2022-37617 · Severity: low · CVSS 3.1 · Published 2022-10-12

browserify-shim is a Node.js build tool that enables the use of browser-oriented libraries in CommonJS environments. A prototype pollution vulnerability in the resolveShims function allows attackers to inject malicious properties into JavaScript object prototypes, potentially leading to arbitrary code execution, data manipulation, or denial of service in applications using affected versions.

Technologies: browserify-shim (npm). Vendors: npm.

Quick answers

Is CVE-2022-37617 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2022-37617 being exploited in the wild.
How severe is CVE-2022-37617?
Low severity, with a CVSS score of 3.1, published 12 October 2022.
Which products and versions are affected?
browserify-shim (npm) SEMVER:introduced=0,fixed=3.8.16.
Is there a fix for CVE-2022-37617?
Yes. browserify-shim (npm): upgrade to 3.8.16 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2022-37617 attacked?
It is attacked over the network.
Am I affected by CVE-2022-37617?
Check whether you run browserify-shim (npm) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

How to fix

  • browserify-shim (npm): upgrade to 3.8.16 or later
    npm install browserify-shim@3.8.16

Technical details

A prototype pollution vulnerability exists in the resolveShims function within resolve-shims.js (versions ≤ 3.8.15), triggered via the k variable. The vulnerability allows an attacker to pollute the JavaScript Object prototype by crafting malicious input that assigns properties to the prototype chain. No authentication or user interaction is required; the vulnerability is triggered during the build/shim resolution process. Successful exploitation enables arbitrary property injection into all JavaScript objects, leading to code execution, function override, or application logic bypass. The vulnerability was patched in version 3.8.16 via commit 97855e622b6dcd117c77e6583701962ff45e7338.

Affected products

  • thlorenz browserify-shim 0 through 3.8.15

Identifiers

  • CVE-2022-37617
  • GHSA-866w-wm4h-95c6

Timeline

  • 2022-10-12: disclosed: Vulnerability advisory published
  • 2022-10-11: patched: Fixed in version 3.8.16

References

This page as Markdown. Free to reuse under CC BY 4.0 with a link back.