Angularにリソースの過剰消費の脆弱性(CVE-2026-101895)
概要
Angularにリソースの過剰消費の脆弱性が確認されました。
バージョン 22.0.0 以上 22.1.6 未満、21.0.0 以上 21.2.23 未満、20.0.0 以上 20.3.31 未満、19.2.25 以前に影響があります。
修正版 22.1.6 / 21.2.23 / 20.3.31 への更新が推奨されます。
脆弱性の基本情報
| 脆弱性ID |
CVE-2026-101895 GHSA-f67j-2jqw-jpq7 |
|---|---|
| 脆弱性の種類 | リソースの過剰消費 |
| 危険度 | 高 |
| CVSSスコア |
8.7(CVSS v4.0) CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N |
| 公開日 | 2026年10月14日 |
影響を受ける製品
| 製品 | 影響を受けるバージョン | 修正版 | 出典 |
|---|---|---|---|
| Angular |
22.0.0 以上 22.1.6 未満、21.0.0 以上 21.2.23 未満、20.0.0 以上 20.3.31 未満、19.2.25 以前 | 22.1.6 / 21.2.23 / 20.3.31 | OSV.dev |
推奨対応
- Angularを、ご利用中の系列に対応する修正版(22.1.6 / 21.2.23 / 20.3.31)またはそれ以降の公式最新版へ更新してください。
情報元の原文
OSV.dev
Angular SSR: Denial of Service (DoS) via Infinite Loop on Malformed DOCTYPE
A Denial of Service (DoS) vulnerability exists in `@angular/platform-server`'s DOM emulation parser (`domino`). When processing untrusted user input containing an incomplete DOCTYPE declaration ending with whitespace before EOF (such as `<!DOCTYPE html `), the HTML parser enters an infinite synchronous loop, pegging CPU utilization at 100% and completely freezing the Node.js server process.
### Technical Description
In Angular Server-Side Rendering (SSR), `@angular/platform-server` uses `domino` to parse and sanitize HTML bound through template bindings (such as `[innerHTML]`) or manipulated via DOM APIs.
In Domino's HTML parser (`lib/HTMLParser.js`), tokenizer states that specify fixed lookahead—such as `after_doctype_name_state` (`lookahead = 6`)—rely on the state handler function to explicitly advance the character index pointer (`nextchar`). While branches for whitespace, `>`, and keyword matching advance `nextchar`, the EOF branch (`case -1: // EOF`) emitted doctype and EOF tokens without advancing `nextchar` or transitioning out of the state:
```javascript
case -1: // EOF
forcequirks();
emitDoctype();
emitEOF();
break;
```
Because `nextchar` remained unchanged pointing to the EOF marker character (`\uFFFF`), the scanner loop (`while (nextchar < numchars)`) repeatedly re-invoked `after_doctype_name_state` with `codepoint = EOF` indefinitely. In Node.js's single-threaded runtime, this synchronous loop starves the event loop entirely.
### Impact & Reachability
* **Reachability**: The vulnerability is reachable in any Angular SSR application where untrusted user input is bound to `[innerHTML]`, interpolated into markup, or sanitized on the server.
* **Impact**: Successful exploitation allows an unauthenticated remote attacker to cause an immediate Denial of Service (DoS) by sending a payload containing an incomplete DOCTYPE (e.g., `<!DOCTYPE html `). The Node.js SSR process locks up at 100% CPU and ceases responding to all concurrent and subsequent HTTP requests.
**Proof of Concept:**
```ts
import { Component } from '@angular/core';
@Component({
selector: 'app-root',
standalone: true,
template: `<div [innerHTML]="payload"></div>`,
})
export class AppComponent {
// Attacker-controlled input containing an incomplete DOCTYPE ending with whitespace
payload = '<!DOCTYPE html ';
}
```
### Workarounds
* Avoid binding untrusted user input directly to `[innerHTML]` in server-rendered templates; use standard text interpolation (`{{ userInput }}`) or `[textContent]` when raw HTML rendering is not required.
* Validate or sanitize user input before passing it to `[innerHTML]` on the server by stripping or rejecting strings matching `/^<!DOCTYPE/i`.
利用条件:CC BY 4.0
出典: GitHub Advisory Database(OSV.dev 経由で取得)。原文のまま掲載(改変なし)
CVE List(CVE Program)
Angular SSR: Denial of Service (DoS) via Infinite Loop on Malformed DOCTYPE
Angular is a development platform for building mobile and desktop web applications using TypeScript/JavaScript and other languages. Prior to 20.3.31, 21.2.23, and 22.1.6, the @angular/platform-server DOM emulation parser can enter an infinite synchronous loop when Angular server-side rendering processes attacker-controlled HTML containing an incomplete DOCTYPE that ends with whitespace at end of input. In Domino lib/HTMLParser.js, after_doctype_name_state emits doctype and EOF tokens without advancing nextchar or leaving the fixed-lookahead state, so the scanner repeatedly handles the same EOF marker. A remote unauthenticated attacker can use this condition through server-side HTML parsing paths such as innerHTML binding to consume a Node.js SSR worker at full CPU, starve the event loop, and stop concurrent and subsequent requests. This issue is fixed in versions 20.3.31, 21.2.23, and 22.1.6.
利用条件:CVE の利用条件(CVE Terms of Use)・原文のまま掲載
Copyright 1999-2026 The MITRE Corporation
CVE Usage: MITRE hereby grants you a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, sublicense, and distribute Common Vulnerabilities and Exposures (CVE®). Any copy you make for such purposes is authorized provided that you reproduce MITRE's copyright designation and this license in any such copy.
情報元
- OSV.dev
https://github.com/advisories/GHSA-f67j-2jqw-jpq7 - CVE List(CVE Program)
https://www.cve.org/CVERecord?id=CVE-2026-101895