Skip to main content

@angular/common: XSRF Token Leakage via URL Parsing Discrepancy in Angular HTTP Client (Incomplete fix for CVE-2025-66035) (CVE-2026-111753)

0
Medium
Published: 10/20/2026 (10/20/2026, 20:37:57 UTC)
Source: GCVE Database
Product: @angular/common

Description

An incomplete fix in @angular/common's HttpClient for CVE-2025-66035 allows Cross-Site Request Forgery (XSRF) tokens to be leaked to attacker-controlled cross-origin domains due to discrepancies between a regular expression used for URL detection and the browser's WHATWG URL parser. This affects Angular versions prior to 21.0.3 and 20.3.34, where the XSRF token header may be attached to requests that the browser resolves as cross-origin. The vulnerability enables attackers to capture valid XSRF tokens if their server accepts the request and custom header via CORS, potentially enabling CSRF attacks. The issue is fixed in Angular 21.0.3, all 22.x releases, and 20.3.34 by replacing the regex with a proper origin comparison using the standard URL constructor.

CVSS v4.0

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
Present
Privileges Required
None
User Interaction
Active
Vuln. Confidentiality
High
Vuln. Integrity
None
Vuln. Availability
None
Subsq. Confidentiality
None
Subsq. Integrity
None
Subsq. Availability
None
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:A/VC:H/VI:N/VA:N/SC:N/SI:N/SA:N

Affected software

npmghsa
@angular/common
Affected versions
>=21.0.0 <21.0.3
npmghsa
@angular/common
Affected versions
>=20.0.0 <20.3.34
npmghsa
@angular/common
Affected versions
<=19.2.25

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 10/20/2026, 22:42:39 UTC

Technical Analysis

The vulnerability arises from an incomplete fix for CVE-2025-66035 in Angular's @angular/common HttpClient. The XSRF interceptor used a regular expression to detect absolute URLs and skip attaching the XSRF token header. However, the regex did not account for URL normalization performed by the browser's WHATWG URL parser, which treats backslashes as forward slashes and strips control characters. This mismatch causes certain crafted URLs to bypass the regex check, leading the interceptor to treat them as same-origin and attach the XSRF token header. When the browser resolves these URLs, they point to attacker-controlled cross-origin domains, leaking the token. The vulnerability affects versions >=20.0.0 <20.3.34, >=21.0.0 <21.0.3, and <=19.2.25. The fix replaces the regex with a robust origin comparison using new URL(req.url, locationOrigin).

Potential Impact

The vulnerability allows an attacker to obtain a victim user's valid XSRF token by causing the Angular application to send requests with the XSRF token header to attacker-controlled cross-origin URLs that bypass the interceptor's regex check. If the attacker's server permits the request and custom header via CORS, the attacker can capture the token and perform Cross-Site Request Forgery (CSRF) attacks against the victim's session. This bypasses Angular's built-in XSRF protection on affected versions.

Mitigation Recommendations

A patch is available and should be applied. The issue is fixed in Angular versions 21.0.3, all 22.x releases, and 20.3.34 by replacing the regex with a proper origin comparison using the standard URL constructor. If immediate upgrading is not possible, validate and normalize outgoing request URLs using new URL(url, window.location.origin) and verify that parsedUrl.origin === window.location.origin before passing dynamic URLs to mutating HttpClient requests. Avoid passing untrusted or user-controlled URLs to HttpClient mutating methods.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Gcve Source
db.gcve.eu
Osv Id
GHSA-jfgx-762w-99vr
Osv Schema Version
1.4.0
Aliases
["CVE-2026-111753"]
Ecosystems
["npm"]
Database Specific Severity
MODERATE
Cvss Version
4.0

Threat ID: 6ad7ec432cdf04f6566b9ed7

Added to database: 10/20/2026, 22:33:39 UTC

Last enriched: 10/20/2026, 22:42:39 UTC

Last updated: 10/20/2026, 22:42:39 UTC

Views: 4

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses