]> granicus.if.org Git - php/log
php
4 years agoFix potential use-after-scope if crypt_r is used
Nikita Popov [Wed, 24 Jun 2020 11:06:01 +0000 (13:06 +0200)]
Fix potential use-after-scope if crypt_r is used

4 years agoRemove deprecated DES fallback in crypt()
Nikita Popov [Wed, 24 Jun 2020 10:55:37 +0000 (12:55 +0200)]
Remove deprecated DES fallback in crypt()

4 years agoEnforce min/max rounds in sha256/sha512 crypt
Nikita Popov [Wed, 24 Jun 2020 10:41:56 +0000 (12:41 +0200)]
Enforce min/max rounds in sha256/sha512 crypt

This brings our implementation in line with glibc behavior.

4 years agoMerge branch 'PHP-7.4'
Nikita Popov [Wed, 24 Jun 2020 10:22:44 +0000 (12:22 +0200)]
Merge branch 'PHP-7.4'

* PHP-7.4:
  Handle *0 / *1 more consistently

4 years agoHandle *0 / *1 more consistently
Nikita Popov [Wed, 24 Jun 2020 10:20:05 +0000 (12:20 +0200)]
Handle *0 / *1 more consistently

Avoid throwing a DES salt deprecation warning if the libc crypt
implementation is used.

4 years agoFix crypt_r detection
Nikita Popov [Wed, 24 Jun 2020 10:08:31 +0000 (12:08 +0200)]
Fix crypt_r detection

And force use of our own php_crypt_r implementation to keep
previous behavior despite that.

4 years agoProperly initialize displaysize
Christoph M. Becker [Wed, 24 Jun 2020 10:03:13 +0000 (12:03 +0200)]
Properly initialize displaysize

From Microsoft's `SQLColAttribute()` documentation[1]:

| Please note that some drivers may only write the lower 32-bit or
| 16-bit of a buffer and leave the higher-order bit unchanged.
| Therefore, applications should initialize the value to 0 before
| calling this function.

[1] <https://docs.microsoft.com/en-us/sql/odbc/reference/syntax/sqlcolattribute-function>

4 years agoAdd ZEND_ACC_NO_DYNAMIC_PROPERTIES flag to SysvMessageQueue
Máté Kocsis [Wed, 24 Jun 2020 10:04:10 +0000 (12:04 +0200)]
Add ZEND_ACC_NO_DYNAMIC_PROPERTIES flag to SysvMessageQueue

4 years agoAdd flag to forbid dynamic property creation on internal classes
Nikita Popov [Thu, 14 May 2020 09:51:36 +0000 (11:51 +0200)]
Add flag to forbid dynamic property creation on internal classes

While performing resource -> object migrations, we're adding
defensive classes that are final, non-serializable and non-clonable
(unless they are, of course). This path adds a ZEND_ACC_NO_DYNAMIC_PROPERTIES
flag, that also forbids the creation of dynamic properties on these objects.
This is a subset of #3931 and targeted at internal usage only
(though may be extended to userland at some point in the future).

It's already possible to achieve this (what the removed
WeakRef/WeakMap code does), but there's some caveats: First, this
simple approach is only possible if the class has no declared
properties, otherwise it's necessary to special-case those
properties. Second, it's easy to make it overly strict, e.g. by
forbidding isset($obj->prop) as well. And finally, it requires a
lot of boilerplate code for each class.

Closes GH-5572.

4 years agoMerge branch 'PHP-7.4'
Christoph M. Becker [Wed, 24 Jun 2020 09:44:47 +0000 (11:44 +0200)]
Merge branch 'PHP-7.4'

* PHP-7.4:
  Fix potential environment variable deadlock

4 years agoFix potential environment variable deadlock
Christoph M. Becker [Wed, 24 Jun 2020 09:43:04 +0000 (11:43 +0200)]
Fix potential environment variable deadlock

We have to unlock the environment before bailing out.

4 years agoMerge branch 'PHP-7.4'
Christoph M. Becker [Wed, 24 Jun 2020 09:19:17 +0000 (11:19 +0200)]
Merge branch 'PHP-7.4'

* PHP-7.4:
  Fix #69804: ::getStaticPropertyValue() throws on protected props

4 years agoFix #69804: ::getStaticPropertyValue() throws on protected props
Christoph M. Becker [Wed, 15 Apr 2020 13:15:21 +0000 (15:15 +0200)]
Fix #69804: ::getStaticPropertyValue() throws on protected props

`ReflectionClass` allows reading of the values of private and protected
constants, and also to get private and protected static methods.
Therefore getting the values of private and protected static properties
is also permissible, especially since `::getStaticProperties()` already
allows to do so.

We also allow ::setStaticPropertyValue() to modify private and
protected properties, because otherwise this method is useless, as
modifying public properties can be done directly.

4 years agoAdd test case for previous commit
Nikita Popov [Wed, 24 Jun 2020 08:51:51 +0000 (10:51 +0200)]
Add test case for previous commit

Forgot to "git add".

4 years agoFix verify arg jit for references
Nikita Popov [Wed, 24 Jun 2020 08:47:14 +0000 (10:47 +0200)]
Fix verify arg jit for references

4 years agoMark phpdbg test as XFAIL on Windows with JIT enabled
Christoph M. Becker [Wed, 24 Jun 2020 08:33:22 +0000 (10:33 +0200)]
Mark phpdbg test as XFAIL on Windows with JIT enabled

The test fails as of commit 8b12ea04ee405f746ca2394672f8372c57fd05b2.

4 years agoSkip two curl tests under asan
Nikita Popov [Wed, 24 Jun 2020 08:12:37 +0000 (10:12 +0200)]
Skip two curl tests under asan

These tests leak with the curl version on ubuntu 20.04. This should
be fixed when we switch exit to use an exception.

4 years agoMerge branch 'PHP-7.4'
Christoph M. Becker [Wed, 24 Jun 2020 08:07:24 +0000 (10:07 +0200)]
Merge branch 'PHP-7.4'

* PHP-7.4:
  Fix #79487: ::getStaticProperties() ignores property modifications

4 years agoFix #79487: ::getStaticProperties() ignores property modifications
Christoph M. Becker [Wed, 24 Jun 2020 08:03:46 +0000 (10:03 +0200)]
Fix #79487: ::getStaticProperties() ignores property modifications

When retrieving the static class properties via reflection, we have to
cater to possible modifications.

4 years agoInclude stub hash in generated arginfo files
Nikita Popov [Fri, 19 Jun 2020 09:40:31 +0000 (11:40 +0200)]
Include stub hash in generated arginfo files

The hash is used to check whether the arginfo file needs to be
regenerated. PHP-Parser will only be downloaded if this is actually
necessary.

This ensures that release artifacts will never try to regenerate
stubs and thus fetch PHP-Parser, as long as you do not modify any
files.

Closes GH-5739.

4 years agoIncrease failure threshold for 'extensive backtracking' fileinfo test
Alex Dowad [Wed, 24 Jun 2020 06:43:49 +0000 (08:43 +0200)]
Increase failure threshold for 'extensive backtracking' fileinfo test

A spurious failure for this test was seen on Travis CI (S390X):

https://travis-ci.org/github/alexdowad/php-src/jobs/701533828

(The test is expected to finish within 1 second, but it took 1.06 seconds.)
Therefore, increase the threshold a bit.

4 years agoRemove outdated PHPDoc from ext/enchant's stub
Máté Kocsis [Tue, 23 Jun 2020 19:06:36 +0000 (21:06 +0200)]
Remove outdated PHPDoc from ext/enchant's stub

4 years agoImproved JIT for RECV and RECV_INIT instructions
Dmitry Stogov [Tue, 23 Jun 2020 20:21:56 +0000 (23:21 +0300)]
Improved JIT for RECV and RECV_INIT instructions

4 years agoUse standard bool type in EXIF extension
George Peter Banyard [Tue, 23 Jun 2020 18:57:26 +0000 (20:57 +0200)]
Use standard bool type in EXIF extension

4 years agoMerge branch 'PHP-7.4'
Christoph M. Becker [Tue, 23 Jun 2020 17:30:12 +0000 (19:30 +0200)]
Merge branch 'PHP-7.4'

* PHP-7.4:
  Revert "Fix #79487: ::getStaticProperties() ignores property modifications"

4 years agoRevert "Fix #79487: ::getStaticProperties() ignores property modifications"
Christoph M. Becker [Tue, 23 Jun 2020 17:28:51 +0000 (19:28 +0200)]
Revert "Fix #79487: ::getStaticProperties() ignores property modifications"

This reverts commit a895bb6885fbceea3e8375816969d5510d8d082e.

4 years agoMerge branch 'PHP-7.4'
Christoph M. Becker [Tue, 23 Jun 2020 16:52:16 +0000 (18:52 +0200)]
Merge branch 'PHP-7.4'

* PHP-7.4:
  Fix #79487: ::getStaticProperties() ignores property modifications

4 years agoFix #79487: ::getStaticProperties() ignores property modifications
Christoph M. Becker [Tue, 23 Jun 2020 16:34:07 +0000 (18:34 +0200)]
Fix #79487: ::getStaticProperties() ignores property modifications

When retrieving the static class properties via reflection, we have to
cater to possible modifications.

4 years agoDeprecate the procedural API of ext/zip
Máté Kocsis [Sat, 20 Jun 2020 07:50:09 +0000 (09:50 +0200)]
Deprecate the procedural API of ext/zip

Closes GH-5746

4 years agoReplace exceptional code by side exit to VM
Dmitry Stogov [Tue, 23 Jun 2020 15:31:42 +0000 (18:31 +0300)]
Replace exceptional code by side exit to VM

4 years agoCleanup and better register usage
Dmitry Stogov [Tue, 23 Jun 2020 14:51:02 +0000 (17:51 +0300)]
Cleanup and better register usage

4 years agoReduce amount of "cold" code generated for FETCH_OBJ_* instructions
Dmitry Stogov [Tue, 23 Jun 2020 14:16:44 +0000 (17:16 +0300)]
Reduce amount of "cold" code generated for FETCH_OBJ_* instructions

4 years agoSimplify `_crypt_extended_init_r`, and fix redundant initialization on Win32/Solaris
Alex Dowad [Wed, 27 May 2020 04:01:22 +0000 (06:01 +0200)]
Simplify `_crypt_extended_init_r`, and fix redundant initialization on Win32/Solaris

Looking at the history of this function, the original implementation had a bug where
it would return from the middle of the function without unlocking the mutex first.
The author attempted to fix this by incrementing the `initialized` flag atomically,
which is not necessary, since the section which modifies the flag is protected by a
mutex.

Coincidentally, at the same time that all this unnecessary 'atomic' machinery was
introduced, the code was also changed so that it didn't return without unlocking the
mutex. So it looks like the bug was fixed by accident.

It's not necessary to declare the flag as `volatile` either, since it is protected
by a mutex.

Further, the 'fixed' implementation was also wrong in another respect: on Windows
and Solaris, the `initialized` flag was not even declared as `static`!! So the
initialization of the static tables for S-boxes, P-boxes, etc. was repeated on
each call to `php_crypt`, completely defeating the purpose of this function.

4 years agoMerge branch 'PHP-7.4'
Christoph M. Becker [Tue, 23 Jun 2020 14:02:19 +0000 (16:02 +0200)]
Merge branch 'PHP-7.4'

* PHP-7.4:
  Fix #55857: ftp_size on large files

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Christoph M. Becker [Tue, 23 Jun 2020 13:58:49 +0000 (15:58 +0200)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fix #55857: ftp_size on large files

4 years agoFix #55857: ftp_size on large files
Christoph M. Becker [Tue, 23 Jun 2020 13:17:31 +0000 (15:17 +0200)]
Fix #55857: ftp_size on large files

`atol()` returns a `long` which is not the same as `zend_long` on
LLP64; we use `ZEND_ATOL()` instead.

There is no need for a new test case, since filesize_large.phpt already
tests for that behavior; unfortunately, the FTP test suite relies on
`pcntl_fork()` and therefore cannot be run on Windows.

4 years agoFix a couple of UNKNOWN default values in ext/session
Máté Kocsis [Mon, 22 Jun 2020 20:38:01 +0000 (22:38 +0200)]
Fix a couple of UNKNOWN default values in ext/session

Closes GH-5752

4 years agoRemove unnecessary initialization in phpdbg webhelper
Nikita Popov [Tue, 23 Jun 2020 12:28:07 +0000 (14:28 +0200)]
Remove unnecessary initialization in phpdbg webhelper

This whole code is very dubious and should possibly be dropped. For
now just fix the build warning.

4 years agoEnable dba on azure
Nikita Popov [Tue, 23 Jun 2020 10:43:23 +0000 (12:43 +0200)]
Enable dba on azure

Closes GH-5756.

4 years agoFix UNKNOWN default values in ext/readline
Máté Kocsis [Tue, 23 Jun 2020 07:22:22 +0000 (09:22 +0200)]
Fix UNKNOWN default values in ext/readline

Closes GH-5755

4 years agoImprove JIT for SEPARATE_ARRAY
Dmitry Stogov [Tue, 23 Jun 2020 10:46:56 +0000 (13:46 +0300)]
Improve JIT for SEPARATE_ARRAY

4 years agoFix missing initializers in dba inifile
Nikita Popov [Tue, 23 Jun 2020 10:41:10 +0000 (12:41 +0200)]
Fix missing initializers in dba inifile

4 years agoMerge branch 'PHP-7.4'
Nikita Popov [Tue, 23 Jun 2020 10:36:04 +0000 (12:36 +0200)]
Merge branch 'PHP-7.4'

* PHP-7.4:
  Restore XFAIL on fpm test

4 years agoAvoid convert_to_long_ex usage in readline
Nikita Popov [Tue, 23 Jun 2020 10:35:51 +0000 (12:35 +0200)]
Avoid convert_to_long_ex usage in readline

4 years agoRestore XFAIL on fpm test
Nikita Popov [Tue, 23 Jun 2020 10:35:11 +0000 (12:35 +0200)]
Restore XFAIL on fpm test

Still fails intermittently.

4 years agoUpdate azure pipelins to ubuntu 20.04
Nikita Popov [Fri, 19 Jun 2020 13:42:17 +0000 (15:42 +0200)]
Update azure pipelins to ubuntu 20.04

Only updating the main job for now, to see how it goes.

Closes GH-5741.

4 years agoImprove spill code
Dmitry Stogov [Tue, 23 Jun 2020 09:27:14 +0000 (12:27 +0300)]
Improve spill code

4 years agoAvoid register spilling
Dmitry Stogov [Tue, 23 Jun 2020 08:40:36 +0000 (11:40 +0300)]
Avoid register spilling

4 years agoMerge branch 'PHP-7.4'
Christoph M. Becker [Tue, 23 Jun 2020 08:34:44 +0000 (10:34 +0200)]
Merge branch 'PHP-7.4'

* PHP-7.4:
  7.3 is now 7.3.21-dev

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Christoph M. Becker [Tue, 23 Jun 2020 08:32:25 +0000 (10:32 +0200)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  7.3 is now 7.3.21-dev

4 years ago7.3 is now 7.3.21-dev
Christoph M. Becker [Tue, 23 Jun 2020 08:29:42 +0000 (10:29 +0200)]
7.3 is now 7.3.21-dev

4 years agoMerge branch 'PHP-7.4'
Derick Rethans [Tue, 23 Jun 2020 07:46:54 +0000 (08:46 +0100)]
Merge branch 'PHP-7.4'

4 years agoPHP-7.4 is now 7.4.9-dev
Derick Rethans [Tue, 23 Jun 2020 07:46:37 +0000 (08:46 +0100)]
PHP-7.4 is now 7.4.9-dev

4 years agoFix test wrt. commit 1a2732f9a8b3d62471b360f772b5458f78046f80
Christoph M. Becker [Mon, 22 Jun 2020 16:54:16 +0000 (18:54 +0200)]
Fix test wrt. commit 1a2732f9a8b3d62471b360f772b5458f78046f80

4 years agoConsistent file naming.
Derick Rethans [Mon, 22 Jun 2020 14:32:52 +0000 (15:32 +0100)]
Consistent file naming.

4 years agoUse ZPP callable check for preg_replace_callback() $callback argument
George Peter Banyard [Mon, 22 Jun 2020 13:46:23 +0000 (15:46 +0200)]
Use ZPP callable check for preg_replace_callback() $callback argument

4 years agoAlso allow casting CurlMultiHandles
Nikita Popov [Mon, 22 Jun 2020 13:09:22 +0000 (15:09 +0200)]
Also allow casting CurlMultiHandles

4 years agoFixed JIT failures on Windows
Dmitry Stogov [Mon, 22 Jun 2020 11:57:04 +0000 (14:57 +0300)]
Fixed JIT failures on Windows

4 years agoCorrect implementation of joaat hash.
Eddie Kohler [Sun, 21 Jun 2020 23:54:39 +0000 (19:54 -0400)]
Correct implementation of joaat hash.

Before this commit, the result produced by a joaat hash depended
on how the input data was chunked. A hash produced by multiple
`hash_update` operations was incorrect. For example, this code,
which should produce three identical lines:

    var_dump(hash("joaat", "abcd"));

    $hash = hash_init("joaat");
    hash_update($hash, "ab");
    hash_update($hash, "cd");
    var_dump(hash_final($hash));

    $hash = hash_init("joaat");
    hash_update($hash, "abc");
    hash_update($hash, "d");
    var_dump(hash_final($hash));

instead produced:

    string(8) "cd8b6206"
    string(8) "e590d137"
    string(8) "2d59d087"

This is because the finalization step, involving shift operations
and adds, was applied on every chunk, rather than once at the end
as is required by the hash definition.

After this commit, the code above produces:

    string(8) "cd8b6206"
    string(8) "cd8b6206"
    string(8) "cd8b6206"

as expected.

Some tests encoded the wrong behavior and were corrected.

Closes GH-5749

4 years agomake bcpowmod stricter by not returning false, instead throw exception
Vladyslav Startsev [Sat, 20 Jun 2020 15:26:51 +0000 (18:26 +0300)]
make bcpowmod stricter by not returning false, instead throw exception

Closes GH-5747

4 years agoHaiku opcache jit build update
David Carlier [Sat, 20 Jun 2020 16:45:01 +0000 (16:45 +0000)]
Haiku opcache jit build update

4 years agoMerge branch 'PHP-7.4'
Anatol Belski [Sun, 21 Jun 2020 20:55:00 +0000 (22:55 +0200)]
Merge branch 'PHP-7.4'

* PHP-7.4:
  SplHeap: Avoid memcpy on overlapping pointer

4 years agoSplHeap: Avoid memcpy on overlapping pointer
Anatol Belski [Sun, 21 Jun 2020 20:16:56 +0000 (22:16 +0200)]
SplHeap: Avoid memcpy on overlapping pointer

Check if data would overlap and also add an assert. Previous
implementations didn't have this issue, as the direct assignment was
used.

Signed-off-by: Anatol Belski <ab@php.net>
4 years agosapi/fpm/config.m4: add a new --with-fpm-apparmor configure flag.
Michael Orlitzky [Wed, 27 Dec 2017 01:08:37 +0000 (20:08 -0500)]
sapi/fpm/config.m4: add a new --with-fpm-apparmor configure flag.

The existing AC_FPM_APPARMOR macro (which is always run when FPM is
enabled) checks for the existence of libapparmor, and adds it to $LIBS
if found. The result is an "automagic" dependency on libapparmor that
depends not only on the user's configuration, but also on the build
host's environment.

In particular, this can cause problems if the user just happens to
have libapparmor installed (for testing or development) when he builds
PHP. Later, he may remove libapparmor, not realizing that PHP depends
on it. At that point, FPM will cease to work due to the missing library.

This commit adds a new configure flag called "--with-fpm-apparmor",
defaulting to "no", that enables or disables the feature. The new flag
is used to signal the user's intent; whether or not he wants to use
AppArmor. If he does, then we still check for the existence and
usability of libapparmor; however, it is now an error for the library
to be missing when --with-fpm-apparmor is requested.

Gentoo-bug: https://bugs.gentoo.org/637402
PHP-bug: https://bugs.php.net/bug.php?id=75519

4 years agoMark failing tests as XFAIL for now
Christoph M. Becker [Sat, 20 Jun 2020 09:06:38 +0000 (11:06 +0200)]
Mark failing tests as XFAIL for now

These test fail on Window since some recent changes to JIT; we mark
them as XFAIL until the issues are resolved.

4 years agoAllow casting CurlHandle to int
Nikita Popov [Fri, 19 Jun 2020 14:50:59 +0000 (16:50 +0200)]
Allow casting CurlHandle to int

(int) $curlHandle will return spl_object_id($curlHandle). This
makes curl handle objects backwards compatible with code using
(int) $curlHandle to obtain a resource ID.

Closes GH-5743.

4 years agoClean up some unused code (and fix some comments) in build scripts
Alex Dowad [Tue, 26 May 2020 17:56:52 +0000 (19:56 +0200)]
Clean up some unused code (and fix some comments) in build scripts

- Fix typo in build/php.m4

- Nothing uses HAVE_INTTYPES_H; so remove check for header file

- Nothing defines ZEND_ACCONFIG_H_NO_C_PROTOS; so remove #ifndef

- `format_money` was removed in 2019, so <monetary.h> no longer needed

- Nothing uses HAVE_NETDB_H; so remove check for header file

- Nothing checks HAVE_TERMIOS_H; so remove check for header file

    (This was actually added when Wez Furlong was adding the original implementation of
    PTY support in `proc_open`, since replaced.)

- Nothing checks HAVE_SYS_AUXV_H; so remove check for header file

- PHP_BUILD_DATE variable is not used for anything, so remove it

    This variable was added to the Makefile, but from there, was not used for anything.
    The comments suggest it was intended to allow 'reproducible builds'. Presumably,
    this means that if a bug is found in a PHP binary somewhere, one could look at the
    Makefile which it was built from, see the date, and then could check the same
    code version out from source control. But... there can easily be multiple commits
    to the repo in the same day. Also, what makes us think that the Makefile which a
    binary was built from will be easily available?

    Besides, ext/standard/info.c already embeds the build date and time in each binary...
    but it does it using `__DATE__` and `__TIME__` (see `php_print_info`).

- Nothing checks HAVE_FINITE; so don't check for function

- Grammar fix to comment in build/php.m4

- Nothing sets $php_ldflags_add_usr_lib variable in configure, so remove conditional

    This was added in 2002, when Rasmus was having difficulty building PHP on some
    host and needed to have /usr/lib in the rpath. It was never documented and
    probably has never been used by anyone else.

4 years agoMerge branch 'PHP-7.4'
Nikita Popov [Fri, 19 Jun 2020 15:32:34 +0000 (17:32 +0200)]
Merge branch 'PHP-7.4'

* PHP-7.4:
  Fixed bug #79570

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Nikita Popov [Fri, 19 Jun 2020 15:32:00 +0000 (17:32 +0200)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fixed bug #79570

4 years agoFixed bug #79570
Böszörményi Zoltán [Fri, 19 Jun 2020 12:31:28 +0000 (14:31 +0200)]
Fixed bug #79570

Use the same logic for getgrgid_r, getpwnam_r and getpwuid_r
as for getgrnam_r in #75696

Closes GH-5740.

4 years agoFix Haiku build
David Carlier [Wed, 17 Jun 2020 21:16:29 +0000 (21:16 +0000)]
Fix Haiku build

getrusage supports only two fields. The network api sits in the network lib.

Closes GH-5732.

4 years agoReturn void from php_jpeg_emit_message()
Nikita Popov [Fri, 19 Jun 2020 14:07:14 +0000 (16:07 +0200)]
Return void from php_jpeg_emit_message()

Instead of returning long and then casting to void.

This fixes a build warning on Ubuntu 20.04.

Closes GH-5742.

4 years agoJIT for FETCH_OBJ_W
Dmitry Stogov [Fri, 19 Jun 2020 11:36:38 +0000 (14:36 +0300)]
JIT for FETCH_OBJ_W

4 years agoMerge branch 'PHP-7.4'
Nikita Popov [Fri, 19 Jun 2020 08:48:34 +0000 (10:48 +0200)]
Merge branch 'PHP-7.4'

* PHP-7.4:
  Fixed bug #79710

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Nikita Popov [Fri, 19 Jun 2020 08:47:01 +0000 (10:47 +0200)]
Merge branch 'PHP-7.3' into PHP-7.4

4 years agoFixed bug #79710
Nikita Popov [Fri, 19 Jun 2020 08:46:02 +0000 (10:46 +0200)]
Fixed bug #79710

Make sure we don't use zresource after the stream has been destroyed.

4 years agoRemoving HTML Functionality from run-tests.php
Paul Dragoonis [Thu, 18 Jun 2020 09:40:40 +0000 (10:40 +0100)]
Removing HTML Functionality from run-tests.php

As discussed on GH-5632, the HTML functionality does not appear
to be in active use. For HTML rendering of test results, it is
suggested to instead use the JUnit integration, in combination
with your favorite JUnit viewer.

Closes GH-5705.

4 years agoMerge branch 'PHP-7.4'
Nikita Popov [Fri, 19 Jun 2020 07:44:56 +0000 (09:44 +0200)]
Merge branch 'PHP-7.4'

4 years agoGenerate temporary config file when generating certificates
Nikita Popov [Fri, 19 Jun 2020 07:43:56 +0000 (09:43 +0200)]
Generate temporary config file when generating certificates

The putenv trick doesn't work on ZTS Windows, so generate a new
openssl config every time.

4 years agoForbid use of <?= as a semi-reserved identifier
Nikita Popov [Fri, 19 Jun 2020 07:27:19 +0000 (09:27 +0200)]
Forbid use of <?= as a semi-reserved identifier

One of the weirdest pieces of PHP code I've ever seen. In terms
of tokens, this gets internally translated to

    use x as y; echo as my_echo;

On master it crashes because this "echo" does not have attached
identifier metadata. Make sure it is added and then reject the
use of "<?=" as an identifier inside zend_lex_tstring.

Fixes oss-fuzz #23547.

4 years agoMAY_BE_INDIRECT inference
Dmitry Stogov [Thu, 18 Jun 2020 15:54:32 +0000 (18:54 +0300)]
MAY_BE_INDIRECT inference

4 years agoFix CLI test if linked against libedit
Nikita Popov [Thu, 18 Jun 2020 15:30:03 +0000 (17:30 +0200)]
Fix CLI test if linked against libedit

The error message changed here.

4 years agoMerge branch 'PHP-7.4'
Nikita Popov [Thu, 18 Jun 2020 15:14:03 +0000 (17:14 +0200)]
Merge branch 'PHP-7.4'

4 years agocheck for broken libzip versions
Remi Collet [Thu, 18 Jun 2020 14:45:39 +0000 (16:45 +0200)]
check for broken libzip versions

Closes GH-5738.

4 years agoUpdate libzip on macos
Nikita Popov [Thu, 18 Jun 2020 14:25:16 +0000 (16:25 +0200)]
Update libzip on macos

We need libzip 1.7.1, because libzip 1.7.0 is broken.

Closes GH-5737.

4 years agoCall zpp in enchant_broker_*_dict_path with libenchant-2
Nikita Popov [Thu, 18 Jun 2020 15:10:22 +0000 (17:10 +0200)]
Call zpp in enchant_broker_*_dict_path with libenchant-2

Even if the function is a dummy, we still need to call zpp to
comply with arginfo.

4 years agoUse ZEND_TOSTRING_FUNC_NAME
moliata [Thu, 18 Jun 2020 12:24:27 +0000 (15:24 +0300)]
Use ZEND_TOSTRING_FUNC_NAME

Closes GH-5736.

4 years agoMerge branch 'PHP-7.4'
Nikita Popov [Thu, 18 Jun 2020 15:02:24 +0000 (17:02 +0200)]
Merge branch 'PHP-7.4'

4 years agoFix race condition in FPM tests
Nikita Popov [Thu, 18 Jun 2020 15:01:29 +0000 (17:01 +0200)]
Fix race condition in FPM tests

The newly de-XFAILed tests have a race condition. Make sure we
terminate only after expecting all the log lines.

4 years agoAdd reference to phpweb/bin/createReleaseEntry
Sara Golemon [Thu, 18 Jun 2020 14:03:44 +0000 (14:03 +0000)]
Add reference to phpweb/bin/createReleaseEntry

4 years agoMerge branch 'PHP-7.4'
Nikita Popov [Thu, 18 Jun 2020 14:00:30 +0000 (16:00 +0200)]
Merge branch 'PHP-7.4'

4 years agoUn-XFAIL FPM tests
Nikita Popov [Thu, 18 Jun 2020 13:59:32 +0000 (15:59 +0200)]
Un-XFAIL FPM tests

These were XFAILed due to a bug in the log implementation that
caused intermittent failures. However, this issue is supposed to
be resolved in the meantime, so try dropping the XFAIL marker.

4 years agoMerge branch 'PHP-7.4'
Nikita Popov [Thu, 18 Jun 2020 13:55:23 +0000 (15:55 +0200)]
Merge branch 'PHP-7.4'

4 years agoDowngrade server security level in security level test
Nikita Popov [Thu, 18 Jun 2020 13:54:02 +0000 (15:54 +0200)]
Downgrade server security level in security level test

We want to test the client side error here, so make sure the
server side can start up successfully.

4 years agoMerge branch 'PHP-7.4'
Nikita Popov [Thu, 18 Jun 2020 13:49:43 +0000 (15:49 +0200)]
Merge branch 'PHP-7.4'

4 years agoAdd SubjectAltName support to certificate generator
Nikita Popov [Thu, 18 Jun 2020 13:34:33 +0000 (15:34 +0200)]
Add SubjectAltName support to certificate generator

And switch tests using SAN certificates to the generator.

This is ugly, but there doesn't seem to be a more direct way
to privide SAN in PHP.

4 years agoMerge branch 'PHP-7.4'
Christoph M. Becker [Thu, 18 Jun 2020 13:29:50 +0000 (15:29 +0200)]
Merge branch 'PHP-7.4'

* PHP-7.4:
  Add missing NEWS entry

4 years agoAdd missing NEWS entry
Christoph M. Becker [Thu, 18 Jun 2020 13:28:19 +0000 (15:28 +0200)]
Add missing NEWS entry

I forgot to update NEWS after merging back then.

4 years agoDowngrade security level in tests using TLS < 1.2
Nikita Popov [Thu, 18 Jun 2020 13:08:24 +0000 (15:08 +0200)]
Downgrade security level in tests using TLS < 1.2

A few additional tests have been added on master that require
lower security level.

4 years agoMerge branch 'PHP-7.4'
Nikita Popov [Thu, 18 Jun 2020 13:02:02 +0000 (15:02 +0200)]
Merge branch 'PHP-7.4'