CVE-2025-66035 · GitHub_M
Angular HTTP Client Has XSRF Token Leakage via Protocol-Relative URLs
Angular is a development platform for building mobile and desktop web applications using TypeScript/JavaScript and other languages. Prior to versions 19.2.16, 20.3.14, and 21.0.1, there is a XSRF token leakage via protocol-relative URLs in angular HTTP clients. The vulnerability is a Credential Leak by App Logic that leads to the unauthorized disclosure of the Cross-Site Request Forgery (XSRF) token to an attacker-controlled domain. Angular's HttpClient has a built-in XSRF protection mechanism that works by checking if a request URL starts with a protocol (http:// or https://) to determine if it is cross-origin. If the URL starts with protocol-relative URL (//), it is incorrectly treated as a same-origin request, and the XSRF token is automatically added to the X-XSRF-TOKEN header. This issue has been patched in versions 19.2.16, 20.3.14, and 21.0.1. A workaround for this issue involves avoiding using protocol-relative URLs (URLs starting with //) in HttpClient requests. All backend communication URLs should be hardcoded as relative paths (starting with a single /) or fully qualified, trusted absolute URLs.
Published 2025-11-26, last changed 2026-10-19. Weakness: CWE-201, CWE-359.
How to fix
Upgrade to a fixed version: @angular/common 19.2.16, 20.3.14, 21.0.1 (npm) (each is the fix for its own release line). For the version that clears every advisory for your installed version, ask an agent for get_remediation.
Where the flaw is in the code
Fixed in angular/angular by 0276479e7d, 05fe6686a9, 3240d856d9. Functions changed by the fix: xsrfInterceptorFn. Regression tests: packages/common/http/test/xsrf_spec.ts. Confidence: verified (a record names this commit as the fix, and it changed these functions).
Timeline
| 2025-11-26 | Published |
| 2025-11-26 | Package advisory GHSA-58c5-g7wp-6w37 |
| 2026-10-19 | Record last changed |
| 2026-11-30 | EPSS when our history starts: 0.92% |
| 2026-12-04 | Code-level analysis added |
Affected packages
| Advisory | Package | Fixed in |
|---|---|---|
| GHSA-58c5-g7wp-6w37 | @angular/common (npm) | 21.0.1 |
| GHSA-58c5-g7wp-6w37 | @angular/common (npm) | 20.3.14 |
| GHSA-58c5-g7wp-6w37 | @angular/common (npm) | 19.2.16 |
Also known as: GHSA-58c5-g7wp-6w37
Related
| CVE | Published | CVSS | Summary |
|---|---|---|---|
| CVE-2026-111753 | 2026-11-05 | 5.9 | Angular: XSRF Token Leakage via URL Parsing Discrepancy in Angular HTTP Client (Incomplete fix for CVE-2025-66035) |
| CVE-2026-88059 | 2026-09-10 | 5.8 | Angular: Information Leak via `HttpTransferCache` Bypass When Using `withRequestsMadeViaParent` |
| CVE-2026-68945 | 2026-08-03 | 6.1 | Angular: Cache-Key Ambiguity in HttpTransferCache Leading to Cross-Request Response Reuse and State Poisoning |
| CVE-2026-50171 | 2026-06-22 | 6.1 | Angular: Denial of Service (DoS) via OOM in Number Formatting (digitsInfo) |
| CVE-2026-50170 | 2026-06-22 | 7.5 | Angular: Information Leak via Default Caching of Credentialed Requests in HttpTransferCache |
| CVE-2026-54268 | 2026-06-22 | 7.5 | Angular: Denial of Service (DoS) via OOM in Date Formatting (formatDate) |
| CVE-2026-54266 | 2026-06-22 | 6.1 | Angular: Weak 32-Bit Cache Key Hashing in `HttpTransferCache` Leading to Cross-Request Data Leakage and State Poisoning |
| CVE-2026-129992 | 2026-11-18 | 6.3 | Dokploy: Failed builds and backups send every application secret in plain text to notifications |
Add it to your agent
One command for Claude Code; setup for Claude Desktop, Cursor and others. No signup or key.
claude mcp add --transport http keygraph-cve https://cve-mcp.keygraph.io/mcp
Then ask for triage_cve CVE-2025-66035, or call /api/v1/vulnerabilities/CVE-2025-66035. To prove whether it is exploitable in your running app, run Shannon, Keygraph's open-source AI pentester.