PHP 8.2.4: Downloads, Changelog, News

Release Information

Release
8.2.4
PHP Version
PHP 8.2
Release Date
Release Type
Security Update
Release Status
Use PHP 8.2.24 instead
Branch Status
Supported

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

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

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

ChangeLog

Core

  • Fixed incorrect check condition in ZEND_YIELD.
  • Fixed incorrect check condition in type inference.
  • Fix incorrect check in zend_internal_call_should_throw().
  • Fixed overflow check in OnUpdateMemoryConsumption.
  • Fixed bug GH-9916 (Entering shutdown sequence with a fiber suspended in a Generator emits an unavoidable fatal error or crashes).
  • Fixed bug GH-10437 (Segfault/assertion when using fibers in shutdown function after bailout).
  • Fixed SSA object type update for compound assignment opcodes.
  • Fixed language scanner generation build.
  • Fixed zend_update_static_property() calling zend_update_static_property_ex() misleadingly with the wrong return type.
  • Fix bug GH-10570 (Fixed unknown string hash on property fetch with integer constant name).
  • Fixed php_fopen_primary_script() call resulted on zend_destroy_file_handle() freeing dangling pointers on the handle as it was uninitialized.

Curl

  • Fixed deprecation warning at compile time.
  • Fixed bug GH-10270 (Unable to return CURL_READFUNC_PAUSE in readfunc callback).

Date

  • Fix GH-10447 ('p' format specifier does not yield 'Z' for 00:00).
  • Fix GH-10152 (Custom properties of Date's child classes are not serialised).

FFI

  • Fixed incorrect bitshifting and masking in ffi bitfield.

Fiber

  • Fixed assembly on alpine x86.
  • Fixed bug GH-10496 (segfault when garbage collector is invoked inside of fiber).

FPM

  • Fixed bug GH-10315 (FPM unknown child alert not valid).
  • Fixed bug GH-10385 (FPM successful config test early exit).

GMP

  • Properly implement GMP::__construct().

Intl

  • Fixed bug GH-10647 (Spoolchecker isSuspicious/areConfusable methods error code's argument always returning NULL0.

JSON

  • Fixed JSON scanner and parser generation build.

MBString

  • ext/mbstring: fix new_value length check.
  • Fix bug GH-10627 (mb_convert_encoding crashes PHP on Windows).

Opcache

  • Fix incorrect page_size check.
  • Fix readonly modification check when using inc/dec operators on readonly property with JIT.

OpenSSL

  • Fixed php_openssl_set_server_dh_param() DH params errors handling.

PDO OCI

  • Fixed bug #60994 (Reading a multibyte CLOB caps at 8192 chars).

PHPDBG

  • Fixed bug GH-10715 (heap buffer overflow on --run option misuse).

PGSQL

  • Fix GH-10672 (pg_lo_open segfaults in the strict_types mode).

Phar

  • Fix incorrect check in phar tar parsing.

Random

  • Fix GH-10390 (Do not trust arc4random_buf() on glibc).
  • Fix GH-10292 (Made the default value of the first param of srand() and mt_srand() unknown).

Reflection

  • Fixed bug GH-10623 (Reflection::getClosureUsedVariables opcode fix with variadic arguments).
  • Fix Segfault when using ReflectionFiber suspended by an internal function.

Session

  • Fixed ps_files_cleanup_dir() on failure code paths with -1 instead of 0 as the latter was considered success by callers.

Standard

  • Fixed bug GH-8086 (Introduce mail.mixed_lf_and_crlf INI).
  • Fixed bug GH-10292 (Made the default value of the first param of srand() and mt_srand() unknown).
  • Fix incorrect check in cs_8559_5 in map_from_unicode().
  • Fix bug GH-9697 for reset/end/next/prev() attempting to move pointer of properties table for certain internal classes such as FFI classes
  • Fix incorrect error check in browsecap for pcre2_match().

Streams

  • Fixed bug GH-10370 (File corruption in _php_stream_copy_to_stream_ex when using copy_file_range).
  • Fixed bug GH-10548 (copy() fails on cifs mounts because of incorrect copy_file_range() len).

Tidy

  • Fix memory leaks when attempting to open a non-existing file or a file over 4GB.
  • Add missing error check on tidyLoadConfig.

Zlib

  • Fixed output_handler directive value's length which counted the string terminator.

Commit List

Aaron Piotrowski

Arnaud Le Blanc

  • Handle non-INDIRECT symbol table entries in zend_fiber_object_gc() in GH-10386
  • Prevent dtor of generator in suspended fiber in GH-10462
  • Fix concurrent testing in 10f2378584
  • Fix colletion of unfinished function call in fibers in d721dcc2ef

Ben Ramsey

Bob Weinand

  • Fix resetting ZEND_GENERATOR_IN_FIBER flag in b9bca2dadb
  • Look at executing generator for fiber destructor behaviour in 00be6e1aed
  • Fix GH-10496: Fibers must not be garbage collected while implicitly suspended by resumption of another fiber in 95016138a5

Danack

Daniel Black

  • ext/json: add php_json_scanner_defs.h as make target in 2fde3afffb
  • ext/Zend: zend_language_scanner_defs.h as make target in e83cda0887
  • zend win32 RE2C header files to Make targets and generated_files in 2b3fa5edac

Daniil Gentili

David Carlier

Derick Rethans

Dmitry Stogov

  • Fix incorrect compilation of FE_FETCH with predicted empty array in 7d68f9128e
  • Fix type inference in 81607a62ca
  • Fix possible exit_counters memory leak in ZTS build in a21195650e
  • Fix (at lease part of the) #GH-10635: ARM64 function JIT causes impossible assertion in 08e7591206
  • Fix GH-10635: ARM64 function JIT causes impossible assertion in GH-10638
  • Fix incorrect inheritance cache update in GH-10719
  • Fix incorrect inheritance cache update in GH-10719
  • Fix Zend/tests/type_declarations/variance/class_order_autoload1.phpt in 5eb7d7e07b

George Peter Banyard

  • Fix memory leaks in ext-tidy in 704aadd098
  • Fix GH-10672 (pg_lo_open segfaults in the strict_types mode) in 5f357f341d
  • The userland constants do not start with PHP_ in 6a5b3f0ff9
  • Fixed ValueError message in substr_compare() in 2133970152
  • Fixed ValueError message in count_chars() in adc5edd411

Ilija Tovilo

  • Disable timestamp for GitHub actions ccache in c95125d370
  • Mark test as XFAIL in 13c34aac05
  • Temporarily disable odbc in ci in 18b611d6a0
  • Revert "Fix GH-10168: heap-buffer-overflow at zval_undefined_cv" in 7b68ff46da
  • Revert "Remove useless UNEXPECTED around RETURN_VALUE_USED in specialized RETVAL handler" in 81f3fcd5cc

Jakub Zelenka

Kévin Dunglas

  • make clean: remove ext/opcache/minilua in c4c861b01a

Max Kellermann

  • github/workflows/push.yml: enable ccache in f7e678476f
  • ext/opcache/zend_jit: cast function to fix -Wincompatible-pointer-types in GH-10527
  • ext/opcache/zend_jit: call TSRM dtor before unloading opcache.so in GH-10533
  • Zend/zend_cpuinfo, ext/standard/crc32_x86: fix -Wstrict-prototypes in 0752baa583
  • php.ini-production: disable opcache.huge_code_pages by default in e6281db857
  • ext/curl: suppress -Wdeprecated-declarations in 8c8a38a75c
  • ext/mbstring: fix new_value length check in 243865ae57
  • Zend/zend_ini: fix zend_result return values in d51eb1d74c
  • ext/curl/interface: fix zend_result return value in ed4dc39e7f

Michael Voříšek

  • Fix PDO OCI Bug #60994 (Reading a multibyte CLOB caps at 8192 chars) in 4df4264ac9

Máté Kocsis

  • Customize the link of some constants in the manual in 148ac364e9
  • Fix GH-10292 1st param of mt_srand() has UNKNOWN default on PHP <8.3 in 3197104e85

NathanFreeman

ndossche

  • Add missing error check on tidyLoadConfig in f592f75e9c
  • Fix incorrect error check in browsecap for pcre2_match() in 8cac8306c3

nielsdos

  • Fix Tidy tests failing due to different spelling in 74c880edd1
  • Propagate errors correctly in ps_files_cleanup_dir() in da3ce6015d
  • Fix incorrect type for return value of zend_update_static_property_ex() in 8959ff39d8

Niels Dossche

  • Fix incorrect check condition in ZEND_YIELD in b5e9bf7775
  • Implement GMP::__construct() in 4ea85d4044
  • Fix GH-10248: Assertion `!(zval_get_type(&(*(property))) == 10)' failed in 0801c567dc
  • Fix duplicated FILE section in test bug80747.phpt in 974dba3b80
  • Fix incorrect bitshifting and masking in ffi bitfield in GH-10403
  • Fix incorrect check condition in type inference in GH-10425
  • Fix incorrect page_size check in b7a158a19b
  • Fix incorrect check in cs_8559_5 in map_from_unicode() in a8c8fb2564
  • Fix incorrect check in zend_internal_call_should_throw() in 972c74c300
  • Fix overflow check in OnUpdateMemoryConsumption in GH-10456
  • Fix incorrect check in phar tar parsing in ec4939b170
  • Fix GH-10385: FPM successful config test early exit in 5b13e83074
  • Sync boost/context assembly files for fibers in 49551d7c29
  • Fix GH-10168: heap-buffer-overflow at zval_undefined_cv in 71ddede565
  • Fix GH-10370: File corruption in _php_stream_copy_to_stream_ex when using copy_file_range in GH-10440
  • Fix GH-10548: copy() fails on cifs mounts because of incorrect length (cfr_max) specified in streams.c:1584 copy_file_range() in GH-10551
  • Fix array overrun when appending slash to paths in ec10b28d64
  • Fix assertion failure when var_dump'ing void FFI result in GH-10568
  • Fix updating SSA object type for *_ASSIGN_OP in GH-10458
  • Fix GH-10623: ReflectionFunction::getClosureUsedVariables() returns empty array in presence of variadic arguments in ae16471628
  • Fix GH-10627: mb_convert_encoding crashes PHP on Windows in ed0c0df351
  • Fix incorrect string length for output_handler in zlib ini code in c510083c8c
  • Fix GH-10570: Assertion `(key)->h != 0 && "Hash must be known"' failed in b9a5bfc355
  • Fix GH-10692: PHP crashes on Windows when an inexistent filename is executed in df579adac7
  • Fix format string mistake in accel_move_code_to_huge_pages() in eb7bb3430b
  • Fix incorrect error checking in php_openssl_set_server_dh_param() in b09be29ac1
  • Fix GH-10715: phpdbg heap buffer overflow -- by misuse of the option "--run" in 0f21cbc57c
  • Fix module shutdown crash during ZTS JIT shutdown in ca1b7312d2

Pierrick Charron

  • Fixed bug GH-10270 Unable to return CURL_READFUNC_PAUSE in readfunc callback in 91db3a1b85

Remi Collet

SATO Kentaro

  • Add support for generating namespaced constant in 7fccdf72a4

Sergey Panteleev

Stanislav Malyshev

Tim Düsterhus

  • random: Do not trust arc4random_buf() on glibc in GH-10390
  • crypt: Fix validation of malformed BCrypt hashes in c840f71524
  • crypt: Fix possible buffer overread in php_crypt() in a92acbad87
  • makedist: Use fixed owner/group in generated tarball in GH-10613
  • makedist: Use fixed sort in generated tarball in GH-10615

Tyson Andre

  • Avoid crash for reset/end/next/prev() on ffi classes in GH-9711
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 💜