CVE-2015-7803
NoneCVSS
—
EPSS
10.3%
Published
Dec 11, 2015
CISA due date
—
Cloudanix analysis
A flaw in older PHP versions lets attackers crash web applications by feeding them specially crafted archive files.
- Exploitation
- Remote Unauthenticated
- Attacker needs
- None
- Complexity
- Moderate
- Impact
- Denial Of Service
- Component
- Application
- Class
- Memory Corruption
- Remediation
- Upgrade
- Effort
- Medium
- Patch risk
- Low
What it actually does
The vulnerability triggers a NULL pointer dereference inside phar_get_entry_data when a crafted TAR archive entry inside a .phar file uses a Link indicator that references a non-existent file, causing the PHP process to crash.
Why it matters to the business
Results in denial-of-service against PHP-based web applications and services that accept or process .phar archives, leading to unplanned downtime and the need for restarts until systems are updated.
How an attack unfolds
An attacker prepares a .phar file whose embedded TAR archive contains a Link entry pointing to a missing file, then causes a vulnerable PHP installation to invoke phar_get_entry_data on that archive, producing an immediate application crash.
How to fix it
Upgrade PHP to 5.5.30 or 5.6.14 or later on all affected systems, including Apple macOS installations that bundle PHP. Disable the phar extension when .phar support is unnecessary.
How to confirm the fix worked
Confirm PHP version meets or exceeds 5.5.30 / 5.6.14. Attempt to process a test .phar with an invalid TAR Link entry and verify no crash occurs.
Typical attack path
- Create a malicious .phar containing a TAR archive with an invalid Link indicator
- Deliver the .phar to the target application via upload, include, or file processing
- Trigger phar parsing code path to dereference NULL and crash the process
How to detect it
Review web server and PHP error logs for segmentation faults or crashes occurring during .phar file handling; correlate with file-upload or include operations involving .phar archives.
- phar_get_entry_data
- ext/phar/util.c
- Link indicator references a file that does not exist
What your security team should do
- Apply the PHP version updates immediately across development, staging, and production environments
- Restrict untrusted .phar file uploads and processing until patches are deployed
- Add monitoring for PHP segmentation faults or crashes correlated with phar handling
The record
The phar_get_entry_data function in ext/phar/util.c in PHP before 5.5.30 and 5.6.x before 5.6.14 allows remote attackers to cause a denial of service (NULL pointer dereference and application crash) via a .phar file with a crafted TAR archive entry in which the Link indicator references a file that does not exist.
Affected packages
| Ecosystem | Package | Introduced | Fixed |
|---|---|---|---|
| Debian:6.0 | php5 | 0 | 5.3.3.1-7+squeeze28 |
| Debian:7 | php5 | 0 | 5.4.45-0+deb7u2 |
| Debian:8 | php5 | 0 | 5.6.14+dfsg-0+deb8u1 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-bcmath | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-cli | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-common | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-dba | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-dbg | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-debuginfo | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-devel | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-embedded | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-enchant | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-fpm | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-gd | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-gmp | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-imap | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-intl | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-ldap | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-mbstring | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-mysqlnd | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-odbc | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-opcache | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-pdo | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-pgsql | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-process | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-pspell | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-recode | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-snmp | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-soap | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-tidy | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-xml | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el6 | rh-php56-php-xmlrpc | 0 | 0:5.6.5-8.el6 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-bcmath | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-cli | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-common | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-dba | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-dbg | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-debuginfo | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-devel | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-embedded | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-enchant | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-fpm | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-gd | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-gmp | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-intl | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-ldap | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-mbstring | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-mysqlnd | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-odbc | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-opcache | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-pdo | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-pgsql | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-process | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-pspell | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-recode | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-snmp | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-soap | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-xml | 0 | 0:5.6.5-8.el7 |
| Red Hat:rhel_software_collections:2::el7 | rh-php56-php-xmlrpc | 0 | 0:5.6.5-8.el7 |
| SUSE:Linux Enterprise Module for Web and Scripting 12 | php5 | 0 | 5.5.14-42.2 |
| SUSE:Linux Enterprise Server 11 SP2-LTSS | php53 | 0 | 5.3.17-47.1 |
| SUSE:Linux Enterprise Server 11 SP3-LTSS | php53 | 0 | 5.3.17-71.1 |
| SUSE:Linux Enterprise Server 11 SP3-TERADATA | php53 | 0 | 5.3.17-71.1 |
| SUSE:Linux Enterprise Server 11 SP4 | php53 | 0 | 5.3.17-71.1 |
| SUSE:Linux Enterprise Server 11 SP4 | php53 | 0 | 5.3.17-59.1 |
| SUSE:Linux Enterprise Server for SAP Applications 11 SP4 | php53 | 0 | 5.3.17-71.1 |
| SUSE:Linux Enterprise Server for SAP Applications 11 SP4 | php53 | 0 | 5.3.17-59.1 |
| SUSE:Linux Enterprise Software Development Kit 11 SP4 | php53 | 0 | 5.3.17-71.1 |
| SUSE:Linux Enterprise Software Development Kit 11 SP4 | php53 | 0 | 5.3.17-59.1 |
| SUSE:Linux Enterprise Software Development Kit 12 | php5 | 0 | 5.5.14-42.2 |
| SUSE:Linux Enterprise Software Development Kit 12 SP1 | php5 | 0 | 5.5.14-42.2 |
| SUSE:Manager 2.1 | php53 | 0 | 5.3.17-71.1 |
| SUSE:Manager Proxy 2.1 | php53 | 0 | 5.3.17-71.1 |
| SUSE:OpenStack Cloud 5 | php53 | 0 | 5.3.17-71.1 |
| Ubuntu:14.04:LTS | php5 | 0 | 5.5.9+dfsg-1ubuntu4.14 |
Related vulnerabilities
- CVE-2015-6834 Multiple use-after-free vulnerabilities in PHP before 5.4.45, 5.5.x before 5.5.29, and… Also affects php5
- CVE-2015-5589 The phar_convert_to_other function in ext/phar/phar_object.c in PHP before 5.4.43, 5.5.x… Also affects php5
- CVE-2015-4643 Integer overflow in the ftp_genlist function in ext/ftp/ftp.c in PHP before 5.4.42, 5.5.x… Also affects php5
- CVE-2015-4602 The __PHP_Incomplete_Class function in ext/standard/incomplete_class.c in PHP before… Also affects php5
- CVE-2015-4600 The SoapClient implementation in PHP before 5.4.40, 5.5.x before 5.5.24, and 5.6.x before… Also affects php5
- CVE-2015-4599 The SoapFault::__toString method in ext/soap/soap.c in PHP before 5.4.40, 5.5.x before… Also affects php5
- CVE-2015-3411 PHP before 5.4.40, 5.5.x before 5.5.24, and 5.6.x before 5.6.8 does not ensure that… Also affects php5
- CVE-2015-6836 The SoapClient __call method in ext/soap/soap.c in PHP before 5.4.45, 5.5.x before… Also affects php5