Skip to content

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Sep 11, 2025

Note

Mend has cancelled the proposed renaming of the Renovate GitHub app being renamed to mend[bot].

This notice will be removed on 2025-10-07.


This PR contains the following updates:

Package Change Age Confidence
@angular/ssr 20.0.0 -> 20.3.0 age confidence

GitHub Vulnerability Alerts

CVE-2025-59052

Impact

Angular uses a DI container (the "platform injector") to hold request-specific state during server-side rendering. For historical reasons, the container was stored as a JavaScript module-scoped global variable. When multiple requests are processed concurrently, they could inadvertently share or overwrite the global injector state.

In practical terms, this can lead to one request responding with data meant for a completely different request, leaking data or tokens included on the rendered page or in response headers. As long as an attacker had network access to send any traffic that received a rendered response, they may have been able to send a large number of requests and then inspect the responses for information leaks.

The following APIs were vulnerable and required SSR-only breaking changes:

  • bootstrapApplication: This function previously implicitly retrieved the last platform injector that was created. It now requires an explicit BootstrapContext in a server environment. This function is only used for standalone applications. NgModule-based applications are not affected.
  • getPlatform: This function previously returned the last platform instance that was created. It now always returns null in a server environment.
  • destroyPlatform: This function previously destroyed the last platform instance that was created. It's now a no-op when called in a server environment.

For bootstrapApplication, the framework now provides a new argument to the application's bootstrap function:

// Before:
const bootstrap = () => bootstrapApplication(AppComponent, config);

// After:
const bootstrap = (context: BootstrapContext) =>
  bootstrapApplication(AppComponent, config, context);

As is usually the case for changes to Angular, an automatic schematic will take care of these code changes as part of ng update:

# For apps on Angular v20:
ng update @​angular/cli @​angular/core

# For apps on Angular v19:
ng update @​angular/cli@19 @​angular/core@19

# For apps on Angular v18:
ng update @​angular/cli@18 @​angular/core@18

The schematic can also be invoked explicitly if the version bump was pulled in independently:

# For apps on Angular v20:
ng update @​angular/core --name add-bootstrap-context-to-server-main

# For apps on Angular v19:
ng update @​angular/core@19 --name add-bootstrap-context-to-server-main

# For apps on Angular v18:
ng update @​angular/core@18 --name add-bootstrap-context-to-server-main

For applications that still use CommonEngine, the bootstrap property in CommonEngineOptions also gains the same context argument in the patched versions of Angular.

In local development (ng serve), Angular CLI triggered a codepath for Angular's "JIT" feature on the server even in applications that weren't using it in the browser. The codepath introduced async behavior between platform creation and application bootstrap, triggering the race condition even if an application didn't explicitly use getPlatform or custom async logic in bootstrap. Angular applications should never run in this mode outside of local development.

Patches

The issue has been patched in all active release lines as well as in the v21 prerelease:

  • @angular/platform-server: 21.0.0-next.3

  • @angular/platform-server: 20.3.0

  • @angular/platform-server: 19.2.15

  • @angular/platform-server: 18.2.14

  • @angular/ssr: 21.0.0-next.3

  • @angular/ssr: 20.3.0

  • @angular/ssr: 19.2.16

  • @angular/ssr: 18.2.21

Workarounds

  • Disable SSR via Server Routes (v19+) or builder options.
  • Remove any asynchronous behavior from custom bootstrap functions.
  • Remove uses of getPlatform() in application code.
  • Ensure that the server build defines ngJitMode as false.

References


Release Notes

angular/angular-cli (@​angular/ssr)

v20.3.0

Compare Source

Breaking Changes

@​angular/ssr
  • The server-side bootstrapping process has been changed to eliminate the reliance on a global platform injector.

    Before:

    const bootstrap = () => bootstrapApplication(AppComponent, config);

    After:

    const bootstrap = (context: BootstrapContext) =>
      bootstrapApplication(AppComponent, config, context);
@​schematics/angular
Commit Type Description
ef20a278d fix align labels in ai-config schema
@​angular/cli
Commit Type Description
f6ad41c13 fix improve bun lockfile detection and optimize lockfile checks
@​angular-devkit/build-angular
Commit Type Description
1a7890873 fix avoid extra tick in SSR builds
@​angular/build
Commit Type Description
5d46d6ec1 fix preserve names in esbuild for improved debugging in dev mode
@​angular/ssr
Commit Type Description
7eacb4187 feat introduce BootstrapContext for isolated server-side rendering

v20.2.2

Compare Source

@​angular/cli
Commit Type Description
a793bbc47 fix don't set a default for array options when length is 0
2736599e2 fix set process title when running architect commands
@​angular/build
Commit Type Description
5c2abffea fix avoid extra tick in SSR dev-server builds
f3c826853 fix maintain media output hashing with vitest unit-testing

v20.2.1

Compare Source

@​angular/cli
Commit Type Description
3b693e09e fix correctly set default array values
@​schematics/angular
Commit Type Description
6937123a3 fix directly resolve karma config template in migration
5d6dd4425 fix prevent AI config schematic from failing when 'none' and other AI tools are selected
@​angular-devkit/schematics-cli
Commit Type Description
e93919dea fix correctly set default array values
@​angular/build
Commit Type Description
06a6ddc10 fix correct JS/TS file paths when running under Bazel
b6816b0cb fix ensure karma polyfills reporter factory returns a value

v20.2.0

Compare Source

@​angular/cli
Commit Type Description
b4de9a1bf feat add --experimental-tool option to mcp command
755ba70fd feat add --local-only option to mcp command
59d7ef343 feat add --read-only option to mcp command
4e92eb6f1 feat add modernize tool to the MCP server
a3b25f675 fix add choices to command line parser when type is array and has an enum
e19eee614 fix address Node.js deprecation DEP0190
4ee6f327a fix apply default to array types
8ba6b0bcc fix use correct path for MCP get_best_practices tool
@​schematics/angular
Commit Type Description
2e3cfd598 feat add migration to remove default Karma configurations
d80dae276 feat add schematics to generate ai context files.
ffe6fb916 fix allow AI config prompt to be skipped without selecting a value
ae2802b7d fix improve AI config prompt wording
b017f84fd fix improve coverage directory handling for Karma configuration comparisons
6a79f9a75 fix zoneless is now stable
@​angular-devkit/schematics
Commit Type Description
c43504d8d fix address Node.js deprecation DEP0190
@​angular/build
Commit Type Description
fb06bb505 feat add headless mode for vitest browser mode

v20.1.6

Compare Source

@​schematics/angular
Commit Type Description
584bc1d41 fix add extra prettier config
02b0506fd fix correct configure the typeSeparator in the library schematic

v20.1.5

Compare Source

@​angular/cli
Commit Type Description
48ca04474 fix cache MCP best practices content and add tool annotations

v20.1.4

Compare Source

@​angular/cli
Commit Type Description
2d753cc62 fix skip workspace-specific tools when outside a workspace
@​angular/build
Commit Type Description
42d72ef4d fix skip vite transformation of CSS-like assets

v20.1.3

Compare Source

@​angular/build
Commit Type Description
ea5cd0e81 fix update vite to 7.0.6

v20.1.2

Compare Source

@​angular/cli
Commit Type Description
96785224f fix define option is being included multiple times in the JSON help
@​angular-devkit/core
Commit Type Description
0d0040bdf fix use crypto.randomUUID instead of Date.now for unique string in tmp file names

v20.1.1

Compare Source

@​angular/build
Commit Type Description
541b33f8d fix emit a warning when outputHashing is set to all or bundles when HMR is enabled
558a0fe92 fix normalize code coverage include paths to POSIX

v20.1.0

Compare Source

@​angular/cli
Commit Type Description
dc45c186e feat add initial MCP server implementation
@​schematics/angular
Commit Type Description
1c19e0dcd feat use signal in app component
@​angular-devkit/build-angular
Commit Type Description
49a09737d feat provide partial custom postcss configuration support
@​angular/build
Commit Type Description
1159cf081 feat add code coverage reporters option for unit-test
8f305ef0b feat add dataurl, base64 loaders
adfeee0a4 fix adjust coverage includes/excludes for unit-test vitest runner
c19cd2985 fix coverage reporter option
8879716ca fix expose unit test and karma builder API
a415a4999 fix improve default coverage reporter handling for vitest
e0de8680d fix inject zone.js/testing before karma builder execution
2672f6ec1 fix json and json-summary as vitest coverage reporters
b67fdfd6b fix resolve "Controller is already closed" error in Karma
2784883ec fix support extra test setup files with unit-test vitest runner
f177f5508 fix support injecting global styles into vitest unit-tests
130c65014 fix use an empty array as default value for vitest exclude
917af12ae fix use date/time based output path for vitest unit-test
@​angular/ssr
Commit Type Description
21b5852f1 fix ensure loadChildren runs in correct injection context during route extraction

v20.0.6

Compare Source

@​schematics/angular
Commit Type Description
5542445d3 fix remove constructor from service template
@​angular/build
Commit Type Description
0836ad28f fix correctly remap Angular diagnostics
c475e546b fix exclude @vitest/browser/context from esbuild bundling
1a2da161e fix failed to proxy error for assets

v20.0.5

Compare Source

@​angular-devkit/build-angular
Commit Type Description
1ebd53df7 fix remove unused @vitejs/plugin-basic-ssl dependency
@​angular/build
Commit Type Description
05cebdbcd fix proxy karma request from / to /base

v20.0.4

Compare Source

@​schematics/angular
Commit Type Description
2316fe29d fix add missing prettier config
@​angular/ssr
Commit Type Description
309742289 fix avoid preloading unnecessary dynamic bundles
82691b98f fix ensure correct referer header handling in web request conversion

v20.0.3

Compare Source

@​schematics/angular
Commit Type Description
e90a808c0 fix include main.server.ts in tsconfig.files when present
5c48b8e0a fix reset module typeSeparator when generating applications
@​angular/build
Commit Type Description
56f426e25 fix include custom bundle name scripts with karma
dfe3a8b73 fix increase worker idle timeout
e6d27bd5e fix set scripts option output as classic script for karma

v20.0.2

Compare Source

@​schematics/angular
Commit Type Description
bf64a0f2d fix add less as a devDependency when selected as the style preprocessor
cb258a3e1 fix correctly detect modules using new file extension format
@​angular/build
Commit Type Description
424f1cbbf fix do not consider internal Angular files as external imports

v20.0.1

Compare Source

@​angular/cli
Commit Type Description
0883248cb fix improve Node.js version check and error messages
@​schematics/angular
Commit Type Description
525ddcbd2 fix only overwrite JSON file if actually changed
83c820e5a fix remove karma config devkit package usages during application migration
87266b38a fix skip zone.js dependency for zoneless applications
@​angular/build
Commit Type Description
e5efdc577 fix also disable outputMode in vitest unit-tests
5814393db fix resolve junit karma reporter output to workspace root

Configuration

📅 Schedule: Branch creation - "" (UTC), Automerge - At any time (no schedule defined).

🚦 Automerge: Enabled.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

Copy link

netlify bot commented Sep 11, 2025

Deploy Preview for test-angular-starter-template failed. Why did it fail? →

Name Link
🔨 Latest commit b2cf37d
🔍 Latest deploy log https://app.netlify.com/projects/test-angular-starter-template/deploys/68d56faa0a0d39000744e512

Copy link

netlify bot commented Sep 11, 2025

Deploy Preview for testing-angular-template failed. Why did it fail? →

Name Link
🔨 Latest commit b2cf37d
🔍 Latest deploy log https://app.netlify.com/projects/testing-angular-template/deploys/68d56faae1c56a00089f9e5e

@renovate renovate bot force-pushed the renovate/npm-angular-ssr-vulnerability branch from 551f5fe to b2cf37d Compare September 25, 2025 16:36
@renovate renovate bot changed the title fix(deps): update dependency @angular/ssr to v20.3.0 [security] chore(deps): update dependency @angular/ssr to v20.3.0 [security] Sep 25, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

0 participants