Commit Graph

114110 Commits

Author SHA1 Message Date
Nikita Popov
2d15845ae1 Enable ext/sodium in CI 2020-02-24 12:41:30 +01:00
Nikita Popov
6c0a33f2dc Add skipif for argon2id in test
If argon2i is provided by libargon, then argon2id may not be
available here.
2020-02-24 12:41:24 +01:00
Nikita Popov
c5128fb7fc Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Don't treat any WS as start of header
2020-02-24 10:20:43 +01:00
Nikita Popov
56cdbe63c2 Don't treat any WS as start of header
Check that the header occurs after \n, not other whitespace
characters.
2020-02-24 10:20:33 +01:00
Nikita Popov
8d451fd24e Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Reduce code duplication in HTTP header checks
2020-02-24 10:03:30 +01:00
Nikita Popov
3d9c02364d Reduce code duplication in HTTP header checks 2020-02-24 10:03:05 +01:00
Nikita Popov
e855b286c8 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fixes #79265: Improper injection of Host header when using fopen for http requests
2020-02-24 09:51:36 +01:00
Miguel Xavier Penha Neto
d0d60503b5 Fixes #79265: Improper injection of Host header when using fopen for http requests
Check all occurrences of the string "host:" (and other headers),
not just the first one.
2020-02-24 09:50:32 +01:00
Christoph M. Becker
09e7c86779 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix #79299: com_print_typeinfo prints duplicate variables
2020-02-23 23:34:15 +01:00
Christoph M. Becker
9e6358af36 Fix #79299: com_print_typeinfo prints duplicate variables
`lastid` has to retain its value during the traversal, so we move it to
an outer scope.

Patch contributed by Litiano Moura.
2020-02-23 23:31:36 +01:00
Jakub Zelenka
578a8113eb Fix bug #79014 (PHP-FPM & Primary script unknown) 2020-02-23 19:14:05 +00:00
Jakub Zelenka
0bc6a66a7a Fix bug #77653 (operator displayed instead of the real error message) 2020-02-23 18:29:10 +00:00
Christoph M. Becker
2a76e3a457 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix #79294: ::columnType() may fail after SQLite3Stmt::reset()
2020-02-21 13:37:31 +01:00
Christoph M. Becker
f133f0024e Fix #79294: ::columnType() may fail after SQLite3Stmt::reset()
The fix for feature request #53466 did not properly handle resetting of
the corresponding statement; the problem with this is that the
statement does not know about its result sets.  But even if we could
fix this, the `complete` handling still appears to be brittle, since
the `sqlite3_column_type()`docs[1] state:

| If the SQL statement does not currently point to a valid row, or if
| the column index is out of range, the result is undefined.

Fortunately, we can use `sqlite3_data_count()` instead, since[2]:

| If prepared statement P does not have results ready to return (via
| calls to the sqlite3_column() family of interfaces) then
| sqlite3_data_count(P) returns 0.

Thus, we guard `SQLite3::columnType()` with `sqlite3_data_count()`, and
completely drop updating the `php_sqlite3_result_object.complete`
field, but keep it for ABI BC purposes.

[1] <https://www.sqlite.org/c3ref/column_blob.html>
[2] <https://www.sqlite.org/c3ref/data_count.html>
2020-02-21 13:36:29 +01:00
Nikita Popov
5a5680c25b Don't use asm arithmetic under msan
Clang 9 supports asm goto, so these no longer get automatically
skipped.

(cherry picked from commit 33bf1495b2)
2020-02-21 11:58:52 +01:00
Christoph M. Becker
1c6b084262 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Add test for bug #78569
2020-02-21 10:32:45 +01:00
Christoph M. Becker
ad000a63e8 Add test for bug #78569 2020-02-21 10:31:26 +01:00
Nikita Popov
2b50d905df Update Ubuntu version on Azure
The i386 and community jobs were still on 16.04, update them to
18.04.
2020-02-21 10:12:31 +01:00
Christoph M. Becker
1b2e6cb3f5 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix NEWS [ci skip]
2020-02-20 10:57:41 +01:00
Christoph M. Becker
ab5b6702d7 Fix NEWS [ci skip]
Cosmetics.
2020-02-20 10:55:17 +01:00
Nikita Popov
9d31a42a30 Don't use VLA in mysqlnd auth
We use alloca instead of VLA. This should also allow building
this code on Windows.
2020-02-18 16:17:56 +01:00
Christoph M. Becker
f6fcc5c353 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Remove extra tab in NEWS [ci skip]
2020-02-18 11:10:51 +01:00
Christoph M. Becker
31dd45564c Remove extra tab in NEWS [ci skip] 2020-02-18 11:09:37 +01:00
Remi Collet
9f8c32cced Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  bump version to 7.2.29
2020-02-18 11:01:07 +01:00
Remi Collet
2aecf3aba9 Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  bump version to 7.2.29
2020-02-18 11:00:49 +01:00
Remi Collet
63f6608f89 bump version to 7.2.29 2020-02-18 11:00:28 +01:00
Christoph M. Becker
3090c88f55 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix #79038: PDOStatement::nextRowset() leaks column values
2020-02-17 22:54:16 +01:00
Christoph M. Becker
08073b0658 Fix #79038: PDOStatement::nextRowset() leaks column values
Firstly, we must not rely on `stmt->column_count` when freeing the
driver specific column values, but rather store the column count in
the driver data.  Since the column count is a `short`, 16 bit are
sufficient, so we can store it in reserved bits of `pdo_odbc_stmt`.

Furthermore, we must not allocate new column value storage when the
statement is not executed, but rather when the column value storage has
not been allocated.

Finally, we have to introduce a driver specific `cursor_closer` to
avoid that `::closeCursor()` calls `odbc_stmt_next_rowset()` which then
frees the column value storage, because it may be still needed for
bound columns.
2020-02-17 22:53:02 +01:00
Christoph M. Becker
8db8d66df0 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix NEWS [ci skip]
2020-02-17 19:36:52 +01:00
Christoph M. Becker
16c7c71693 Fix NEWS [ci skip] 2020-02-17 19:35:42 +01:00
Christoph M. Becker
583e7bad79 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Update NEWS [ci skip]
2020-02-17 19:24:39 +01:00
Christoph M. Becker
788065fb8c Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Update NEWS [ci skip]
2020-02-17 19:23:31 +01:00
Christoph M. Becker
5009b9811d Update NEWS [ci skip] 2020-02-17 19:21:51 +01:00
Christoph M. Becker
e33ab23c83 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix # 79171: heap-buffer-overflow in phar_extract_file
  Fix bug #79082 - Files added to tar with Phar::buildFromIterator have all-access permissions
  Fix bug #79221 - Null Pointer Dereference in PHP Session Upload Progress
  Mark bug76348.phpt as online test
  Fix bug #79082 - Files added to tar with Phar::buildFromIterator have all-access permissions
  Fix bug #79221 - Null Pointer Dereference in PHP Session Upload Progress
2020-02-17 19:08:22 +01:00
Christoph M. Becker
2831334bd3 Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Mark bug76348.phpt as online test
  Fix bug #79082 - Files added to tar with Phar::buildFromIterator have all-access permissions
  Fix bug #79221 - Null Pointer Dereference in PHP Session Upload Progress
2020-02-17 19:08:04 +01:00
Christoph M. Becker
e1de11d467 Create a new console for each test worker on Windows
The primary motivation to have each test worker running its own console
is to allow the windows_mb_path tests to run in parallel.  A nice side
effect is that this also prevents changing the code page of the
tester's console window (which can even cause its font to be changed).

To be able to do so, we introduce the `create_new_console` option for
`proc_open()`, which might occasionally be useful for other purposes
than testing.
2020-02-17 18:52:45 +01:00
Dmitry Stogov
54ecf57fe2 Disable instantiation of zero size FFI\CData objects 2020-02-17 12:48:55 +03:00
Christoph M. Becker
b01b1f65e7 Fix # 79171: heap-buffer-overflow in phar_extract_file
We must not access memory outside of the allocated buffer.
2020-02-17 00:20:17 -08:00
Stanislav Malyshev
bbcb8cab8c Fix bug #79082 - Files added to tar with Phar::buildFromIterator have all-access permissions 2020-02-17 00:20:17 -08:00
Stanislav Malyshev
282bfb109e Fix bug #79221 - Null Pointer Dereference in PHP Session Upload Progress 2020-02-17 00:20:17 -08:00
Christoph M. Becker
7df594b943 Fix # 79171: heap-buffer-overflow in phar_extract_file
We must not access memory outside of the allocated buffer.
2020-02-17 00:20:04 -08:00
Stanislav Malyshev
6facfa59a5 Fix bug #79082 - Files added to tar with Phar::buildFromIterator have all-access permissions 2020-02-17 00:19:30 -08:00
Stanislav Malyshev
409965fe1c Fix bug #79221 - Null Pointer Dereference in PHP Session Upload Progress 2020-02-17 00:19:30 -08:00
Christoph M. Becker
73a4c50309 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix #79271: DOMDocumentType::$childNodes is NULL
2020-02-17 09:09:30 +01:00
Christoph M. Becker
0966941130 Fix #79271: DOMDocumentType::$childNodes is NULL
Dom level 2 core, DOM level 3 core and the DOM living standard agree
that `childNodes` always return a `NodeList`, and never `null`.
2020-02-17 09:07:54 +01:00
Nikita Popov
2826364298 Mark bug76348.phpt as online test 2020-02-16 22:40:25 -08:00
Stanislav Malyshev
e5c95234d8 Fix bug #79082 - Files added to tar with Phar::buildFromIterator have all-access permissions 2020-02-16 22:38:38 -08:00
Stanislav Malyshev
d76f7c6c63 Fix bug #79221 - Null Pointer Dereference in PHP Session Upload Progress 2020-02-15 20:52:19 -08:00
Christoph M. Becker
8ec76366d0 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix typo in recent bugfix
2020-02-14 09:23:43 +01:00
Christoph M. Becker
392dada1d6 Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Fix typo in recent bugfix
2020-02-14 09:22:51 +01:00