PHP 8.2.26: Downloads, Changelog, News

Release Information

Release
8.2.26
PHP Version
PHP 8.2
Release Date
Release Type
Security Update
Release Status
Latest Release in 8.2
Branch Status
Supported

Latest release for PHP 8.2. This release contains security fixes, and it is recommended to update as soon as possible.
PHP 8.2 continues to receive bug fixes and security fixes until 2024-12-31.

Downloads

Source Code

Git Clone
Use Git to clone the 8.2.26 tag from the PHP Git repository.
git clone https://github.com/php/php-src.git --depth 1 --branch php-8.2.26
How to compile PHP
PHP can be compiled by setting up the dependencies, building the configure script (./buildconf), configuring the build ./configure, and running make.
Detailed articles on how to compile PHP are available for Ubuntu/Debian based systems and Fedora/RHEL based systems.

Windows binaries

Non-Thread Safe Builds
Non-Thread Safe (NTS) builds are single-threaded PHP builds. They can be used on web servers that integrate PHP over FastCGI protocol, such as Nginx, Caddy, and IIS.
Thread-Safe Builds
Thread-Safe (TS) builds are multi-thread PHP builds, often used to integrate PHP as a Server API for multithreaded servers. The most common use case is using PHP as an Apache module.

Docker/Podman Containers

PHP CLI
PHP CLI Containers images only include the PHP CLI, and no FPM or Apache modules. The Alpine builds are lightweight, but may introduce incompatibilities due to their musl builds. Albeit their larger size, the Debian-based (without the "-alpine" suffix) images are more complete, and widely used.

Alpine-based: Lightweight, but may introduce incompatibilities due to their musl builds.
docker pull php:8.2.26-cli-alpine

Debian-based: More compatible with other components, complete, and are widely used.
docker pull php:8.2.26-cli
PHP CLI + Web Server Integration
These container images include PHP CLI, and a web server integration. FPM container images can be integrated with web servers such as Nginx, Caddy, and Apache with Event MPM. The Apache container images include Apache web server, integrating PHP as an Apache module.

Alpine-based: Lightweight, but may introduce incompatibilities due to their musl builds.
docker pull php:8.2.26-fpm-alpine

Debian-based ZTS Apache: Includes Apache web server integrating PHP as an Apache module.
docker pull php:8.2.26-apache

Debian-based NTS FPM: PHP-FPM, can be integrated with Nginx, Caddy, and other web servers over Fast CGI.
docker pull php:8.2.26-fpm

ChangeLog

CLI

  • Fixed bug GH-16373 (Shebang is not skipped for router script in cli-server started through shebang).
  • Fixed bug GHSA-4w77-75f9-2c8w (Heap-Use-After-Free in sapi_read_post_data Processing in CLI SAPI Interface).

COM

  • Fixed out of bound writes to SafeArray data.

Core

  • Fixed bug GH-16168 (php 8.1 and earlier crash immediately when compiled with Xcode 16 clang on macOS 15).
  • Fixed bug GH-16371 (Assertion failure in Zend/zend_weakrefs.c:646).
  • Fixed bug GH-16515 (Incorrect propagation of ZEND_ACC_RETURN_REFERENCE for call trampoline).
  • Fixed bug GH-16509 (Incorrect line number in function redeclaration error).
  • Fixed bug GH-16508 (Incorrect line number in inheritance errors of delayed early bound classes).
  • Fixed bug GH-16648 (Use-after-free during array sorting).
  • Fixed bug GH-15915 (overflow with a high value for precision INI). (David Carlier / cmb)

Curl

  • Fixed bug GH-16302 (CurlMultiHandle holds a reference to CurlHandle if curl_multi_add_handle fails).

Date

  • Fixed bug GH-16454 (Unhandled INF in date_sunset() with tiny $utcOffset).
  • Fixed bug GH-16037 (Assertion failure in ext/date/php_date.c).
  • Fixed bug GH-14732 (date_sun_info() fails for non-finite values).

DBA

  • Fixed bug GH-16390 (dba_open() can segfault for "pathless" streams).

DOM

  • Fixed bug GH-16316 (DOMXPath breaks when not initialized properly).
  • Fixed bug GH-16473 (dom_import_simplexml stub is wrong).
  • Fixed bug GH-16533 (Segfault when adding attribute to parent that is not an element).
  • Fixed bug GH-16535 (UAF when using document as a child).
  • Fixed bug GH-16593 (Assertion failure in DOM->replaceChild).
  • Fixed bug GH-16595 (Another UAF in DOM -> cloneNode).

EXIF

  • Fixed bug GH-16409 (Segfault in exif_thumbnail when not dealing with a real file).

FFI

  • Fixed bug GH-16397 (Segmentation fault when comparing FFI object).

Filter

  • Fixed bug GH-16523 (FILTER_FLAG_HOSTNAME accepts ending hyphen).

FPM

  • Fixed bug GH-16628 (FPM logs are getting corrupted with this log statement).

GD

  • Fixed bug GH-16334 (imageaffine overflow on matrix elements).
  • Fixed bug GH-16427 (Unchecked libavif return values).
  • Fixed bug GH-16559 (UBSan abort in ext/gd/libgd/gd_interpolation.c:1007).

GMP

  • Fixed floating point exception bug with gmp_pow when using large exposant values.
  • Fixed bug GH-16411 (gmp_export() can cause overflow).
  • Fixed bug GH-16501 (gmp_random_bits() can cause overflow).
  • Fixed gmp_pow() overflow bug with large base/exponents.
  • Fixed segfaults and other issues related to operator overloading with GMP objects.

LDAP

MBstring

  • Fixed bug GH-16361 (mb_substr overflow on start/length arguments).

MySQLnd

OpenSSL

  • Fixed bug GH-16357 (openssl may modify member types of certificate arrays).
  • Fixed bug GH-16433 (Large values for openssl_csr_sign() $days overflow).
  • Fix various memory leaks on error conditions in openssl_x509_parse().

PDO DBLIB

PDO Firebird

PDO ODBC

  • Fixed bug GH-16450 (PDO_ODBC can inject garbage into field values).

Phar

  • Fixed bug GH-16406 (Assertion failure in ext/phar/phar.c:2808).

PHPDBG

  • Fixed bug GH-16174 (Empty string is an invalid expression for ev).

Reflection

  • Fixed bug GH-16601 (Memory leak in Reflection constructors).

Session

  • Fixed bug GH-16385 (Unexpected null returned by session_set_cookie_params).
  • Fixed bug GH-16290 (overflow on cookie_lifetime ini value).

SOAP

  • Fixed bug GH-16429 (Segmentation fault access null pointer in SoapClient).

Sockets

  • Fixed bug with overflow socket_recvfrom $length argument.

SPL

  • Fixed bug GH-16337 (Use-after-free in SplHeap).
  • Fixed bug GH-16464 (Use-after-free in SplDoublyLinkedList::offsetSet()).
  • Fixed bug GH-16479 (Use-after-free in SplObjectStorage::setInfo()).
  • Fixed bug GH-16478 (Use-after-free in SplFixedArray::unset()).
  • Fixed bug GH-16588 (UAF in Observer->serialize).
  • Fix GH-16477 (Segmentation fault when calling debugInfo() after failed SplFileObject::constructor).
  • Fixed bug GH-16589 (UAF in SplDoublyLinked->serialize()).
  • Fixed bug GH-14687 (segfault on SplObjectIterator instance).
  • Fixed bug GH-16604 (Memory leaks in SPL constructors).
  • Fixed bug GH-16646 (UAF in ArrayObject::unset() and ArrayObject::exchangeArray()).

Standard

  • Fixed bug GH-16293 (Failed assertion when throwing in assert() callback with bail enabled).

Streams

SysVMsg

  • Fixed bug GH-16592 (msg_send() crashes when a type does not properly serialized). (David Carlier / cmb)

SysVShm

  • Fixed bug GH-16591 (Assertion error in shm_put_var).

XMLReader

  • Fixed bug GH-16292 (Segmentation fault in ext/xmlreader/php_xmlreader.c).

Zlib

  • Fixed bug GH-16326 (Memory management is broken for bad dictionaries.)

Commit List

Arnaud Le Blanc

  • Fix handling of invalid iterator in zend_weakmap_iterator_get_current_key() in 1d94fb86b7

Christoph M. Becker

David Carlier

Derick Rethans

Dmitry Stogov

Gina Peter Banyard

  • Fix GH-16477 (Segmentation fault when calling debugInfo() after failed SplFileObject::constructor) in a19029fc8b
  • ext/gmp: Add behavioural tests for operator overloading in fe02fd5095
  • ext/gmp: Fix segfault when null is encountered on an overloaded operator in 5253647500

Ilija Tovilo

  • Skip shebang in cli-server router script in 06efe44c2e
  • Fix exception in assert() callback with bail enabled in b5c09b1a61
  • Fix segfault in zend_test_execute_internal() in 5c798415cd
  • Fix segfault on debug_backtrace() in _ZendTestFiber in 5955ce8987
  • Fix uaf in SplDoublyLinkedList::offsetSet() in 8820a10360
  • Fix use-after-free in SplObjectStorage::setInfo() in 12c987fae2
  • Fix uaf in SplFixedArray::unset() in 7fe168d855
  • Fix propagation of ZEND_ACC_RETURN_REFERENCE for call trampoline in 8720063c4e
  • Fix handling of nested generator in zend_test observer in 69bcbdc3c5
  • Fix lineno in function redeclaration error in de7ef3fa66
  • Fix lineno for inheritance errors of early bound classes in 2d068c4f47
  • Backport CI fixes to security branches in 25c0993902
  • Fix icu dependency for macos build in e3de1a1a21
  • Backport nightly.yml and nightly_matrix.php to PHP-8.1 in 27e8860594
  • [CI] Backport usage of db service for 8.1 in 560a585117
  • Partial backport of e7462bf in ed041c3443
  • Remove -Werror for libmysql test on 8.1 only in 769947648e
  • Fix array going away during sorting in 2bdce61390
  • Postpone zend_array_sort() in ext-intl in 845cdbce67
  • Fix use-after-free in ArrayObject::unset() with destructor in 8910ac800d
  • Also fix same issue in ArrayObject::exchangeArray() in f7222bd2de
  • Add NEWS entry in 418f820f5d

Jakub Zelenka

Niels Dossche

Pierrick Charron

Saki Takamachi

Tim Düsterhus

  • curl: Prevent a CurlMultiHandle from holding onto a CurlHandle if add_handle fails in GH-16302
Subscribe to PHP.Watch newsletter for monthly updates

You will receive an email on last Wednesday of every month and on major PHP releases with new articles related to PHP, upcoming changes, new features and what's changing in the language. No marketing emails, no selling of your contacts, no click-tracking, and one-click instant unsubscribe from any email you receive.

Support PHP.Watch — If you find the articles, version information, Codex, and other PHP.Watch contributions useful, consider supporting through GitHub Sponsors. Your sponsorship helps dedicate more time to creating valuable content and improving the PHP community. Together, we can keep the momentum going — thank you for your support!

Thanks to the highest tier sponsor: @TomasVotruba for your generous support to keep PHP.Watch moving 💜