Bug 1359828 (CVE-2016-6297) - CVE-2016-6297 php: Stack-based buffer overflow vulnerability in php_stream_zip_opener
Summary: CVE-2016-6297 php: Stack-based buffer overflow vulnerability in php_stream_zi...
Keywords:
Status: CLOSED ERRATA
Alias: CVE-2016-6297
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
low
low
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
URL:
Whiteboard:
Depends On: 1359837
Blocks: 1359830
TreeView+ depends on / blocked
 
Reported: 2016-07-25 14:00 UTC by Adam Mariš
Modified: 2020-01-17 15:51 UTC (History)
14 users (show)

Fixed In Version: php 5.5.38, php 5.6.24, php 7.0.9
Clone Of:
Environment:
Last Closed: 2016-09-26 18:18:12 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2016:2750 0 normal SHIPPED_LIVE Moderate: rh-php56 security, bug fix, and enhancement update 2016-11-15 16:40:02 UTC

Description Adam Mariš 2016-07-25 14:00:57 UTC
It was found that when opening a zip stream, php_stream_zip_opener fails to check the path_len that is vulnerable to integer overflow. It is later used to calculate the length of mempcy that can lead to buffer overflow and memory corruption.

Upstream bug:

https://bugs.php.net/bug.php?id=72520

Upstream patch:

http://git.php.net/?p=php-src.git;a=commit;h=81406c0c1d45f75fcc7972ed974d2597abb0b9e9

CVE assignment:

http://seclists.org/oss-sec/2016/q3/137

Comment 1 Adam Mariš 2016-07-25 14:10:15 UTC
Created php tracking bugs for this issue:

Affects: fedora-all [bug 1359837]

Comment 2 Stefan Cornelius 2016-09-21 09:17:09 UTC
The affected function has to be used in a very specific way. It's unlikely that this function is used in a way that lends it to exploitation.

Compile time buffer overflow protection should mitigate this problem, preventing exploitation to gain code execution. Thus, this should be limited to a crash only.

Comment 3 errata-xmlrpc 2016-11-15 11:44:26 UTC
This issue has been addressed in the following products:

  Red Hat Software Collections for Red Hat Enterprise Linux 6
  Red Hat Software Collections for Red Hat Enterprise Linux 6.7 EUS
  Red Hat Software Collections for Red Hat Enterprise Linux 7
  Red Hat Software Collections for Red Hat Enterprise Linux 7.2 EUS
  Red Hat Software Collections for Red Hat Enterprise Linux 7.3 EUS

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


Note You need to log in before you can comment on or make changes to this bug.