Commit graph

2326 commits

Author SHA1 Message Date
Jakub Zelenka
b60f9bf27a
Merge branch 'PHP-8.4' 2025-01-19 20:39:27 +01:00
Jakub Zelenka
b3c297d88f
Merge branch 'PHP-8.3' into PHP-8.4 2025-01-19 20:38:51 +01:00
Jakub Zelenka
191e16b703
Merge branch 'PHP-8.2' into PHP-8.3 2025-01-19 20:38:19 +01:00
Jakub Zelenka
5d632230ba
Merge branch 'PHP-8.1' into PHP-8.2 2025-01-19 20:37:53 +01:00
Jakub Zelenka
235d1b14a3
Fix GH-17499: mysqli flaky test: ghsa-h35g-vwh6-m678-stmt-row-string 2025-01-19 20:36:12 +01:00
Kamil Tekiela
a883082f87
Improve mysqli_thread_id test (#17515) 2025-01-19 17:54:01 +00:00
Kamil Tekiela
d6d23fe002
Improve bug74021 test (#17514) 2025-01-19 17:53:54 +00:00
Kamil Tekiela
6919b95010
Ensure charset in tests (#17513) 2025-01-19 17:53:37 +00:00
Kamil Tekiela
b47d17188b
Improve mysqli test 066.phpt (#17022) 2024-12-10 02:11:43 +01:00
Jakub Zelenka
8ef9302c31
Merge branch 'PHP-8.4' 2024-12-09 23:38:20 +01:00
Jakub Zelenka
7d77082dca
Merge branch 'PHP-8.3' into PHP-8.4 2024-12-09 23:37:31 +01:00
Jakub Zelenka
5168a2f5ba
Merge branch 'PHP-8.2' into PHP-8.3 2024-12-09 23:37:03 +01:00
Jakub Zelenka
d18768e231
Merge branch 'PHP-8.1' into PHP-8.2 2024-12-09 23:36:36 +01:00
Jakub Zelenka
39c292b1eb
Use empheral port for mysqli fake server tests 2024-12-09 23:34:50 +01:00
Niels Dossche
e36dea065d
Merge branch 'PHP-8.4'
* PHP-8.4:
  Fix some MariaDB test failures
2024-12-02 19:22:27 +01:00
Niels Dossche
6753c55bdb
Merge branch 'PHP-8.3' into PHP-8.4
* PHP-8.3:
  Fix some MariaDB test failures
2024-12-02 19:21:37 +01:00
Niels Dossche
51e0920e45
Merge branch 'PHP-8.2' into PHP-8.3
* PHP-8.2:
  Fix some MariaDB test failures
2024-12-02 19:21:03 +01:00
Niels Dossche
1a6f8a0b79
Fix some MariaDB test failures
Allow other wording too such that these mysqli tests pass.

Closes GH-17004.
2024-12-02 19:20:54 +01:00
Jakub Zelenka
b0b876d076
Merge branch 'PHP-8.4' 2024-11-24 23:50:09 +01:00
Jakub Zelenka
a5db8b3fe5
Merge branch 'PHP-8.3' into PHP-8.4 2024-11-24 23:49:55 +01:00
Jakub Zelenka
ac57b81c7c
Merge branch 'PHP-8.2' into PHP-8.3 2024-11-24 23:49:29 +01:00
Jakub Zelenka
173175badd
Merge branch 'PHP-8.1' into PHP-8.2 2024-11-24 23:49:04 +01:00
Jakub Zelenka
eb951b3d11
Increase MySQLi fake server read timeout for ASAN job 2024-11-24 23:48:27 +01:00
Jakub Zelenka
59ed9cebaa
Merge branch 'PHP-8.4' 2024-11-24 20:16:26 +01:00
Jakub Zelenka
17c93e6c51
Merge branch 'PHP-8.3' into PHP-8.4 2024-11-24 20:16:01 +01:00
Jakub Zelenka
b707f42119
Merge branch 'PHP-8.2' into PHP-8.3 2024-11-24 20:15:02 +01:00
Jakub Zelenka
06082671f4
Merge branch 'PHP-8.1' into PHP-8.2 2024-11-24 20:14:29 +01:00
Jakub Zelenka
51f5539914
Change port for mysqli fake server auth message test 2024-11-24 20:13:47 +01:00
Jakub Zelenka
c70b97d8eb
Make MySQLnd protocol stmt test work on 32bit
Closes GH-16869.
2024-11-20 13:52:53 +01:00
Jakub Zelenka
4b211a7769
Merge branch 'PHP-8.4' 2024-11-20 11:14:32 +01:00
Jakub Zelenka
7c96af42b7
Merge branch 'PHP-8.3' into PHP-8.4 2024-11-20 11:14:04 +01:00
Jakub Zelenka
ffff27f734
Merge branch 'PHP-8.2' into PHP-8.3 2024-11-20 11:12:19 +01:00
Jakub Zelenka
a21e48a93a
Make MySQLnd protocol stmt test work on 32bit 2024-11-20 11:06:43 +01:00
Jakub Zelenka
c595455300
Fix GHSA-h35g-vwh6-m678: Mysqlnd - various heap buffer over-reads
This fixes issues causing buffer over-read that leak heap content:
- RESP packet field default left over for COM_LIST
- RESP packet upsert filename
- OK packet message
- RESP packet for stmt row data
  - ps_fetch_from_1_to_8_bytes
  - ps_fetch_float
  - ps_fetch_double
  - ps_fetch_time
  - ps_fetch_date
  - ps_fetch_datetime
  - ps_fetch_string
  - ps_fetch_bit
- RESP packet for query row data (just possible overflow on 32bit)

It also adds various protocol tests using a new fake server.
2024-11-20 11:06:26 +01:00
Jakub Zelenka
2f5aa9f9d1
Fix GHSA-h35g-vwh6-m678: Mysqlnd - various heap buffer over-reads
This fixes issues causing buffer over-read that leak heap content:
- RESP packet field default left over for COM_LIST
- RESP packet upsert filename
- OK packet message
- RESP packet for stmt row data
  - ps_fetch_from_1_to_8_bytes
  - ps_fetch_float
  - ps_fetch_double
  - ps_fetch_time
  - ps_fetch_date
  - ps_fetch_datetime
  - ps_fetch_string
  - ps_fetch_bit
- RESP packet for query row data (just possible overflow on 32bit)

It also adds various protocol tests using a new fake server.
2024-11-17 19:30:13 +01:00
DanielEScherzer
7a8b1f683b
Generated arginfo header files: use known strings for prop names when… (#15751)
Instead of allocating, using, and then releasing a zend_string for every
property name unconditionally, only do so when the minimum supported version of
PHP does not have that string in its known strings (ZEND_KNOWN_STRINGS). If the
string is already known, just use the known version directly. This is already
done for some non-generated class registrations, e.g. in
`zend_enum_register_props()`.
2024-09-30 13:22:34 +02:00
DanielEScherzer
db545767e5
Rename ZEND_STR_DEPRECATED to ZEND_STR_DEPRECATED_CAPITALIZED (#15831)
To match other capitalized strings like `ZEND_STR_UNKNOWN_CAPITALIZED` and
`ZEND_STR_ARRAY_CAPITALIZED`. Since this known string was only added in PHP
8.4, no backwards compatibility alias is needed.
2024-09-10 22:45:23 +01:00
DanielEScherzer
53cb89670c
Generated arginfo header files: remove empty zend_function_entry arrays (#15705)
When a class (or enum) has no methods, rather than using an array that only
contains `ZEND_FE_END`, use `NULL` for the functions. The implementation of
class registration for internal classes, `do_register_internal_class()` in
zend_API.c, already skips classes where the functions are `NULL`. By removing
these unneeded arrays, we can reduce the size of the header files, while also
removing an unneeded call to zend_register_functions() for each internal class
with no extra methods.
2024-09-03 23:19:53 +02:00
Peter Kokot
7e1e450bb9
Autotools: Remove redundant double quotes (#15634) 2024-08-29 15:17:03 +02:00
^_^
555b603d23
mysqlnd: support ER_CLIENT_INTERACTION_TIMEOUT (#13618) 2024-08-26 12:52:26 +09:00
Kamil Tekiela
2446500d97 Remove unsupported mysqlnd options 2024-08-25 10:32:50 +02:00
Kamil Tekiela
082b964dfa Remove ifdefs from stub file 2024-08-25 10:32:50 +02:00
Máté Kocsis
8d12f666ae
Fix registration of internal readonly child classes (#15459)
Currently, internal classes are registered with the following code:

INIT_CLASS_ENTRY(ce, "InternalClass", class_InternalClass_methods);
class_entry = zend_register_internal_class_ex(&ce, NULL);
class_entry->ce_flags |= ...;

This has worked well so far, except if InternalClass is readonly. It is because some inheritance checks are run by zend_register_internal_class_ex before ZEND_ACC_READONLY_CLASS is added to ce_flags.

The issue is fixed by adding a zend_register_internal_class_with_flags() zend API function that stubs can use from now on. This function makes sure to add the flags before running any checks. Since the new API is not available in lower PHP versions, gen_stub.php has to keep support for the existing API for PHP 8.3 and below.
2024-08-24 12:36:54 +02:00
Peter Kokot
6351468a5e
Autotools: Replace break 2 with break (#15563)
As there is not nested loop here, a single break can do as well.
2024-08-24 00:49:13 +02:00
Gina Peter Banyard
15ea82da2b
ext/mysqli: Minor clean-up (#15526)
It is likely that more functions should have their return type changed to `enum_func_status` and have the return value checked against `PASS`/`FAIL` rather than assuming the inverse of boolean logic.
2024-08-22 12:34:57 +01:00
Gina Peter Bnayard
5853cdb73d Use "must not" instead of "cannot" wording 2024-08-21 21:12:17 +01:00
Gina Peter Bnayard
e7c4d54d65 Use new helper function for "cannot be empty" ValueErrors 2024-08-21 21:12:17 +01:00
Kamil Tekiela
0775b99d5e Fix mysqli_fetch_field_types.phpt 2024-08-21 12:14:47 +02:00
Kamil Tekiela
c290996db6 Remove MYSQLI_TYPE_INTERVAL constant 2024-08-21 12:14:47 +02:00
Kamil Tekiela
69d9c12df6
Fix mysqli_stmt_get_result.phpt (#15495) 2024-08-21 01:11:31 +02:00