A flaw was found in the way file parsed property information from Composite Document Files (CDF) files. A property entry with 0 elements triggers an infinite loop. The problem is in cdf_read_property_info() function in src/cdf.c: https://github.com/file/file/blob/FILE5_18/src/cdf.c#L742 A for loop with counter i is used to loop through properties. Inside it, nelements value is read from the input file. For string type properties, there is additional nested for loop with counter j, which also increments counter i of the outer for loop. https://github.com/file/file/blob/FILE5_18/src/cdf.c#L890 In cdf.c: 801 for (i = 0; i < sh.sh_properties; i++) { .. 814 if (inp[i].pi_type & CDF_VECTOR) { 815 nelements = CDF_GETUINT32(q, 1); .. 873 case CDF_LENGTH32_STRING: 874 case CDF_LENGTH32_WSTRING: .. 890 for (j = 0; j < nelements; j++, i++) { .. 905 } 906 i--;
*** Bug 1098175 has been marked as a duplicate of this bug. ***
PHP bug https://bugs.php.net/bug.php?id=67327
Upstream commit: https://github.com/file/file/commit/f97486ef5dc3e8735440edc4fc8808c63e1a3ef0
PHP commit in 5.4.29 http://git.php.net/?p=php-src.git;a=commit;h=22736b7c56d678f142d5dd21f4996e5819507a2b
Public now: http://www.php.net/ChangeLog-5.php#5.5.13
Created php tracking bugs for this issue: Affects: fedora-all [bug 1103569]
Created file tracking bugs for this issue: Affects: fedora-all [bug 1103568]
Fixed in PHP 5.4.29 and 5.5.13.
php-5.5.13-3.fc20, php-phpunit-PHPUnit-MockObject-1.2.3-4.fc20, php-doctrine-orm-2.4.2-2.fc20 has been pushed to the Fedora 20 stable repository. If problems still persist, please make note of it in this bug report.
php-5.5.13-3.fc19, php-phpunit-PHPUnit-MockObject-1.2.3-4.fc19, php-doctrine-orm-2.4.2-2.fc19 has been pushed to the Fedora 19 stable repository. If problems still persist, please make note of it in this bug report.
Statement: This issue did not affect the php and the file packages as shipped with Red Hat Enterprise Linux 5. This issue affects the versions of file as shipped with Red Hat Enterprise Linux 7. Red Hat Product Security has rated this issue as having Moderate security impact. A future update may address this issue. For additional information, refer to the Issue Severity Classification: https://access.redhat.com/security/updates/classification/.
IssueDescription: A denial of service flaw was found in the way the File Information (fileinfo) extension parsed certain Composite Document Format (CDF) files. A remote attacker could use this flaw to crash a PHP application using fileinfo via a specially crafted CDF file.
This issue has been addressed in following products: Red Hat Enterprise Linux 6 Red Hat Enterprise Linux 5 Via RHSA-2014:1012 https://rhn.redhat.com/errata/RHSA-2014-1012.html
This issue has been addressed in following products: Red Hat Enterprise Linux 7 Via RHSA-2014:1013 https://rhn.redhat.com/errata/RHSA-2014-1013.html
This issue has been addressed in the following products: Red Hat Enterprise Linux 6 Via RHSA-2014:1606 https://rhn.redhat.com/errata/RHSA-2014-1606.html
This issue has been addressed in the following products: Red Hat Software Collections 1 for Red Hat Enterprise Linux 7 Red Hat Software Collections 1 for Red Hat Enterprise Linux 6.5 EUS Red Hat Software Collections 1 for Red Hat Enterprise Linux 6.4 EUS Red Hat Software Collections 1 for Red Hat Enterprise Linux 6.6 EUS Red Hat Software Collections 1 for Red Hat Enterprise Linux 6 Via RHSA-2014:1766 https://rhn.redhat.com/errata/RHSA-2014-1766.html
This issue has been addressed in the following products: Red Hat Software Collections 1 for Red Hat Enterprise Linux 7 Red Hat Software Collections 1 for Red Hat Enterprise Linux 6.5 EUS Red Hat Software Collections 1 for Red Hat Enterprise Linux 6.4 EUS Red Hat Software Collections 1 for Red Hat Enterprise Linux 6.6 EUS Red Hat Software Collections 1 for Red Hat Enterprise Linux 6 Via RHSA-2014:1765 https://rhn.redhat.com/errata/RHSA-2014-1765.html
This issue has been addressed in the following products: Red Hat Enterprise Linux 7 Via RHSA-2015:2155 https://rhn.redhat.com/errata/RHSA-2015-2155.html