Commit graph

132415 commits

Author SHA1 Message Date
Jakub Zelenka
4c77a397d0
Update NEWS with entries for security fixes 2025-07-01 19:00:26 +03:00
Ahmed Lekssays
97c51c0e3d
Fix GHSA-453j-q27h-5p8x
Libxml versions prior to 2.13 cannot correctly handle a call to
xmlNodeSetName() with a name longer than 2G. It will leave the node
object in an invalid state with a NULL name. This later causes a NULL
pointer dereference when using the name during message serialization.

To solve this, implement a workaround that resets the name to the
sentinel name if this situation arises.

Versions of libxml of 2.13 and higher are not affected.

This can be exploited if a SoapVar is created with a fully qualified
name that is longer than 2G. This would be possible if some application
code uses a namespace prefix from an untrusted source like from a remote
SOAP service.

Co-authored-by: Niels Dossche <7771979+nielsdos@users.noreply.github.com>
2025-07-01 18:24:47 +03:00
Jakub Zelenka
339ff58f57
Fix GHSA-hrwm-9436-5mv3: pgsql escaping no error checks
This adds error checks for escape function is pgsql and pdo_pgsql
extensions. It prevents possibility of storing not properly escaped
data which could potentially lead to some security issues.
2025-07-01 18:24:44 +03:00
Jakub Zelenka
0c1971387d
Fix GHSA-3cr5-j632-f35r: Null byte in hostnames
This fixes stream_socket_client() and fsockopen().

Specifically it adds a check to parse_ip_address_ex and it also makes
sure that the \0 is not ignored in fsockopen() hostname formatting.
2025-07-01 18:24:41 +03:00
Shivam Mathur
c5f1ae38a2
Merge branch 'PHP-8.1' into PHP-8.2 2025-06-30 20:01:49 +05:30
Shivam Mathur
8ddc210bf7
Fix PHP_BUILD_CRT input in the nightly workflow (#18982) 2025-06-30 20:00:25 +05:30
Arnaud Le Blanc
05a44d2813
Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Add FreeBSD ZTS nightly build
2025-06-30 11:47:49 +02:00
Arnaud Le Blanc
85522c0d48
Add FreeBSD ZTS nightly build
Closes GH-18959
2025-06-30 11:47:26 +02:00
Shivam Mathur
ea6a7a9725
Fix CI for windows-2022
This is a continuation of GH-18927 to fix CI for windows-2022
2025-06-25 03:17:32 +05:30
Shivam Mathur
91f2458020
Merge branch 'PHP-8.1' into PHP-8.2 2025-06-25 02:00:11 +05:30
Shivam Mathur
6233dc6210
Switch to windows-2022 in CI (#18927)
* Switch to windows-2022 in CI

windows-2019 runner will be dropped by GitHub on 2025-06-30.

* xfail test cases that fail on windows-2022
2025-06-25 01:57:07 +05:30
Ilija Tovilo
2ecdde0045
Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Remove bug61371 test
2025-06-20 22:43:18 +02:00
Ilija Tovilo
391bd2a48f
Remove bug61371 test
These tests attempt to test that no memory is leaked for stream calls. However,
it is incorrect to assume the memory will not increase for other reasons, e.g.
when growing resource buffers, for the output buffer, etc. This was discovered
through 9cacc57350 with USE_TRACKED_ALLOC=1, but
this can also fail with USE_ZEND_ALLOC=1 when increasing loop iterations.
2025-06-20 22:42:03 +02:00
Ilija Tovilo
7841c8a3df
Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Track heap->real_size for USE_TRACKED_ALLOC
2025-06-20 14:49:47 +02:00
Ilija Tovilo
9cacc57350
Track heap->real_size for USE_TRACKED_ALLOC
real_size is returned by memory_get_usage(true), which previously returned 0.
Discovered in Symfony ConsumeMessagesCommandTest::testRunWithMemoryLimit()
through nightly.

Closes GH-18880
2025-06-20 14:48:47 +02:00
Ilija Tovilo
25d21f4161
Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Use --ignore-platform-req=php+ in community build
2025-04-28 17:10:58 +02:00
Ilija Tovilo
0a42e6fbc5
Use --ignore-platform-req=php+ in community build
--ignore-platform-reqs may accidentally install versions of dependencies
that no longer support the given PHP version. --ignore-platform-req=php+
will only suppress errors for new PHP version but not change behavior
for older versions. Thanks to Tim for the hint.

Also skip the Laravel build for PHP 8.1, which is no longer supported on
Laravel's default branch.
2025-04-28 17:04:54 +02:00
Ilija Tovilo
86ac21c3cd
Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  [skip ci] Increase tolerance for cve-2014-3538 tests
2025-04-24 11:27:16 +02:00
Ilija Tovilo
b5081339e9
[skip ci] Increase tolerance for cve-2014-3538 tests
These regularly fail with "Failed, time=1.5x".
2025-04-24 11:26:17 +02:00
Ilija Tovilo
8e533496b0
Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  backporting C++17 detection support for recent icu4c releases.
  Drop tidyp from FreeBSD build
2025-04-23 11:01:23 +02:00
David Carlier
3fdd3ed9f7
backporting C++17 detection support for recent icu4c releases. 2025-04-23 11:01:11 +02:00
Ilija Tovilo
35936bfa79
Drop tidyp from FreeBSD build
It looks like it's no longer supported. We don't test tidy on FreeBSD
anyway.
2025-04-23 11:00:24 +02:00
Ilija Tovilo
8b27c14aa9
Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  [skip ci] Restrict on-push freebsd build to main repo
2025-04-03 13:02:51 +02:00
Ilija Tovilo
7a3383b482
[skip ci] Restrict on-push freebsd build to main repo
The same applies to all other push jobs, it was just forgotten here.
2025-04-03 13:01:59 +02:00
Ilija Tovilo
d4c548cf42
Backport intl test changes for ICU 77
See GH-18125
See 8823f89a32
2025-03-24 15:07:14 +01:00
Jakub Zelenka
e144c58fb2
Merge branch 'PHP-8.1' into PHP-8.2 2025-03-13 22:25:53 +01:00
Jakub Zelenka
70c2ebb698
Fix typo in GHSA-hgf5-96fm-v528 NEWS entry 2025-03-13 22:24:49 +01:00
Pierrick Charron
d9c0a49cba
[skip ci] Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  [skip ci] Fix invalid release date of 8.1.1
2025-03-13 13:47:22 -04:00
Pierrick Charron
c62523666c
[skip ci] Fix invalid release date of 8.1.1 2025-03-13 13:45:08 -04:00
Ilija Tovilo
f390425db3
Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Fix flaky connection count in mysqli test
2025-03-13 16:46:03 +01:00
Ilija Tovilo
00ebd2d7f2
Fix flaky connection count in mysqli test
Use connection ID instead of count to check whether we're using a
persistent connection. This allows the test to be run in parallel with
the other tests, but also protects against the possibility that some
other service connects to the mysql server.

Closes GH-18040
2025-03-13 16:40:33 +01:00
Pierrick Charron
b617b0832c
PHP-8.2 is now for PHP 8.2.29-dev 2025-03-11 18:31:23 -04:00
Ben Ramsey
b6d61f5ec0
Merge branch 'PHP-8.1' into PHP-8.2 2025-03-11 16:42:29 -05:00
Ben Ramsey
858c378930
PHP-8.1 is now for PHP 8.1.33-dev 2025-03-11 16:34:23 -05:00
Jakub Zelenka
4af1830356
Merge branch 'PHP-8.1' into PHP-8.2 2025-03-11 21:57:33 +01:00
Jakub Zelenka
74d548bf58
Update NEWS with entries for security fixes 2025-03-11 21:50:17 +01:00
Niels Dossche
0e715e71d9
Fix GHSA-wg4p-4hqh-c3g9 2025-03-11 21:50:17 +01:00
Tim Düsterhus
b6004a043c
Fix GHSA-p3x9-6h7p-cgfc: libxml streams wrong content-type on redirect
libxml streams use wrong content-type header when requesting a
redirected resource.
2025-03-11 21:50:17 +01:00
Jakub Zelenka
41d49abbd9
Fix GHSA-hgf5-96fm-v528: http user header check of crlf 2025-03-11 21:50:16 +01:00
Jakub Zelenka
ac1a054bb3
Fix GHSA-52jp-hrpf-2jff: http redirect location truncation
It converts the allocation of location to be on heap instead of stack
and errors if the location length is greater than 8086 bytes.
2025-03-11 21:50:16 +01:00
Jakub Zelenka
0548c4c175
Fix GHSA-pcmh-g36c-qc44: http headers without colon
The header line must contain colon otherwise it is invalid and it needs
to fail.

Reviewed-by: Tim Düsterhus <tim@tideways-gmbh.com>
2025-03-11 21:50:16 +01:00
Jakub Zelenka
d20b4c97a9
Fix GHSA-ghsa-v8xr-gpvj-cx9g: http header folding
This adds HTTP header folding support for HTTP wrapper response
headers.

Reviewed-by: Tim Düsterhus <tim@tideways-gmbh.com>
2025-03-11 21:50:16 +01:00
Niels Dossche
b5471300d2
Fix test GH-16535 for libxml2 2.14 2025-03-10 20:23:23 +01:00
Niels Dossche
239b01db7c
Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Fix tests for libxml2 2.14
2025-03-10 20:22:27 +01:00
Niels Dossche
f209eb448e
Fix tests for libxml2 2.14
See GH-18009.
2025-03-10 20:22:11 +01:00
Ilija Tovilo
9842508580
Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Increase CircleCI no_output_timeout
2025-03-10 13:37:46 +01:00
Ilija Tovilo
ee7fcf2a07
Increase CircleCI no_output_timeout
Closes GH-18002
2025-03-10 13:37:24 +01:00
Ilija Tovilo
d6172ce37a
[skip ci] Ignore snmp test on asan that frequently times out
Not sure why this happens only on master.

Cherry-picked from becf207d0c
No longer happens just on master. ;)
2025-03-10 11:24:27 +01:00
Ilija Tovilo
084446418f
Merge branch 'PHP-8.1' into PHP-8.2
* PHP-8.1:
  Suppress snmp lib memory leak, skip ASAN tests
2025-03-08 16:11:33 +01:00
Ilija Tovilo
b0858427aa
Suppress snmp lib memory leak, skip ASAN tests
I don't know enough about this library to fix those :(

Cherry-picked from:
be4db6b550
ba1d9d0ab2
2025-03-08 16:10:59 +01:00