THREATOPS
THREAT OPS › Threat News › [GHSA] GHSA-r7hq-q2xm-6c5m (medium) — @grpc/grpc-js: safe_regex incorrectly applies partial string matching for patterns with alternation

[GHSA] GHSA-r7hq-q2xm-6c5m (medium) — @grpc/grpc-js: safe_regex incorrectly applies partial string matching for patterns with alternation

highgithub_advisoriesPublished 2026-11-12

GHSA-r7hq-q2xm-6c5m Severity: medium CVE: CVE-2026-126367

@grpc/grpc-js: safe_regex incorrectly applies partial string matching for patterns with alternation

### Summary

The StringMatcher/PathMatcher for `safe_regex` builds its RE2 as `^${regex}$` with no surrounding group. Because alternation has the lowest precedence, a pattern `"a|b|c"` compiles to `/^a|b|c$/` -- "starts with a" OR "contains

MITRE ATT&CK techniques

Indicators of compromise

Original source: https://github.com/advisories/GHSA-r7hq-q2xm-6c5m