Phar TAR phar_tar_number() Integer Overflow - Archive Entry Injection
- Published
- Last modified
- Where the record stands: published, rejected by its publisher, or superseded by another id.What do these mean? →
- published
- Whether CISA lists it in its Known Exploited Vulnerabilities catalog: proof that attackers are using it.What do these mean? →
- Not listed in CISA KEV
- Fix
- Fixed in 8.2.34, 8.3.35, 8.4.26, 8.5.11
- Whether working attack code is public (Exploit-DB, Metasploit, Nuclei or GitHub). Public code makes attacks easier.What do these mean? →
- None on Exploit-DB, Metasploit or GitHub
- Exploitation: poc
- Automatable: no
- Technical impact: partial
Summary
phar_tar_number() parses the octal size field of a TAR header into a uint32_t with no overflow check. The field is 11 octal digits wide and holds values up to 0x1FFFFFFFF, so a size above 0xFFFFFFFF silently wraps. The parser then skips the wrong number of data blocks and interprets attacker-controlled file content as the next TAR header, which lets a crafted archive inject entries that PharData reports and extracts as if they were genuine.
Timeline
- CVE published
- CISA SSVC assessment
Exploitation: poc · Automatable: no · Technical impact: partial
- Record last updated
Affected versions
- PHP Group PHP
From 8.2.* · fixed in 8.2.34; From 8.3.* · fixed in 8.3.35; From 8.4.* · fixed in 8.4.26; From 8.5.* · fixed in 8.5.11
- libphpBitnami
From 8.2.0 · fixed in 8.2.34; From 8.3.0 · fixed in 8.3.35; From 8.4.0 · fixed in 8.4.26; From 8.5.0 · fixed in 8.5.11
- phpBitnami
From 8.2.0 · fixed in 8.2.34; From 8.3.0 · fixed in 8.3.35; From 8.4.0 · fixed in 8.4.26; From 8.5.0 · fixed in 8.5.11
- php-minBitnami
From 8.2.0 · fixed in 8.2.34; From 8.3.0 · fixed in 8.3.35; From 8.4.0 · fixed in 8.4.26; From 8.5.0 · fixed in 8.5.11