CVE-2026-50557
Angular: Template and Attribute Namespace Sanitization Bypass (XSS)
Description
Angular is a development platform for building mobile and desktop web applications using TypeScript/JavaScript and other languages. Prior to 22.0.0-rc.2, 21.2.15, 20.3.22 and 19.2.22, an issue in the @angular/compiler and @angular/core packages allows bypassing element and attribute sanitization/validation through specific namespace workarounds. Specifically, namespaced script elements (e.g., <svg:script> or <:svg:script>) were not properly identified as script elements by the Angular template preparser, allowing them to pass through template compilation without being stripped. Furthermore, security context schema mappings for element attributes did not consistently handle attributes within namespaced elements (like SVG and MathML), opening up gaps where malicious namespaced attributes could bypass runtime and compile-time sanitizers. Combined, these flaws enable an attacker who can inject or supply a template/tag structure with custom namespaces to bypass Angular's script-stripping logic and attribute sanitizers, leading to client-side Cross-Site Scripting (XSS). This vulnerability is fixed in 22.0.0-rc.2, 21.2.15, 20.3.22 and 19.2.22.
INFO
Published Date :
June 22, 2026, 4:16 p.m.
Last Modified :
July 9, 2026, 3:40 p.m.
Remotely Exploit :
Yes !
Source :
[email protected]
Affected Products
The following products are affected by CVE-2026-50557
vulnerability.
Even if cvefeed.io is aware of the exact versions of the
products
that
are
affected, the information is not represented in the table below.
CVSS Scores
| Score | Version | Severity | Vector | Exploitability Score | Impact Score | Source |
|---|---|---|---|---|---|---|
| CVSS | 134c704f-9b21-4f2e-91b3-4a467353bcc0 | |||||
| CVSS 3.1 | MEDIUM | [email protected] | ||||
| CVSS 4.0 | MEDIUM | [email protected] |
Solution
- Update @angular/compiler to a fixed version.
- Update @angular/core to a fixed version.
- Apply patches for affected Angular packages.
- Test application with updated packages.
Public PoC/Exploit Available at Github
CVE-2026-50557 has a 1 public
PoC/Exploit available at Github.
Go to the Public Exploits tab to see the list.
References to Advisories, Solutions, and Tools
Here, you will find a curated list of external links that provide in-depth
information, practical solutions, and valuable tools related to
CVE-2026-50557.
| URL | Resource |
|---|---|
| https://github.com/angular/angular/pull/68689 | Issue Tracking Patch |
| https://github.com/angular/angular/pull/68868 | Issue Tracking |
| https://github.com/angular/angular/security/advisories/GHSA-f3m7-gqxr-g87x | Third Party Advisory |
CWE - Common Weakness Enumeration
While CVE identifies
specific instances of vulnerabilities, CWE categorizes the common flaws or
weaknesses that can lead to vulnerabilities. CVE-2026-50557 is
associated with the following CWEs:
Common Attack Pattern Enumeration and Classification (CAPEC)
Common Attack Pattern Enumeration and Classification
(CAPEC)
stores attack patterns, which are descriptions of the common attributes and
approaches employed by adversaries to exploit the CVE-2026-50557
weaknesses.
We scan GitHub repositories to detect new proof-of-concept exploits. Following list is a collection of public exploits and proof-of-concepts, which have been published on GitHub (sorted by the most recently updated).
Config files for my GitHub profile.
config github-config
Results are limited to the first 15 repositories due to potential performance issues.
The following list is the news that have been mention
CVE-2026-50557 vulnerability anywhere in the article.
The following table lists the changes that have been made to the
CVE-2026-50557 vulnerability over time.
Vulnerability history details can be useful for understanding the evolution of a vulnerability, and for identifying the most recent changes that may impact the vulnerability's severity, exploitability, or other characteristics.
-
Reanalysis by [email protected]
Jul. 09, 2026
Action Type Old Value New Value Changed CPE Configuration OR *cpe:2.3:a:angularjs:angularjs:*:*:*:*:*:*:*:* versions up to (including) 18.2.14 *cpe:2.3:a:angularjs:angularjs:22.0.0:next0:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next1:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next10:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next11:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next12:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next2:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next3:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next4:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next5:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next6:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next7:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next8:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next9:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:rc0:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:rc1:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:*:*:*:*:*:*:*:* versions from (including) 19.0.0 up to (excluding) 19.2.22 *cpe:2.3:a:angularjs:angularjs:*:*:*:*:*:*:*:* versions from (including) 20.0.0 up to (excluding) 20.3.22 *cpe:2.3:a:angularjs:angularjs:*:*:*:*:*:*:*:* versions from (including) 21.0.0 up to (excluding) 21.2.15 OR *cpe:2.3:a:angular:angular:*:*:*:*:*:node.js:*:* versions up to (including) 18.2.14 *cpe:2.3:a:angular:angular:22.0.0:next0:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:22.0.0:next1:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:22.0.0:next2:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:22.0.0:next3:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:22.0.0:next4:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:22.0.0:next5:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:22.0.0:next6:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:22.0.0:next7:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:22.0.0:next8:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:*:*:*:*:*:node.js:*:* versions from (including) 20.0.0 up to (excluding) 20.3.22 *cpe:2.3:a:angular:angular:*:*:*:*:*:node.js:*:* versions from (including) 21.0.0 up to (excluding) 21.2.15 *cpe:2.3:a:angular:angular:22.0.0:next10:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:22.0.0:next11:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:22.0.0:next12:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:22.0.0:next9:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:22.0.0:rc0:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:22.0.0:rc1:*:*:*:node.js:*:* *cpe:2.3:a:angular:angular:*:*:*:*:*:node.js:*:* versions from (including) 19.0.0 up to (excluding) 19.2.22 -
Initial Analysis by [email protected]
Jun. 26, 2026
Action Type Old Value New Value Added CVSS V3.1 AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:L/A:N Added CPE Configuration OR *cpe:2.3:a:angularjs:angularjs:*:*:*:*:*:*:*:* versions up to (including) 18.2.14 *cpe:2.3:a:angularjs:angularjs:22.0.0:next0:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next1:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next10:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next11:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next12:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next2:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next3:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next4:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next5:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next6:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next7:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next8:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:next9:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:rc0:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:22.0.0:rc1:*:*:*:*:*:* *cpe:2.3:a:angularjs:angularjs:*:*:*:*:*:*:*:* versions from (including) 19.0.0 up to (excluding) 19.2.22 *cpe:2.3:a:angularjs:angularjs:*:*:*:*:*:*:*:* versions from (including) 20.0.0 up to (excluding) 20.3.22 *cpe:2.3:a:angularjs:angularjs:*:*:*:*:*:*:*:* versions from (including) 21.0.0 up to (excluding) 21.2.15 Added Reference Type GitHub, Inc.: https://github.com/angular/angular/pull/68689 Types: Issue Tracking, Patch Added Reference Type GitHub, Inc.: https://github.com/angular/angular/pull/68868 Types: Issue Tracking Added Reference Type GitHub, Inc.: https://github.com/angular/angular/security/advisories/GHSA-f3m7-gqxr-g87x Types: Third Party Advisory -
CVE Modified by 134c704f-9b21-4f2e-91b3-4a467353bcc0
Jun. 22, 2026
Action Type Old Value New Value Added SSVC {'id': 'CVE-2026-50557', 'role': 'CISA Coordinator', 'options': [{'exploitation': 'none'}, {'automatable': 'yes'}, {'technicalImpact': 'partial'}], 'version': '2.0.3', 'timestamp': '2026-06-22T17:51:06.519025Z'} -
New CVE Received by [email protected]
Jun. 22, 2026
Action Type Old Value New Value Added Affected [{'vendor': 'angular', 'product': 'angular', 'versions': [{'status': 'affected', 'version': '>= 21.0.0-next.0 < 21.2.15'}, {'status': 'affected', 'version': '>= 22.0.0-next.0 < 22.0.0-rc.2'}, {'status': 'affected', 'version': '>= 20.0.0-next.0 < 20.3.22'}, {'status': 'affected', 'version': '>= 19.0.0-next.0 < 19.2.22'}, {'status': 'affected', 'version': '<= 18.2.14'}]}] Added Description Angular is a development platform for building mobile and desktop web applications using TypeScript/JavaScript and other languages. Prior to 22.0.0-rc.2, 21.2.15, 20.3.22 and 19.2.22, an issue in the @angular/compiler and @angular/core packages allows bypassing element and attribute sanitization/validation through specific namespace workarounds. Specifically, namespaced script elements (e.g., <svg:script> or <:svg:script>) were not properly identified as script elements by the Angular template preparser, allowing them to pass through template compilation without being stripped. Furthermore, security context schema mappings for element attributes did not consistently handle attributes within namespaced elements (like SVG and MathML), opening up gaps where malicious namespaced attributes could bypass runtime and compile-time sanitizers. Combined, these flaws enable an attacker who can inject or supply a template/tag structure with custom namespaces to bypass Angular's script-stripping logic and attribute sanitizers, leading to client-side Cross-Site Scripting (XSS). This vulnerability is fixed in 22.0.0-rc.2, 21.2.15, 20.3.22 and 19.2.22. Added CVSS V4.0 AV:N/AC:L/AT:N/PR:N/UI:P/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X Added CWE CWE-79 Added Reference https://github.com/angular/angular/pull/68689 Added Reference https://github.com/angular/angular/pull/68868 Added Reference https://github.com/angular/angular/security/advisories/GHSA-f3m7-gqxr-g87x