CVE-2026-104871: Path Traversal Vulnerability in @angular/ssr Leading to Unauthorized Access

@angular/ssr Updated 06 Oct 2026

Summary

05/10/2026
Yes i
Moderate
6.3

CVE-2026-104871: Angular SSR: Path Traversal to Sibling Directories in CommonEngine on Windows. Affects @angular/ssr across 4 version ranges.

< 19.2.27 >= 20.0.0, < 20.3.36 >= 21.0.0, < 21.2.23 >= 22.0.0, < 22.1.7

Fixed in 4 releases; the minimum fixed version depends on the release line you run. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

The @angular/ssr package is a server-side rendering engine for Angular applications, enabling developers to generate static HTML pages for improved performance and SEO. This package is widely used in web applications to enhance user experience by pre-rendering content. However, a specific vulnerability has been identified that affects the prerendered page retrieval logic, particularly on Windows systems.

Vulnerability Detail

A Path Traversal vulnerability exists in the prerendered page retrieval logic of CommonEngine in @angular/ssr. When deployed on Windows, an attacker can craft a request path with backslash directory traversal sequences, allowing unauthorized access to prerendered static pages from sibling directories. This vulnerability arises from improper handling of relative URLs and Windows file paths, leading to potential information disclosure of sensitive HTML pages.

How To Fix

Latest published version: 22.2.4 as of 22 Oct 2026

npm install @angular/ssr@22.2.4

Upgrading to it may include breaking changes; the versions below are the minimum fixed release for this vulnerability.

If you can't move to the latest

The minimum fixed version depends on the release line you run.

  • < 19.2.27 19.2.27
    npm install @angular/ssr@19.2.27
  • >= 20.0.0, < 20.3.36 20.3.36
    npm install @angular/ssr@20.3.36
  • >= 21.0.0, < 21.2.23 21.2.23
    npm install @angular/ssr@21.2.23
  • >= 22.0.0, < 22.1.7 22.1.7
    npm install @angular/ssr@22.1.7

Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →

Workaround

Until a patch is applied, developers can sanitize request URLs in the server.ts file before passing them to CommonEngine.render. Here is a code snippet to normalize backslashes or construct a full HTTP URL:

server.use((req, res, next) => {
  const { protocol, originalUrl, headers } = req;

  // Normalize backslashes or construct a full HTTP URL
  const sanitizedUrl = `${protocol}://$ {headers.host}${originalUrl.replace(/\\/g, '/')}`;

  commonEngine
    .render({
      bootstrap,
      documentFilePath: indexHtml,
      url: sanitizedUrl,
      publicPath: distFolder,
    })
    .then((html) => res.send(html))
    .catch((err) => next(err));
});

Conclusion

The Path Traversal vulnerability in @angular/ssr poses a significant risk to applications running on Windows, allowing unauthorized access to sensitive prerendered pages. It is crucial to update to the latest patched versions or implement the suggested workarounds to mitigate this risk.

See every vulnerability recorded for @angular/ssr →

Share this vulnerability

FAQ

The vulnerability is a Path Traversal issue that allows unauthorized access to prerendered HTML pages from sibling directories on Windows systems.

Affected versions include >= 22.0.0, < 22.1.7; >= 21.0.0, < 21.2.23; >= 20.0.0, < 20.3.36; and <= 19.2.27.

You can use Vulert's playground to check if your application is affected by this vulnerability without requiring any signup.

The vulnerability can lead to information disclosure of sensitive prerendered HTML pages, which may contain internal application data.

Implement the provided workaround to sanitize request URLs until you can apply the necessary updates.

Related vulnerabilities

Recent vulnerabilities recorded for @angular/ssr.

How To Fix

Latest published version: 22.2.4 as of 22 Oct 2026

npm install @angular/ssr@22.2.4

Upgrading to it may include breaking changes; the versions below are the minimum fixed release for this vulnerability.

If you can't move to the latest

The minimum fixed version depends on the release line you run.

  • < 19.2.27 19.2.27
    npm install @angular/ssr@19.2.27
  • >= 20.0.0, < 20.3.36 20.3.36
    npm install @angular/ssr@20.3.36
  • >= 21.0.0, < 21.2.23 21.2.23
    npm install @angular/ssr@21.2.23
  • >= 22.0.0, < 22.1.7 22.1.7
    npm install @angular/ssr@22.1.7

Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback