Stanislav Malyshev
2dc170e25d
More checks for php_strip_tags_ex
2020-01-22 22:37:30 -08:00
Stanislav Malyshev
0f79b1bf30
Fix #79099 : OOB read in php_strip_tags_ex
2020-01-20 21:43:42 -08:00
Christoph M. Becker
600f1f898f
Fix #78814 : strip_tags allows / in tag name => whitelist bypass
...
When normalizing tags to check whether they are contained in the set
of allowable tags, we must not strip slashes, unless they come
immediately after the opening `<`, or immediately before the closing
`>`.
2019-12-02 11:37:25 +01:00
Nikita Popov
6fcde56b03
Fixed bug #78612
2019-09-30 15:06:07 +02:00
Christoph M. Becker
f3ff72e54b
Fix #77937 : preg_match failed
...
On some recent Windows systems, ext\pcre\tests\locales.phpt fails,
because 'pt_PT' is accepted by `setlocale()`, but not properly
supported by the ctype functions, which are used internally by PCRE2 to
build the localized character tables.
Since there appears to be no way to properly check whether a given
locale is fully supported, but we want to minimize BC impact, we filter
out typical Unix locale names, except for a few cases which have
already been properly supported on Windows. This way code like
setlocale(LC_ALL, 'de_DE.UTF-8', 'de_DE', 'German_Germany.1252');
should work like on older Windows systems.
It should be noted that the locale names causing trouble are not (yet)
documented as valid names anyway, see
<https://docs.microsoft.com/en-us/cpp/c-runtime-library/locale-names-languages-and-country-region-strings?view=vs-2019 >.
2019-06-11 08:42:32 +02:00
Nikita Popov
d7b5954f28
Fixed bug #77853
2019-04-08 11:40:50 +02:00
Peter Kokot
902d39a3a7
Trim trailing whitespace in source code files
2018-10-13 14:14:50 +02:00
Xinchen Hui
9a2fc39542
Merge branch 'PHP-7.1' into PHP-7.2
...
* PHP-7.1:
Fixed bug #75781 (substr_count incorrect result)
2018-01-09 16:21:13 +08:00
Xinchen Hui
6da44fefb2
Fixed bug #75781 (substr_count incorrect result)
2018-01-09 16:21:02 +08:00
Xinchen Hui
7a7ec01a49
year++
2018-01-02 12:55:14 +08:00
Xinchen Hui
ccd4716ec7
year++
2018-01-02 12:53:31 +08:00
Dmitry Stogov
9c2a1f52a5
Avoid useless dereferences and separations during paramter passing.
2017-06-19 12:55:59 +03:00
Dmitry Stogov
3a4fcee767
trim() micro-optimization
2017-05-30 17:14:08 +03:00
Dmitry Stogov
dd4a78b631
Don't separate output arguments
2017-05-23 17:18:05 +03:00
Dmitry Stogov
a08723d3d3
Use interned empty and "one char" strings.
2017-05-18 17:59:59 +03:00
Anatol Belski
c698299550
Interned strings unification for TS/NTS
...
Hereby, interned strings are supported in thread safe PHP. The patch
implements two types of interned strings
- interning per process, strings are not freed till process end
- interning per request, strings are freed at request end
There is no runtime interning.
With Opcache, all the permanent iterned strings are copied into SHM on
startup, additional copying into SHM might happen on demand.
2017-03-04 10:39:13 +01:00
Nikita Popov
2634b13e88
Deprecate parse_str() without second argument
2017-02-03 18:52:57 +01:00
Nikita Popov
5537a4e2b8
Merge branch 'PHP-7.1'
2017-02-03 17:55:08 +01:00
Nikita Popov
8660e95b4c
Fixed bug #74041
2017-02-03 17:54:39 +01:00
Stanislav Malyshev
cbc416e8d3
Merge branch 'PHP-7.1'
...
* PHP-7.1:
Fix bug #73648 - integer overflow in substr
2017-01-16 12:14:10 -08:00
Stanislav Malyshev
05f2f730e6
Merge branch 'PHP-7.0' into PHP-7.1
...
* PHP-7.0:
Fix bug #73648 - integer overflow in substr
2017-01-16 12:14:03 -08:00
Stanislav Malyshev
d1d002fc4d
Fix bug #73648 - integer overflow in substr
2017-01-16 12:11:50 -08:00
Joe Watkins
7fd318bc4c
Merge branch 'PHP-7.1'
...
* PHP-7.1:
Fixed bug #72979 money_format stores wrong length on AIX
2017-01-09 05:33:48 +00:00
Joe Watkins
bf6eb65673
Merge branch 'PHP-7.0' into PHP-7.1
...
* PHP-7.0:
Fixed bug #72979 money_format stores wrong length on AIX
2017-01-09 05:32:50 +00:00
Joe Watkins
8dd523a216
Fixed bug #72979 money_format stores wrong length on AIX
2017-01-09 05:31:41 +00:00
Sammy Kaye Powers
dac6c639bb
Update copyright headers to 2017
2017-01-04 11:23:42 -06:00
Sammy Kaye Powers
478f119ab9
Update copyright headers to 2017
2017-01-04 11:14:55 -06:00
Sammy Kaye Powers
9e29f841ce
Update copyright headers to 2017
2017-01-02 09:30:12 -06:00
Sara Golemon
a23f08a33c
Use new param API in standard
2016-12-30 17:28:55 -08:00
Sara Golemon
331dcf08df
Use new param API in standard/string
2016-12-30 16:40:45 -08:00
Stanislav Malyshev
c4ebe4da04
Merge branch 'PHP-7.1'
...
* PHP-7.1:
Add more mbfl string size checks (bug #73505 )
2016-11-26 14:48:57 -08:00
Stanislav Malyshev
dd7eee0609
Merge branch 'PHP-7.0' into PHP-7.1
...
* PHP-7.0:
Add more mbfl string size checks (bug #73505 )
2016-11-26 14:48:50 -08:00
Stanislav Malyshev
58cdd03d92
Merge branch 'PHP-5.6' into PHP-7.0
...
* PHP-5.6:
Add more mbfl string size checks (bug #73505 )
2016-11-26 14:48:40 -08:00
Stanislav Malyshev
5ee02b207d
Add more mbfl string size checks (bug #73505 )
2016-11-26 14:47:58 -08:00
Levi Morrison
5ff2990cb3
Refactor: rename variables to match documentation
...
Rename 'arr' to 'pieces'
Rename 'delim' to 'glue'
2016-11-20 14:54:06 -07:00
Kalle Sommer Nielsen
2104bea5d7
Remove Netware support
...
If this does not break the Unix system somehow, I'll be amazed. This should get most of it out, apologies for any errors this may cause on non-Windows ends which I cannot test atm.
2016-11-12 11:20:01 +01:00
Andrea Faulds
1a512eed44
Move utf8_encode and utf8_decode to ext/standard
2016-10-17 15:39:02 +01:00
Anatol Belski
0ca15cbeba
reduce size of stream struct
...
32 bytes are spared on 64-bit build
2016-10-05 22:53:21 +02:00
Stanislav Malyshev
8ea01d5f19
Apparently negative wordwrap is a thing and should work as length = 0.
...
I'll leave it as is for now.
2016-10-03 19:17:42 -07:00
Stanislav Malyshev
631173aa5c
Really fix bug #73017
2016-10-03 18:07:21 -07:00
Anatol Belski
2088e3eb45
Merge branch 'PHP-7.0' into PHP-7.1
...
* PHP-7.0:
pick up the safe alloc pieces from 19866fb76c
2016-09-13 11:51:17 +02:00
Anatol Belski
c403b30291
pick up the safe alloc pieces from
...
19866fb76c
2016-09-13 11:50:18 +02:00
Stanislav Malyshev
65c8caafa8
Also fix overflow in wordwrap
2016-09-12 21:04:23 -07:00
Stanislav Malyshev
19866fb76c
Fix various int size overflows.
...
Add function for detection of string zvals with length that does not fit
INT_MAX.
2016-09-12 21:04:23 -07:00
Andrea Faulds
fc5497cb92
Merge branch 'PHP-7.0' into PHP-7.1
2016-09-11 22:46:20 +01:00
Andrea Faulds
d690014bf3
Remove zpp fallback code (always use Fast ZPP)
...
Squashed commit of the following:
commit 3e27fbb3d2
Author: Andrea Faulds <ajf@ajf.me >
Date: Sun Sep 11 19:14:37 2016 +0100
Keep dummy FAST_ZPP macro for compatibility
commit 8a7cfd00de
Author: Andrea Faulds <ajf@ajf.me >
Date: Mon Sep 5 22:36:03 2016 +0100
Remove FAST_ZPP macro and plain zpp fallback code
2016-09-11 22:44:46 +01:00
Anatol Belski
50c5d13d26
Merge branch 'PHP-7.0' into PHP-7.1
...
* PHP-7.0:
fix leak
2016-08-29 15:44:13 +02:00
Anatol Belski
d80a317c0b
fix leak
2016-08-29 15:43:10 +02:00
Christoph M. Becker
ae3b2078ea
Fix #72823 : strtr out-of-bound access
...
If php_strtr_array_prepare_repls() reports pattern_len == 0, we return
early to avoid OOB accesses, and because there is nothing to replace anyway.
2016-08-13 11:40:33 +02:00
Nikita Popov
e52c1f3ca9
Merge branch 'PHP-7.0' into PHP-7.1
2016-08-07 18:50:27 +02:00