Out-of-bounds Read Affecting php/php-src package, versions [,8.2.34)[8.3.0RC1,8.3.35)[8.4.0RC1,8.4.26)[8.5.0RC1,8.5.11)


Severity

Recommended
0.0
low
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

Exploit Maturity
Proof of Concept
EPSS
0.36% (30th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications

Snyk Learn

Learn about Out-of-bounds Read vulnerabilities in an interactive lesson.

Start learning
  • Snyk IDSNYK-UNMANAGED-PHPPHPSRC-20158712
  • published27 Sept 2026
  • disclosed25 Sept 2026
  • creditbao00065, cxxz16, TristanInSec, OSTIF-Derek, Nora Dossche

Introduced: 25 Sep 2026

NewCVE-2025-1218  (opens in a new tab)
CWE-125  (opens in a new tab)

How to fix?

Upgrade php/php-src to version 8.2.34, 8.3.35, 8.4.26, 8.5.11 or higher.

Overview

Affected versions of this package are vulnerable to Out-of-bounds Read in ext/mysqlnd/mysqlnd_wireprotocol.c, where the BAIL_IF_NO_MORE_DATA macro guarantees only that one byte remains while several call sites then consume two or more bytes before checking again, affecting the greeting, OK, EOF, auth-switch, cached-sha2, change-user, result set header, prepared statement response, and row packet handlers along with php_mysqlnd_net_field_length() and php_mysqlnd_net_field_length_ll(). An attacker can crash the client process by answering a connection with truncated packets so the parser reads past the end of the received buffer and interprets adjacent heap bytes as packet fields. This requires the application to connect to a MySQL server the attacker controls or has compromised, or a network position allowing server responses to be substituted, so connections to trusted database servers are unaffected.

CVSS Base Scores

version 4.0
version 3.1