CVE-2012-1823
· published 2012-05-11
Source record Collected from the National Vulnerability Database (NVD)
CISA Known Exploited Vulnerabilities
CISA lists this CVE as known exploited (added 2022-03-25).
- CISA's name for it: PHP-CGI Query String Parameter Vulnerability
- CISA's description: sapi/cgi/cgi_main.c in PHP, when configured as a CGI script, does not properly handle query strings, which allows remote attackers to execute arbitrary code.
- Known ransomware campaign use, per CISA: Unknown
Source: CISA KEV catalog (CC0 1.0).
Description
Description by CERT/CC via the CVE Program.
sapi/cgi/cgi_main.c in PHP before 5.3.12 and 5.4.x before 5.4.2, 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 execute arbitrary code by placing command-line options in the query string, related to lack of skipping a certain php_getopt for the 'd' case.
Status at the source
- NVD status: Analyzed
Affected products, as the source lists them
| Vendor | Product | Versions |
|---|---|---|
| n/a | n/a | n/a: affected |
Products named in NVD's CPE match criteria (17)
cpe:2.3:a:php:php:*:*:*:*:*:*:*:*cpe:2.3:o:fedoraproject:fedora:39:*:*:*:*:*:*:*cpe:2.3:o:debian:debian_linux:6.0:*:*:*:*:*:*:*cpe:2.3:o:hp:hp-ux:b.11.23:*:*:*:*:*:*:*cpe:2.3:o:opensuse:opensuse:11.4:*:*:*:*:*:*:*cpe:2.3:o:suse:linux_enterprise_server:10:sp4:*:*:-:*:*:*cpe:2.3:o:suse:linux_enterprise_software_development_kit:10:sp4:*:*:*:*:*:*cpe:2.3:o:apple:mac_os_x:*:*:*:*:*:*:*:*cpe:2.3:a:redhat:application_stack:2.0:*:*:*:*:*:*:*cpe:2.3:a:redhat:gluster_storage_server_for_on-premise:2.0:*:*:*:*:*:*:*cpe:2.3:a:redhat:storage:2.0:*:*:*:*:*:*:*cpe:2.3:a:redhat:storage_for_public_cloud:2.0:*:*:*:*:*:*:*cpe:2.3:o:redhat:enterprise_linux_desktop:6.0:*:*:*:*:*:*:*cpe:2.3:o:redhat:enterprise_linux_eus:5.6:*:*:*:*:*:*:*cpe:2.3:o:redhat:enterprise_linux_server:5.0:*:*:*:*:*:*:*cpe:2.3:o:redhat:enterprise_linux_server_aus:5.3:*:*:*:*:*:*:*cpe:2.3:o:redhat:enterprise_linux_workstation:5.0:*:*:*:*:*:*:*
DeSpy has not checked any unit, hardware revision or firmware. A product missing here is not a statement that it is unaffected.
Scores, as their sources published them
- CVSS 3.1: 9.8 CRITICAL — as published by CISA-ADP (Secondary)
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H - CVSS 2.0: 7.5 HIGH — as published by NIST (Primary)
AV:N/AC:L/Au:N/C:P/I:P/A:P - SSVC — CISA's assessment (SSVC 2.0.3, CISA Coordinator): Exploitation: active · Automatable: yes · Technical impact: total
DeSpy does not score records. These are the sources' own values.
Weaknesses
Sources
References the source lists
- http://eindbazen.net/2012/05/php-cgi-advisory-cve-2012-1823/
- http://h20000.www2.hp.com/bizsupport/TechSupport/Document.jsp?objectID=c03360041
- http://lists.apple.com/archives/security-announce/2012/Sep/msg00004.html
- http://lists.opensuse.org/opensuse-security-announce/2012-05/msg00002.html
- http://lists.opensuse.org/opensuse-security-announce/2012-05/msg00007.html
- http://lists.opensuse.org/opensuse-security-announce/2012-05/msg00011.html
- http://marc.info/?l=bugtraq&m=134012830914727&w=2
- http://rhn.redhat.com/errata/RHSA-2012-0546.html
- http://rhn.redhat.com/errata/RHSA-2012-0547.html
- http://rhn.redhat.com/errata/RHSA-2012-0568.html
- http://rhn.redhat.com/errata/RHSA-2012-0569.html
- http://rhn.redhat.com/errata/RHSA-2012-0570.html
- http://secunia.com/advisories/49014
- http://secunia.com/advisories/49065
- http://secunia.com/advisories/49085
- http://secunia.com/advisories/49087
- http://support.apple.com/kb/HT5501
- http://www.debian.org/security/2012/dsa-2465
- http://www.kb.cert.org/vuls/id/520827
- http://www.kb.cert.org/vuls/id/673343
- http://www.mandriva.com/security/advisories?name=MDVSA-2012:068
- http://www.openwall.com/lists/oss-security/2024/06/07/1
- http://www.php.net/ChangeLog-5.php#5.4.2
- http://www.php.net/archive/2012.php#id2012-05-03-1
- http://www.securitytracker.com/id?1027022
- https://bugs.php.net/bug.php?id=61910
- https://bugs.php.net/patch-display.php?bug_id=61910&patch=cgi.diff&revision=1335984315&display=1
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/PKGTQUOA2NTZ3RXN22CSAUJPIRUYRB4B/
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/W45DBOH56NQDRTOM2DN2LNA2FZIMC3PK/
- http://eindbazen.net/2012/05/php-cgi-advisory-cve-2012-1823/
The source lists more references.
Source dates: published 2012-05-11, last changed 2026-06-16. DeSpy's copy of this version is dated 2026-09-28.
This product uses the NVD API but is not endorsed or certified by the NVD.
CVE records: Copyright © 1999-2026, The MITRE Corporation. CVE is a trademark and the CVE logo is a registered trademark of The MITRE Corporation.
CVE Usage: MITRE hereby grants you a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, sublicense, and distribute Common Vulnerabilities and Exposures (CVE™). Any copy you make for such purposes is authorized provided that you reproduce MITRE's copyright designation and this license in any such copy.
CISA's Known Exploited Vulnerabilities catalog and CISA Vulnrichment data are CC0 1.0. CISA advisories are shown with the TLP label their document carries. No endorsement by CISA, DHS, NIST or MITRE is stated or implied.