Skip to main content

node-re2 CVE-2026-68499

| EUVDEUVD-2026-51298 MEDIUM
Loop with Unreachable Exit Condition (Infinite Loop) (CWE-835)
2026-07-30 GitHub_M GHSA-6hxr-mr5r-9836
6.2
CVSS 3.1 · Vendor: GitHub_M
Share

Severity by source

Vendor (GitHub_M) PRIMARY
6.2 MEDIUM
AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
vuln.today AI
7.5 HIGH

Typical deployment exposes RE2 global match to network-supplied strings unauthenticated; zero-width trigger requires no privileges, only control over the subject string.

3.1 AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
4.0 AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Local
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
High

Lifecycle Timeline

3
Source Code Evidence Fetched
Jul 30, 2026 - 21:18 vuln.today
Analysis Generated
Jul 30, 2026 - 21:18 vuln.today
Patch available
Jul 30, 2026 - 21:04 EUVD

Blast Radius

ecosystem impact
† from your stack dependencies † transitive graph · vuln.today resolves 4-path depth
  • 40 npm packages depend on re2 (4 direct, 37 indirect)

Ecosystem-wide dependent count for version 1.25.2.

DescriptionCVE.org

re2 provides Node.js bindings for Google's RE2 regular expression engine. Prior to 1.25.2, re2's String.prototype.match implementation with a global RE2 pattern that can match the empty string fails to advance its native matching cursor in lib/match.cc, causing an infinite loop and unbounded native memory growth that blocks the event loop and can exhaust host memory. This issue is fixed in 1.25.2.

AnalysisAI

node-re2, the Node.js native binding for Google's RE2 regular expression engine, enters an infinite loop and leaks unbounded native memory when String.prototype.match is called with a global pattern capable of producing zero-width (empty string) matches. All versions prior to 1.25.2 are affected; because RE2 executes synchronously within the Node.js event loop thread, the hang is unrecoverable without a process restart, making any service that exposes RE2 global matching to externally-supplied input susceptible to complete denial of service. No public exploit code or CISA KEV listing has been identified at time of analysis, but the trigger condition is mechanically trivial and directly exercisable from patterns confirmed in the vendor's own test additions.

Technical ContextAI

node-re2 (CPE: cpe:2.3:a:uhop:node-re2:*:*:*:*:*:*:*:*) wraps Google's RE2 C++ engine as a Node.js native addon, providing ReDoS-safe regular expressions with a JavaScript-compatible API. The vulnerability is classified as CWE-835 (Loop with Unreachable Exit Condition) and originates in lib/match.cc: the global match iterator advanced the byte-index cursor by match.size() after each match; for zero-width matches this value is zero, so the cursor never moves and the loop iterates forever, accumulating result entries and consuming unbound native heap. The committed fix (https://github.com/uhop/node-re2/commit/56293de4fc0914d7bc35f92e98de25b0d9bb417d) adds an explicit branch in match.cc - when match.size() equals zero, the cursor advances by one UTF-8 code-point width using getUtf8CharSize(), preventing the stall. The same commit co-fixes a related issue in addon.cc and wrapped_re2.h where lastIndex bounds-checking used the UTF-8 byte length rather than the UTF-16 code-unit length of the subject string, which could allow an out-of-range lastIndex to read past the buffer on non-ASCII inputs (referenced internally as GHSA-ff84-5f28-78qj).

RemediationAI

Upgrade node-re2 to version 1.25.2, the vendor-released patch available at https://github.com/uhop/node-re2/releases/tag/1.25.2 and on npm as re2@1.25.2. Because the fix resides in the native C++ addon rather than pure JavaScript, a full package reinstall (npm install re2@^1.25.2 followed by npm rebuild if necessary) is required to replace the compiled binary. If an immediate upgrade is blocked, two specific compensating controls are available: first, audit all call sites that invoke RE2 with the global flag and add a pre-flight check to reject patterns that can match the empty string (e.g., verify the pattern does not match '' before use), at the cost of rejecting some legitimate patterns; second, run RE2 global-match operations in a worker thread or child process with a hard timeout and forcible termination on expiry, at the cost of added per-request latency and process-management complexity. Do not substitute Node.js's built-in RegExp engine as a workaround if the original motivation for adopting RE2 was ReDoS safety, since the two engines have fundamentally different worst-case complexity guarantees.

CVE-2024-41713 CRITICAL POC
9.1 Oct 21

A vulnerability in the NuPoint Unified Messaging (NPM) component of Mitel MiCollab through 9.8 SP1 FP2 (9.8.1.201) could

CVE-2024-55591 CRITICAL POC
9.8 Jan 14

FortiOS and FortiProxy contain an authentication bypass via the Node.js websocket module allowing unauthenticated remote

CVE-2023-44487 HIGH POC
7.5 Oct 10

Denial of service against HTTP/2 server implementations allows remote unauthenticated attackers to exhaust server resour

CVE-2014-7205 CRITICAL POC
10.0 Oct 08

Eval injection vulnerability in the internals.batch function in lib/batch.js in the bassmaster plugin before 1.5.2 for t

CVE-2025-59528 CRITICAL POC
10.0 Sep 22

Flowise version 3.0.5 contains a remote code execution vulnerability in the CustomMCP node. The mcpServerConfig paramete

CVE-2017-14849 HIGH POC
7.5 Sep 28

Node.js 8.5.0 before 8.6.0 allows remote attackers to access unintended files, because a change to ".." handling was inc

CVE-2017-5941 CRITICAL POC
9.8 Feb 09

An issue was discovered in the node-serialize package 0.0.4 for Node.js. Rated critical severity (CVSS 9.8), this vulner

CVE-2014-0224 HIGH POC
7.4 Jun 05

OpenSSL before 0.9.8za, 1.0.0 before 1.0.0m, and 1.0.1 before 1.0.1h does not properly restrict processing of ChangeCiph

CVE-2014-3744 HIGH POC
7.5 Oct 23

Directory traversal vulnerability in the st module before 0.2.5 for Node.js allows remote attackers to read arbitrary fi

CVE-2014-9566 HIGH POC
7.5 Mar 10

Multiple SQL injection vulnerabilities in the Manage Accounts page in the AccountManagement.asmx service in the Solarwin

CVE-2013-4660 MEDIUM POC
6.8 Jun 28

The JS-YAML module before 2.0.5 for Node.js parses input without properly considering the unsafe !!js/function tag, whic

CVE-2016-2107 MEDIUM POC
5.9 May 05

The AES-NI implementation in OpenSSL before 1.0.1t and 1.0.2 before 1.0.2h does not consider memory allocation during a

Share

CVE-2026-68499 vulnerability details – vuln.today

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy