CVE-2026-68499: uhop re2 infinite loop in String.prototype.match

CVE-2026-68499 · Severity: medium · CVSS 6.2 · Published 2026-07-30

The re2 library, a popular Node.js wrapper for the RE2 regular expression engine, is vulnerable to a denial-of-service attack. When processing certain patterns that can match empty strings, the library enters an infinite loop that rapidly consumes all available system memory and CPU. This can cause the entire application to freeze or crash, requiring a manual restart of the service.

Technologies: re2 (npm), Uhop Re2. Vendors: npm, Uhop.

Quick answers

Is CVE-2026-68499 exploited in the wild?
No. Junglewise Threat Intelligence has no report of CVE-2026-68499 being exploited in the wild.
How severe is CVE-2026-68499?
Medium severity, with a CVSS score of 6.2, published 30 July 2026.
Which products and versions are affected?
re2 (npm) SEMVER:introduced=0,fixed=1.25.2; Uhop Re2 < 1.25.2, <= 1.25.1.
Is there a fix for CVE-2026-68499?
Yes. re2 (npm): upgrade to 1.25.2 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.
How is CVE-2026-68499 attacked?
It is attacked with local access, in a software library.
Am I affected by CVE-2026-68499?
Check whether you run re2 (npm) or Uhop Re2 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

  • re2 (npm): upgrade to 1.25.2 or later
    npm install re2@1.25.2

Technical details

A vulnerability exists in the global match implementation within `lib/match.cc` of the node-re2 library. When `String.prototype.match` is called with a global RE2 object, the native C++ loop fails to advance the byte index if a zero-width (empty) match is found. This results in an infinite loop where the same empty match is repeatedly appended to a native vector, leading to 100% CPU utilization and rapid heap exhaustion. The issue is reachable if an attacker can influence either the regular expression pattern or the subject string. The vulnerability was fixed in version 1.25.2 by ensuring the cursor advances by at least one code point after an empty match.

Affected products

  • uhop re2 (npm) <= 1.25.1

Identifiers

  • CVE-2026-68499
  • GHSA-6hxr-mr5r-9836

Timeline

  • 2026-07-07: disclosed
  • 2026-07-30: advisory: NVD publication
  • 2026-07-31: patched: GitHub Advisory published and reviewed

References

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