Medium

@angular/platform-server: Open Redirect via Protocol-Relative URLs in Server-Side Rendering (SSR)

  • Disclosed: 20.10.2026
  • Updated: 20.10.2026 18:18

An open redirect vulnerability was identified in @angular/platform-server when Server-Side Rendering (SSR) is enabled.

When Angular SSR renders an incoming request, URL resolution and platform navigation are managed by ServerPlatformLocation using resolveUrl (or parseUrl in v20). While resolveUrl rejected protocol-relative URLs whose raw string directly started with //, this check ran prior to WHATWG URL normalization.

When a request URL includes a popping dot-segment followed by multiple slashes (such as /.//evil.test or serialized from router route shapes like /.;/(//evil.test)), the input bypassed the initial urlStr.startsWith('//') check. Subsequent WHATWG URL parsing resolved the dot-segments and resulted in a pathname starting with // (//evil.test).

Consequently, ServerPlatformLocation stored pathname = '//evil.test'. When @angular/ssr detected a mismatch between the rendered URL and the router's final location state, it emitted the unnormalized pathname into the HTTP Location response header, producing an HTTP 302 redirect with Location: //evil.test, which browsers resolve as a protocol-relative navigation off-origin.

Impact

Successful exploitation allows an unauthenticated remote attacker to craft URLs that trick Angular SSR into redirecting users to an arbitrary external domain.

  • Bypasses Application-Level Guards: Common application-level validation routines (such as checking !returnUrl.startsWith('//') before invoking router.navigateByUrl) accept /.//evil.test or /.;/(//evil.test) as a safe relative path, allowing attackers to bypass redirect allowlists.
  • Client-side SPAs Unaffected: Pure client-side Angular applications (Single Page Applications without SSR) are not vulnerable, as ServerPlatformLocation is only utilized in server-side execution environments.

Attack Preconditions & Vulnerable Configurations

An application is affected if the following conditions are met:

  • SSR Enabled: The application runs in a Server-Side Rendering environment using @angular/platform-server and @angular/ssr.
  • Parameter Route Shapes: The router contains parameter routes with wildcard or child segments (e.g. /:tenant matching . and serializing secondary outlet groups (//evil.test) to /.//evil.test), or passes user-provided navigation targets (e.g. returnUrl).
  • Reverse Proxy Passthrough: Upstream reverse proxies (Nginx, Cloudflare, ALB) pass semicolons (;) or dot-segments without stripping or normalizing them.

Exploit Payload Example

An attacker sends a request targeting a route with parameters and child segments:

http
GET /.;/(//evil.test) HTTP/1.1
Host: example.com

Response:

http
HTTP/1.1 302 Found
Location: //evil.test

The client browser resolves //evil.test protocol-relatively and redirects the user away from example.com to evil.test.

Patches

The issue is resolved by updating resolveUrl (and parseUrl in v20) in @angular/platform-server to verify that the normalized URL pathname does not start with // when allowProtocolRelative is false.

  • 22.2.1
  • 21.2.25
  • 20.3.33

Workarounds & Mitigations

If you cannot immediately upgrade to a patched version, apply one of the following mitigations at your edge reverse proxy or WAF:

  1. Reject Paths with Dot-Segments Followed by Slashes: Configure your reverse proxy (e.g., Nginx, Cloudflare, AWS WAF) to block requests containing /.//, /..//, or /.;/:
    nginx
    # Nginx example: reject suspicious path normalization sequences
    if ($request_uri ~* "(\n/\.\/|\/\.\;)") {
        return 400;
    }
  2. Sanitize Redirect Headers: Ensure edge proxies or API gateways rewrite or disallow protocol-relative (//) Location response headers originating from the SSR upstream.

What to do

Update @angular/platform-server to patched version 22.2.1, 21.2.25, or 20.3.33.

If upgrading immediately is not feasible, apply workarounds at the reverse proxy or WAF level:

  • Block requests containing dot-segments followed by slashes (/.//, /..//, or /.;/).
  • Sanitize, rewrite, or reject protocol-relative Location response headers originating from the upstream SSR server.

Affected software

Click a technology to see all vulnerabilities affecting it.

PlatformPackageVulnerable versionsFixed in
npm package @angular/platform-server >= 22.0.0, < 22.2.1, >= 21.0.0, < 21.2.25, >= 20.0.0, < 20.3.33, <= 19.2.25 22.2.1, 21.2.25, 20.3.33

References

CVSS score -
CVSS vector
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:N/VI:N/VA:N/SC:L/SI:L/SA:N
Weakness (CWE)
CWE-601
Platform
npm
Package
@angular/platform-server
Disclosed
20.10.2026
Updated
20.10.2026 18:18

Sources and licenses · Edited or translated by DockRay; source rights and applicable licenses are retained.

OSV / GitHub Advisory Database - GHSA-w739-gvwx-grc3 - CC BY 4.0

Vulnerability history: @angular/platform-server

All published vulnerabilities of this package (npm package), newest first. Shows whether this is a one-off slip or a package that needs watching.

All (12) in the archive
Total entries
12
First → latest
09.2025 10.2026
Without a fix
0
Exploited in attacks
0

Severity breakdown

  • High 11
  • Medium 1

Disclosures per year

  1. 2025: 1
  2. 2026: 11
Severity:
  1. @angular/platform-server: Open Redirect via Protocol-Relative URLs in Server-Side Rendering (SSR) this entry
    Medium CVE-2026-111754 >= 22.0.0, < 22.2.1, >= 21.0.0, < 21.2.25, >= 20.0.0, < 20.3.33, <= 19.2.25 22.2.1, 21.2.25, 20.3.33
  2. High CVE-2026-101895 >= 22.0.0, < 22.1.6, >= 21.0.0, < 21.2.23, >= 20.0.0, < 20.3.31, <= 19.2.25 22.1.6, 21.2.23, 20.3.31
  3. High CVE-2026-88058 >= 22.0.0, < 22.1.4, >= 21.0.0, < 21.2.22, >= 20.0.0, < 20.3.30, <= 19.2.25 22.1.4, 21.2.22, 20.3.30
  4. High CVE-2026-88060 >= 22.0.0, < 22.1.4, >= 21.0.0, < 21.2.22, >= 20.0.0, < 20.3.30, <= 19.2.25 22.1.4, 21.2.22, 20.3.30
  5. High CVE-2026-88056 >= 22.0.0, < 22.1.4, >= 21.0.0, < 21.2.22, >= 20.0.0, < 20.3.30, <= 19.2.25 22.1.4, 21.2.22, 20.3.30
  6. High CVE-2026-69149 >= 22.0.0-next.0, < 22.0.7, >= 21.0.0-next.0, < 21.2.19, >= 20.0.0-next.0, < 20.3.27, <= 19.2.25 22.0.7, 21.2.19, 20.3.27
  7. High CVE-2026-50556 >= 22.0.0-next.0, < 22.0.0-rc.2, >= 21.0.0-next.0, < 21.2.16, >= 20.0.0-next.0, < 20.3.24, >= 19.0.0-next.0, < 19.2.25, <= 18.2.14 22.0.0-rc.2, 21.2.16, 20.3.24, 19.2.25
  8. High · 6.1 CVE-2026-50555 >= 22.0.0-next.0, < 22.0.0-rc.2, >= 21.0.0-next.0, < 21.2.16, >= 20.0.0-next.0, < 20.3.24, >= 19.0.0-next.0, < 19.2.25, <= 18.2.14 22.0.0-rc.2, 21.2.16, 20.3.24, 19.2.25
  9. High · 8.2 CVE-2026-50168 >= 22.0.0-next.0, < 22.0.0-rc.2, >= 20.0.0-next.0, < 20.3.22, >= 19.0.0-next.0, < 19.2.23, <= 18.2.14, >= 21.0.0-next.0, < 21.2.15 22.0.0-rc.2, 20.3.22, 19.2.23, 21.2.15
  10. High · 6.1 CVE-2026-46417 >= 22.0.0-next.0, < 22.0.0-next.12, >= 21.0.0-next.0, < 21.2.13, >= 20.0.0-next.0, < 20.3.21, >= 19.0.0-next.0, < 19.2.22, <= 18.2.14 22.0.0-next.12, 21.2.13, 20.3.21, 19.2.22
  11. High CVE-2026-41423 >= 22.0.0-next.0, < 22.0.0-next.8, >= 21.0.0-next.0, < 21.2.9, >= 20.0.0-next.0, < 20.3.19, >= 19.0.0-next.0, < 19.2.21, <= 18.2.14 22.0.0-next.8, 21.2.9, 20.3.19, 19.2.21
  12. High CVE-2025-59052 >= 16.0.0-next.0, < 18.2.14, >= 20.0.0-next.0, < 20.3.0, >= 19.0.0-next.0, < 19.2.15, >= 21.0.0-next.0, < 21.0.0-next.3 18.2.14, 20.3.0, 19.2.15, 21.0.0-next.3

Know which vulnerabilities affect your application

With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.

Connect your application
DockRay newsletter

Application security in your inbox

Important vulnerabilities, actionable guidance and practical advice for your applications. Choose your technologies and follow what matters to your project.

  • A daily digest of new vulnerabilities, critical ones included.
  • Notifications about important updates.
  • Practical advice on application security and monitoring.

Leave empty to receive updates for every technology.

Free to subscribe. Unsubscribe with one click in any email.