Skip to main content
Live Webinar with SANS (June 25)— Agentic CTI Automation for Fun & ProfitRegister Free
Mallory
HighPublic exploit

DoS via NULL pointer dereference in PHP PDO PostgreSQL (emulated prepares)

IdentifiersCVE-2025-14180CWE-476· NULL Pointer Dereference

CVE-2025-14180 affects PHP when using the PDO PostgreSQL driver with PDO::ATTR_EMULATE_PREPARES enabled. In PHP 8.1.* before 8.1.34, 8.2.* before 8.2.30, 8.3.* before 8.3.29, 8.4.* before 8.4.16, and 8.5.* before 8.5.1, supplying an invalid character sequence (e.g., \x99) in a prepared statement parameter can cause libpq’s PQescapeStringConn() quoting routine to return NULL. PHP’s pdo_parse_params() then dereferences this NULL pointer, resulting in a segmentation fault (NULL pointer dereference) and process crash.

Share:
For your environment

Are you exposed to this one?

Mallory correlates every CVE against your assets, your vendors, and active adversary campaigns. Know which vulnerabilities matter for you, not just which ones are loud.

ANALYST BRIEF

Impact, mitigation & remediation

What it means. What to do now. Patch path, mitigations, and the assume-compromise checklist.

Impact

What an attacker gets, and what they’ve been doing with it.

Remote attackers can trigger a crash (segmentation fault) of the PHP process handling the request, causing denial of service and impacting availability of the target application/server. (Debian advisory notes DoS and potential memory disclosure for multiple PHP issues; for this CVE the described primary impact is DoS via crash.)

Mitigation

If you can’t patch tonight, do this now.

If immediate upgrade is not possible, reduce exposure by disabling PDO::ATTR_EMULATE_PREPARES for PostgreSQL connections (use native prepares) and/or ensure untrusted input cannot reach prepared-statement parameters in a way that can introduce invalid byte sequences. Prefer vendor-provided patched packages as the primary mitigation.

Remediation

Patch, then assume compromise.

Upgrade PHP to a fixed release: 8.1.34+ / 8.2.30+ / 8.3.29+ / 8.4.16+ / 8.5.1+. On Debian (trixie) for PHP 8.4, upgrade to php8.4 8.4.16-1~deb13u1 or later (per DSA-6088-1).
PUBLIC EXPLOITS

Exploits

1 valid exploit after Mallory filtered fakes, detection scripts, and README-only repos.

VALID 1 / 1 TOTALView more in app
PHP_8.1.x_ExploitMaturityPoCVerified exploit

This repository is a standalone Bash-based exploit toolkit centered on PHP8.1.x_Exploit.sh, which orchestrates detection and exploitation of four PHP CVEs using modular helper scripts under modules/. The main script normalizes target URLs, fingerprints OS and PHP version via HTTP headers and a phpinfo.php probe, crawls homepage links/forms, enumerates likely CGI and upload endpoints, and then invokes per-CVE modules. The repository structure is simple: one main driver script, four CVE-specific Bash modules, one shared utils module, and a README. Primary exploit capability is CVE-2024-4577 against Windows PHP-CGI. The module tests two query-string injection variants, including a soft-hyphen bypass, by setting allow_url_include and auto_prepend_file=php://input and POSTing PHP code. On success it either demonstrates command execution with whoami or launches a PowerShell reverse shell to an operator-supplied IP/port. This is a real exploitation path providing RCE. A second remote capability targets CVE-2025-14177 by generating malformed JPEG files and POSTing them to discovered upload endpoints using multipart form field file. Detection looks for a marker string or long printable output in responses; exploitation repeats the upload 10 times and stores raw responses and extracted strings under a reports subdirectory, aiming to capture leaked heap data. The remaining two modules, CVE-2025-14180 and CVE-2025-14178, are effectively local/RCE-follow-on checks and crash payloads rather than pure remote exploits. Both use php -r locally when PHP CLI is present; the exploit functions POST PHP snippets to a target URL if remote code execution is already available. CVE-2025-14180 attempts to trigger a PDO PostgreSQL null dereference using DSN pgsql:host=localhost;dbname=postgres with emulated prepares enabled. CVE-2025-14178 attempts an array_merge integer overflow by allocating extremely large arrays. Both are described as potentially crashing or destabilizing the PHP process. Overall, this is an operational multi-CVE web exploitation script, not just a detector. It supports single-target and batch modes, optional GNU parallel execution, report logging, and automatic exploitation unless scan-only is specified. Fingerprintable targets include common CGI paths, common upload paths, phpinfo.php probing, php://input injection, localhost PostgreSQL access, and attacker-defined reverse-shell callback endpoints.

gl1tch0x1Disclosed Apr 29, 2026bashmarkdownwebnetworklocal
EXPOSURE SURFACE

Affected products & vendors

Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.

VendorProductType
PHP GroupPhpapplication

Vendor-confirmed product mapping. Mallory continuously reconciles this list against your asset inventory.

What this page doesn’t show

The version that knows your environment.

This page is what’s public. Mallory adds the parts that aren’t: which of your assets are affected, which adversaries are exploiting it right now, which detections to deploy, and what to do tonight.
Exposure mapping

Query your assets running an affected version, and investigate the blast radius.

Threat actor evidence

Every observed campaign linking this CVE to a named adversary.

Associated malware

Malware families riding this exploit, with evidence and IOCs.

Detection signatures

YARA, Sigma, Snort, and vendor rules, auto-deployed to your SIEM.

Vendor-by-vendor mapping

Cross-references every affected SKU, including bundled OEM variants.

Social activity9

Community discussion across Reddit, Mastodon, and other social sources.