1
0
mirror of https://github.com/php/php-src.git synced 2026-04-26 01:18:19 +02:00
Commit Graph

51003 Commits

Author SHA1 Message Date
Nikita Popov 021bb35aec Merge branch 'PHP-7.3' into PHP-7.4 2019-06-21 15:08:12 +02:00
Nikita Popov 66e4b78519 Merge branch 'PHP-7.2' into PHP-7.3 2019-06-21 15:07:59 +02:00
Nikita Popov 99f3e0f0ed Fix PKCS12 leak in openssl 2019-06-21 15:07:37 +02:00
Nikita Popov c939a67866 Fix d leak in ecc openssl_pkey_new 2019-06-21 15:07:32 +02:00
Nikita Popov dfe6f0c1c6 Fix netscape spki leak in openssl 2019-06-21 15:07:26 +02:00
Nikita Popov a0da2fb2b7 Fix X509 leak in openssl_pkcs7_verify() 2019-06-21 15:07:18 +02:00
Nikita Popov e0bafc6da4 Fix CSR leaks in openssl 2019-06-21 15:07:10 +02:00
Nikita Popov 90cb3743be Free cert in php_openssl_load_stream_cafile()
X509_STORE_add_cert() increments the refcount of the cert, so we
should free it here.
2019-06-21 15:07:00 +02:00
Nikita Popov 1de7c4b919 Fix memory leaks in browscap parsing
Also make the interning a bit more efficient, no need to check for
a "real" interned string every time, we can also store that in the
HT.
2019-06-21 12:56:37 +02:00
Nikita Popov f781c8f110 Fix leak in bcpowmod 2019-06-21 12:56:28 +02:00
Nikita Popov e7ef2b52db Merge branch 'PHP-7.3' into PHP-7.4 2019-06-21 12:56:12 +02:00
Nikita Popov 414db07bdb Merge branch 'PHP-7.2' into PHP-7.3 2019-06-21 12:55:12 +02:00
Niklas Keller fea9f93166 Fix memory leak in TLS matches_san_list 2019-06-21 12:54:30 +02:00
Nikita Popov 8227e0f747 Avoid ub in shift overflow check
Also fix an off-by-one error. While 1 << 63 overflows, -1 << 63 does
not.
2019-06-21 10:24:27 +02:00
Christoph M. Becker 81fd113506 Support TGA reading
We add PHP bindings for libgd's features to read TGA files, which are
available as of libgd 2.1.0.

As PHP's bundled libgd doesn't yet include the respective features of the
external libgd, we add these.

Since TGA has no easily recognizable file signature, we don't add TGA
support for imagecreatefromstring() or getimagesize() and friends.
2019-06-20 23:40:51 +02:00
Christoph M. Becker 2b4fc9eb9c Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fix #78189: file cache strips last character of uname hash
2019-06-20 18:01:02 +02:00
Christoph M. Becker a85254b898 Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Fix #78189: file cache strips last character of uname hash
2019-06-20 17:59:59 +02:00
Christoph M. Becker fcd6f2de60 Fix #78189: file cache strips last character of uname hash
We must not forget to increase `len` by one to cater to the directory
separator.
2019-06-20 17:58:32 +02:00
Nikita Popov 59974000eb Remove leftover check
This is checked below now in a way that handles misaligned pointers.
2019-06-20 17:24:22 +02:00
Nikita Popov dd6d471834 Handle misaligned ifreq on macos 2019-06-20 17:24:16 +02:00
Nikita Popov d80f0ff6c0 Handle gr_mem misalignment on macos 2019-06-20 17:24:06 +02:00
Christoph M. Becker ecae9100dc Rename test file to reflect the appropriate ticket number 2019-06-20 16:54:17 +02:00
Nikita Popov 26ac6cb6be Handle gethostbyname misalignment on macos 2019-06-20 16:22:40 +02:00
Nikita Popov 27d3373496 SOAP: Avoid indexing into null pointer 2019-06-20 16:22:34 +02:00
Nikita Popov f127d77eef FFI: Use signed arithmetic for pointer offset
offset can be negative here, using signed arithmetic avoids ubsan
warnings.
2019-06-20 16:22:26 +02:00
Nikita Popov d4de127dd8 In php_needle_char() use well-defined double->integer cast
...by going through zval_get_long(). Generally out of range double
casts are undefined.
2019-06-20 16:22:10 +02:00
Nikita Popov e8ae19223c Avoid address calculation overflow 2019-06-20 16:22:04 +02:00
Remi Collet 961935fde2 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  fix test for Windows and for parallel run
2019-06-20 11:59:04 +02:00
Remi Collet 676b564f43 Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  fix test for Windows and for parallel run
2019-06-20 11:58:49 +02:00
Remi Collet d8202bf917 fix test for Windows and for parallel run 2019-06-20 11:58:32 +02:00
Remi Collet 522cf62906 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  improve test clean section
  move NEWS entry
2019-06-20 11:52:25 +02:00
Remi Collet d7597f73cc Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  improve test clean section
2019-06-20 11:51:51 +02:00
Remi Collet b3cfeda3c7 improve test clean section 2019-06-20 11:51:18 +02:00
Nikita Popov e162a1c02e Fix maybe uninit warning 2019-06-20 10:35:22 +02:00
Remi Collet fa70aedf03 Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  add test for #78185
2019-06-20 10:28:26 +02:00
Remi Collet a197dc72c3 Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  add test for #78185
2019-06-20 10:28:00 +02:00
Remi Collet 63f2d88088 add test for #78185 2019-06-20 10:27:33 +02:00
Nikita Popov 4488475a3e imagecolorallocate(): Check that RGB components are in-range
Instead of letting them bleed over into other components.
2019-06-20 10:09:54 +02:00
Nikita Popov 117c7b3f65 Avoid overflow in mul range calculation
By using ZEND_SIGNED_MULTIPLY_LONG, which already implemented
efficient overflow checking logic.
2019-06-20 09:57:55 +02:00
Nikita Popov 3a97b8b4f9 Backport "Avoid UB in overflow checks"
Cherry-pick of bb940d9969 without
the JIT parts.
2019-06-20 09:51:05 +02:00
Nikita Popov ccfe6c862a Avoid memset/memcpy null ub in block pass
The arena allocator has no problem with zero-size allocations (and
will just return the same pointer for each in this case), so just
do that to avoid null pointers.
2019-06-20 09:49:07 +02:00
Dmitry Stogov 05c8f1ff2e Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
  Fixed bug #78185 (File cache no longer works)
2019-06-20 09:07:39 +03:00
Dmitry Stogov 35acda856a Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Fixed bug #78185 (File cache no longer works)
2019-06-20 09:05:50 +03:00
Dmitry Stogov cd6a6e4cf2 Fixed bug #78185 (File cache no longer works) 2019-06-20 09:04:14 +03:00
Nikita Popov 8743d5e99a Avoid signed shift ub in php_sdl 2019-06-19 17:27:09 +02:00
Nikita Popov 608097a901 Fix various instances of memcpy null ub 2019-06-19 17:27:09 +02:00
Nikita Popov 7cbd4f31c4 Remove copy argument from php_glob_stream_get_path/pattern
This is unused, and shouldn't be part of the API.
2019-06-19 17:27:09 +02:00
Nikita Popov 9b3b07cd26 Suppress shift UB in gd_itofx()
There doesn't seem to be a corresponding upstream fix for this.
2019-06-19 17:27:09 +02:00
Andrey Hristov 10afeead62 Merge branch 'PHP-7.4' of https://git.php.net/push/php-src into PHP-7.4 2019-06-19 18:17:35 +03:00
Nikita Popov 555d68be10 Fix shift UB in hash_snefru 2019-06-19 15:55:56 +02:00