CVEBrief

Home / Php / Php / CVE-2012-1823

CVE-2012-1823: is it exploited, and which versions of Php are affected and fixed?

CVE-2012-1823 is a command injection vulnerability in Php, and it is exploited in the wild: CISA added it to its Known Exploited Vulnerabilities catalog on March 25, 2022, with a federal due date of April 15, 2022. Affected: php before 5.3.12, php from 5.4.0 before 5.4.2, fedora 39 and 26 more (NVD). Fixed in 5.3.12, 5.4.2, 10.7.5 and 10.8.2 (NVD). Severity: Critical (9.8, CVSS 3.1, from CISA-ADP).

Data checked December 3, 2026: last read CISA KEV December 3, 2026, 06:38 UTC, CVE record November 19, 2026, 07:20 UTC and NVD November 19, 2026, 08:49 UTC.

Exploited in the wild
Yes, CISA KEV
added March 25, 2022, due April 15, 2022
Affected
php before 5.3.12, php from 5.4.0 before 5.4.2, fedora 39 and 26 more
NVD
Fixed in
5.3.12, 5.4.2, 10.7.5 and 10.8.2
NVD
Severity
Critical 9.8
CVSS 3.1 from CISA-ADP
Exploit odds (EPSS)
100.0% in 30 days
higher than 100% of CVEs; FIRST, December 2, 2026

What is CVE-2012-1823?

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.

From the CVE record by certcc, last updated November 4, 2025, 17:11 UTC.

Which products and versions does the NVD list as affected?

VendorProductVersionsType
phpphpbefore 5.3.12application
phpphpfrom 5.4.0 before 5.4.2application
fedoraprojectfedora39operating system
fedoraprojectfedora40operating system
debiandebian linux6.0operating system
hphp-uxb.11.23operating system
hphp-uxb.11.31operating system
opensuseopensuse11.4operating system
opensuseopensuse12.1operating system
suselinux enterprise server10operating system
suselinux enterprise server11operating system
suselinux enterprise software development kit10operating system
suselinux enterprise software development kit11operating system
applemac os xfrom 10.6.8 before 10.7.5operating system
applemac os xfrom 10.8.0 before 10.8.2operating system
redhatapplication stack2.0application
redhatgluster storage server for on-premise2.0application
redhatstorage2.0application
redhatstorage for public cloud2.0application
redhatenterprise linux desktop6.0operating system
redhatenterprise linux eus5.6operating system
redhatenterprise linux eus6.1operating system
redhatenterprise linux eus6.2operating system
redhatenterprise linux server5.0operating system
redhatenterprise linux server6.0operating system

NVD analysis (status Analyzed), last modified June 16, 2026, 23:40 UTC.

How severe is CVE-2012-1823?

ScoreVersionVectorSource
Critical 9.8CVSS 3.1CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:HCISA-ADP
High 7.5CVSS 2.0AV:N/AC:L/Au:N/C:P/I:P/A:PNVD

Each score is shown as its source gave it: the CNA that wrote the record, CISA's ADP (vulnrichment) and the NVD. They can differ.

What the ratings mean: in CVSS 3 and 4, scores run from 0 to 10, with Low 0.1 to 3.9, Medium 4.0 to 6.9, High 7.0 to 8.9 and Critical 9.0 to 10.0. CVSS 2 has no Critical band: its High runs from 7.0 to 10.0. The vector lists how the flaw is reached (network, local), what an attacker needs (privileges, a user's click) and what it can harm.

Is CVE-2012-1823 exploited in the wild?

CISA KEV
Listed as PHP-CGI Query String Parameter Vulnerability, added March 25, 2022; federal agencies must act by April 15, 2022
Required action
Apply updates per vendor instructions.
Ransomware use
Unknown
CISA's summary
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.
CISA SSVC
Exploitation: active; automatable: yes; technical impact: total (CISA ADP, February 7, 2025)
EPSS
100.0% probability of exploitation activity in the next 30 days, percentile 100.0 (FIRST EPSS, scores of December 2, 2026)

What kind of flaw is it?

Where are the vendor advisories and references?

When was it published, and where is the official record?

Reserved
March 21, 2012
Published
May 11, 2012, 10:00 UTC
CVE record updated
November 4, 2025, 17:11 UTC by certcc
NVD
Analyzed, last modified June 16, 2026, 23:40 UTC
Last checked
CVE list November 19, 2026, 07:20 UTC; NVD November 19, 2026, 08:49 UTC; KEV December 3, 2026, 06:38 UTC; EPSS December 2, 2026
Official record
cve.org · NVD · CISA KEV

What other CVEs affect Php?

Every CVE in Php

Questions about CVE-2012-1823

Is CVE-2012-1823 exploited in the wild?

Yes. CISA added CVE-2012-1823 to its Known Exploited Vulnerabilities catalog on March 25, 2022 and set federal agencies a due date of April 15, 2022. FIRST's EPSS gives it a 100.0% chance of exploitation activity in the next 30 days (scores of December 2, 2026).

Which versions of Php are affected by CVE-2012-1823?

php before 5.3.12, php from 5.4.0 before 5.4.2, fedora 39, fedora 40, debian linux 6.0, hp-ux b.11.23 and 23 more, per the NVD. The tables above give every range the sources list.

Which version fixes CVE-2012-1823?

5.3.12, 5.4.2, 10.7.5 and 10.8.2, per the NVD. Check the vendor's advisory before you rely on it.

How severe is CVE-2012-1823?

Critical (9.8, CVSS 3.1, from CISA-ADP). The severity table above shows each score with its source.

Where is the official record of CVE-2012-1823?

The CVE Program's record is at cve.org and the NVD's at nvd.nist.gov; CISA's entry is in its Known Exploited Vulnerabilities catalog. For a fix, the vendor's own advisory is the one to follow.