PHP 8.2.5: Downloads, Changelog, News

Release Information

Release
8.2.5
PHP Version
PHP 8.2
Release Date
Release Type
Bug Fix Release
Release Status
Use PHP 8.2.20 instead
Branch Status
Supported

PHP 8.2.5 is an old release of PHP 8.2 series. Using the latest version PHP 8.2.20 is highly recommended.
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.5 tag from the PHP Git repository.
git clone https://github.com/php/php-src.git --depth 1 --branch php-8.2.5
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.5-cli-alpine

Debian-based: More compatible with other components, complete, and are widely used.
docker pull php:8.2.5-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.5-fpm-alpine

Debian-based ZTS Apache: Includes Apache web server integrating PHP as an Apache module.
docker pull php:8.2.5-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.5-fpm

ChangeLog

Core

  • Added optional support for max_execution_time in ZTS/Linux builds
  • Fixed use-after-free in recursive AST evaluation.
  • Fixed bug GH-8646 (Memory leak PHP FPM 8.1).
  • Re-add some CTE functions that were removed from being CTE by a mistake.
  • Remove CTE flag from array_diff_ukey(), which was added by mistake.
  • Fixed bug GH-10801 (Named arguments in CTE functions cause a segfault).
  • Fixed bug GH-8789 (PHP 8.0.20 (ZTS) zend_signal_handler_defer crashes on apache).
  • Fixed bug GH-10015 (zend_signal_handler_defer crashes on apache shutdown).
  • Fixed bug GH-10810 (Fix NUL byte terminating Exception::__toString()).
  • Fix potential memory corruption when mixing __callStatic() and FFI.

Date

  • Fixed bug GH-10747 (Private and protected properties in serialized Date* objects throw).

FPM

  • Fixed bug GH-10611 (fpm_env_init_main leaks environ).
  • Destroy file_handle in fpm_main.
  • Fixed bug #74129 (Incorrect SCRIPT_NAME with apache ProxyPassMatch when spaces are in path).

FTP

  • Propagate success status of ftp_close().
  • Fixed bug GH-10521 (ftp_get/ftp_nb_get resumepos offset is maximum 10GB).

IMAP

  • Fix build failure with Clang 16.

MySQLnd

  • Fixed bug GH-8979 (Possible Memory Leak with SSL-enabled MySQL connections).

Opcache

  • Fixed build for macOS to cater with pkg-config settings.
  • Fixed bug GH-8065 (opcache.consistency_checks > 0 causes segfaults in PHP >= 8.1.5 in fpm context).

OpenSSL

  • Add missing error checks on file writing functions.

PDO Firebird

  • Fixed bug GH-10908 (Bus error with PDO Firebird on RPI with 64 bit kernel and 32 bit userland).

Phar

  • Fixed bug GH-10766 (PharData archive created with Phar::Zip format does not keep files metadata (datetime)).
  • Add missing error checks on EVP_MD_CTX_create() and EVP_VerifyInit().

PDO ODBC

  • Fixed missing and inconsistent error checks on SQLAllocHandle.

PGSQL

  • Fixed typo in the array returned from pg_meta_data (extended mode).

SPL

  • Fixed bug GH-10519 (Array Data Address Reference Issue).
  • Fixed bug GH-10907 (Unable to serialize processed SplFixedArrays in PHP 8.2.4).
  • Fixed bug GH-10844 (ArrayIterator allows modification of readonly props).

Standard

  • Fixed bug GH-10885 (stream_socket_server context leaks).
  • Fixed bug GH-10052 (Browscap crashes PHP 8.1.12 on request shutdown (apache2)).
  • Fixed oss-fuzz #57392 (Buffer-overflow in php_fgetcsv() with \0 delimiter and enclosure).
  • Fixed undefined behaviour in unpack().

Commit List

Alex Dowad

  • mb_encode_mimeheader does not crash if provided encoding has no MIME name set in 7c1ee5a02a

Arnaud Le Blanc

  • Remove xfail from tests that do not fail anymore in GH-10871

Bob Weinand

David Carlier

David CARLIER

  • ext/psql: pg_meta_data, extended mode, fix typo for pseudo typtype in 5adeed3051
  • ext/pdo_mysql: mysql_handle_closer nullify some freed data in f6989df8cc

Derick Rethans

Dmitry Stogov

  • Fix Zend/tests/type_declarations/variance/class_order_autoload1.phpt in 18b43d2950
  • Fix incorrect optimization in 1f5d9534ae

Ilija Tovilo

  • Fix unescaped {TMP} variables in tests in 2b5aac9303
  • Fix missing readonly modification error with inc/dec in JIT in df93146a15
  • Update windows action to checkout@v3 in 28ef654648
  • Fix GH-10709: UAF in recursive AST evaluation in 7202fe16b7
  • Enable GitHub actions cancel-in-progress for PRs in cfe1aab865
  • Update libmysql 5.7 version in 12290b796b
  • Test Windows with opcache on GitHub actions in 6b884737c4
  • Disable asan instrumentation for phpdbg_watchpoint_userfaultfd_thread in f415ba60ab
  • Fix RC1 assumption for typed properties with __get in 3175f24d6a
  • use_tls=0 on MSAN in 63525ee600
  • Move ARM64 build to Cirrus in ccca59728e
  • Another attempt to fix MSAN nightly on master in 471105abd7
  • Fix NUL byte in exception string terminating Exception::__toString() in b5726c2cb1
  • Fix GH-10885: Leaking stream_socket_server context in 122f1287a0
  • By-ref modification of typed and readonly props through ArrayIterator in 9aaa5cd093
  • Fix buffer-overflow in php_fgetcsv() with \0 delimiter and enclosure in 57029ce92e
  • Unparallelize IO heavy tests in e1ec67acd6
  • Reset EG(trampoline).op_array.last_var that FFI may modify in 4e0bd03681

Jakub Zelenka

  • Add extra option to FPM tester for handling script filename in 3125155b5d
  • Test FPM FCGI envs without path info fix for custom source in 92d2cd5cb8
  • Test FPM FCGI envs with path info fix for Apache proxy balancer in b53b0ac2ea
  • Test FPM FCGI envs with path info fix for Apache proxy handler in 8cf621e0e4
  • Test FPM FCGI envs with path info fix for Apache proxy pass in 38d2e7ea9a
  • Fix FPM tester $scriptName logic in 7d987ebbbf
  • Fix bug #74129: Incorrect SCRIPT_NAME with apache ProxyPassMatch in 0d4d471847

Kamil Tekiela

  • Fix strlen error message param name in 1be99faeff

Kévin Dunglas

  • fix: support for timeouts with ZTS on Linux in GH-10141

Max Kellermann

  • ext/curl: suppress -Wdeprecated-declarations in curl_arginfo.h in 2646d76abc

Michael Orlitzky

  • ext/imap/config.m4: -Werror=implicit-function-declaration compatibility in f9cbeaa033

Michael Voříšek

  • Add Windows GitHub actions build in 916b132ea0
  • Re-add some CTE functions that were removed from being CTE by a mistake in 411cd04541
  • Remove CTE flag from array_diff_ukey(), which was added by mistake in 5239f9fc86
  • Windows CI log verbosity, CI bat file guard in f42e56286a

NathanFreeman

nielsdos

  • Make error checks on encoding methods for docomo, kddi, sb consistent in 69543e6a10
  • Use CK() macro to check the output function in mbfilter_unicode2sjis_emoji_sb() in 263655a520
  • Propagate error checks for mbfl_filt_conv_illegal_output() in d66ca5dabb
  • Propagate success status of ftp_close() to userland in abc6fe8f2e
  • Add missing error check on i2d_PKCS12_bio() in d2ef1561fb
  • Add missing error check on PEM_write_bio_CMS() in 51ea4a680d
  • Fix missing and inconsistent error check on SQLAllocHandle in c4c8d6ced7

Niels Dossche

  • Fix GH-10766: PharData archive created with Phar::Zip format does not keep files metadata (datetime) in e633be3e87
  • Add missing error checks on EVP_MD_CTX_create() and EVP_VerifyInit() in 30ebecb1d4
  • Add missing error check on PEM_write_bio_PKCS7() in 22c9e7e27e
  • Fix GH-8646: Memory leak PHP FPM 8.1 in ff62d117a3
  • Fix GH-8065: opcache.consistency_checks > 0 causes segfaults in PHP >= 8.1.5 in fpm context in 85df512a12
  • Fix GH-10801: Named arguments in CTE functions cause a segfault in 2c53d63197
  • Fix GH-10611: fpm_env_init_main leaks environ in 71c63723c8
  • Fix module shutdown crash during ZTS JIT shutdown in b3e28e2290
  • Fix GH-8789 and GH-10015: Fix ZTS zend signal crashes due to NULL globals in 06ae75007a
  • Destroy file_handle in fpm_main in f30e71cbde
  • Fix GH-10052: Browscap crashes PHP 8.1.12 on request shutdown (apache2) in c407243712
  • Fix GH-10521: ftp_get/ftp_nb_get resumepos offset is maximum 10GB in 301418284d
  • Fix GH-8979: Possible Memory Leak with SSL-enabled MySQL connections in 8930bf8c33
  • Fix GH-10907: Unable to serialize processed SplFixedArrays in PHP 8.2.4 in a082696699
  • Fix GH-10928: PHP Build Failed - Test curl_version() basic functionality [ext/curl/tests/curl_version_basic_001.phpt] in 8e620b4ecb
  • Fix undefined behaviour in string uppercasing and lowercasing in 93e0f6b424
  • Fix undefined behaviour when writing 32-bit values in phar/tar.c in 19ddc62778
  • Fix undefined behaviour in GENERATE_SEED() in 6f56c00498
  • Fix GH-10908: Bus error with PDO Firebird on RPI with 64 bit kernel and 32 bit userland in 21e0305f5d
  • Handle indirect zvals in SplFixedArray::__serialize in e698938229
  • Revert "Handle indirect zvals in SplFixedArray::__serialize" in 0d524eda94
  • Fix test for GH-10908 in 1357d1eb41
  • Fix undefined behaviour in unpack() in 87862835e2

pakutoma

  • Fix phpGH-10648: add check function pointer into mbfl_encoding in 6fc8d014df
  • Fix phpGH-10648: add check function pointer into mbfl_encoding in b721d0f71e

Pierrick Charron

Remi Collet

  • avoid test file being consider binary in f575027b56
  • remove assert raising strange behavior with GCC 10 in bdf2f722ca

Tim Düsterhus

  • random: Add missing php.h include to php_random.h in GH-10764
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.