PHP 8.2.1: Downloads, Changelog, News

Release Information

Release
8.2.1
PHP Version
PHP 8.2
Release Date
Release Type
Security Update
Release Status
Use PHP 8.2.16 instead
Branch Status
Supported

PHP 8.2.1 is an old release of PHP 8.2 series. Using the latest version PHP 8.2.16 is highly recommended.
PHP 8.2 continues to receive bug fixes and security fixes until 2024-12-08.

Downloads

Source Code

Git Clone
Use Git to clone the 8.2.1 tag from the PHP Git repository.
git clone https://github.com/php/php-src.git --depth 1 --branch php-8.2.1
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.1-cli-alpine

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

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

ChangeLog

Core

  • Fixed bug GH-9905 (constant() behaves inconsistent when class is undefined).
  • Fixed bug GH-9918 (License information for xxHash is not included in README.REDIST.BINS file).
  • Fixed bug GH-9890 (OpenSSL legacy providers not available on Windows).
  • Fixed bug GH-9650 (Can't initialize heap: [0x000001e7]).
  • Fixed potentially undefined behavior in Windows ftok(3) emulation.
  • Fixed GH-9769 (Misleading error message for unpacking of objects).

Apache

  • Fixed bug GH-9949 (Partial content on incomplete POST request).

FPM

  • Fixed bug GH-9959 (Solaris port event mechanism is still broken after bug #66694).
  • Fixed bug #68207 (Setting fastcgi.error_header can result in a WARNING).
  • Fixed bug #80669 (FPM numeric user fails to set groups).
  • Fixed bug GH-8517 (Random crash of FPM master process in fpm_stdio_child_said).

Imap

  • Fixed bug GH-10051 (IMAP: there's no way to check if a IMAP\Connection is still open).

MBString

  • Fixed bug GH-9535 (The behavior of mb_strcut in mbstring has been changed in PHP8.1).

Opcache

  • Fixed bug GH-9968 (Segmentation Fault during OPCache Preload).

OpenSSL

  • Fixed bug GH-9997 (OpenSSL engine clean up segfault).
  • Fixed bug GH-9064 (PHP fails to build if openssl was built with --no-ec).
  • Fixed bug GH-10000 (OpenSSL test failures when OpenSSL compiled with no-dsa).

Pcntl

  • Fixed bug GH-9298 (Signal handler called after rshutdown leads to crash).

PDO_Firebird

  • Fixed bug GH-9971 (Incorrect NUMERIC value returned from PDO_Firebird).

PDO/SQLite

Session

  • Fixed GH-9932 (session name silently fails with . and [).

SPL

  • Fixed GH-9883 (SplFileObject::__toString() reads next line).
  • Fixed GH-10011 (Trampoline autoloader will get reregistered and cannot be unregistered).

SQLite3

  • Fixed bug #81742 (open_basedir bypass in SQLite3 by using file URI).

TSRM

  • Fixed Windows shmget() wrt. IPC_PRIVATE.

Commit List

Alex Dowad

  • Fix regression test for GH-9535 on PHP-8.2+ in d3933e0b6c
  • For UTF-7, flag unnecessary extra trailing byte in Base64 section as error in a618682373
  • Fix mangled kana output for JIS encoding in 8f84192403
  • Support Microsoft's "Best Fit" mappings for Windows-1252 text encoding in a1a69c3734

Arnaud Le Blanc

  • Do not resolve constants on non-linked class during preloading in GH-9975
  • Fallback to first line of function when ex->opline is NULL in GH-10003

Bob Weinand

  • Move observer_declared_function_notify until after pass_two() in 6bd8f40291
  • Do not report MINIT stage internal class aliases in extensions in 182314c317
  • Fix opcache preload with observers enabled in 4052bbf0e3
  • Fix crash reading module_entry after DL_UNLOAD() when module already loaded in 0bfdd5691c

Christoph M. Becker

Daniel Black

  • ext/mysqli tests "using password" optional in error messages in b6b4a628a5
  • ext/mysqli tests "using password" optional in error messages (part 2) in c21a5920ac
  • Fix mysqli test wrt. MariaDB in b77edf82ac

David Carlier

Derick Rethans

Dmitry Stogov

  • Fix memory leak in a8bd342397
  • Fix a memory leak in tracig JIT when the same closure is called through Closure::call() and natively in 45cb3f917a

Erki Aring

  • Fix GH-9298: remove all registered signal handlers in pcntl RSHUTDOWN in 5ecbb1b39d

George Peter Banyard

  • Fix GH-9883 SplFileObject::__toString() reads next line in 6fbf81c674
  • Fix performance degradation introduced in c2547ab7 in 86456574bb
  • Fix GH-10011 (Trampoline autoloader will get reregistered and cannot be unregistered) in 608ddb0321
  • Add a new imap_is_open() function to check that a connection object is still valid in 52a891aeaa

George Wang

  • Use __atomic_xxxx() instead of __sync_xxxx() for lsapi in 4bdfce6c1a

Ilija Tovilo

  • Disable opcache file_cache for observer preloading test in 09f071e63b
  • Add wordpress to community build in cdc0a8b06b

Jakub Zelenka

Mattias Ellert

  • Fix compilation on RHEL 7 ppc64le (gcc 4.8) in a83923044c

Michael Voříšek

NathanFreeman

Petr Sumbera

  • php-fpm: fix Solaris port events.mechanism in 72da2b02e2

Pierrick Charron

Sara Golemon

Stanislav Malyshev

Tyson Andre

  • Fix Windows shmget() wrt. IPC_PRIVATE in 7a983e281c

蝦米

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.