1
0
mirror of https://github.com/php/php-src.git synced 2026-04-06 15:43:13 +02:00
Commit Graph

132843 Commits

Author SHA1 Message Date
Jakub Zelenka
2fe3332653 Update versions for PHP 8.3.0beta2 php-8.3.0beta2 2023-08-01 12:05:21 +01:00
Ilija Tovilo
dc368d3983 Merge branch 'PHP-8.2'
* PHP-8.2:
  Fix zend/test arginfo stub hash
2023-08-01 11:42:04 +02:00
Ilija Tovilo
e14421cd73 Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Fix zend/test arginfo stub hash
2023-08-01 11:41:46 +02:00
Ilija Tovilo
e61dbe54e9 Fix zend/test arginfo stub hash 2023-08-01 11:41:13 +02:00
Ben Ramsey
3d5f239474 Merge branch 'PHP-8.2' 2023-07-31 20:15:51 -05:00
Ben Ramsey
7ecb284926 Merge branch 'PHP-8.1' into PHP-8.2 2023-07-31 20:06:37 -05:00
Ben Ramsey
ebbccb3dc6 Merge branch 'PHP-8.0' into PHP-8.1 2023-07-31 20:01:03 -05:00
Niels Dossche
d8f2584ebb NEWS
Signed-off-by: Ben Ramsey <ramsey@php.net>
2023-07-31 19:56:12 -05:00
Niels Dossche
62228a2568 Disable global state test on Windows
It looks like the config.w32 uses CHECK_HEADER_ADD_INCLUDE to add the include
path to libxml into the search path.
That doesn't happen in zend-test.
To add to the Windows trouble, libxml is statically linked in, ext/libxml can
only be built statically but ext/zend-test can be built both statically and
dynamically.
So the regression tests won't work in all possible configurations anyway on Windows.
All of this is no problem on Linux because it just uses dynamic linking
and pkg-config, without any magic.

Signed-off-by: Ben Ramsey <ramsey@php.net>
2023-07-31 19:55:10 -05:00
Kamil Tekiela
548fc6a818 As of 8.2 this SKIP is no longer possible 2023-08-01 00:53:47 +01:00
Kamil Tekiela
73d6869337 Remove unnecessary parentheses around language constructs in mysqli 2023-08-01 00:40:55 +01:00
Kamil Tekiela
a21edc52aa Remove unnecessary parentheses around language constructs in mysqli 2023-07-31 23:46:45 +01:00
Kamil Tekiela
c1a085290a Convert CRLF to LF 2023-07-31 23:26:49 +01:00
Kamil Tekiela
a53e56176c Remove unnecessary parentheses around language constructs in oci8 2023-07-31 22:52:43 +01:00
Derick Rethans
193f879057 Merge branch 'PHP-8.2' 2023-07-31 20:24:25 +01:00
Derick Rethans
855dd2767a Fixed another broken merge (sorry) 2023-07-31 20:24:20 +01:00
Derick Rethans
01746d0617 Merge branch 'PHP-8.2' 2023-07-31 20:14:52 +01:00
Derick Rethans
dcc429557d Fixed artifacts from merging 2023-07-31 20:08:45 +01:00
Derick Rethans
797bd9f384 Merge branch 'PHP-8.2' 2023-07-31 20:05:28 +01:00
Derick Rethans
47a347e8b0 Merge branch 'PHP-8.1' into PHP-8.2 2023-07-31 20:05:20 +01:00
Derick Rethans
93b43ac238 Fix broken merge 2023-07-31 20:05:12 +01:00
Derick Rethans
86afbe10e2 Merge branch 'PHP-8.2' 2023-07-31 19:57:02 +01:00
Derick Rethans
deddf4692a Merge branch 'PHP-8.1' into PHP-8.2 2023-07-31 19:54:44 +01:00
Derick Rethans
0870ebb862 Merge branch 'PHP-8.0' into PHP-8.1 2023-07-31 19:53:43 +01:00
Niels Dossche
c283c3ab0b Sanitize libxml2 globals before parsing
Fixes GHSA-3qrf-m4j2-pcrr.

To parse a document with libxml2, you first need to create a parsing context.
The parsing context contains parsing options (e.g. XML_NOENT to substitute
entities) that the application (in this case PHP) can set.
Unfortunately, libxml2 also supports providing default set options.
For example, if you call xmlSubstituteEntitiesDefault(1) then the XML_NOENT
option will be added to the parsing options every time you create a parsing
context **even if the application never requested XML_NOENT**.

Third party extensions can override these globals, in particular the
substitute entity global. This causes entity substitution to be
unexpectedly active.

Fix it by setting the parsing options to a sane known value.
For API calls that depend on global state we introduce
PHP_LIBXML_SANITIZE_GLOBALS() and PHP_LIBXML_RESTORE_GLOBALS().
For other APIs that work directly with a context we introduce
php_libxml_sanitize_parse_ctxt_options().
2023-07-31 19:47:19 +01:00
Niels Dossche
80316123f3 Fix buffer mismanagement in phar_dir_read()
Fixes GHSA-jqcx-ccgc-xwhv.
2023-07-31 19:47:05 +01:00
Ilija Tovilo
e8edd35c49 Merge branch 'PHP-8.2'
* PHP-8.2:
  Check if restart is pending before trying to lock SHM
2023-07-31 20:01:23 +02:00
Ilija Tovilo
f2328302b6 Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Check if restart is pending before trying to lock SHM
2023-07-31 20:00:49 +02:00
Mikhail Galanin
3e9792f4a2 Check if restart is pending before trying to lock SHM
This reduces lock contention when Opcache restart is scheduled
but not yet started.

Closes GH-11805
2023-07-31 20:00:31 +02:00
Juliette
68e6de5408 GH Actions: auto-skip CI on PRs containing only docs changes (#11839)
As per https://github.com/php/php-src/pull/11838#issuecomment-1658648817

Co-authored-by: jrfnl <jrfnl@users.noreply.github.com>
2023-07-31 18:47:31 +02:00
jrfnl
78bfe682a5 [ci skip] PHP 8.3 Upgrading:
add missing PGSQL functions/constants

Follow up on 10868, which introduced these functions and constants.

add missing PGSQL visibility constants

Follow up on 10935, which introduced these constants.

Close GH-11838
2023-07-31 17:08:25 +01:00
jrfnl
a8fa0b54d8 [ci skip] PHP 8.3 Upgrading: fix pg_set_error_context_visibility typo
Ref: 21aaf3321f

Close GH-11837
2023-07-31 17:07:20 +01:00
jrfnl
c7cbe3764a [ci skip] PHP 8.3 Upgrading: add missing POSIX constants
Follow up on 10238 which added these constants.

Close GH-11835
2023-07-31 17:07:04 +01:00
Peter Kokot
37d35f5ed8 Move --enable/--disable-fiber-asm help output (#11827)
This moves the fiber configure option in the Zend section. TSRM doesn't
currently have any specific configure options so it can be removed from
the ./configure --help output.
2023-07-31 15:29:14 +01:00
Michael Orlitzky
605c60cd5f Skip oci8 tests when no database is available (#11820)
Most oci8 tests fail out-of-the-box because a typical host won't have
an Oracle database instance available. Other database drivers like
mysqli and pgsql address this problem with an include file, inserted
into SKIPIF, that skips the test if no connection at all can be made.

This commits adds such a file (skipifconnectfailure.inc) for oci8, and
adds the corresponding SKIPIF to any tests that connect to a database.

Closes GH-11804

* ext/oci8/tests/lob_aliases.phpt: drop unnecessary SKIPIF.
2023-07-31 15:19:31 +01:00
Ilija Tovilo
82aa4253f1 Fix some uouv in ext/pgsql 2023-07-31 15:18:13 +02:00
Ilija Tovilo
322da7bcc3 Fix various uouv in intl 2023-07-31 15:18:13 +02:00
Ilija Tovilo
a145b40fa6 Fix uouv in password_needs_rehash() and password_hash() 2023-07-31 15:18:13 +02:00
Ilija Tovilo
2053af6628 Fix uouv in array_column
column_long and index_long might not be set, but are still used as arguments.
They are not actually used if column_str is set, but it's better to initialize
them anyway, if only to make MemorySanitizer happy.
2023-07-31 15:18:13 +02:00
Dmitry Stogov
79a8cf1b96 Merge branch 'PHP-8.2'
* PHP-8.2:
  Fixed incorrect QM_ASSIGN elimination
2023-07-31 14:51:14 +03:00
Dmitry Stogov
91dc3e15e9 Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Fixed incorrect QM_ASSIGN elimination
2023-07-31 14:51:06 +03:00
Dmitry Stogov
b5f8a7270a Fixed incorrect QM_ASSIGN elimination
Fixes OSS Fuzz #60895
2023-07-31 14:50:13 +03:00
Ilija Tovilo
7364b7bc0b Fix uaf of MBSTRG(all_encodings_list)
We need to remove the value from the GC buffer before freeing it. Otherwise
shutdown will uaf when running the gc. Do that by switching from
zend_hash_destroy to zend_array_destroy, which should also be faster for freeing
members due to inlining of i_zval_ptr_dtor.

Closes GH-11822
2023-07-31 13:31:50 +02:00
Niels Dossche
655f116be5 XLEAK XML_SAVE_NO_DECL test for old libxml2 versions 2023-07-29 17:42:31 +02:00
Niels Dossche
ae66a0d142 Corrections to return type of loading DOM documents 2023-07-29 14:58:01 +02:00
George Peter Banyard
b389846d05 ext/mysqli: Remove catchable fatal error handler
Recoverable fatal error haven't been a thing for a while, and proper fatal error have never been catchable
2023-07-29 06:17:20 +01:00
George Peter Banyard
8582d97b8c ext/mysqli: Stop using global variable in connection test helper 2023-07-29 06:17:20 +01:00
George Peter Banyard
0c21715935 ext/mysqli: Remove conditional function declaration 2023-07-29 06:17:20 +01:00
George Peter Banyard
17a80eb08b ext/mysqli: Remove custom sys_get_temp_dir() function
It has existed since PHP 5.2.1...
2023-07-29 06:17:19 +01:00
tekimen
092726fb1e Fix GH-11785: '++nothing+crc' is not a recognized feature for M1 / M2 macOS compile target (#11796)
#pragma GCC target("+nothing+crc") is means clear outs aarch64_isa_flags.

However, #pragma clang attribute push(__attribute__((target("+nothing+crc") is not means any, then displays ignore feature. (Not reproduce Linux on ARM (ex: Raspberry Pi))

Therefore, Add new #pragma when compiling on M1/M2 macOS.
2023-07-29 06:00:47 +01:00