summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Update NEWS for PHP 7.4.15PHP-7.4.15Derick Rethans2021-02-021-1/+1
|
* Prepare NEWSDerick Rethans2021-02-021-1/+5
|
* Rm unneeded functionStanislav Malyshev2021-02-021-16/+0
|
* Fix buildNikita Popov2021-02-021-1/+1
|
* Alternative fix for bug 77423Christoph M. Becker2021-02-028-28/+38
| | | | | | | | | | | That bug report originally was about `parse_url()` misbehaving, but the security aspect was actually only regarding `FILTER_VALIDATE_URL`. Since the changes to `parse_url_ex()` apparently affect userland code which is relying on the sloppy URL parsing[1], this alternative restores the old parsing behavior, but ensures that the userinfo is checked for correctness for `FILTER_VALIDATE_URL`. [1] <https://github.com/php/php-src/commit/5174de7cd33c3d4fa591c9c93859ff9989b07e8c#commitcomment-45967652>
* Merge branch 'PHP-7.3' into PHP-7.4Stanislav Malyshev2021-02-024-14/+37
| | | | | * PHP-7.3: Fix bug #80672 - Null Dereference in SoapClient
* Update NEWS for PHP 7.4.15RC2Derick Rethans2021-01-191-1/+1
|
* Reset date so I can try againDerick Rethans2021-01-191-1/+1
|
* Set right versionDerick Rethans2021-01-191-1/+1
|
* Update NEWS for PHP 7.4.15RC1Derick Rethans2021-01-191-1/+1
|
* Fixed bug #42560sj-i2021-01-196-10/+37
| | | | | | | | | | | | Check open_basedir after the fallback to the system's temporary directory in tempnam(). In order to preserve the current behavior of upload_tmp_dir (do not check explicitly specified dir, but check fallback), new flags are added to check open_basedir for explicit dir and for fallback. Closes GH-6526.
* Fix #69279: Compressed ZIP Phar extractTo() creates garbage filesChristoph M. Becker2021-01-196-1/+93
| | | | | | | | | | | | | | | When extracting compressed files from an uncompressed Phar, we must not use the direct file pointer, but rather get an uncompressed file pointer. We also add a test to show that deflated and stored entries are properly extracted. This also fixes #79912, which appears to be a duplicate of #69279. Co-authored-by: Anna Filina <afilina@gmail.com> Closes GH-6599.
* Fix #80595: Resetting POSTFIELDS to empty array breaks requestChristoph M. Becker2021-01-184-2/+43
| | | | | | | | | | | | This is mainly to work around https://github.com/curl/curl/issues/6455, but not building the mime structure for empty hashtables is a general performance optimization, so we do not restrict it to affected cURL versions (7.56.0 to 7.75.0). The minor change to bug79033.phpt is unexpected, but should not matter in practice. Closes GH-6606.
* Revert "Fix #76813: Access violation near NULL on source operand"Christoph M. Becker2021-01-114-24/+3
| | | | | This reverts commit 5e15c9c41f8318a8392c2e2c78544f218736549c, since re2c default rules are only available as of re2c 0.13.7.
* Avoid modifying the return value of readline_completion_function()Christoph M. Becker2021-01-071-0/+1
| | | | | | | | | The internal function `_readline_command_generator()` modifies the internal array pointer of `readline_completion_function()`'s return value. We therefore separate the array, what also avoids failing assertions regarding the array refcount. Closes GH-6582.
* Fix #77565: Incorrect locator detection in ZIP-based pharsChristoph M. Becker2021-01-056-40/+77
| | | | | | | | | | | | | | | | | We must not assume that the first end of central dir signature in a ZIP archive actually designates the end of central directory record, since the data in the archive may contain arbitrary byte patterns. Thus, we better search from the end of the data, what is also slightly more efficient. There is, however, no way to detect the end of central directory signature by searching from the end of the ZIP archive with absolute certainty, since the signature could be part of the trailing comment. To mitigate, we check that the comment length fits to the found position, but that might still not be the correct position in rare cases. Closes GH-6507.
* Fix memory leak in Phar::webPhar() on WindowsChristoph M. Becker2021-01-051-19/+17
| | | | Closes GH-6574.
* gdbinit: use ____print_str to print htable keysDylan K. Taylor2021-01-051-1/+2
| | | | | | | | | I noticed this problem while dumping the contents of EG(function_table), where keys for closures start with a null byte. printf interprets this as a zero-length string and emits nothing. This allows the key to be rendered properly in readable form. Closes GH-6577.
* Disable non-cron travis jobsNikita Popov2021-01-041-0/+3
| | | | | This was already done for PHP-8.0 and master, do it for PHP-7.4 as well.
* [ci skip] Update NEWSStanislav Malyshev2021-01-041-0/+2
|
* Merge branch 'PHP-7.3' into PHP-7.4Stanislav Malyshev2021-01-040-0/+0
|\ | | | | | | | | * PHP-7.3: [ci skip] Fix order
| * [ci skip] Fix orderStanislav Malyshev2021-01-041-2/+2
| |
* | Merge branch 'PHP-7.3' into PHP-7.4Stanislav Malyshev2021-01-040-0/+0
|\ \ | |/ | | | | | | * PHP-7.3: [ci skip] Unpdate NEWS
| * [ci skip] Unpdate NEWSStanislav Malyshev2021-01-041-0/+2
| |
* | Merge branch 'PHP-7.3' into PHP-7.4Stanislav Malyshev2021-01-017-15/+61
|\ \ | |/ | | | | | | * PHP-7.3: Fix #77423: parse_url() will deliver a wrong host to user
| * Merge branch 'PHP-7.2' into PHP-7.3Stanislav Malyshev2021-01-017-15/+61
| |\ | | | | | | | | | | | | * PHP-7.2: Fix #77423: parse_url() will deliver a wrong host to user
| | * Fix #77423: parse_url() will deliver a wrong host to userPHP-7.2Christoph M. Becker2021-01-017-14/+59
| | | | | | | | | | | | | | | | | | | | | | | | | | | To avoid that `parse_url()` returns an erroneous host, which would be valid for `FILTER_VALIDATE_URL`, we make sure that only userinfo which is valid according to RFC 3986 is treated as such. For consistency with the existing url parsing code, we use ctype functions, although that is not necessarily correct.
* | | Replace sort() function calls with ksort() in basic ksort testhaszi2020-12-271-27/+27
| | | | | | | | | | | | Closes GH-6541.
* | | Fix #80384: limit read buffer sizeAdam Seitz2020-12-234-2/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the case of a stream with no filters, php_stream_fill_read_buffer only reads stream->chunk_size into the read buffer. If the stream has filters attached, it could unnecessarily buffer a large amount of data. With this change, php_stream_fill_read_buffer only proceeds until either the requested size or stream->chunk_size is available in the read buffer. Co-authored-by: Christoph M. Becker <cmbecker69@gmx.de> Closes GH-6444.
* | | Fixed bug #80376 (last day of the month causes runway cpu usage)Derick Rethans2020-12-213-16889/+19647
| | |
* | | MySQLnd: Support cursors in store/get resultNikita Popov2020-12-185-92/+231
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes two related issues: 1. When a PS with cursor is used in store_result/get_result, perform a COM_FETCH with maximum number of rows rather than silently switching to an unbuffered result set (in the case of store_result) or erroring (in the case of get_result). In the future, we might want to make get_result unbuffered for PS with cursors, as using cursors with buffered result sets doesn't really make sense. Unlike store_result, get_result isn't very explicit about what kind of result set is desired. 2. If the client did not request a cursor, but the server reports that a cursor exists, ignore this and treat the PS as if it has no cursor (i.e. to not use COM_FETCH). It appears to be a server side bug that a cursor used inside an SP will be reported to the client, even though the client cannot use the cursor. Fixes bug #64638, bug #72862, bug #77935. Closes GH-6518.
* | | Fixed bug #67983Nikita Popov2020-12-163-22/+62
| | | | | | | | | | | | | | | We need to check the BIT case first, otherwise it will get skipped in INT_AND_FLOAT_NATIVE mode.
* | | Fix bug #80523Nikita Popov2020-12-162-4/+5
| | | | | | | | | | | | | | | | | | | | | | | | Don't truncate the file length to unsigned int... I have no idea whether that fully fixes the problem because the process gets OOM killed before finishing, but at least the immediate parse error is gone now.
* | | Prepare for 7.4.15Derick Rethans2020-12-151-1/+5
| | |
* | | Fix #77322: PharData::addEmptyDir('/') Possible integer overflowChristoph M. Becker2020-12-153-2/+28
| | | | | | | | | | | | | | | | | | | | | `phar_path_check()` already strips a leading slash, so we must not attempt to strip the trailing slash from an now empty directory name. Closes GH-6508.
* | | Merge branch 'PHP-7.3' into PHP-7.4Christoph M. Becker2020-12-150-0/+0
|\ \ \ | |/ / | | | | | | | | | * PHP-7.3: 7.3.27 is next
| * | 7.3.27 is nextChristoph M. Becker2020-12-154-6/+9
| | |
* | | IBM i PASE doesn't support ITIMER_PROFCalvin Buckley2020-12-152-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Like Cygwin, this platform needs to use a real-time timer. This was based on a patch by @kadler, but it didn't handle unsetting the timer, so the timeout would continue to be active, triggering `hard_timeout` unexpectedly. The patch is fixed to handle unsetting. Closes GH-6503.
* | | Drop pdo_mysql_prepare_load_data.phptChristoph M. Becker2020-12-141-129/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Like the test title and some comments in this test describe, this test was supposed to have `::prepare()` failing because `LOAD DATA INFILE` would not be supported as prepared statement, and then the test checks whether follow-up queries would succeed. However, `LOAD DATA INFILE` is supported for prepared statements at least on Windows with mysqlnd, so the test does no longer test what it is supposed to do. Therefore, we drop it. Closes GH-6509.
* | | Fix bug #69625: FPM returns 200 status on request without SCRIPT_FILENAMEJakub Zelenka2020-12-135-6/+84
| | |
* | | Fixed bug #76815Nikita Popov2020-12-103-0/+42
| | | | | | | | | | | | | | | | | | When we receive an error while reading a result set, we should assume that no more result sets are available. libmysqlclient implements the same behavior.
* | | Fixed bug #71145Nikita Popov2020-12-103-5/+34
| | | | | | | | | | | | Consume any additional result sets when running INIT_COMMAND.
* | | Backport fix for bug #70066Nikita Popov2020-12-105-11/+37
| | | | | | | | | | | | | | | | | | | | | Given the number of duplicates this bug report had, it seems worthwhile to fix this on PHP-7.4 as well. Cherry-pick of 106e7e4bca7c0fd975eb219b18e3c34957ba8657.
* | | Fixed bug #78154Nikita Popov2020-12-093-1/+37
| | | | | | | | | | | | Handle errors during next_result in exec.
* | | Fix #48725: Support for flushing in zlib streamChristoph M. Becker2020-12-083-4/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When `php_zlib_deflate_filter()` is called with `PSFS_FLAG_FLUSH_INC` but without new buckets being available (e.g. because a user calls `rewind()` after writing to the stream), we have to make sure that any pending data are flushed. This could basically be done like in the attached patch[1], but that could cause unnessary flushes, which can be harmful for compression, and adds unnecessary flush markers to the stream. Thus, we use the `php_zlib_filter_data.finished` field, which has not been used for `zlib.deflate` filters, and properly keep track of the need to flush. [1] <https://bugs.php.net/patch-display.php?bug_id=48725&patch=zlib-filter-flush-fix.patch&revision=latest> Closes GH-6019.
* | | Fix #77069: stream filter loses final block of dataChristoph M. Becker2020-12-087-2/+148
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reading from a stream may return greater than zero, but nonetheless the stream's EOF flag may have been set. We have to cater to this condition by setting the close flag for filters. We also have to cater to that change in the zlib.inflate filter: If `inflate()` is called with flush mode `Z_FINISH`, but the output buffer is not large enough to inflate all available data, it fails with `Z_BUF_ERROR`. However, `Z_BUF_ERROR` is not fatal; in fact, the zlib manual states: "If deflate returns with Z_OK or Z_BUF_ERROR, this function must be called again with Z_FINISH and more output space (updated avail_out) but no more input data, until it returns with Z_STREAM_END or an error." Hence, we do so. Closes GH-6001.
* | | Fixed bug #63185Nikita Popov2020-12-083-0/+70
| | |
* | | Fixed bug #80458Dharman2020-12-043-11/+200
| | | | | | | | | | | | | | | | | | | | | | | | | | | If there is no result set (e.g. for upsert queries), still allow fetching to occur without error, i.e. treat it the same way as an empty result set. This normalizes behavior between native and emulated prepared statements and addresses a regression in PHP 7.4.13.
* | | Fix #75102: `PharData` says invalid checksum for valid tarChristoph M. Becker2020-12-044-0/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Apparently, there are broken tarballs out there which are actually in ustar format, but did not write the `ustar` marker. Since popular tar tools like GNU tar and 7zip have no issues dealing with such tarballs, Phar should also be more resilient. Thus, when the first checksum check of a tarball in (presumed) in old- style format fails, we check whether the checksum would be suitable for ustar format; if so, we treat the tarball as being in ustar format. Closes GH-6479.
* | | Upload coverage data to codecov.ioPaul Crovella2020-12-031-1/+4
| | | | | | | | | | | | Closes GH-6486.