CVE-2012-2336 json
sapi/cgi/cgi_main.c in PHP before 5.3.13 and 5.4.x before 5.4.3, when configured as a CGI script (aka php-cgi), does not properly handle qu…
published 2012-05-11 14 y ago modified 2026-06-16 4 mo ago also EUVD-2012-2329
- cvss
- 5.0
- version 2.0, NVD
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 52.1%
- EPSS 52.1% chance of exploitation in 30 days, percentile 98%
- public exploits
- 4
- Exploit-DB
Summary
sapi/cgi/cgi_main.c in PHP before 5.3.13 and 5.4.x before 5.4.3, when configured as a CGI script (aka php-cgi), does not properly handle query strings that lack an = (equals sign) character, which allows remote attackers to cause a denial of service (resource consumption) by placing command-line options in the query string, related to lack of skipping a certain php_getopt for the 'T' case. NOTE: this vulnerability exists because of an incomplete fix for CVE-2012-1823.
Patch / fix
- php53 RHEL 5 5.3.3-13.el5_8
- php53-gd RHEL 5 5.3.3-13.el5_8
- php53-cli RHEL 5 5.3.3-13.el5_8
- php53-dba RHEL 5 5.3.3-13.el5_8
- php53-pdo RHEL 5 5.3.3-13.el5_8
- php53-xml RHEL 5 5.3.3-13.el5_8
- php53-imap RHEL 5 5.3.3-13.el5_8
- php53-intl RHEL 5 5.3.3-13.el5_8
red hat advisories RHSA-2012:1047RHSA-2012:1046RHSA-2012:1045
- php7 openSUSE Tumbleweed 7.0.14-1.4
- php5 openSUSE Tumbleweed 5.6.28-1.1
opensuse advisories openSUSE-SU-2024:10290-1openSUSE-SU-2024:10344-1
Vendor advisories
What the vendors themselves say about their products: affected, fixed or not affected, and what to do.
red hat product security vex CVE-2012-2336 updated cvss 7.5
php: incomplete CVE-2012-1823 fix - missing filtering of -T and -h
-
Red Hat Enterprise Linux (v. 5 server) php 5.1.6-39.el5_8, php53 5.3.3-13.el5_8, php-gd 5.1.6-39.el5_8, php-cli 5.1.6-39.el5_8, php-dba 5.1.6-39.el5_8, php-pdo 5.1.6-39.el5_8, +32 morefixed: vendor fix RHSA-2012:1045
-
Red Hat Enterprise Linux Desktop Optional (v. 6) php 5.3.3-14.el6_3, php-gd 5.3.3-14.el6_3, php-cli 5.3.3-14.el6_3, php-dba 5.3.3-14.el6_3, php-pdo 5.3.3-14.el6_3, php-xml 5.3.3-14.el6_3, +19 more Red Hat Enterprise Linux HPC Node (v. 6) php 5.3.3-14.el6_3, php-cli 5.3.3-14.el6_3, php-common 5.3.3-14.el6_3 Red Hat Enterprise Linux HPC Node Optional (v. 6) php 5.3.3-14.el6_3, php-gd 5.3.3-14.el6_3, php-dba 5.3.3-14.el6_3, php-pdo 5.3.3-14.el6_3, php-xml 5.3.3-14.el6_3, php-zts 5.3.3-14.el6_3, +17 more Red Hat Enterprise Linux Server (v. 6) php 5.3.3-14.el6_3, php-gd 5.3.3-14.el6_3, php-cli 5.3.3-14.el6_3, php-pdo 5.3.3-14.el6_3, php-xml 5.3.3-14.el6_3, php-ldap 5.3.3-14.el6_3, +6 more Red Hat Enterprise Linux Server Optional (v. 6) php 5.3.3-14.el6_3, php-dba 5.3.3-14.el6_3, php-zts 5.3.3-14.el6_3, php-imap 5.3.3-14.el6_3, php-intl 5.3.3-14.el6_3, php-snmp 5.3.3-14.el6_3, +8 more Red Hat Enterprise Linux Workstation (v. 6) php 5.3.3-14.el6_3, php-gd 5.3.3-14.el6_3, php-cli 5.3.3-14.el6_3, php-pdo 5.3.3-14.el6_3, php-xml 5.3.3-14.el6_3, php-ldap 5.3.3-14.el6_3, +6 morefixed: vendor fix RHSA-2012:1046
+1 more productsfewer
Red Hat Enterprise Linux Workstation Optional (v. 6) php 5.3.3-14.el6_3, php-dba 5.3.3-14.el6_3, php-zts 5.3.3-14.el6_3, php-imap 5.3.3-14.el6_3, php-intl 5.3.3-14.el6_3, php-snmp 5.3.3-14.el6_3, +8 more -
Red Hat RHEL Desktop Workstation (v. 5 client) php 5.1.6-39.el5_8, php53 5.3.3-13.el5_8, php-gd 5.1.6-39.el5_8, php-cli 5.1.6-39.el5_8, php-dba 5.1.6-39.el5_8, php-pdo 5.1.6-39.el5_8, +32 morefixed: vendor fix RHSA-2012:1045
-
Red Hat Enterprise Linux 4 phpnot affected: vulnerable code not present
Red Hat CSAF VEX © Red Hat, Inc., from https://security.access.redhat.com/data/csaf/v2/vex/; changed: reduced to product statuses and remediations. CC BY 4.0 · csaf
Timeline
- First public exploit (EDB-18834)
- Published
Exploit prediction
52.09% chance of exploitation in the next 30 days, higher than 98% of all scored CVEs (FIRST EPSS, 2026-11-09).
Exploits and checks
- EDB-29316 Apache + PHP < 5.3.12 / < 5.4.2 - Remote Code Execution + Scanner remote, 2013-10-31
- EDB-29290 Apache + PHP < 5.3.12 / < 5.4.2 - cgi-bin Remote Code Execution remote, 2013-10-29
- EDB-18836 PHP < 5.3.12 / < 5.4.2 - CGI Argument Injection remote, 2012-05-05
- EDB-18834 PHP 5.3.12/5.4.2 - CGI Argument Injection (Metasploit) remote, 2012-05-04
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| NVD | 2.0 | 5.0 | AV:N/AC:L/Au:N/C:N/I:N/A:P |
Classification
- Weakness
-
- CWE-20 Improper Input Validation
- Technology feeds
References
-
lists.opensuse.org
/opensuse-security-announce/2012-06/msg00004.html
vendor-advisory
-
lists.opensuse.org
/opensuse-security-announce/2012-07/msg00003.html
vendor-advisory
-
h20564.www2.hp.com
/portal/site/hpsc/public/kb/docDisplay?docId=emr_na-c03839862
vendor-advisory
-
secunia.com
/advisories/49014
third-party-advisory, vendor-advisory
-
bugs.php.net
/bug.php?id=61910
vendor-advisory
-
php.net
/archive/2012.php#id2012-05-08-1
vendor-advisory
- bugs.php.net /patch-display.php?bug_id=61910&patch=CVE-2012-1823.patch&revision=1336251592&display=1
- php.net /ChangeLog-5.php#5.4.3
Sources
- CVE List CVE-2012-2336
- NVD CVE-2012-2336
Fencer Intel keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.