Commit Graph

106270 Commits

Author SHA1 Message Date
Matteo Beccati
796efd849e Skip test when SIGKILL is not defined 2019-08-09 10:32:15 +02:00
Dmitry Stogov
358379be22 Fixed bug #78379 (Cast to object confuses GC, causes crash) 2019-08-08 10:00:39 +03:00
Christoph M. Becker
954543cec6 Fix #78282: atime and mtime mismatch
The fix for bug #78241 assumed that `time_t` would always be 64bit, but
actually is 32bit for x86.  We therefore enforce 64bit arithmetic to
avoid wrapping.

(cherry picked from commit bf242d58e7)
2019-08-06 17:25:54 +02:00
Christoph M. Becker
f9f4a68368 Fix #78179: MariaDB server version incorrectly detected
As of MariaDB 10.0.2, the server reports a fake version number as work-
around for replication issues[1].  We apply the same "fix" as in the
MariaDB client to cater to this.

[1] <c50ee6c23d (diff-5b45fa673c88c06a9651c7906364f592)>
2019-08-02 16:42:49 +02:00
Nikita Popov
85e8ccd55e Fixed bug #78363 2019-08-02 10:35:24 +02:00
Remi Collet
b29ecec4ef add security NEW entries + reorder [ci skip] 2019-07-30 09:26:50 +02:00
Stanislav Malyshev
284fb08fdc Merge branch 'PHP-7.1' into PHP-7.2
* PHP-7.1:
  Fix #77919: Potential UAF in Phar RSHUTDOWN
  Update NEWS
  Fix bug #78256 (heap-buffer-overflow on exif_process_user_comment)
  Fix bug #78222 (heap-buffer-overflow on exif_scan_thumbnail)
2019-07-29 13:19:16 -07:00
Christoph M. Becker
cd1101e8c8 Fix #77919: Potential UAF in Phar RSHUTDOWN
We have to properly clean up in case phar_flush() is failing.

We also make the expectation of the respective test case less liberal
to avoid missing such bugs in the future.
2019-07-29 13:18:27 -07:00
Stanislav Malyshev
42e8b85d94 Update NEWS 2019-07-29 13:16:53 -07:00
Albert Casademont
dc7aa22b18 Fix bug #78326
Similar to what fread() does, truncate the stream_get_contents()
result if the original buffer was way too large.
2019-07-29 17:33:57 +02:00
Nikita Popov
38f1288b64 Fix Zend signals unblocking
There are a few parts here:
 * opcache should not be blocking signals while invoking compile_file,
   otherwise signals may remain blocked on a compile error. While at
   it, also protect SHM memory during compile_file.
 * We should deactivate Zend signals at the end of the request, to make
   sure that we gracefully recover from a missing unblock and signals
   don't remain blocked forever.
 * We don't use a critical section in deactivation, because it should
   not be necessary. Additionally we want to clean up the signal queue,
   if it is non-empty.
 * Enable SIGG(check) in debug builds so we notice issues in the future.
2019-07-29 15:17:32 +02:00
Nikita Popov
68fd435ba8 Fixed bug #78333
Don't dereference float/double values at unknown address, instead
memcpy it into an aligned stack slot and dereference that.
2019-07-29 11:27:21 +02:00
Stanislav Malyshev
aeb6d13185 Fix bug #78256 (heap-buffer-overflow on exif_process_user_comment) 2019-07-29 00:53:37 -07:00
Stanislav Malyshev
dea2989ab8 Fix bug #78222 (heap-buffer-overflow on exif_scan_thumbnail) 2019-07-29 00:53:28 -07:00
Christoph M. Becker
30eb4b3563 Fix #78342: Bus error in configure test for iconv //IGNORE
We have to check the return value of iconv_open() for error, to avoid
that and potentially other undesired behavior of iconv().
2019-07-29 08:48:13 +02:00
Levi Morrison
5649267b25 Remove .post files only for passing tests
This allows the sh script for failing tests with --POST-- to work
2019-07-25 09:48:39 -06:00
Peter Kokot
8f384bea93 Update NEWS 2019-07-23 02:13:00 +02:00
George Wang
eb7e45f662 Checked in LiteSpeed SAPI 7.5, addressed two main problems in "clean shutdown" introduced in 7.4.3,
1. falls in an infinite loop because PHP engine's inconsistent state, now override the ITIMER_PROF to 0.1 second, clean shutdown must finish before that.
2. generate too much error log, we completely disable "error_reporting" before calling php_request_shutdown().
2019-07-20 23:59:43 -04:00
Abyr Valg
c8c183eb62 Fixed bug #77946
Save multi_info_read() result into easy handle.
2019-07-18 14:40:47 +02:00
Nikita Popov
b864abfe23 Fixed bug #69100 2019-07-17 15:58:29 +02:00
Remi Collet
bd0514913b move NEWS entry [ci skip] 2019-07-16 13:00:13 +02:00
Nikita Popov
8a19fe29de Fixed bug #78297 2019-07-16 11:09:17 +02:00
Remi Collet
c9037421ac next is 7.2.22 2019-07-16 10:38:20 +02:00
Dmitry Stogov
9ccf3fb996 Fixed incorrect specialization (missed IS_INDIRECT handling) 2019-07-16 01:50:10 +03:00
Nikita Popov
88ffe05797 Fix bug #77124
This is a backport of 6fcae63f61
to PHP 7.2.
2019-07-15 15:19:31 +02:00
Remi Collet
eab0079c90 Fix #78269 password_hash uses weak options for argon2 2019-07-15 14:10:38 +02:00
Andrew Collington
768ad70f70 Fix bug #78291 Missing opcache directives
New opcache directives have been added recently which are returned
if using `ini_get_all('zend opcache')` but are not listed in the
directives if using `opcache_get_configuration()`.  This fix adds
those missing directives as well as if `opcache.mmap_base` is used
instead of `opcache.lockfile_path`.  Also adds a test to ensure the
directives match with both methods of fetching.
2019-07-15 10:22:47 +02:00
Nikita Popov
a7de2af46c Use TRY_ADDREF/TRY_DELREF in soap
The DELREF part is a possible fix for bug #78278, the ADDREF part
is a drive-by fix.
2019-07-12 16:50:43 +02:00
Nikita Popov
4a91f66b8f Fixed bug #78279
Even if we don't initialize the callback on every request, we
should still reset our globals to default values...
2019-07-12 16:29:18 +02:00
Nikita Popov
22ed362810 Revert "Fixed bug #76980"
This reverts commit 35353dc49a.

This changes causes issues for Symfony, see
https://github.com/symfony/symfony/issues/32395. I'm reverting it
from PHP 7.2 and PHP 7.3 and only leaving it in PHP 7.4.
2019-07-09 11:04:16 +02:00
Christoph M. Becker
40f7533cc1 Merge branch 'PHP-7.1' into PHP-7.2
* PHP-7.1:
  Upgrade to SQLite 3.28.0
2019-07-09 10:02:47 +02:00
Christoph M. Becker
e944ae6b2a Upgrade to SQLite 3.28.0
Over the years, multiple security vulnerabilities[1] have been found
and fixed in SQLite3, so it makes sense to update our bundled libsqlite
to the latest available version.

[1] <https://www.cvedetails.com/vulnerability-list/vendor_id-9237/Sqlite.html>
2019-07-09 09:59:46 +02:00
Peter Kokot
f81be1aff6 Update NEWS [ci skip] 2019-07-08 18:47:55 +02:00
Nikita Popov
5846e85283 Backport fe_reset_rw case 2019-07-05 12:06:52 +02:00
Nikita Popov
c353f17d42 Fix inference for compound object op on dim 2019-07-05 11:39:42 +02:00
George Wang
32af676bd9 Updated to LiteSpeed SAPI V7.4.3
Increased response header count limit from 100 to 1000.
Added crash handler to cleanly shutdown PHP request.
Added CloudLinux mod_lsapi mode
Fixed bug #76058
2019-07-04 12:03:21 -04:00
Nikita Popov
0e48e35e04 Fixed bug #78231 2019-07-03 12:36:06 +02:00
Christoph M. Becker
44c8b7414c Fix #78241: touch() does not handle dates after 2038 in PHP 64-bit
`time_t` defaults to `_time64` (which is 64bit signed) even on x86, but
`Int32x32To64()` truncates it to signed 32bit.  We replace the macro
with the "manual" calculation.
2019-07-03 09:59:17 +02:00
Nikita Popov
32c68428a9 Backport test fix
Closes GH-3816.
2019-07-02 16:11:54 +02:00
Alex Scott
a4acff3e21 Fix bug #78138: opcache.validate_permission incorrectly works with PHAR files
opcache incorrectly handles PHAR files when opcache.validate_permission
option enabled, because it calls

  access("phar://path-to/file.phar/path/inside.php", R_OK);

rather than

  access("path-to/file.phar", R_OK)
2019-07-02 12:25:50 +02:00
Christoph M. Becker
57688ad7bf Add missing SKIPIFs
All these tests are meant to run with OPcache available, and some will
even fail inevitably without it, so we add OPcache as SKIPIF
requirement.
2019-07-01 18:11:13 +02:00
Christoph M. Becker
75bc3446f8 Add missing SKIPIFs
All these tests are meant to run with OPcache available, and some will
even fail inevitably without it, so we add OPcache as SKIPIF
requirement.
2019-07-01 17:21:16 +02:00
Christoph M. Becker
be559e6c37 Fix brittle test
This test is easily tripped by former test runs with other PHP
versions.  To avoid such false positives, we check that there is at
least one respective OPcache file, and that all found OPcache user ID
folders have exactly 32 hexadecimal digits.
2019-07-01 16:42:55 +02:00
Anatol Belski
a149f9f3c0 Update NEWS [ci skip] 2019-06-29 17:39:45 +02:00
Joshua Westerheide
855bbc88c9 Fix #78183: finfo_file shows wrong mime-type for .tga file
Due to a bug in the underlying libmagic 5.31, .tga images returned mime type "image/x-tgaimage/x-tga".
2019-06-29 13:24:52 +02:00
sunnyeo
f7327b6244 Fix bugs in AST printer
Closes GH-4324.
2019-06-28 16:08:44 +02:00
Vincent
05c00a832c Fix bug #78192 PDO SQLite SegFault when reuse statement after schema has changed
Reset stmt->columns when column count changed on new execution of prepared statement
2019-06-28 12:36:02 +02:00
Nikita Popov
7d28a24c66 Remove stream_socket_sendto.phpt
Fails for me locally due to different number of warnings with
different messages. Rather than adding more wildcards I'm dropping
this test entirely, as it doesn't seem to test anything particularly
useful.

(cherry picked from commit 84333cad67)
2019-06-26 16:58:37 +02:00
Christoph M. Becker
4366f22dfc Fix #78202: Opcache stats for cache hits are capped at 32bit NUM
We use the proper format specifiers now.
2019-06-25 13:00:28 +02:00
Andrey Hristov
102c64e827 Add explicit cast to uint32_t.
It works even without it but explicit stuff is better. The compiler probably converts the 16-bit
uint16_t to uint32_t before doing the shift.
2019-06-21 16:31:56 +03:00