Bug 1348439 (CVE-2016-4300)

Summary: CVE-2016-4300 libarchive: Heap buffer overflow vulnerability in the 7zip read_SubStreamsInfo
Product: [Other] Security Response Reporter: Andrej Nemec <anemec>
Component: vulnerabilityAssignee: Red Hat Product Security <security-response-team>
Status: CLOSED ERRATA QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: dmoppert, ndevos, praiskup, sardella, slawomir
Target Milestone: ---Keywords: Security
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: libarchive 3.2.1 Doc Type: Bug Fix
Doc Text:
A vulnerability was found in libarchive's handling of 7zip data. A specially crafted 7zip file can cause a integer overflow resulting in memory corruption that can lead to code execution.
Story Points: ---
Clone Of: Environment:
Last Closed: 2016-10-18 04:58:55 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1352776, 1353065, 1353066    
Bug Blocks: 1334215    

Description Andrej Nemec 2016-06-21 07:50:09 UTC
An exploitable heap overflow vulnerability exists in the 7zip read_SubStreamsInfo functionality of libarchive. A specially crafted 7zip file can cause a integer overflow resulting in memory corruption that can lead to code execution. An attacker can send a malformed file to trigger this vulnerability.

External references:

http://www.talosintel.com/reports/TALOS-2016-0152/

Upstream fix:

https://github.com/libarchive/libarchive/commit/e79ef306afe332faf22e9b442a2c6b59cb175573

Comment 1 Doran Moppert 2016-06-22 06:31:02 UTC
libarchive-2.8 does not include the affected functionality.

libarchive-3.1 has a smaller limit for UMAX_ENTRY (1m vs 100m), making
exploitation more difficult but not impossible.

Comment 2 Doran Moppert 2016-07-05 04:37:46 UTC
Created libarchive tracking bugs for this issue:

Affects: fedora-all [bug 1352776]

Comment 5 errata-xmlrpc 2016-09-12 20:14:17 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7

Via RHSA-2016:1844 https://rhn.redhat.com/errata/RHSA-2016-1844.html