]> granicus.if.org Git - php/log
php
4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Christoph M. Becker [Mon, 3 Feb 2020 11:29:28 +0000 (12:29 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fix #79212: NumberFormatter::format() may detect wrong type

4 years agoFix #79212: NumberFormatter::format() may detect wrong type
Christoph M. Becker [Sun, 2 Feb 2020 12:38:34 +0000 (13:38 +0100)]
Fix #79212: NumberFormatter::format() may detect wrong type

We have to convert to number *before* detecting the type, to cater to
internal objects implementing `cast_object`.

We also get rid of the fallback behavior of using `FORMAT_TYPE_INT32`,
because that can no longer happen; after `convert_scalar_to_number_ex`
the type is either `IS_LONG` or `IS_DOUBLE`.  We cater explicitly to
the `IS_ARRAY` case what also avoids triggering a type confusion when
`::TYPE_INT64` is passed as `$type`.

4 years agoadd test
Remi Collet [Mon, 3 Feb 2020 09:21:46 +0000 (10:21 +0100)]
add test

4 years agoNEWS
Remi Collet [Mon, 3 Feb 2020 09:09:12 +0000 (10:09 +0100)]
NEWS

4 years agoFixed bug #73119 Wrong return for ZipArchive::addEmptyDir Method
Remi Collet [Mon, 3 Feb 2020 09:06:44 +0000 (10:06 +0100)]
Fixed bug #73119 Wrong return for ZipArchive::addEmptyDir Method

4 years agoAdd WHITESPACE_SENSITIVE run-tests section
Nikita Popov [Fri, 10 Jan 2020 15:54:12 +0000 (16:54 +0100)]
Add WHITESPACE_SENSITIVE run-tests section

This is used to indicate that the test should not be changed by
automated formatting changes.

4 years agoDisable parallelism for FPM tests
Nikita Popov [Mon, 3 Feb 2020 08:57:34 +0000 (09:57 +0100)]
Disable parallelism for FPM tests

Let's see if this helps with spurious failures on Azure.

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Nikita Popov [Fri, 31 Jan 2020 09:29:26 +0000 (10:29 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fix bug #76047

4 years agoFix bug #76047
Nikita Popov [Fri, 31 Jan 2020 09:21:37 +0000 (10:21 +0100)]
Fix bug #76047

Unlink the current stack frame before freeing CVs or extra args.
This means it will no longer show up in back traces that are
generated during CV destruction.

We already did this prior to destructing the object/closure,
presumably for the same reason.

4 years agoFixed bug #79094 (Crashing when running recursion function)
Dmitry Stogov [Fri, 31 Jan 2020 07:34:04 +0000 (10:34 +0300)]
Fixed bug #79094 (Crashing when running recursion function)

4 years agofix cross compilation failure due to size_t typecast in define
Pascal de Bruijn [Thu, 30 Jan 2020 12:48:44 +0000 (13:48 +0100)]
fix cross compilation failure due to size_t typecast in define

The following commit introduces a cross-compilation failure:

   93c728b77cfb47f5cfdd1863f8982ea59d344205
  "Try to control ZEND_MM_ALIGNED_SIZE type"

br-arm-full/build/php-7.4.2/Zend/zend_alloc.h:30:38:
error: missing binary operator before token "8"
                                              ^
br-arm-full/build/php-7.4.2/ext/opcache/ZendAccelerator.c:1380:7:
note: in expansion of macro ‘ZEND_MM_ALIGNMENT’

Closes GH-5128.

4 years agoFixed bug #79193
Nikita Popov [Thu, 30 Jan 2020 13:55:58 +0000 (14:55 +0100)]
Fixed bug #79193

4 years agoFix live range calculation for FE_FETCH
Nikita Popov [Thu, 30 Jan 2020 13:23:46 +0000 (14:23 +0100)]
Fix live range calculation for FE_FETCH

Op2 is def here, not a use, so treat it accordingly.

4 years agoFix DatePeriod property handling with indirect modification
Nikita Popov [Thu, 30 Jan 2020 12:09:15 +0000 (13:09 +0100)]
Fix DatePeriod property handling with indirect modification

We do need to implement get_property_ptr_ptr to make arrays work
correctly.

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Christoph M. Becker [Thu, 30 Jan 2020 12:05:49 +0000 (13:05 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fix #70078: XSL callbacks with nodes as parameter leak memory

4 years agoFix #70078: XSL callbacks with nodes as parameter leak memory
Christoph M. Becker [Wed, 29 Jan 2020 17:23:51 +0000 (18:23 +0100)]
Fix #70078: XSL callbacks with nodes as parameter leak memory

The fix for bug #49634 solved a double-free by copying the node with
`xmlDocCopyNodeList()`, but the copied node is later freed by calling
`xmlFreeNode()` instead of `xmlFreeNodeList()`, thus leaking memory.
However, there is no need to treat the node as node list, i.e. to copy
also the node's siblings; just creating a recursive copy of the node
with `xmlDocCopyNode()` is sufficient, while that also avoids the leak.

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Nikita Popov [Thu, 30 Jan 2020 11:17:10 +0000 (12:17 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fix leak in DateTimeImmutable::modify()

4 years agoFix leak in DateTimeImmutable::modify()
Nikita Popov [Thu, 30 Jan 2020 11:16:43 +0000 (12:16 +0100)]
Fix leak in DateTimeImmutable::modify()

4 years agoFix copying of functions in variance obligations
Nikita Popov [Thu, 30 Jan 2020 10:55:38 +0000 (11:55 +0100)]
Fix copying of functions in variance obligations

Only copy sizeof(zend_internal_function) for internal functions.

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Nikita Popov [Thu, 30 Jan 2020 10:21:26 +0000 (11:21 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Add SKIPIF to test requiring mbregex

4 years agoAdd SKIPIF to test requiring mbregex
Nikita Popov [Thu, 30 Jan 2020 10:20:42 +0000 (11:20 +0100)]
Add SKIPIF to test requiring mbregex

4 years agoReset trampoline on executor startup
Nikita Popov [Thu, 30 Jan 2020 10:03:14 +0000 (11:03 +0100)]
Reset trampoline on executor startup

Make sure the trampoline is usable, even if we had an unclean
shutdown on the last request.

4 years agoFix UAF in is_callable() and allocated trampoline
Nikita Popov [Thu, 30 Jan 2020 10:01:13 +0000 (11:01 +0100)]
Fix UAF in is_callable() and allocated trampoline

By nulling out the function_handler, so it will not get used
below. Reuse the existing helper for this purpose.

4 years agoFix shift ub in mbstring
Nikita Popov [Tue, 28 Jan 2020 15:18:46 +0000 (16:18 +0100)]
Fix shift ub in mbstring

Ideally "c" would be an unsigned integer...

4 years agoRestore digit check in mb_decode_numericentity()
Nikita Popov [Wed, 29 Jan 2020 15:40:13 +0000 (16:40 +0100)]
Restore digit check in mb_decode_numericentity()

I replaced it with a multiplication overflow check in
18599f9c52959b2e8cbfac57e278644499a3547d. However, we need both,
because the code for restoring the number can't handle numbers
with many leading zeros right now and I don't feel like teaching it.

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Nikita Popov [Wed, 29 Jan 2020 15:19:14 +0000 (16:19 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fix mb_ord() crash if internal encoding not supported

4 years agoFix mb_ord() crash if internal encoding not supported
Nikita Popov [Wed, 29 Jan 2020 15:17:30 +0000 (16:17 +0100)]
Fix mb_ord() crash if internal encoding not supported

enc_name can be NULL here. Take the name from the mbfl_encoding
instead.

4 years agoBetter overflow check for entity decoding
Nikita Popov [Wed, 29 Jan 2020 13:22:45 +0000 (14:22 +0100)]
Better overflow check for entity decoding

Check for multiplication overflow rather than number of digits.

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Nikita Popov [Wed, 29 Jan 2020 15:05:38 +0000 (16:05 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Reset MBREX(search_re) in RSHUTDOWN

4 years agoReset MBREX(search_re) in RSHUTDOWN
Nikita Popov [Wed, 29 Jan 2020 15:03:44 +0000 (16:03 +0100)]
Reset MBREX(search_re) in RSHUTDOWN

This is going to cause a segfault if reused in the next request.
To illustrate the issue, run these two scripts in sequence with
the built-in server:

// script1.php
mb_ereg_search_init('foobar');
mb_ereg_search('foo');

// script2.php
var_dump(mb_ereg_search_init("foobar"));
var_dump(mb_ereg_search_pos());

4 years agozip: more constants
Remi Collet [Wed, 29 Jan 2020 13:25:16 +0000 (14:25 +0100)]
zip: more constants

4 years agoBackport 7d2ef3d2e540885dec26d91dad061bff1621ad07 into 7.4
Anatol Belski [Wed, 29 Jan 2020 12:19:27 +0000 (13:19 +0100)]
Backport 7d2ef3d2e540885dec26d91dad061bff1621ad07 into 7.4

As the data structures are public, the fix for 64-bit consists
on replacing the blanket memcpy with individual assignments.

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Nikita Popov [Wed, 29 Jan 2020 11:50:40 +0000 (12:50 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fix use of mb_ereg_search_getregs() after invalid pattern

4 years agoFix use of mb_ereg_search_getregs() after invalid pattern
Nikita Popov [Wed, 29 Jan 2020 11:49:28 +0000 (12:49 +0100)]
Fix use of mb_ereg_search_getregs() after invalid pattern

This segfaulted because we assumed that if there are matches,
there must be a regular expression as well.

4 years agoFix length inconsistency in mb_convert_encoding
Nikita Popov [Wed, 29 Jan 2020 11:19:28 +0000 (12:19 +0100)]
Fix length inconsistency in mb_convert_encoding

Don't mix strlen() and ZSTR_LEN(). If the encoding contains a
NULL byte, this will overflow the buffer.

NULL bytes will still make this behave oddly because the consuming
code will cut off the string there, but let's address that in master...

4 years agoFix recovery of large entities in mb_decode_numericentity()
Nikita Popov [Wed, 29 Jan 2020 10:44:56 +0000 (11:44 +0100)]
Fix recovery of large entities in mb_decode_numericentity()

Make sure we don't overflow the integer.

4 years agoUse "%define parse.error verbose"
Akim Demaille [Tue, 28 Jan 2020 19:41:56 +0000 (20:41 +0100)]
Use "%define parse.error verbose"

The YYERROR_VERBOSE macro will no longer be supported in Bison 3.6.
It was superseded by the "%error-verbose" directive in Bison 1.875
(2003-01-01).  Bison 2.6 (2012-07-19) clearly announced that support
for YYERROR_VERBOSE would be removed.  Note that since Bison 3.0
(2013-07-25), "%error-verbose" is deprecated in favor of "%define
parse.error verbose".

Closes GH-5125.

4 years agoFixed bug #79092 (Building with clang+lld-9 results in a broken PHP binary)
Dmitry Stogov [Wed, 29 Jan 2020 09:15:03 +0000 (12:15 +0300)]
Fixed bug #79092 (Building with clang+lld-9 results in a broken PHP binary)

4 years agoFix #78666 mysqli_options generates Warning on var_dump()
Máté Kocsis [Fri, 24 Jan 2020 19:08:32 +0000 (20:08 +0100)]
Fix #78666 mysqli_options generates Warning on var_dump()

Closes GH-5121

4 years agoFix memory leak in mb_str_split
Nikita Popov [Tue, 28 Jan 2020 16:39:37 +0000 (17:39 +0100)]
Fix memory leak in mb_str_split

4 years agoFix mysqli_get_warnings() with multi queries
Nikita Popov [Tue, 28 Jan 2020 16:12:45 +0000 (17:12 +0100)]
Fix mysqli_get_warnings() with multi queries

In this case warning_count may be non-zero, but php_get_warnings()
may still return no warnings. In this case we should return false
rather than returning a corrupted mysqli_warning object.

4 years agoFix #79174: cookie values with spaces fail to round-trip
Christoph M. Becker [Tue, 28 Jan 2020 14:11:59 +0000 (15:11 +0100)]
Fix #79174: cookie values with spaces fail to round-trip

The fix for bug #78929 disabled the conversion of spaces in cookie
values to plus signs, but failed to adapt `php_setcookie()`
accordingly, so that it uses raw URL encoding as well.

4 years agoEnable support for LIBZIP_VERSION
Christoph M. Becker [Tue, 28 Jan 2020 12:30:53 +0000 (13:30 +0100)]
Enable support for LIBZIP_VERSION

This is already supported by non Windows builds for libzip >= 1.3.1,
and since we're using at least libzip 1.4.0 on Windows, we should
support it there as well.

4 years agoFixed bug #78989
Nikita Popov [Tue, 28 Jan 2020 09:41:11 +0000 (10:41 +0100)]
Fixed bug #78989

Always operate on copies of the functions, so we don't reference
temporary trait methods that have gone out of scope.

This could be more efficient, but doing an allocated copy only when
strictly necessary turned out to be somewhat tricky.

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Christoph M. Becker [Tue, 28 Jan 2020 09:32:26 +0000 (10:32 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fix #76584: PharFileInfo::decompress not working

4 years agoFix #76584: PharFileInfo::decompress not working
Christoph M. Becker [Sun, 26 Jan 2020 12:33:07 +0000 (13:33 +0100)]
Fix #76584: PharFileInfo::decompress not working

We actually have to decompress, when told to do so.

4 years agoFix #79172: STRUCT_OFFSET() relies on undefined behavior
Christoph M. Becker [Tue, 28 Jan 2020 08:15:23 +0000 (09:15 +0100)]
Fix #79172: STRUCT_OFFSET() relies on undefined behavior

Since this pattern is understood by compilers, not a real issue, but
certainly cleaner this way.

4 years ago- bump zip extension version to 1.15.6
Remi Collet [Mon, 27 Jan 2020 15:47:28 +0000 (16:47 +0100)]
- bump zip extension version to 1.15.6
- add ZipArchive::LIBZIP_VERSION
- skip bug53885.phpt with libzip 1.6.0 (empty file is no more valid archive)

4 years agoFix #78969 Make PASSWORD_DEFAULT match PASSWORD_BCRYPT instead of being null
Máté Kocsis [Wed, 22 Jan 2020 12:33:11 +0000 (13:33 +0100)]
Fix #78969 Make PASSWORD_DEFAULT match PASSWORD_BCRYPT instead of being null

It was an unintentional BC break.

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Nikita Popov [Mon, 27 Jan 2020 12:32:29 +0000 (13:32 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fix bug #78323: Code 0 is returned on invalid options

4 years agoFix bug #78323: Code 0 is returned on invalid options
Ivan Mikheykin [Fri, 17 Jan 2020 19:26:35 +0000 (22:26 +0300)]
Fix bug #78323: Code 0 is returned on invalid options

Set CLI exit code to 1 when invalid parameters are passed,
and print error to stderr.

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Christoph M. Becker [Sun, 26 Jan 2020 13:13:52 +0000 (14:13 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Add CURLOPT CURLOPT_HTTP09_ALLOWED available since 7.64.0

4 years agoAdd CURLOPT CURLOPT_HTTP09_ALLOWED available since 7.64.0
Florian Smeets [Sun, 26 Jan 2020 04:18:57 +0000 (05:18 +0100)]
Add CURLOPT CURLOPT_HTTP09_ALLOWED available since 7.64.0

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
George Peter Banyard [Sat, 25 Jan 2020 12:31:10 +0000 (13:31 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fixed bug #79080 [ci skip]

4 years agoFixed bug #79080 [ci skip]
George Peter Banyard [Sat, 25 Jan 2020 12:23:51 +0000 (13:23 +0100)]
Fixed bug #79080 [ci skip]

Rewrote session.gc_probability and session.gc_divisor INI setting
description to be more succint.

4 years agoFixed bug #79128
Nikita Popov [Fri, 24 Jan 2020 15:18:28 +0000 (16:18 +0100)]
Fixed bug #79128

We need to extend the hash table before performing raw append
operations.

This doesn't matter if preloading happens in the same process,
as the tables will be large enough to hold all entries as a
side-effect of the preloading process. However, if preloading
happens in a different process, we need to reserve space here.

4 years agoFix mysqli ssl test for tls1.3
Nikita Popov [Fri, 24 Jan 2020 14:14:52 +0000 (15:14 +0100)]
Fix mysqli ssl test for tls1.3

Specifying AES256-SHA results in TLS_AES_256_GCM_SHA384 if the
connection uses TLS v1.3.

4 years agoFixed bug #79011
Nikita Popov [Fri, 24 Jan 2020 13:52:28 +0000 (14:52 +0100)]
Fixed bug #79011

auth_plugin_data_len here is 21, including the trailing null byte.
Directly use SCRAMBLE_LENGTH instead. Also add a sanity check that
the provided scramble is long enough.

4 years agoFix memory leaks in mysqlnd debug functionality
Nikita Popov [Fri, 24 Jan 2020 12:12:11 +0000 (13:12 +0100)]
Fix memory leaks in mysqlnd debug functionality

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Christoph M. Becker [Fri, 24 Jan 2020 13:19:17 +0000 (14:19 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Make test independent of online XSD schema
  Yet another check for php_strip_tags_ex()

4 years agoMake test independent of online XSD schema
Christoph M. Becker [Fri, 24 Jan 2020 09:18:01 +0000 (10:18 +0100)]
Make test independent of online XSD schema

The test still needs to access <http://www.w3.org/2009/01/xml.xsd>, but
at least we no longer depend on <http://x-road.eu/xsd/x-road.xsd>,
which may be moved again.

4 years agoAdd ZipArchive::CM_LZMA2 constant (since libzip 1.6.0)
Remi Collet [Fri, 24 Jan 2020 13:06:19 +0000 (14:06 +0100)]
Add ZipArchive::CM_LZMA2 constant (since libzip 1.6.0)

4 years agoYet another check for php_strip_tags_ex()
Christoph M. Becker [Fri, 24 Jan 2020 11:45:04 +0000 (12:45 +0100)]
Yet another check for php_strip_tags_ex()

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Christoph M. Becker [Fri, 24 Jan 2020 11:51:02 +0000 (12:51 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Yet another check for php_strip_tags_ex()

4 years agoYet another check for php_strip_tags_ex()
Christoph M. Becker [Fri, 24 Jan 2020 11:45:04 +0000 (12:45 +0100)]
Yet another check for php_strip_tags_ex()

4 years agoDon't use CRLF when generating diffs
Nikita Popov [Fri, 24 Jan 2020 11:28:37 +0000 (12:28 +0100)]
Don't use CRLF when generating diffs

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Nikita Popov [Thu, 23 Jan 2020 14:09:54 +0000 (15:09 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fix bug76348.phpt

4 years agoFix bug76348.phpt
Nikita Popov [Thu, 23 Jan 2020 14:08:20 +0000 (15:08 +0100)]
Fix bug76348.phpt

Adjust for URL change in XSD file and mark as online test.

Is it possible for use to store http://x-road.eu/xsd/xroad.xsd
locally instead? Do relative file system paths work here?
I'm not familiar with this.

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Nikita Popov [Thu, 23 Jan 2020 13:58:01 +0000 (14:58 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fixed bug #78902
  Add unit test for bug #78902

4 years agoFixed bug #78902
liudaixiao [Mon, 16 Dec 2019 01:10:28 +0000 (09:10 +0800)]
Fixed bug #78902

4 years agoAdd unit test for bug #78902
Léopold Jacquot [Wed, 4 Dec 2019 14:14:50 +0000 (15:14 +0100)]
Add unit test for bug #78902

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Nikita Popov [Thu, 23 Jan 2020 13:21:14 +0000 (14:21 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fixed bug #79151

4 years agoFixed bug #79151
Nikita Popov [Thu, 23 Jan 2020 13:19:20 +0000 (14:19 +0100)]
Fixed bug #79151

Make sure we also NULL out next/prev of the removed element on
pop/shift. This only matter is that element is still being referenced
by an iterator.

4 years agoFixed bug #79155
Nikita Popov [Thu, 23 Jan 2020 11:48:45 +0000 (12:48 +0100)]
Fixed bug #79155

Make sure we only unset the NULLABLE flag temporarily for class
resolution, as the same type may be compiled multiple types.

4 years agoEnable UBSan in addition to ASan
Christoph M. Becker [Tue, 31 Dec 2019 10:46:04 +0000 (11:46 +0100)]
Enable UBSan in addition to ASan

UBSan is a useful tool, so we enable it for `--enable-sanitizer` in
addition to ASan.

4 years agoMake MSVCRT memory leak checking usable for the test suite
Christoph M. Becker [Wed, 15 Jan 2020 22:04:03 +0000 (23:04 +0100)]
Make MSVCRT memory leak checking usable for the test suite

While basic support for MSVCRT debugging has been added long
ago[1], the leak checking is not usable for the test suite, because we
are no longer calling `xmlCleanupParser()` on RSHUTDOWN of
ext/libxml[2], and therefore a few bogus leaks are reported whenever
ext/libxml is unloaded.

We therefore ignore memory leaks for this case.  We introduce
`ZEND_IGNORE_LEAKS_BEGIN()` and `ZEND_IGNORE_LEAKS_END()` to keep
those ignores better readable, and also because these *might* be
useful for other leak checkers as well.

We also explicitly free the `zend_handlers_table` and the `p5s` to
avoid spurious leak reports.

[1] <http://git.php.net/?p=php-src.git;a=commit;h=d756e1db2324c1f4ab6f9b52e329959ce6a02bc3>
[2] <http://git.php.net/?p=php-src.git;a=commit;h=8742276eb3905eb97a585417000c7b8df85006d4>

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Stanislav Malyshev [Thu, 23 Jan 2020 07:06:28 +0000 (23:06 -0800)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  More checks for php_strip_tags_ex

4 years agoMerge branch 'PHP-7.2' into PHP-7.3
Stanislav Malyshev [Thu, 23 Jan 2020 06:41:56 +0000 (22:41 -0800)]
Merge branch 'PHP-7.2' into PHP-7.3

* PHP-7.2:
  More checks for php_strip_tags_ex

4 years agoMore checks for php_strip_tags_ex
Stanislav Malyshev [Thu, 23 Jan 2020 06:36:53 +0000 (22:36 -0800)]
More checks for php_strip_tags_ex

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Christoph M. Becker [Wed, 22 Jan 2020 10:15:55 +0000 (11:15 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Don't leak encoding_str

4 years agoDon't leak encoding_str
Christoph M. Becker [Wed, 22 Jan 2020 10:13:12 +0000 (11:13 +0100)]
Don't leak encoding_str

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Christoph M. Becker [Wed, 22 Jan 2020 09:30:25 +0000 (10:30 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fix #79154: mb_convert_encoding() can modify $from_encoding

4 years agoFix #79154: mb_convert_encoding() can modify $from_encoding
Christoph M. Becker [Wed, 22 Jan 2020 09:25:37 +0000 (10:25 +0100)]
Fix #79154: mb_convert_encoding() can modify $from_encoding

We must not modify arrays passed by value.

4 years agoFix #79149: SEGV in mb_convert_encoding with non-string encodings
Christoph M. Becker [Wed, 22 Jan 2020 08:43:51 +0000 (09:43 +0100)]
Fix #79149: SEGV in mb_convert_encoding with non-string encodings

We must not assume that `hash_entry` `IS_STRING`, but rather use
`encoding_str` which is guaranteed to be.

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Remi Collet [Wed, 22 Jan 2020 08:17:56 +0000 (09:17 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  next will be 7.2.28

4 years agoMerge branch 'PHP-7.2' into PHP-7.3
Remi Collet [Wed, 22 Jan 2020 08:17:33 +0000 (09:17 +0100)]
Merge branch 'PHP-7.2' into PHP-7.3

* PHP-7.2:
  next will be 7.2.28

4 years agonext will be 7.2.28
Remi Collet [Wed, 22 Jan 2020 08:17:00 +0000 (09:17 +0100)]
next will be 7.2.28

4 years agoAvoid some @count() suppressions in run-tests.php
Nikita Popov [Tue, 21 Jan 2020 17:49:59 +0000 (18:49 +0100)]
Avoid some @count() suppressions in run-tests.php

4 years agoAdd sleep in FPM reload test
Nikita Popov [Tue, 21 Jan 2020 16:55:47 +0000 (17:55 +0100)]
Add sleep in FPM reload test

Explicitly mark the point where we have to wait.

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Christoph M. Becker [Tue, 21 Jan 2020 15:19:04 +0000 (16:19 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fix #79145: openssl memory leak

4 years agoFix #79145: openssl memory leak
Christoph M. Becker [Tue, 21 Jan 2020 15:17:25 +0000 (16:17 +0100)]
Fix #79145: openssl memory leak

We must increase the refcount of `return_value` only if `cert` is a
resource; this is already done in `php_openssl_evp_from_zval()`,
though.

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Christoph M. Becker [Tue, 21 Jan 2020 10:53:36 +0000 (11:53 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Fix #79146: cscript can fail to run on some systems

4 years agoFix #79146: cscript can fail to run on some systems
Deus Kane [Mon, 20 Jan 2020 16:16:01 +0000 (16:16 +0000)]
Fix #79146: cscript can fail to run on some systems

In the buildconf and configure batch files, Windows' cscript utility was being
run without the /e:jscript flag. This works on systems that have not had the
default .js file association changed, but if .js has been re-associated to
(say) an IDE, the batch files fail with the error message:

Input Error: There is no script engine for file extension ".js".

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Christoph M. Becker [Tue, 21 Jan 2020 10:48:48 +0000 (11:48 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Update NEWS wrt. sec fixes

4 years agoFix file clash in bug54446.phpt tests
Nikita Popov [Tue, 21 Jan 2020 10:38:49 +0000 (11:38 +0100)]
Fix file clash in bug54446.phpt tests

4 years agoUpdate NEWS wrt. sec fixes
Christoph M. Becker [Tue, 21 Jan 2020 10:31:14 +0000 (11:31 +0100)]
Update NEWS wrt. sec fixes

4 years agoMerge branch 'PHP-7.3' into PHP-7.4
Stanislav Malyshev [Tue, 21 Jan 2020 06:47:01 +0000 (22:47 -0800)]
Merge branch 'PHP-7.3' into PHP-7.4

* PHP-7.3:
  Update NEWS
  Fix bug #79037 (global buffer-overflow in `mbfl_filt_conv_big5_wchar`)
  Fix #79099: OOB read in php_strip_tags_ex
  Fix #79091: heap use-after-free in session_create_id()

4 years agoMerge branch 'PHP-7.2' into PHP-7.3
Stanislav Malyshev [Tue, 21 Jan 2020 06:22:02 +0000 (22:22 -0800)]
Merge branch 'PHP-7.2' into PHP-7.3

* PHP-7.2:
  Update NEWS
  Fix bug #79037 (global buffer-overflow in `mbfl_filt_conv_big5_wchar`)
  Fix #79099: OOB read in php_strip_tags_ex
  Fix #79091: heap use-after-free in session_create_id()

4 years agoUpdate NEWS
Stanislav Malyshev [Tue, 21 Jan 2020 06:12:32 +0000 (22:12 -0800)]
Update NEWS

4 years agoFix bug #79037 (global buffer-overflow in `mbfl_filt_conv_big5_wchar`)
Stanislav Malyshev [Tue, 21 Jan 2020 05:42:44 +0000 (21:42 -0800)]
Fix bug #79037 (global buffer-overflow in `mbfl_filt_conv_big5_wchar`)