{"id":"CVE-2026-32635","aliases":["CVE-2026-32635","GHSA-g93w-mfhg-p222"],"related":[],"kind":"vulnerability","state":"published","title":"Angular has XSS in i18n attribute bindings","summary":"Angular is a development platform for building mobile and desktop web applications using TypeScript/JavaScript and other languages. Prior to 22.0.0-next.3, 21.2.4, 20.3.18, and 19.2.20, 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. This vulnerability is fixed in 22.0.0-next.3, 21.2.4, 20.3.18, and 19.2.20.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"Angular is a development platform for building mobile and desktop web applications using TypeScript/JavaScript and other languages. Prior to 22.0.0-next.3, 21.2.4, 20.3.18, and 19.2.20, 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. This vulnerability is fixed in 22.0.0-next.3, 21.2.4, 20.3.18, and 19.2.20.","source":"cvelist"},{"lang":"en","text":"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. \n\nThe following example illustrates the issue:\n```html\n<a href=\"{{maliciousUrl}}\" i18n-href>Click me</a>\n```\n\nThe following attributes have been confirmed to be vulnerable:\n- `action`\n- `background`\n- `cite`\n- `codebase`\n- `data`\n- `formaction`\n- `href`\n- `itemtype`\n- `longdesc`\n- `poster`\n- `src`\n- `xlink:href`\n\n### Impact\nWhen exploited, this vulnerability allows an attacker to execute arbitrary code within the context of the vulnerable application's domain. This enables:\n- Session Hijacking: Stealing session cookies and authentication tokens.\n- Data Exfiltration: Capturing and transmitting sensitive user data.\n- Unauthorized Actions: Performing actions on behalf of the user.\n\n### Attack Preconditions\n1. The application must use a vulnerable version of Angular.\n2. The application must bind unsanitized user input to one of the attributes mentioned above.\n3. The bound value must be marked for internationalization via the presence of a `i18n-<name>` attribute on the same element.\n\n### Patches\n- 22.0.0-next.3\n- 21.2.4\n- 20.3.18\n- 19.2.20\n\n### Workarounds\nThe 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.\n\nAlternatively, users can explicitly sanitize their attributes by passing them through Angular's `DomSanitizer`:\n```ts\nimport {Component, inject, SecurityContext} from '@angular/core';\nimport {DomSanitizer} from '@angular/platform-browser';\n\n@Component({\n  template: `\n    <form action=\"{{url}}\" i18n-action>\n      <button>Submit</button>\n    </form>\n  `,\n})\nexport class App {\n  url: string;\n\n  constructor() {\n    const dangerousUrl = 'javascript:alert(1)';\n    const sanitizer = inject(DomSanitizer);\n    this.url = sanitizer.sanitize(SecurityContext.URL, dangerousUrl) || '';\n  }\n}\n```\n\n### References\n- [Fix 1](https://github.com/angular/angular/pull/67541) \n- [Fix 2](https://github.com/angular/angular/pull/67561)","format":"markdown","source":"ghsa"},{"lang":"es","text":"Angular es una plataforma de desarrollo para construir aplicaciones web móviles y de escritorio usando TypeScript/JavaScript y otros lenguajes. Antes de las versiones 22.0.0-next.3, 21.2.4, 20.3.18 y 19.2.20, se ha identificado una vulnerabilidad de cross-site scripting (XSS) en el tiempo de ejecución y el compilador de Angular. Ocurre cuando la aplicación utiliza un atributo sensible a la seguridad (por ejemplo, href en una etiqueta de anclaje) junto con la capacidad de Angular para internacionalizar atributos. Habilitar la internacionalización para el atributo sensible añadiendo i18n- omite el mecanismo de saneamiento integrado de Angular, lo que, cuando se combina con un enlace de datos a datos no confiables generados por el usuario, puede permitir a un atacante inyectar un script malicioso. Esta vulnerabilidad está corregida en las versiones 22.0.0-next.3, 21.2.4, 20.3.18 y 19.2.20.","source":"nvd"}],"published":"2026-03-13T20:56:18.000Z","modified":"2026-06-17T10:36:08.510Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:4.0","vector":"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","score":8.6,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:4.0","vector":"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","score":8.6,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:H","score":9,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:4.0","vector":"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","rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:H","score":9,"rating":"CRITICAL"}],"cwes":["CWE-79"],"affected":[{"ranges":[{"version":">= 22.0.0-next.0, < 22.0.0-next.3","status":"affected"},{"version":">= 21.0.0-next.0, < 21.2.4","status":"affected"},{"version":">= 20.0.0-next.0, < 20.3.18","status":"affected"},{"version":">= 17.0.0.next.0, < 19.2.20","status":"affected"}],"vendor":"@angular","product":"compiler","source":"cvelist"},{"ranges":[{"version":">= 22.0.0-next.0, < 22.0.0-next.3","status":"affected"},{"version":">= 21.0.0-next.0, < 21.2.4","status":"affected"},{"version":">= 20.0.0-next.0, < 20.3.18","status":"affected"},{"version":">= 17.0.0.next.0, < 19.2.20","status":"affected"}],"vendor":"@angular","product":"core","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"22.0.0-next.0","status":"affected","fixed":"22.0.0-next.3"}],"ecosystem":"npm","package":"@angular/core","purl":"pkg:npm/%40angular/core","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"21.0.0-next.0","status":"affected","fixed":"21.2.4"}],"ecosystem":"npm","package":"@angular/core","purl":"pkg:npm/%40angular/core","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"20.0.0-next.0.0.0","status":"affected","fixed":"20.3.18"}],"ecosystem":"npm","package":"@angular/core","purl":"pkg:npm/%40angular/core","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"19.0.0-next.0","status":"affected","fixed":"19.2.20"}],"ecosystem":"npm","package":"@angular/core","purl":"pkg:npm/%40angular/core","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"17.0.0-next.0","status":"affected","lastAffected":"18.2.14"}],"ecosystem":"npm","package":"@angular/core","purl":"pkg:npm/%40angular/core","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"22.0.0-next.0","status":"affected","fixed":"22.0.0-next.3"}],"ecosystem":"npm","package":"@angular/compiler","purl":"pkg:npm/%40angular/compiler","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"21.0.0-next.0","status":"affected","fixed":"21.2.4"}],"ecosystem":"npm","package":"@angular/compiler","purl":"pkg:npm/%40angular/compiler","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"20.0.0-next.0.0.0","status":"affected","fixed":"20.3.18"}],"ecosystem":"npm","package":"@angular/compiler","purl":"pkg:npm/%40angular/compiler","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"19.0.0-next.0","status":"affected","fixed":"19.2.20"}],"ecosystem":"npm","package":"@angular/compiler","purl":"pkg:npm/%40angular/compiler","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"17.0.0-next.0","status":"affected","lastAffected":"18.2.14"}],"ecosystem":"npm","package":"@angular/compiler","purl":"pkg:npm/%40angular/compiler","source":"ghsa"},{"ranges":[{"status":"affected","introduced":"17.0.0","fixed":"19.2.0"},{"status":"affected","introduced":"20.0.0","lastAffected":"20.3.18"},{"status":"affected","introduced":"21.0.0","fixed":"21.2.4"},{"status":"affected","version":"22.0.0"},{"status":"affected","version":"22.0.0"}],"vendor":"angular","product":"angular_cli","cpe":"cpe:2.3:a:angular:angular_cli:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://github.com/angular/angular/security/advisories/GHSA-g93w-mfhg-p222","tags":["mitigation","vendor-advisory","web","x-refsource-confirm"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/angular/angular/pull/67541","tags":["issue-tracking","patch","web","x-refsource-misc"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://github.com/angular/angular/pull/67561","tags":["issue-tracking","patch","web","x-refsource-misc"],"sources":["cvelist","ghsa","nvd"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-32635","tags":["advisory"],"sources":["ghsa"]},{"url":"https://github.com/angular/angular/commit/224e60ecb1b90115baa702f1c06edc1d64d86187","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/angular/angular/commit/78dea55351fb305b33a919c43a6b363137eca166","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/angular/angular/commit/8630319f74c9575a21693d875cc7d5252516146d","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/angular/angular/commit/ed2d324f9cc12aab6cfa0569ef10b73243a62c65","tags":["web"],"sources":["ghsa"]},{"url":"https://github.com/angular/angular","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"total","date":"2026-03-16T00:00:00.000Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-32635","url":"https://www.cve.org/CVERecord?id=CVE-2026-32635","licence":"CVE Terms of Use","modified":"2026-03-17T03:55:33.785Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-g93w-mfhg-p222","url":"https://github.com/advisories/GHSA-g93w-mfhg-p222","licence":"CC-BY-4.0","modified":"2026-05-06T20:48:48.425Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-32635","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-32635","licence":"Public domain","modified":"2026-06-17T10:36:08.510Z"}],"updatedAt":"2026-11-25T22:59:15.959Z","epss":{"score":0.00536,"percentile":0.46632,"date":"2026-12-01T12:00:22.000Z"}}