Skip to content
High 7.2

node-tarの脆弱性、アーカイブの解析がずれて追加のファイルが作られるおそれ

CVE-2026-140236 First seen on SecPulse

Summary

node-tarの8.0.0より前のバージョンには、PAXのsizeの扱いが他のtar実装と異なる脆弱性(CVE-2026-140236)があります。アーカイブ内の本体の範囲がずれ、再構成された出力アーカイブに追加のメンバーが作られるおそれがあり、CVSS v4のスコアは7.2です。問題は8.0.0で修正されているため、8.0.0以降へ更新してください。

AI summary

Produced by SecPulse using an external AI model; it may contain mistakes. Check the original description and references below before acting on it.

node-tarの8.0.0より前のバージョンには、PAXのsizeの扱いが他のtar実装と異なる脆弱性(CVE-2026-140236)があります。アーカイブ内の本体の範囲がずれ、再構成された出力アーカイブに追加のメンバーが作られるおそれがあり、CVSS v4のスコアは7.2です。問題は8.0.0で修正されているため、8.0.0以降へ更新してください。

Affected packages

PackageAffected → Fixed
isaacsnode-tar —
npmtar
< 8.0.0→ 8.0.0
Original description The description as published by the source.

Summary

The GHSA-vmf3 fix (7.5.16, commit 21a8220) stopped Header.decode from applying extended-header values to non-file blocks. ReadEntry, however, still copies the PAX size onto meta entries (GNU long-name/long-link and PAX headers), and the parser uses that value to decide how many bytes belong to the meta entry. node-tar can therefore frame an archive differently from other tar implementations. Three related places in the same code take sizes or precedence from inconsistent sources.

Details

# Issue Location Default options
VULN-001 ReadEntry applies ex/gex size to meta entries, and the parser uses it to frame the meta body. This is what GHSA-vmf3 meant to prevent, through a different code path src/read-entry.ts:105-110 → src/parse.ts:241,246 Yes (x, t, Parser, Unpack, UnpackSync)
VULN-004 maxMetaEntrySize is checked against the PAX-overridden entry.size, but the meta buffer accumulates header.size bytes, so the limit can be exceeded src/parse.ts:241 (check) vs :248 (accumulation) Yes
VULN-005 ReadEntry applies the global header after the local one, so global values override local ones (the reverse of PAX semantics), and it applies a global linkpath, which Header excludes. Commit af04392 fixed this order in Header only src/read-entry.ts:105-110, :145 Yes
VULN-003 When re-packing (c/r/u with @archive, or Pack.add(ReadEntry)), the written head…

Source: CVE.org (CVE Program・cvelistV5) NVD GitHub Advisory

References

We use cookies for analytics and ad measurement. This setting applies to all Game co., Ltd. sites. Details