Skip to content

chore(deps): update dependency @angular/core to v20.3.18 [security]#3685

Open
renovate[bot] wants to merge 1 commit intomasterfrom
renovate/npm-angular-core-vulnerability
Open

chore(deps): update dependency @angular/core to v20.3.18 [security]#3685
renovate[bot] wants to merge 1 commit intomasterfrom
renovate/npm-angular-core-vulnerability

Conversation

@renovate
Copy link
Copy Markdown
Contributor

@renovate renovate Bot commented Mar 5, 2026

This PR contains the following updates:

Package Change Age Confidence
@angular/core (source) 20.3.1020.3.18 age confidence

Angular has XSS Vulnerability via Unsanitized SVG Script Attributes

CVE-2026-22610 / GHSA-jrmj-c5cx-3cw6

More information

Details

A Cross-Site Scripting (XSS) vulnerability has been identified in the Angular Template Compiler. The vulnerability exists because Angular’s internal sanitization schema fails to recognize the href and xlink:href attributes of SVG <script> elements as a Resource URL context.

In a standard security model, attributes that can load and execute code (like a script's source) should be strictly validated. However, because the compiler does not classify these specific SVG attributes correctly, it allows attackers to bypass Angular's built-in security protections.

When template binding is used to assign user-controlled data to these attributes for example, <script [attr.href]="userInput"> the compiler treats the value as a standard string or a non-sensitive URL rather than a resource link. This enables an attacker to provide a malicious payload, such as a data:text/javascript URI or a link to an external malicious script.

Impact

When successfully exploited, this vulnerability allows for arbitrary JavaScript execution within the context of the victim's browser session. This can lead to:

  • Session Hijacking: Stealing session cookies, localStorage data, or authentication tokens.
  • Data Exfiltration: Accessing and transmitting sensitive information displayed within the application.
  • Unauthorized Actions: Performing state-changing actions (like clicking buttons or submitting forms) on behalf of the authenticated user.
Attack Preconditions
  1. The victim application must explicitly use SVG <script> elements within its templates.
  2. The application must use property or attribute binding (interpolation) for the href or xlink:href attributes of those SVG scripts.
  3. The data bound to these attributes must be derived from an untrusted source (e.g., URL parameters, user-submitted database entries, or unsanitized API responses).
Patches
  • 19.2.18
  • 20.3.16
  • 21.0.7
  • 21.1.0-rc.0
Workarounds

Until the patch is applied, developers should:

  • Avoid Dynamic Bindings: Do not use Angular template binding (e.g., [attr.href]) for SVG <script> elements.
  • Input Validation: If dynamic values must be used, strictly validate the input against a strict allowlist of trusted URLs on the server side or before it reaches the template.
Resources

Severity

  • CVSS Score: 8.5 / 10 (High)
  • Vector String: CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:A/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

References

This data is provided by the GitHub Advisory Database (CC-BY 4.0).


Angular i18n vulnerable to Cross-Site Scripting

CVE-2026-27970 / GHSA-prjf-86w9-mfqv

More information

Details

A Cross-site Scripting (XSS) vulnerability has been identified in the Angular internationalization (i18n) pipeline. In ICU messages (International Components for Unicode), HTML from translated content was not properly sanitized and could execute arbitrary JavaScript.

Angular i18n typically involves three steps, extracting all messages from an application in the source language, sending the messages to be translated, and then merging their translations back into the final source code. Translations are frequently handled by contracts with specific partner companies, and involve sending the source messages to a separate contractor before receiving final translations for display to the end user.

If the returned translations have malicious content, it could be rendered into the application and execute arbitrary JavaScript.

Impact

When successfully exploited, this vulnerability allows for execution of attacker controlled JavaScript in the application origin. Depending on the nature of the application being exploited this could lead to:

  • Credential Exfiltration: Stealing sensitive user data stored in page memory, LocalStorage, IndexedDB, or cookies available to JS and sending them to an attacker controlled server.
  • Page Vandalism: Mutating the page to read or act differently than intended by the developer.
Attach Preconditions
  • The attacker must compromise the translation file (xliff, xtb, etc.).
  • Unlike most XSS vulnerabilities, this one is not exploitable by arbitrary users. An attacker must first compromise an application's translation file before they can escalate privileges into the Angular application client.
  • The victim application must use Angular i18n.
  • The victim application must use one or more ICU messages.
  • The victim application must render an ICU message.
  • The victim application must not defend against XSS via a safe Content-Security Policy (CSP) or Trusted Types.
Patches
  • 21.2.0
  • 21.1.6
  • 20.3.17
  • 19.2.19
Workarounds

Until the patch is applied, developers should consider:

  • Reviewing and verifying translated content received from untrusted third parties before incorporating it in an Angular application.
  • Enabling strict CSP controls to block unauthorized JavaScript from executing on the page.
  • Enabling Trusted Types to enforce proper HTML sanitization.
References

Severity

  • CVSS Score: 7.0 / 10 (High)
  • Vector String: CVSS:4.0/AV:L/AC:L/AT:N/PR:H/UI:A/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

References

This data is provided by the GitHub Advisory Database (CC-BY 4.0).


Angular vulnerable to XSS in i18n attribute bindings

CVE-2026-32635 / GHSA-g93w-mfhg-p222

More information

Details

A Cross-Site Scripting (XSS) vulnerability has been identified in the Angular runtime and compiler. It occurs when the application uses a security-sensitive attribute (for example href on an anchor tag) together with Angular's ability to internationalize attributes. Enabling internationalization for the sensitive attribute by adding i18n-<attribute> name bypasses Angular's built-in sanitization mechanism, which when combined with a data binding to untrusted user-generated data can allow an attacker to inject a malicious script.

The following example illustrates the issue:

<a href="" i18n-href>Click me</a>

The following attributes have been confirmed to be vulnerable:

  • action
  • background
  • cite
  • codebase
  • data
  • formaction
  • href
  • itemtype
  • longdesc
  • poster
  • src
  • xlink:href
Impact

When exploited, this vulnerability allows an attacker to execute arbitrary code within the context of the vulnerable application's domain. This enables:

  • Session Hijacking: Stealing session cookies and authentication tokens.
  • Data Exfiltration: Capturing and transmitting sensitive user data.
  • Unauthorized Actions: Performing actions on behalf of the user.
Attack Preconditions
  1. The application must use a vulnerable version of Angular.
  2. The application must bind unsanitized user input to one of the attributes mentioned above.
  3. The bound value must be marked for internationalization via the presence of a i18n-<name> attribute on the same element.
Patches
  • 22.0.0-next.3
  • 21.2.4
  • 20.3.18
  • 19.2.20
Workarounds

The primary workaround is to ensure that any data bound to the vulnerable attributes is never sourced from untrusted user input (e.g., database, API response, URL parameters) until the patch is applied, or when it is, it shouldn't be marked for internationalization.

Alternatively, users can explicitly sanitize their attributes by passing them through Angular's DomSanitizer:

import {Component, inject, SecurityContext} from '@&#8203;angular/core';
import {DomSanitizer} from '@&#8203;angular/platform-browser';

@&#8203;Component({
  template: `
    <form action="" i18n-action>
      <button>Submit</button>
    </form>
  `,
})
export class App {
  url: string;

  constructor() {
    const dangerousUrl = 'javascript:alert(1)';
    const sanitizer = inject(DomSanitizer);
    this.url = sanitizer.sanitize(SecurityContext.URL, dangerousUrl) || '';
  }
}
References

Severity

  • CVSS Score: 8.6 / 10 (High)
  • Vector String: CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N

References

This data is provided by the GitHub Advisory Database (CC-BY 4.0).


Release Notes

angular/angular (@​angular/core)

v20.3.18

Compare Source

compiler
Commit Type Description
02fbf08890 fix disallow translations of iframe src
core
Commit Type Description
72126f9a08 fix sanitize translated attribute bindings with interpolations
626bc8bc20 fix sanitize translated form attributes

v20.3.17

Compare Source

Breaking Changes

core
  • Angular now only applies known attributes from HTML in translated ICU content. Unknown attributes are dropped and not rendered.

    (cherry picked from commit 03da204)

core
Commit Type Description
7f9de3c118 fix block creation of sensitive URI attributes from ICU messages

v20.3.16

Compare Source

core
Commit Type Description
c2c2b4aaa8 fix sanitize sensitive attributes on SVG script elements

v20.3.15

Compare Source

compiler
Commit Type Description
d1ca8ae043 fix prevent XSS via SVG animation attributeName and MathML/SVG URLs

v20.3.14

Compare Source

http
Commit Type Description
0276479e7d fix prevent XSRF token leakage to protocol-relative URLs

v20.3.13

Compare Source

v20.3.12

Compare Source

v20.3.11

Compare Source

common
Commit Type Description
5047849a4a fix remove placeholder image listeners once view is removed
compiler
Commit Type Description
f9d0818087 fix support arbitrary nesting in :host-context()
106b9040df fix support commas in :host() argument
9419ea348a fix support complex selectors in :nth-child()
036c5d2a07 fix support one additional level of nesting in :host()
core
Commit Type Description
dcdd1bcdbb fix skip leave animations on view swaps

Configuration

📅 Schedule: (UTC)

  • Branch creation
    • ""
  • Automerge
    • At any time (no schedule defined)

🚦 Automerge: Enabled.

Rebasing: Whenever PR is behind base branch, 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.

@renovate
Copy link
Copy Markdown
Contributor Author

renovate Bot commented Mar 5, 2026

⚠️ Artifact update problem

Renovate failed to update an artifact related to this branch. You probably do not want to merge this PR as-is.

♻ Renovate will retry this branch, including artifacts, only when one of the following happens:

  • any of the package files in this branch needs updating, or
  • the branch becomes conflicted, or
  • you click the rebase/retry checkbox if found above, or
  • you rename this PR's title to start with "rebase!" to trigger it manually

The artifact failure details are included below:

File name: package-lock.json
npm warn Unknown env config "store". This will stop working in the next major version of npm. See `npm help npmrc` for supported config options.
npm error code ERESOLVE
npm error ERESOLVE could not resolve
npm error
npm error While resolving: @angular/animations@20.3.10
npm error Found: @angular/core@20.3.18
npm error node_modules/@angular/core
npm error   dev @angular/core@"20.3.18" from the root project
npm error   peer @angular/core@">=16.0.0" from @acrodata/code-editor@0.5.1
npm error   node_modules/@acrodata/code-editor
npm error     @acrodata/code-editor@"0.5.1" from the root project
npm error   14 more (@angular-devkit/build-angular, @angular/build, ...)
npm error
npm error Could not resolve dependency:
npm error peer @angular/core@"20.3.10" from @angular/animations@20.3.10
npm error node_modules/@angular/animations
npm error   dev @angular/animations@"20.3.10" from the root project
npm error   peerOptional @angular/animations@"20.3.10" from @angular/platform-browser@20.3.10
npm error   node_modules/@angular/platform-browser
npm error     dev @angular/platform-browser@"20.3.10" from the root project
npm error     9 more (@angular-devkit/build-angular, @angular/build, ...)
npm error   2 more (ngx-bootstrap, ngx-ui-switch)
npm error
npm error Conflicting peer dependency: @angular/core@20.3.10
npm error node_modules/@angular/core
npm error   peer @angular/core@"20.3.10" from @angular/animations@20.3.10
npm error   node_modules/@angular/animations
npm error     dev @angular/animations@"20.3.10" from the root project
npm error     peerOptional @angular/animations@"20.3.10" from @angular/platform-browser@20.3.10
npm error     node_modules/@angular/platform-browser
npm error       dev @angular/platform-browser@"20.3.10" from the root project
npm error       9 more (@angular-devkit/build-angular, @angular/build, ...)
npm error     2 more (ngx-bootstrap, ngx-ui-switch)
npm error
npm error Fix the upstream dependency conflict, or retry this command with --force or --legacy-peer-deps to accept an incorrect (and potentially broken) dependency resolution.
npm error
npm error
npm error For a full report see:
npm error /runner/cache/others/npm/_logs/2026-05-03T18_34_17_493Z-eresolve-report.txt
npm error A complete log of this run can be found in: /runner/cache/others/npm/_logs/2026-05-03T18_34_17_493Z-debug-0.log

@renovate renovate Bot force-pushed the renovate/npm-angular-core-vulnerability branch 6 times, most recently from c2767b0 to 6d638e9 Compare March 6, 2026 07:42
@renovate renovate Bot force-pushed the renovate/npm-angular-core-vulnerability branch 2 times, most recently from cbfceda to ac7bc55 Compare March 14, 2026 03:06
@renovate renovate Bot changed the title chore(deps): update dependency @angular/core to v20.3.17 [security] chore(deps): update dependency @angular/core to v20.3.18 [security] Mar 14, 2026
@renovate renovate Bot force-pushed the renovate/npm-angular-core-vulnerability branch from ac7bc55 to 962f8c9 Compare March 14, 2026 06:33
@renovate renovate Bot changed the title chore(deps): update dependency @angular/core to v20.3.18 [security] chore(deps): update dependency @angular/core to v20.3.17 [security] Mar 14, 2026
@renovate renovate Bot force-pushed the renovate/npm-angular-core-vulnerability branch from 962f8c9 to ea6a3b4 Compare March 22, 2026 16:37
@renovate renovate Bot changed the title chore(deps): update dependency @angular/core to v20.3.17 [security] chore(deps): update dependency @angular/core to v20.3.18 [security] Mar 22, 2026
@renovate renovate Bot force-pushed the renovate/npm-angular-core-vulnerability branch from ea6a3b4 to d4c3ea2 Compare March 23, 2026 05:03
@renovate renovate Bot changed the title chore(deps): update dependency @angular/core to v20.3.18 [security] chore(deps): update dependency @angular/core to v20.3.17 [security] Mar 23, 2026
@renovate renovate Bot changed the title chore(deps): update dependency @angular/core to v20.3.17 [security] chore(deps): update dependency @angular/core to v20.3.17 [security] - autoclosed Mar 27, 2026
@renovate renovate Bot closed this Mar 27, 2026
@renovate renovate Bot deleted the renovate/npm-angular-core-vulnerability branch March 27, 2026 02:07
@renovate renovate Bot changed the title chore(deps): update dependency @angular/core to v20.3.17 [security] - autoclosed chore(deps): update dependency @angular/core to v20.3.17 [security] Mar 30, 2026
@renovate renovate Bot reopened this Mar 30, 2026
@renovate renovate Bot force-pushed the renovate/npm-angular-core-vulnerability branch 3 times, most recently from 5c2ebd0 to f88e8bf Compare March 30, 2026 20:53
@renovate renovate Bot changed the title chore(deps): update dependency @angular/core to v20.3.17 [security] chore(deps): update dependency @angular/core to v20.3.18 [security] Mar 30, 2026
@renovate renovate Bot force-pushed the renovate/npm-angular-core-vulnerability branch 5 times, most recently from cf15108 to 0bfd823 Compare April 3, 2026 13:34
@renovate renovate Bot force-pushed the renovate/npm-angular-core-vulnerability branch 3 times, most recently from f16678b to f6fb29e Compare April 4, 2026 15:04
@renovate renovate Bot force-pushed the renovate/npm-angular-core-vulnerability branch 4 times, most recently from 2068c0f to 21a3c90 Compare April 15, 2026 19:52
@renovate renovate Bot force-pushed the renovate/npm-angular-core-vulnerability branch 3 times, most recently from 02271f3 to 927cbf8 Compare April 24, 2026 17:33
@renovate renovate Bot changed the title chore(deps): update dependency @angular/core to v20.3.18 [security] chore(deps): update dependency @angular/core to v20.3.18 [security] - autoclosed Apr 27, 2026
@renovate renovate Bot closed this Apr 27, 2026
@renovate renovate Bot changed the title chore(deps): update dependency @angular/core to v20.3.18 [security] - autoclosed chore(deps): update dependency @angular/core to v20.3.18 [security] Apr 27, 2026
@renovate renovate Bot reopened this Apr 27, 2026
@renovate renovate Bot force-pushed the renovate/npm-angular-core-vulnerability branch 4 times, most recently from 5526ac9 to e51fe1c Compare May 3, 2026 17:35
@renovate renovate Bot force-pushed the renovate/npm-angular-core-vulnerability branch from e51fe1c to 5f12751 Compare May 3, 2026 18:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants