CVE-2025-14179: CWE-89 Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection') in PHP Group PHP
In PHP versions 8.2.* before 8.2.31, 8.3.* before 8.3.31, 8.4.* before 8.4.21, and 8.5.* before 8.5.6, the PDO Firebird driver improperly handles NUL bytes when preparing SQL queries. During token-by-token query construction, a string token containing a NUL byte is copied via strncat(), which stops at the NUL byte, dropping the closing quote and causing subsequent SQL tokens to be interpreted as part of the string. This allows SQL injection when attacker-controlled values are quoted via PDO::quote() and embedded in SQL statements.
AI Analysis
Technical Summary
This vulnerability in PHP's PDO Firebird driver involves improper neutralization of special elements used in SQL commands (CWE-89). Specifically, when preparing SQL queries, the driver copies string tokens containing NUL bytes using strncat(), which stops at the NUL byte and drops the closing quote. This causes subsequent SQL tokens to be interpreted as part of the string, allowing an attacker to perform SQL injection if they control values quoted via PDO::quote(). The issue affects PHP versions 8.2.* before 8.2.31, 8.3.* before 8.3.31, 8.4.* before 8.4.21, and 8.5.* before 8.5.6.
Potential Impact
Successful exploitation allows an attacker to perform SQL injection attacks via the PDO Firebird driver, potentially leading to unauthorized data access or manipulation. The CVSS 4.0 base score is 7.4 (high), indicating significant impact with network attack vector, low attack complexity, partial user interaction, and high impact on confidentiality, integrity, and availability.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. The Red Hat advisory linked does not explicitly state a patch or workaround. Users should monitor the official PHP and Red Hat advisories for updates and apply any released patches promptly. Until a fix is available, avoid using PDO Firebird driver with untrusted input or ensure input is sanitized to prevent injection.
CVE-2025-14179: CWE-89 Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection') in PHP Group PHP
Description
In PHP versions 8.2.* before 8.2.31, 8.3.* before 8.3.31, 8.4.* before 8.4.21, and 8.5.* before 8.5.6, the PDO Firebird driver improperly handles NUL bytes when preparing SQL queries. During token-by-token query construction, a string token containing a NUL byte is copied via strncat(), which stops at the NUL byte, dropping the closing quote and causing subsequent SQL tokens to be interpreted as part of the string. This allows SQL injection when attacker-controlled values are quoted via PDO::quote() and embedded in SQL statements.
CVSS v4.0
Score 7.4high
Affected software
pkg:github/php/php-srcRun on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
This vulnerability in PHP's PDO Firebird driver involves improper neutralization of special elements used in SQL commands (CWE-89). Specifically, when preparing SQL queries, the driver copies string tokens containing NUL bytes using strncat(), which stops at the NUL byte and drops the closing quote. This causes subsequent SQL tokens to be interpreted as part of the string, allowing an attacker to perform SQL injection if they control values quoted via PDO::quote(). The issue affects PHP versions 8.2.* before 8.2.31, 8.3.* before 8.3.31, 8.4.* before 8.4.21, and 8.5.* before 8.5.6.
Potential Impact
Successful exploitation allows an attacker to perform SQL injection attacks via the PDO Firebird driver, potentially leading to unauthorized data access or manipulation. The CVSS 4.0 base score is 7.4 (high), indicating significant impact with network attack vector, low attack complexity, partial user interaction, and high impact on confidentiality, integrity, and availability.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. The Red Hat advisory linked does not explicitly state a patch or workaround. Users should monitor the official PHP and Red Hat advisories for updates and apply any released patches promptly. Until a fix is available, avoid using PDO Firebird driver with untrusted input or ensure input is sanitized to prevent injection.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- php
- Date Reserved
- 2025-12-06T06:34:43.979Z
- Cvss Version
- 4.0
- State
- PUBLISHED
- Remediation Level
- null
- Vendor Advisory Urls
- [{"url":"https://access.redhat.com/security/cve/CVE-2025-14179","vendor":"Red Hat"}]
Threat ID: 6a000b48cbff5d861022ac68
Added to database: 05/10/2026, 04:36:24 UTC
Last enriched: 07/15/2026, 08:16:24 UTC
Last updated: 07/31/2026, 19:22:53 UTC
Views: 173
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.