Description
gd_ctx.c in the GD component in PHP 5.4.x before 5.4.32 and 5.5.x before 5.5.16 does not ensure that pathnames lack %00 sequences, which might allow remote attackers to overwrite arbitrary files via crafted input to an application that calls the (1) imagegd, (2) imagegd2, (3) imagegif, (4) imagejpeg, (5) imagepng, (6) imagewbmp, or (7) imagewebp function.
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Red Hat
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| RHEL 7 | php +24 | 5.4.16-23.el7_0.1 | RHSA-2014:1327 |
| RHEL 1 | php54-php +24 | 5.4.16-22.el6 | RHSA-2014:1765 |
| RHEL 1 | php55-php +26 | 5.5.6-13.el6 | RHSA-2014:1766 |
openSUSE
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| openSUSE Tumbleweed | php5 | 5.6.28-1.1 | openSUSE-SU-2024:10344-1 |
| openSUSE Tumbleweed | php7 | 7.0.14-1.4 | openSUSE-SU-2024:10290-1 |
Oracle Linux
| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Oracle Linux 7 | php +24 | 5.4.16-23.el7_0.1 | ELSA-2014-1327 |
Advisories 6
- RHSA-2014:1766 Red Hat Security Advisory: php55-php security update Red Hat Security Advisories (RHSA) · Jun 29, 2026
- RHSA-2014:1765 Red Hat Security Advisory: php54-php security update Red Hat Security Advisories (RHSA) · Jun 29, 2026
- RHSA-2014:1327 Red Hat Security Advisory: php security update Red Hat Security Advisories (RHSA) · Jun 29, 2026
- openSUSE-SU-2024:10290-1 apache2-mod_php7-7.0.14-1.4 on GA media SUSE / openSUSE Security Updates · Feb 4, 2026
- openSUSE-SU-2024:10344-1 apache2-mod_php5-5.6.28-1.1 on GA media SUSE / openSUSE Security Updates · Feb 4, 2026
- ELSA-2014-1327 Moderate: php security update (Oracle Linux 7) Oracle Linux Security Advisories (ELSA) · Sep 30, 2014
References
- https://support.apple.com/HT204659
- RHSA-2014:1766 vendor-advisory
- https://bugs.php.net/bug.php?id=67730
- http://php.net/ChangeLog-5.php
- APPLE-SA-2015-04-08-2 vendor-advisory
- RHSA-2014:1327 vendor-advisory
- http://www.oracle.com/technetwork/topics/security/bulletinjan2015-2370101.html
- RHSA-2014:1765 vendor-advisory
- openSUSE-SU-2014:1133 vendor-advisory