@fastify/multipartに一時ファイルが残り、ディスクを枯渇させられる脆弱性
概要
@fastify/multipartの3.0.0から10.1.3までは、アップロード完了後にクライアントが切断すると一時ファイルが削除されず、ディスク容量を使い切られるサービス拒否の被害を受けるおそれがあります。10.1.4以降に修正版が公開されているため、10.1.4以降へアップグレードしてください。
AI要約
SecPulse が外部の生成 AI を使って作った要約です。誤りを含むことがあります。重要な判断の前に、下の原文と参照URLを確認してください。
@fastify/multipartの3.0.0から10.1.3までは、アップロード完了後にクライアントが切断すると一時ファイルが削除されず、ディスク容量を使い切られるサービス拒否の被害を受けるおそれがあります。10.1.4以降に修正版が公開されているため、10.1.4以降へアップグレードしてください。
影響パッケージ
| パッケージ | 影響を受ける版 → 修正版 | |
|---|---|---|
| @fastify/multipart@fastify/multipart |
3.0.0 以上 10.1.4 未満→ 10.1.4 |
10.1.4 |
原文の説明 取得元が公開している説明をそのまま載せています (多くは英語)。
@fastify/multipart is the official Fastify plugin for handling multipart/form-data uploads. In versions 3.0.0 through 10.1.3, temporary files written by the saveRequestFiles helper are removed only by a response hook that runs when the response finishes or errors. When a client completes an upload and then disconnects before the handler writes the reply, for example while the handler scans, hashes or forwards the file, the response only emits a close event, the cleanup hook never runs, and the saved files are left on disk. An unauthenticated client can repeat this cheaply to exhaust disk space and deny service to applications that save uploaded files to disk. The issue is fixed in @fastify/multipart 10.1.4, and users should upgrade to 10.1.4 or later. As a workaround, avoid saving request files for untrusted clients, or clean the saved files from a close handler on the raw response so removal also happens when the client disconnects.
出典: CVE.org (CVE Program・cvelistV5) NVD GitHub Advisory
参照URL
- advisory github.com
- advisory cna.openjsf.org
- advisory github.com
- advisory nvd.nist.gov