Release Information
- Release Type
- Security Update
- Release Status
- QA Release Latest
- Branch Status
- Upcoming Release
PHP 8.6 is a development version, and is not recommended for production use. This is the latest QA release in the series.
Downloads
Source Code
Git Clone
Use Git to clone the 8.6.0alpha3 tag from the PHP Git repository.
git clone https://github.com/php/php-src.git --depth 1 --branch php-8.6.0alpha3How to compile PHP
PHP can be compiled by setting up the dependencies, building the configure script (
Detailed articles on how to compile PHP are available for Ubuntu/Debian based systems and Fedora/RHEL based systems.
./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.
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.6.0alpha3-cli-alpineDebian-based: More compatible with other components, complete, and are widely used.
docker pull php:8.6.0alpha3-cliPHP 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.6.0alpha3-fpm-alpineDebian-based ZTS Apache: Includes Apache web server integrating PHP as an Apache module.
docker pull php:8.6.0alpha3-apacheDebian-based NTS FPM: PHP-FPM, can be integrated with Nginx, Caddy, and other web servers over Fast CGI.
docker pull php:8.6.0alpha3-fpmChangeLog
Core
- Implemented partial function application RFC.
- Fixed bug GH-22263 (reset typed property default on every unserialize failure path).
- Fixed bug GH-18985 (Wrong line numbers for match with constant arms).
- Fixed bug GH-18847 (SEGV in
zend_fetch_debug_backtrace()when the memory limit is reached while the tracing JIT enters a call frame).
DOM
- Fixed bug GH-22825 (
DOMElement::setAttribute()fails silently when the DTD declares a default value for the attribute).
Embed
- Made php-cli functionality available in embed builds.
GMP
- Added
gmp_prevprime(). - Fixed GMP power and shift operators to reject GMP right operands outside the unsigned long range instead of silently truncating them.
- Fixed GMP integer string parsing to reject strings containing NUL bytes instead of silently truncating them.
- Fixed GMP error messages that referenced outdated parameter names.
Intl
- Fixed grammatical issues in Normalizer invalid form and IntlCalendar time zone offset error messages.
- Removed the dependency on the ICU IO library.
ODBC
- Fixed bug GH-22668 (Heap buffer over-read when a column value exceeds the driver-reported display size).
Opcache
- Re-enable JIT for ZTS builds on Apple Silicon.
PDO_ODBC
- Fixed bug GH-22667 (Heap buffer over-read when a column value exceeds the driver-reported display size).
- Fixed bug GH-22666 (Heap buffer overflow when an output parameter value is longer than the declared maxlen).
- Fixed bug GH-22665 (Out-of-bounds write when the ODBC driver reports a diagnostic message length beyond the error buffer).
Phar
- Fixed grammatical issues and outdated terminology in Phar error messages.
Reflection
- Fixed bug GH-22681 (Reflection*::__toString() truncates on null bytes).
SOAP
- Fixed header injection through the Content-Type context option, the soapaction and the cookie names and values.
- Fixed the SoapClient and SoapServer "classmap" option to reject arrays containing integer keys, and made SoapClient throw TypeError/ValueError for invalid "classmap" options.
MBString
- Fixed bug GH-22779 (
mb_strrpos()returns the wrong position for a negative offset in a non-UTF-8 encoding).
Sockets
- Fixed
socket_set_option()validation error messages for UDP_SEGMENT and TCP_USER_TIMEOUT, andSO_LINGERoptions. - Fixed various memory related issues in
ext/sockets.
Standard
- Fixed
setlocale()to reject locale names containing NUL bytes instead of silently truncating them, and to reject arrays passed after the$localesargument or additional arguments passed after an array$localesargument.
Streams
- Added a new IO copy API used by
php_stream_copy_to_stream_ex()that leverages platform primitives (sendfile, splice, copy_file_range, TransmitFile) for faster stream copying. - Fixed bug GH-22841 (
php_stream_copy_to_stream_ex()drops progress notifications when using the copy fast path). - Fixed bug GH-15836 (Use-after-free when a user stream filter accesses $this->stream during the close flush).
Commit List
Arnaud Le Blanc
- CI: Enable JIT testing on Apple Silicon ZTS 8.6+ in fa47ae16a1
zend_API: Add_exvariants ofzend_argument_error*in GH-21829- Partial function application in GH-20848
- run-tests: Clean the file cache directory in
--file-cache-primein GH-22784 zend_jit_resolve_tsrm_ls_cache_offsets: clobber volatile registers in GH-22832- Clear ZREG_TYPE_ONLY flag for in-register vars in
zend_jit_snapshot_handler()in GH-22764 - Fix const expr support in preloading in GH-22783
- [PFA 3/n] Support PFA in const exprs in GH-22785
- Forbid \C in UTF-8 patterns in GH-21139
- [PFA 4/n] Optimize constant pre-bound arguments in GH-22829
Calvin Buckley
- main: Add AIX to
PHP_OS_FAMILYin GH-22834 - Fix GH-22849: error_include_args=1 mishandled for
include()in GH-22851 - Remove docref1/docref2 in GH-22742
- Remove
paramargument fromphp_verrorin GH-22865 - Use
php_pollfd_for_msmore consistently for single fd polling in GH-22872
Cas Ebbers
- Change
pcre.backtrack_limitin the ini templates to the default value in GH-22868
Daniel Scherzer
- Add regression tests for
ReflectionEnum::__toString()with null bytes in 0fca39de81 - GH-22681: avoid truncation on null bytes in
ReflectionEnum::__toString()in 1b2c0abbdb - Update NEWS in e2c975d4fc
- Fix inline documentation of
ReflectionParameter::isPassedByReference()in 2fc1912022 - Reflection: optimize closure checking in 8ddd6e38d2
- Reflection: remove unused indentation support from
_parameter_string()in d0d7951521 ReflectionFunctionAbstract::getDocComment(): usezend_function.commonin 5457092f87- Reflection: improve handling of dynamic properties in
_property_string()in de36957ee8 - Reflection: start cleaning up variable declarations in 767f31a627
- Reflection: clean up variables for hash iteration in 009bedb353
- Reflection: unhoist more variable declarations in 48af536c8e
- Reflection: layout and indentation cleanup in 44608b00ea
- Reflection: use early returns to reduce indentation in 121d19f62a
- Reflection: integer types cleanup in 6455aab46f
- Reflection: mark a whole bunch of pointers as
constin 07b5905d7f - Reflection: replace
struct _zend_arg_infowithzend_arg_infoin b8dc2a804c - Reflection: consistent pointer type declaration spacing in c06e86d9ca
- Reflection: remove unused parameter from
get_ce_from_scope_name()in 79144103ad - Reflection: whitespace cleanup in b043ea3579
ReflectionMethod::getPrototype(): add parentheses to error message in a1cd11ad0d- Reflection: add regression tests for lazy initialization errors in e0693e9c3d
- Reflection: improve error messages for lazy initialization errors in acf7ba883f
ReflectionClass::setStaticPropertyValue(): update missing property error in a5e34c6030
David Carlier
- GH-22617: avoid null byte truncation of persistent stream keys in df773093ef
ext/sockets: memory related issues fix in 754ea6e14eext/opcache:zend_jit_resolve_tsrm_ls_cache_offsets()TEXTREL from bare__tls_get_addrcall in 19af2e43f3- Zend: reset typed property default on every unserialize failure path in ab99a29383
ext/soap: truncate header values containing newline characters in f6fe838e36ext/dom: fix UAF when setting an attribute colliding by local name in 3221a076f2- streams:
php_stream_copy_to_stream_ex()drops progress notifications in 1da60a2a39
David CARLIER
ext/gd: conflicting iconv_t typedef breaking the Solaris build. in GH-22810
Eyüp Can Akman
- Fix GH-22779:
mb_strrpos()wrong result in a non-UTF-8 encoding in 0d6ab5321d
Florian Engelhardt
- Re-enable JIT for ZTS builds on Apple Silicon in a6f85c3bfd
- Rather than erroring, disable JIT when pthread protection is unavailable (GH-22853) in 16da1f51ba
Gina Peter Banyard
- standard/file.c: use normal docref function for E_WARNINGs in
popen()in GH-22746 - exif: change usage of
php_error_docref1()tophp_error_docref()in GH-22747 - streams: use built-in argument handling for warnings instead of 2 param functions in GH-22749
- main: convert win32_docref functions to a new function using new stream error API in GH-22748
- streams: remove
php_stream_wrapper_warn_param()functions in 1f7abed789 - streams: embed
php_stream_wrapper_log_error_internal()in b06eb82fef - streams: remove 'param' parameter of
php_stream_wrapper_log_store_error()in dec19edc4b - enchant: update test after deprecation message changes in GH-22800
- stream: remove
php_stream_fopen_with_path()function in GH-22793 - stream: remove path parameter in stream error functions in GH-22792
- Add UPGRADING.INTERNALS entry after function removal in cfbe114468
- Reorganise UPGRADING.INTERNALS to be more legible in GH-22808
- stream: improve bugfix, check class is instantiable prior to registering in GH-22806
- Voidify
zend_std_unset_static_property()in GH-22809 - stream: registering cannot fail, thus voidify function in GH-22811
- main: convert sys_temp_dir global to
zend_string*in GH-22812 - poll: fetch method ptr directly in GH-22816
- streams: remove parameters that always passed NULL or unused in 85fc5768d6
- streams: remove param field of
php_stream_error_entryin 0cf29ab058 - streams: remove StreamError::$param property in 36d854783b
- standard/filestats.c: use RETURN_BOOL() when possible in GH-22876
- sapi: only use FCC for
header_register_callback()in GH-22877 - streams: drop leading _ for most stream functions in 8aca9f2ad6
- streams: make
php_stream_scandir()a proper function in fae14143b5 - streams: make
php_stream_flush()a proper function in 0980c33acd - Add UPGRADING.INTERNALS notes for stream functions in f77523b538
- streams: mark
php_stream_error_create_array()as static in bd8a3ee16f - streams: use PRIu32 format specifier rather than u in c852fce5a7
- streams: use C enums instead of define for error{store}mode in GH-22901
- streams: use zend string property update function in GH-22903
- sapi: use bool type for post_read global in ec29a6bd76
- sapi: use bool type for headers_sent global in c30acf5b78
- sapi: pack globals struct in 25159e0619
- sapi: use
zend_resulttype for return types when possible in 395d0186c1
Ilia Alshanetsky
- Fix GH-22667: pdo_odbc heap over-read on oversized column value in 103c84ff4c
- Fix GH-22480: phpdbg use-after-free re-watching a watched variable in GH-22493
- Fix GH-22668: odbc heap over-read on oversized column value in 8e4daeff7a
- Fix GH-22666: pdo_odbc heap overflow on oversized output param in a7539ff834
- Fix GH-22665: pdo_odbc OOB write on oversized diagnostic length in 345b88deeb
- Run oversized bz2 resource tests in isolation to avoid OOM in GH-22744
- Fix pdo_odbc output-buffer leak and stale-binding out-of-bounds read in bdcf9ceee3
- Fix use-after-free serializing an array grown by an element's hook in GH-22714
- Fix GH-21691: OPcache CFG optimizer drops QM_ASSIGN feeding JMPZ/JMPZ_EX with IS_VAR in 6441f89857
ext/filter: fix use-after-free inparse_str()with filter.default in 0549c8e054ext/soap: fix NULL deref on malformed HTTP status line in 1c4bf04783ext/sockets: run the AF_PACKET error test in isolation in GH-22773ext/standard: fix out-of-bounds access in the ftp:// directory stream in b750803b76ext/soap: truncate a user_agent containing newline characters in GH-22771- ext/sqlite3: reject NUL bytes in
SQLite3::escapeString()in GH-22774 ext/odbc: do not mutate the caller's DSN string in f9b6254375- Free unbound arguments when partial application construction throws in GH-22788
- Fix double-free of closure run_time_cache in partial application in GH-22790
ext/sockets: bound interface name copy infrom_zval_write_ifindex()in 009a0c276dext/ftp: apply the connect timeout ceiling to the remaining entry points in c1773a1da2ext/standard: reject a dechunk chunk size that overflows size_t in 04f3d282f8- Check partial-application bound arguments in the creating scope in GH-22789
- Fix crash when a partial skips a param with a constant default in GH-22804
- Fix GH-22825: DOM attribute methods on a DTD default attribute in 145e8c26d4
ext/filter: encode 0xFF inFILTER_SANITIZE_ENCODEDin 56149186d8- Regenerate the expired ext/ftp/tests/cert.pem in GH-22873
- Guard var_dump()/
debug_zval_dump()against native stack overflow in 889ae478bd - Fix phpdbg over-read when watching a packed array element in GH-22756
- Don't expose a freed stream resource to user filters in 3db0487860
- Fix OOB read in opcache POSIX largepage page-size selection in 68d605fa92
- Fix GH-18847: save EX(opline) before extending the VM stack on all VMs in GH-22542
Ilija Tovilo
- Fix leak on double
DatePeriod::__construct()call in 2d86f8cf48 - Adjust XtOffsetOf() to
offsetof()for master in 070f8b2186 - Tweak lineno compilation in 07d308a0de
- Fix
run-tests.php--file-cache-primewith multiple workers (GH-22886) in 387a3afc6b - Fix use-of-uninitialized-value ast->lineno in 7ad79be655
- libgd patch for CVE-2026-9672 in fcd691b377
- Fix SQL injection in ext-pgsql via E'...' backslash breakout in ab048bd83b
- Add NEWS entries in f93c48725d
- Fix string freeing in
phar_follow_one_link()in 56b8d1040d
Jakub Zelenka
- IO copy API for stream copying in GH-20399
- Add
$salt_lengthparam to openssl_sign and openssl_verify in GH-20681 - Add OpenSSL TLS 1.3 early data (0-RTT) support in GH-22802
- Fix GHSA-vc5h-9ppw-p5f3: phar circular symlink crash in 2e0fa0a444
Khaled Alam
- Add trait support for internal classes (GH-20976) in 63e26ab716
Marc
- Make php-cli functionality available in embed build in GH-21385
Matteo Beccati
- Update versions for PHP 8.6.0alpha3 in 85c26f2346
Máté Kocsis
ext/uri: Add @strict-properties to the newly introduced UriBuilder class in e3de8edbae
NickSdot
- docs/source/miscellaneous/writing-tests.rst: remove misplaced "is" in GH-22904
Nicolas Grekas
- Skip
__get()when__isset()materialised the property (GH-22181) in 06411654ff
Nora Dossche
- Fix unchecked
sqlite3_column_text()calls in GH-22715
Pierre Joye
- Sync gd 2 4 in GH-22532
Recep A.
- Fix out-of-bounds write in ext-bcmath
bccomp()viabc_str2num()in 4f83876af7
Remi Collet
Shivam Mathur
ext/gd: remove libde265 and x265 checks on Windows in GH-22869
Sjoerd Langkemper
- Size is always one in curl functions in GH-22733
- Remove compat hack for
curl_httppostin GH-22821 - Fix leak when cURL PREREQFUNCTION returns a type other than int in GH-22726
ext/curl: fix mem leak when duphandle fails incurl_clone_objin GH-22899
Tim Düsterhus
- Fix categorization in UPGRADING.INTERNALS in 55c4eb2a1b
zend_string: Addzend_string_ends_with*()in GH-22819
Weilin Du
- CI: fix unstable test \ext\sockets\tests`socket_recvfrom_afpacket_no_port.phpt` in GH-22724
ext/gmp: Fix GMP operator RHS overflow for GMP values in GH-22656ext/exif: Fix EXIF warning format specifiers for size_t values in GH-22750ext/sockets: Fixsocket_set_option()validation error messages in GH-22772ext/sockets: FixTCP_USER_TIMEOUTrange error message in 583403a9a0ext/opcache: fix "untill" to "until" in various comments in 5b79dc5514ext/gmp: Fix GMP accepting integer strings with NUL bytes in GH-22798ext/intl: Fix various error messages in GH-22828- Fix GH-22759: Keep Io\Poll watcher registry in sync in GH-22760
ext/gmp: Fix GMP error messages using outdated parameter names in GH-22846ext/phar: Improve various error messages in GH-22858- Refactor various raw C-string concatenation to use existing API in GH-22879
ext/intl: Remove icu-io as a dependency in GH-22891- CI: Fix writing-tests.rst format to pass doc rstfmt CI in 8334703dd9
ext/standard: Fixsetlocale()NUL byte truncation in GH-22843ext/gmp: Addgmp_prevprime()in GH-22807