Added
- Added Oracle 9 images to Zend container registry
- Added RHEL 8 and 9 images to Zend container registry
Changed
- PHP 8.0 packages and container images are now LTS, and only available via a ZendPHP subscription.
- CentOS 7 images now include the EPEL repository, due to dependency changes for ZendHQ 1.5.0.
New Release: PHP 8.3
Please see our blog post on features, changes, and deprecations in PHP 8.3 for more detail.
-
Bcmath
- Fixed GH-11761: removing trailing zeros from numbers
-
CLI
- Added
pdeathsig
to builtin server to terminate workers when the master process is killed. - Fixed bug GH-11104: STDIN/STDOUT/STDERR is not available for CLI without a script.
- Implement GH-10024: support linting multiple files at once using
php -l
.
- Added
-
Core:
- Fix GH-11388: Allow
final
modifier when importing a method from a trait. - Fixed bug GH-11406: segfault with unpacking and magic method closure.
- Fixed bug GH-9388: Improve unset property and
__get
type incompatibility error message. -
SA_ONSTACK
is now set for signal handlers to be friendlier to other in-process code such as Go's cgo. -
SA_ONSTACK
is now set when signals are disabled. - Fix GH-9649: Signal handlers now do a no-op instead of crashing when executed on threads not managed by TSRM.
- Added shadow stack support for fibers.
- Fix bug GH-9965: Fix accidental caching of default arguments with side effects.
- Implement GH-10217: Use
strlen()
for determining theclass_name
length. - Fix bug GH-8821: Improve line numbers for errors in constant expressions.
- Fix bug GH-10083: Allow comments between & and parameter.
- Zend Max Execution Timers is now enabled by default for ZTS builds on Linux.
- Fix bug GH-10469: Disallow
..
inopen_basedir
paths set at runtime. - Fix bug GH-10168, GH-10582: Various segfaults with destructors and VM return values.
- Fix bug GH-10935: Use of trait doesn't redeclare static property if class has inherited it from its parent.
- Fix bug GH-11154: Negative indices on empty array don't affect next chosen index.
- Fix bug GH-8846: Implement delayed early binding for classes without parents.
- Fix bug #79836: Segfault in
concat_function
. - Fix bug #81705: type confusion/UAF on
set_error_handler
withconcat
operation. - Fix GH-11348: Closure created from magic method does not accept named arguments.
- Fix GH-11388: Allow
final
modifier when importing a method from a trait. - Fixed bug GH-11406: segfault with unpacking and magic method closure.
- Fixed bug GH-11507: String concatenation performance regression in 8.3.
- Fixed GH-11488: Missing "Optional parameter before required" deprecation on union null type.
- Implement the
#[\Override]
attribute RFC. - Fixed bug GH-11601: Incorrect handling of unwind and graceful exit exceptions.
- Added
zend_call_stack_get
implementation for OpenBSD. - Add stack limit check in
zend_eval_const_expr()
. - Expose time spent collecting cycles in
gc_status()
. - Remove
WeakMap
entries whose key is only reachable through the entry value. - Resolve
open_basedir
paths on INI update. - Fixed oss-fuzz #60741: Leak in
open_basedir
. - Fixed segfault during freeing of some incompletely initialized objects due to OOM error (PDO, SPL, XSL).
- Introduced Zend guard recursion protection to fix
__debugInfo
issue. - Fixed oss-fuzz #61712: assertion failure with error handler during binary op.
- Fixed GH-11847: DTrace enabled build is broken.
- Fixed OSS Fuzz #61865: Undef variable in
++
/--
for declared property that is unset in error handler. - Fixed warning emitted when checking if a user stream is castable.
- Fixed bug GH-12123: Compile error on MacOS with C++ extension when using
ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX
. - Fixed bug GH-12189:
#[Override]
attribute in trait does not check for parent class implementations. - Fixed OSS Fuzz #62294: Unsetting variable after
++
/--
on string variable warning. - Fixed buffer underflow when compiling memoized expression.
- Fixed oss-fuzz #63802: OP1 leak in error path of post inc/dec.
- Fix GH-11388: Allow
-
Curl
- Added Curl options and constants up to (including) version 7.87.
-
Date
- Implement "More Appropriate Date/Time Exceptions" RFC.
-
DOM
- Fix bug GH-8388:
DOMAttr
unescapes character reference. - Fix bug GH-11308:
getElementsByTagName()
isO(N^2)
. - Fix #79700: wrong use of libxml oldNs leads to performance problem.
- Fix #77894:
DOMNode::C14N()
very slow on generatedDOMDocument
s even after normalisation. - Revert changes to
DOMAttr::$value
andDOMAttr::$nodeValue
expansion. - Fixed bug GH-11500: Namespace reuse in
createElementNS()
generates wrong output. - Implemented
DOMDocument::adoptNode()
. Previously this always threw a "not yet implemented" exception. - Fixed bug GH-9628: Implicitly removing nodes from
\DOMDocument
breaks existing references. - Added
DOMNode::contains()
andDOMNameSpaceNode::contains()
. - Added
DOMElement::getAttributeNames()
. - Added
DOMNode::getRootNode()
. - Added
DOMElement::className
andDOMElement::id
. - Added
DOMParentNode::replaceChildren()
. - Added
DOMNode::isConnected
andDOMNameSpaceNode::isConnected
. - Added
DOMNode::parentElement
andDOMNameSpaceNode::parentElement
. - Added
DOMNode::isEqualNode()
. - Added
DOMElement::insertAdjacentElement()
andDOMElement::insertAdjacentText()
. - Added
DOMElement::toggleAttribute()
. - Fixed bug GH-11792:
LIBXML_NOXMLDECL
is not implemented or broken. -
adoptNode
now respects the strict error checking property. - Align
DOMChildNode
parent checks with spec. - Fixed bug #80927: Removing
documentElement
after creating attribute node: possible use-after-free. - Fix various namespace prefix conflict resolution bugs.
- Fix calling
createAttributeNS()
without prefix causing the default namespace of the element to change. - Fixed GH-11952: Confusing warning when blocking entity loading via
libxml_set_external_entity_loader
. - Fix broken cache invalidation with deallocated and reallocated document node.
- Fix compile error when
php_libxml.h
header is included in C++. - Fixed bug #47531: No way of removing redundant
xmlns:
declarations.
- Fix bug GH-8388:
-
Exif
- Removed unneeded codepaths in
exif_process_TIFF_in_JPEG()
.
- Removed unneeded codepaths in
-
FFI
- Implement GH-11934: Allow to pass
CData
into struct and/or union fields.
- Implement GH-11934: Allow to pass
-
Fileinfo
- Upgrade bundled libmagic to 5.43.
- Fix GH-11408: Unable to build PHP 8.3.0 alpha 1 / fileinfo extension.
-
FPM
- The status.listen shared pool now uses the same
php_values
(includingexpose_php
) andphp_admin_value
as the pool it is shared with. - Added warning to log when fpm socket was not registered on the expected path.
- Fixed bug #76067:
system()
function call leaks php-fpm listening sockets. - Fixed GH-12077: PHP 8.3.0RC1 borked
socket-close-on-exec.phpt
.
- The status.listen shared pool now uses the same
-
GD
- Removed
imagerotate
"ignore_transparent" argument since it has no effect.
- Removed
-
Intl
- Added pattern format error infos for
numfmt_set_pattern
. - Added
MIXED_NUMBERS
andHIDDEN_OVERLAY
constants for theSpoofchecker
's class. - Updated
datefmt_set_timezone
/IntlDateformatter::setTimezone
returns type. - Updated
IntlBreakInterator::setText
return type. - Updated
IntlChar::enumCharNames
return type. - Removed the BC break on
IntlDateFormatter::construct
which threw an exception with an invalid locale.
- Added pattern format error infos for
-
JSON
- Added
json_validate()
.
- Added
-
LDAP
- Deprecate calling
ldap_connect()
with separate hostname and port.
- Deprecate calling
-
LibXML
- Fix compile error with
-Werror=incompatible-function-pointer-types
and old libxml2.
- Fix compile error with
-
MBString
-
mb_detect_encoding
is better able to identify the correct encoding for Turkish text. -
mb_detect_encoding
's "non-strict" mode now behaves as described in the documentation. Previously, it would returnfalse
if the same byte (for example, the first byte) of the input string was invalid in all candidate encodings. More generally, it would eliminate candidate encodings from consideration when an invalid byte was seen, and if the same input byte eliminated all remaining encodings still under consideration, it would return false. On the other hand, if all candidate encodings but one were eliminated from consideration, it would return the last remaining one without regard for how many encoding errors might be encountered later in the string. This is different from the behavior described in the documentation, which says: "If strict is set to false, the closest matching encoding will be returned." -
mb_strtolower
,mb_strtotitle
, andmb_convert_case
implement conditional casing rules for the Greek letter sigma. Formb_convert_case
, conditional casing only applies toMB_CASE_LOWER
andMB_CASE_TITLE
modes, not toMB_CASE_LOWER_SIMPLE
andMB_CASE_TITLE_SIMPLE
. -
mb_detect_encoding
is better able to identify UTF-8 and UTF-16 strings with a byte-order mark. -
mb_decode_mimeheader
interprets underscores in QPrint-encoded MIME encoded words as required by RFC 2047; they are converted to spaces. Underscores must be encoded as "=5F" in such MIME encoded words. -
mb_encode_mimeheader
no longer dropsNUL
(zero) bytes when QPrint-encoding the input string. This previously caused strings in certain text encodings, especially UTF-16 and UTF-32, to be corrupted bymb_encode_mimeheader
. - Implement
mb_str_pad()
RFC. - Fixed bug GH-11514: PHP 8.3 build fails with
--enable-mbstring
enabled. - Fix use-after-free of
mb_list_encodings()
return value. - Fixed bug GH-11992:
utf_encodings.phpt
fails on Windows 32-bit.
-
-
mysqli
-
mysqli_fetch_object
raises aValueError
instead of anException
.
-
-
Opcache
- Added start, restart and force restart time to opcache's phpinfo section.
- Fix GH-9139: Allow FFI in
opcache.preload
whenopcache.preload_user=root
. - Made
opcache.preload_user
always optional in the cli and phpdbg SAPIs. - Allows W/X bits on page creation on FreeBSD despite system settings.
- Added memfd api usage, on Linux, for
zend_shared_alloc_create_lock()
to create an abstract anonymous file for the opcache's lock. - Avoid resetting JIT counter handlers from multiple processes/threads.
- Fixed
COPY_TMP
type inference for references.
-
OpenSSL
- Added
OPENSSL_CMS_OLDMIMETYPE
andPKCS7_NOOLDMIMETYPE
constants to switch between mime content types. - Fixed GH-11054: Reset OpenSSL errors when using a PEM public key.
- Added support for additional EC parameters in
openssl_pkey_new
.
- Added
-
PCNTL
-
SA_ONSTACK
is now set forpcntl_signal
. - Added
SIGINFO
constant.
-
-
PCRE
- Update bundled libpcre2 to 10.42.
-
PGSQL
-
pg_fetch_object
raises aValueError
instead of anException
. -
pg_cancel
use thread safe PQcancel api instead. -
pg_trace
newPGSQL_TRACE_SUPPRESS_TIMESTAMPS
/PGSQL_TRACE_REGRESS_MODE
contants support. -
pg_set_error_verbosity
addingPGSQL_ERRORS_STATE
constant. -
pg_convert
/pg_insert
E_WARNING
on type errors had been converted toValueError
/TypeError
exceptions. - Added
pg_set_error_context_visibility
to set the context's visibility within the error messages.
-
-
Phar
- Fix memory leak in
phar_rename_archive()
.
- Fix memory leak in
-
POSIX
- Added
posix_sysconf
. - Added
posix_pathconf
. - Added
posix_fpathconf
. - Fixed
zend_parse_arg_long
's bool pointer argument assignment. - Added
posix_eaccess
.
- Added
-
Random
- Added
Randomizer::getBytesFromString()
. - Added
Randomizer::nextFloat()
,::getFloat()
, andIntervalBoundary
. - Enable
getrandom()
for NetBSD (from 10.x). - Deprecate
MT_RAND_PHP
. - Fix
Randomizer::getFloat()
returning incorrect results under certain circumstances.
- Added
-
Reflection
- Fix GH-9470:
ReflectionMethod
constructor should not find private parent method. - Fix GH-10259
ReflectionClass::getStaticProperties
doesn't need null return type.
- Fix GH-9470:
-
SAPI
- Fixed GH-11141: Could not open input file: should be sent to
stderr
.
- Fixed GH-11141: Could not open input file: should be sent to
-
Session
- Fixed bug GH-11529: Crash after dealing with an Apache request.
-
SimpleXML
- Fixed bug GH-12192: SimpleXML infinite loop when
getName()
is called withinforeach
. - Fixed bug GH-12208: SimpleXML infinite loop when a cast is used inside a
foreach
. - Fixed bug #55098: SimpleXML iteration produces infinite loop.
- Fixed bug GH-12192: SimpleXML infinite loop when
-
Sockets
- Added
SO_ATTACH_REUSEPORT_CBPF
socket option, to give tighter control over socket binding for a cpu core. - Added
SKF_AD_QUEUE
for cbpf filters. - Added
socket_atmark
ifsend
/recv
needs usingMSG_OOB
. - Added
TCP_QUICKACK
constant, to give tighter control overACK
delays. - Added
DONTFRAGMENT
support for path MTU discovery purpose. - Added
AF_DIVERT
for raw socket for divert ports. - Added
SOL_UPDLITE
,UDPLITE_RECV_CSCOV
andUDPLITE_SEND_CSCOV
for updlite protocol support. - Added
SO_RERROR
,SO_ZEROIZE
andSO_SPLICE
netbsd and openbsd constants. - Added
TCP_REPAIR
for quietly close a connection. - Added
SO_REUSEPORT_LB
freebsd constant. - Added
IP_BIND_ADDRESS_NO_PORT
.
- Added
-
SPL
- Fixed GH-11573:
RecursiveDirectoryIterator::hasChildren
is slow.
- Fixed GH-11573:
-
Standard
-
E_NOTICE
s emitted byunserialize()
have been promoted toE_WARNING
. -
unserialize()
now emits a newE_WARNING
if the input contains unconsumed bytes. - Make
array_pad
's$length
warning less confusing. -
E_WARNING
emitted bystrtok
in the case both arguments are not provided when starting tokenisation. -
password_hash()
will now chain the originalRandomException
to theValueError
on salt generation failure. - Fix GH-10239:
proc_close
afterproc_get_status
always returns-1
. - Improve the warning message for
unpack()
in case not enough values were provided. - Fix GH-11010:
parse_ini_string()
now preserves formatting of unquoted strings starting with numbers when theINI_SCANNER_TYPED
flag is specified. - Fix GH-10742:
http_response_code
emits no error when headers were already sent. - Added support for rounding negative places in
number_format()
. - Prevent precision loss on formatting decimal integers in
number_format()
. - Added usage of
posix_spawn
forproc_open
when supported by OS. - Added
$before_needle
argument tostrrchr()
. - Fixed GH-11982:
str_getcsv
returns null byte for unterminated enclosure. - Fixed
str_decrement()
on "1".
-
-
Streams
- Fixed bug #51056: blocking
fread()
will block even if data is available. - Added storing of the original path used to open xport stream.
- Implement GH-8641:
STREAM_NOTIFY_COMPLETED
over HTTP never emitted. - Fix bug GH-10406:
fgets
on a redis socket connection fails on PHP 8.3. - Implemented GH-11242:
_php_stream_copy_to_mem
: Allow specifying a maximum length without allocating a buffer of that size. - Fixed bug #52335:
fseek()
on memory stream behavior different than file. - Fixed bug #76857: Can read "non-existant" files.
- Fixed bug #51056: blocking
-
XSLTProcessor
- Fixed bug #69168:
DomNode::getNodePath()
returns invalid path.
- Fixed bug #69168:
-
ZIP
- zip extension version 1.22.0 for libzip 1.10.0.
- add new error macros (
ER_DATA_LENGTH
andER_NOT_ALLOWED
). - add new archive global flags (
ER_AFL_*
). - add
ZipArchive::setArchiveFlag
andZipArchive::getArchiveFlag
methods.
Community Fixes in PHP 8.2.13
-
Core
- Fixed double-free of non-interned enum case name.
- Fixed bug GH-12457: Incorrect result of
stripos
with single character needle. - Fixed bug GH-12468: Double-free of
doc_comment
when overriding static property via trait. - Fixed segfault caused by weak references to FFI objects.
- Fixed max_execution_time: don't delete an unitialized timer.
- Fixed bug GH-12558: Arginfo soft-breaks with namespaced class return type if the class name starts with N.
-
DOM
- Fix
registerNodeClass
with abstract class crashing. - Add missing NULL pointer error check.
- Fix validation logic of
php:function()
callbacks.
- Fix
-
Fiber
- Fixed bug GH-11121:
ReflectionFiber
segfault.
- Fixed bug GH-11121:
-
FPM
- Fixed bug GH-9921: Loading ext in FPM config does not register module handlers.
- Fixed bug GH-12232: FPM: segfault dynamically loading extension without opcache.
- Fixed bug #76922: FastCGI terminates conn after
FCGI_GET_VALUES
.
-
Intl
- Removed the BC break on
IntlDateFormatter::construct
which threw an exception with an invalid locale.
- Removed the BC break on
-
Opcache
- Added warning when JIT cannot be enabled.
- Fixed bug GH-8143: Crashes in
zend_accel_inheritance_cache_find
since upgrading to 8.1.3 due to corrupt on-disk file cache.
-
OpenSSL
- Fixed bug GH-12489: Missing
sigbio
creation checking inopenssl_cms_verify
.
- Fixed bug GH-12489: Missing
-
PCRE
- Fixed bug GH-11374: Backport upstream fix, Different
preg_match
result with-d pcre.jit=0
.
- Fixed bug GH-11374: Backport upstream fix, Different
-
SOAP
- Fixed bug GH-12392: Segmentation fault on
SoapClient::__getTypes
. - Fixed bug #66150: SOAP WSDL cache race condition causes Segmentation Fault.
- Fixed bug #67617: SOAP leaves incomplete cache file on
ENOSPC
. - Fix incorrect uri check in SOAP caching.
- Fix segfault and assertion failure with refcounted props and arrays.
- Fix potential crash with an edge case of persistent encoders.
- Fixed bug #75306: Memleak in
SoapClient
.
- Fixed bug GH-12392: Segmentation fault on
-
Streams
- Fixed bug #75708:
getimagesize
with&$imageinfo
fails onStreamWrapper
s.
- Fixed bug #75708:
-
XMLReader
- Add missing NULL pointer error check.
-
XMLWriter
- Add missing NULL pointer error check.
-
XSL
- Add missing module dependency.
- Fix validation logic of
php:function()
callbacks.
Community Fixes in PHP 8.1.26
-
Core
- Fixed bug GH-12468: Double-free of
doc_comment
when overriding static property via trait. - Fixed segfault caused by weak references to FFI objects.
- Fixed max_execution_time: don't delete an unitialized timer.
- Fixed bug GH-12468: Double-free of
-
DOM
- Fix
registerNodeClass
with abstract class crashing. - Add missing NULL pointer error check.
- Fix validation logic of
php:function()
callbacks.
- Fix
-
Fiber
- Fixed bug GH-11121:
ReflectionFiber
segfault.
- Fixed bug GH-11121:
-
FPM
- Fixed bug GH-9921: Loading ext in FPM config does not register module handlers.
- Fixed bug GH-12232: FPM: segfault dynamically loading extension without opcache.
-
Intl
- Removed the BC break on
IntlDateFormatter::construct
which threw an exception with an invalid locale.
- Removed the BC break on
-
Opcache
- Added warning when JIT cannot be enabled.
- Fixed bug GH-8143: Crashes in
zend_accel_inheritance_cache_find
since upgrading to 8.1.3 due to corrupt on-disk file cache.
-
OpenSSL
- Fixed bug GH-12489: Missing
sigbio
creation checking inopenssl_cms_verify
.
- Fixed bug GH-12489: Missing
-
PCRE
- Fixed bug GH-11374: Backport upstream fix, Different
preg_match
result with-d pcre.jit=0
.
- Fixed bug GH-11374: Backport upstream fix, Different
-
SOAP
- Fixed bug GH-12392: Segmentation fault on
SoapClient::__getTypes
. - Fixed bug #66150: SOAP WSDL cache race condition causes Segmentation Fault.
- Fixed bug #67617: SOAP leaves incomplete cache file on
ENOSPC
. - Fix incorrect uri check in SOAP caching.
- Fix segfault and assertion failure with refcounted props and arrays.
- Fix potential crash with an edge case of persistent encoders.
- Fixed bug #75306: Memleak in
SoapClient
.
- Fixed bug GH-12392: Segmentation fault on
-
Streams
- Fixed bug #75708:
getimagesize
with&$imageinfo
fails onStreamWrapper
s.
- Fixed bug #75708:
-
XMLReader
- Add missing NULL pointer error check.
-
XMLWriter
- Add missing NULL pointer error check.
-
XSL
- Add missing module dependency.
- Fix validation logic of
php:function()
callbacks.