{"id":"CVE-2026-41423","aliases":["GHSA-45q2-gjvg-7973"],"url":"https://o3.security/vulnerability/CVE-2026-41423","summary":"Angular: SSRF via protocol-relative and backslash URLs in Angular Platform-Server","details":"### Impact\n\nA [Server-Side Request Forgery (SSRF)](https://developer.mozilla.org/en-US/docs/Web/Security/Attacks/SSRF) vulnerability exists in `@angular/platform-server` due to improper handling of URLs during Server-Side Rendering (SSR).\n\nWhen an attacker sends a request such as `GET /\\evil.com/ HTTP/1.1` the server engine (Express, etc.) passes the URL string to Angular’s rendering functions.\n\nBecause the URL parser normalizes the backslash to a forward slash for HTTP/HTTPS schemes, the internal state of the application is hijacked to believe the current origin is `evil.com`. This misinterpretation tricks the application into treating the attacker’s domain as the local origin. Consequently, any relative `HttpClient` requests or `PlatformLocation.hostname` references are redirected to the attacker controlled server, potentially exposing internal APIs or metadata services.\n\n**Affected APIs:**\n- `renderModule`\n- `renderApplication`\n- `CommonEngine` (from `@angular/ssr`)\n\n**Non-Affected APIs:**\n- `AngularAppEngine` (from `@angular/ssr`)\n- `AngularNodeAppEngine` (from `@angular/ssr`)\n\n### Attack Preconditions\n- The server has outbound network access.\n- The application uses Angular SSR via the affected APIs.\n- A pathname is passed as URL to the rendering method  (e.g. using `req.url`).\n- The server-side code performs HTTP requests using `HttpClient` with relative URLs or uses `PlatformLocation.hostname` to build URLs. \n\n\n### Patches\n- 22.0.0-next.8\n- 21.2.9\n- 20.3.19\n- 19.2.21\n\n### Workarounds\nDevelopers should implement a middleware to sanitize the request URL before it reaches Angular. This involves stripping or normalizing leading slashes:\n\n```js\napp.use((req, res, next) => {\n  // Sanitize the URL to ensure it starts with a single forward slash\n  if (req.url.startsWith('//') || req.url.startsWith('/\\\\') || req.url.startsWith('\\\\')) {\n     req.url = '/' + req.url.replace(/^[/\\\\]+/, '');\n  }\n  next();\n});\n\n```\n### References\n- [Fix](https://github.com/angular/angular/pull/68194)","published":"2026-05-08T13:06:59.289Z","modified":"2026-08-12T03:51:46.751907603Z","cvss":null,"epss":{"score":0.00305,"percentile":0.23244,"asOf":"2026-09-17"},"cisaKev":null,"exploitsKnown":0,"affectedPackages":[{"ecosystem":"npm","name":"@angular/platform-server","fixedVersion":"22.0.0-next.8"},{"ecosystem":"npm","name":"@angular/platform-server","fixedVersion":"21.2.9"},{"ecosystem":"npm","name":"@angular/platform-server","fixedVersion":"20.3.19"},{"ecosystem":"npm","name":"@angular/platform-server","fixedVersion":"19.2.21"},{"ecosystem":"npm","name":"@angular/platform-server","fixedVersion":null}],"fix":{"url":"https://github.com/angular/angular/commit/ede7c58a2aa13fdccc8f0b67ce93ba1c11749412","label":"angular/angular@ede7c58"},"references":[{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/41xxx/CVE-2026-41423.json"},{"type":"ADVISORY","url":"https://github.com/angular/angular/security/advisories/GHSA-45q2-gjvg-7973"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-41423"},{"type":"FIX","url":"https://github.com/angular/angular/commit/ede7c58a2aa13fdccc8f0b67ce93ba1c11749412"},{"type":"FIX","url":"https://github.com/angular/angular/pull/68194"},{"type":"PACKAGE","url":"https://github.com/angular/angular"}],"provenance":{"sources":["OSV.dev","FIRST.org (EPSS)"],"lastVerified":"2026-08-12T03:51:46.751907603Z"}}