mirror of
https://github.com/bdnugget/php-src.git
synced 2026-11-08 01:37:30 +00:00
Compare commits
9
Commits
php-7.2.31
...
php-5.5.23
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7fb06ce4d3 | ||
|
|
4a8d8b4154 | ||
|
|
94e7638d9a | ||
|
|
2256ee4fa7 | ||
|
|
b690be4d22 | ||
|
|
048e0d58bf | ||
|
|
93b8970b33 | ||
|
|
10d61a3a3e | ||
|
|
e14401deca |
No files matched your search
@@ -1,6 +1,6 @@
|
||||
PHP NEWS
|
||||
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||
?? ??? 2015, PHP 5.5.23
|
||||
19 Mar 2015, PHP 5.5.23
|
||||
|
||||
- Core:
|
||||
. Fixed bug #69174 (leaks when unused inner class use traits precedence).
|
||||
@@ -18,6 +18,16 @@ PHP NEWS
|
||||
. Fixed bug #68166 (Exception with invalid character causes segv). (Rasmus)
|
||||
. Fixed bug #69141 (Missing arguments in reflection info for some builtin
|
||||
functions). (kostyantyn dot lysyy at oracle dot com)
|
||||
. Fixed bug #68976 (Use After Free Vulnerability in unserialize()). (Stas)
|
||||
. Fixed bug #69134 (Per Directory Values overrides PHP_INI_SYSTEM
|
||||
configuration options). (Anatol Belski)
|
||||
. Fixed bug #69207 (move_uploaded_file allows nulls in path). (Stas)
|
||||
|
||||
- CGI:
|
||||
. Fixed bug #69015 (php-cgi's getopt does not see $argv). (Laruence)
|
||||
|
||||
- CLI:
|
||||
. Fixed bug #67741 (auto_prepend_file messes up __LINE__). (Reeze Xia)
|
||||
|
||||
- cURL:
|
||||
. Fixed bug #69088 (PHP_MINIT_FUNCTION does not fully initialize cURL on
|
||||
@@ -25,6 +35,12 @@ PHP NEWS
|
||||
. Add CURLPROXY_SOCKS4A and CURLPROXY_SOCKS5_HOSTNAME constants if supported
|
||||
by libcurl. (Linus Unneback)
|
||||
|
||||
- Ereg:
|
||||
. Fixed bug #69248 (heap overflow vulnerability in regcomp.c). (Stas)
|
||||
|
||||
- FPM:
|
||||
. Fixed bug #68822 (request time is reset too early). (honghu069 at 163 dot com)
|
||||
|
||||
- ODBC:
|
||||
. Fixed bug #68964 (Allowed memory size exhausted with odbc_exec). (Anatol)
|
||||
|
||||
@@ -54,14 +70,9 @@ PHP NEWS
|
||||
. Fixed bug #68557 (RecursiveDirectoryIterator::seek(0) broken after
|
||||
calling getChildren()). (Julien)
|
||||
|
||||
- CGI:
|
||||
. Fixed bug #69015 (php-cgi's getopt does not see $argv). (Laruence)
|
||||
|
||||
- CLI:
|
||||
. Fixed bug #67741 (auto_prepend_file messes up __LINE__). (Reeze Xia)
|
||||
|
||||
- FPM:
|
||||
. Fixed bug #68822 (request time is reset too early). (honghu069 at 163 dot com)
|
||||
- ZIP:
|
||||
. Fixed bug #69253 (ZIP Integer Overflow leads to writing past heap
|
||||
boundary) (CVE-2015-2331). (Stas)
|
||||
|
||||
19 Feb 2015, PHP 5.5.22
|
||||
|
||||
|
||||
+1
-1
@@ -120,7 +120,7 @@ int zend_sprintf(char *buffer, const char *format, ...);
|
||||
PHP_MAJOR_VERSION=5
|
||||
PHP_MINOR_VERSION=5
|
||||
PHP_RELEASE_VERSION=23
|
||||
PHP_EXTRA_VERSION="-dev"
|
||||
PHP_EXTRA_VERSION=""
|
||||
PHP_VERSION="$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION"
|
||||
PHP_VERSION_ID=`expr [$]PHP_MAJOR_VERSION \* 10000 + [$]PHP_MINOR_VERSION \* 100 + [$]PHP_RELEASE_VERSION`
|
||||
|
||||
|
||||
@@ -117,7 +117,15 @@ int cflags;
|
||||
(NC-1)*sizeof(cat_t));
|
||||
if (g == NULL)
|
||||
return(REG_ESPACE);
|
||||
p->ssize = len/(size_t)2*(size_t)3 + (size_t)1; /* ugh */
|
||||
{
|
||||
/* Patched for CERT Vulnerability Note VU#695940, Feb 2015. */
|
||||
size_t new_ssize = len/(size_t)2*(size_t)3 + (size_t)1; /* ugh */
|
||||
if (new_ssize < len || new_ssize > LONG_MAX / sizeof(sop)) {
|
||||
free((char *) g);
|
||||
return REG_INVARG;
|
||||
}
|
||||
p->ssize = new_ssize;
|
||||
}
|
||||
p->strip = (sop *)malloc(p->ssize * sizeof(sop));
|
||||
p->slen = 0;
|
||||
if (p->strip == NULL) {
|
||||
|
||||
+5
-4
@@ -99,6 +99,11 @@ AC_DEFUN([PHP_ODBC_FIND_EMPRESS_BCS_LIBS],[
|
||||
dnl
|
||||
dnl configure options
|
||||
dnl
|
||||
|
||||
PHP_ARG_WITH(odbcver,,
|
||||
[ --with-odbcver[=HEX] Force support for the passed ODBC version. A hex number is expected, default 0x0300.
|
||||
Use the special value of 0 to prevent an explicit ODBCVER to be defined. ], 0x0300)
|
||||
|
||||
if test -z "$ODBC_TYPE"; then
|
||||
PHP_ARG_WITH(adabas,,
|
||||
[ --with-adabas[=DIR] Include Adabas D support [/usr/local]])
|
||||
@@ -490,10 +495,6 @@ PHP_ARG_WITH(dbmaker,,
|
||||
fi
|
||||
fi
|
||||
|
||||
PHP_ARG_WITH(odbcver,,
|
||||
[ --with-odbcver[=HEX] Force support for the passed ODBC version. A hex number is expected, default 0x0300.
|
||||
Use the special value of 0 to prevent an explicit ODBCVER to be defined. ], 0x0300)
|
||||
|
||||
if test "no" != "$PHP_ODBCVER"; then
|
||||
if test "$PHP_ODBCVER" != "0"; then
|
||||
AC_DEFINE_UNQUOTED(ODBCVER, $PHP_ODBCVER, [ The highest supported ODBC version ])
|
||||
|
||||
@@ -5833,7 +5833,7 @@ PHP_FUNCTION(move_uploaded_file)
|
||||
RETURN_FALSE;
|
||||
}
|
||||
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &path, &path_len, &new_path, &new_path_len) == FAILURE) {
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sp", &path, &path_len, &new_path, &new_path_len) == FAILURE) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,37 @@
|
||||
--TEST--
|
||||
Bug #68976 Use After Free Vulnerability in unserialize()
|
||||
--FILE--
|
||||
<?php
|
||||
class evilClass {
|
||||
public $name;
|
||||
function __wakeup() {
|
||||
unset($this->name);
|
||||
}
|
||||
}
|
||||
|
||||
$fakezval = pack(
|
||||
'IIII',
|
||||
0x00100000,
|
||||
0x00000400,
|
||||
0x00000000,
|
||||
0x00000006
|
||||
);
|
||||
|
||||
$data = unserialize('a:2:{i:0;O:9:"evilClass":1:{s:4:"name";a:2:{i:0;i:1;i:1;i:2;}}i:1;R:4;}');
|
||||
|
||||
for($i = 0; $i < 5; $i++) {
|
||||
$v[$i] = $fakezval.$i;
|
||||
}
|
||||
|
||||
var_dump($data);
|
||||
?>
|
||||
===DONE===
|
||||
--EXPECTF--
|
||||
array(2) {
|
||||
[0]=>
|
||||
object(evilClass)#1 (0) {
|
||||
}
|
||||
[1]=>
|
||||
int(1)
|
||||
}
|
||||
===DONE===
|
||||
@@ -348,6 +348,7 @@ static inline int process_nested_data(UNSERIALIZE_PARAMETER, HashTable *ht, long
|
||||
zend_hash_update(ht, Z_STRVAL_P(key), Z_STRLEN_P(key) + 1, &data,
|
||||
sizeof data, NULL);
|
||||
}
|
||||
var_push_dtor(var_hash, &data);
|
||||
|
||||
zval_dtor(key);
|
||||
FREE_ZVAL(key);
|
||||
@@ -482,7 +483,7 @@ PHPAPI int php_var_unserialize(UNSERIALIZE_PARAMETER)
|
||||
|
||||
|
||||
|
||||
#line 486 "ext/standard/var_unserializer.c"
|
||||
#line 487 "ext/standard/var_unserializer.c"
|
||||
{
|
||||
YYCTYPE yych;
|
||||
static const unsigned char yybm[] = {
|
||||
@@ -542,9 +543,9 @@ yy2:
|
||||
yych = *(YYMARKER = ++YYCURSOR);
|
||||
if (yych == ':') goto yy95;
|
||||
yy3:
|
||||
#line 837 "ext/standard/var_unserializer.re"
|
||||
#line 838 "ext/standard/var_unserializer.re"
|
||||
{ return 0; }
|
||||
#line 548 "ext/standard/var_unserializer.c"
|
||||
#line 549 "ext/standard/var_unserializer.c"
|
||||
yy4:
|
||||
yych = *(YYMARKER = ++YYCURSOR);
|
||||
if (yych == ':') goto yy89;
|
||||
@@ -587,13 +588,13 @@ yy13:
|
||||
goto yy3;
|
||||
yy14:
|
||||
++YYCURSOR;
|
||||
#line 831 "ext/standard/var_unserializer.re"
|
||||
#line 832 "ext/standard/var_unserializer.re"
|
||||
{
|
||||
/* this is the case where we have less data than planned */
|
||||
php_error_docref(NULL TSRMLS_CC, E_NOTICE, "Unexpected end of serialized data");
|
||||
return 0; /* not sure if it should be 0 or 1 here? */
|
||||
}
|
||||
#line 597 "ext/standard/var_unserializer.c"
|
||||
#line 598 "ext/standard/var_unserializer.c"
|
||||
yy16:
|
||||
yych = *++YYCURSOR;
|
||||
goto yy3;
|
||||
@@ -623,7 +624,7 @@ yy20:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych != '"') goto yy18;
|
||||
++YYCURSOR;
|
||||
#line 685 "ext/standard/var_unserializer.re"
|
||||
#line 686 "ext/standard/var_unserializer.re"
|
||||
{
|
||||
size_t len, len2, len3, maxlen;
|
||||
long elements;
|
||||
@@ -769,7 +770,7 @@ yy20:
|
||||
|
||||
return object_common2(UNSERIALIZE_PASSTHRU, elements);
|
||||
}
|
||||
#line 773 "ext/standard/var_unserializer.c"
|
||||
#line 774 "ext/standard/var_unserializer.c"
|
||||
yy25:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych <= ',') {
|
||||
@@ -794,7 +795,7 @@ yy27:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych != '"') goto yy18;
|
||||
++YYCURSOR;
|
||||
#line 677 "ext/standard/var_unserializer.re"
|
||||
#line 678 "ext/standard/var_unserializer.re"
|
||||
{
|
||||
|
||||
INIT_PZVAL(*rval);
|
||||
@@ -802,7 +803,7 @@ yy27:
|
||||
return object_common2(UNSERIALIZE_PASSTHRU,
|
||||
object_common1(UNSERIALIZE_PASSTHRU, ZEND_STANDARD_CLASS_DEF_PTR));
|
||||
}
|
||||
#line 806 "ext/standard/var_unserializer.c"
|
||||
#line 807 "ext/standard/var_unserializer.c"
|
||||
yy32:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych == '+') goto yy33;
|
||||
@@ -823,7 +824,7 @@ yy34:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych != '{') goto yy18;
|
||||
++YYCURSOR;
|
||||
#line 657 "ext/standard/var_unserializer.re"
|
||||
#line 658 "ext/standard/var_unserializer.re"
|
||||
{
|
||||
long elements = parse_iv(start + 2);
|
||||
/* use iv() not uiv() in order to check data range */
|
||||
@@ -843,7 +844,7 @@ yy34:
|
||||
|
||||
return finish_nested_data(UNSERIALIZE_PASSTHRU);
|
||||
}
|
||||
#line 847 "ext/standard/var_unserializer.c"
|
||||
#line 848 "ext/standard/var_unserializer.c"
|
||||
yy39:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych == '+') goto yy40;
|
||||
@@ -864,7 +865,7 @@ yy41:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych != '"') goto yy18;
|
||||
++YYCURSOR;
|
||||
#line 628 "ext/standard/var_unserializer.re"
|
||||
#line 629 "ext/standard/var_unserializer.re"
|
||||
{
|
||||
size_t len, maxlen;
|
||||
char *str;
|
||||
@@ -893,7 +894,7 @@ yy41:
|
||||
ZVAL_STRINGL(*rval, str, len, 0);
|
||||
return 1;
|
||||
}
|
||||
#line 897 "ext/standard/var_unserializer.c"
|
||||
#line 898 "ext/standard/var_unserializer.c"
|
||||
yy46:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych == '+') goto yy47;
|
||||
@@ -914,7 +915,7 @@ yy48:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych != '"') goto yy18;
|
||||
++YYCURSOR;
|
||||
#line 600 "ext/standard/var_unserializer.re"
|
||||
#line 601 "ext/standard/var_unserializer.re"
|
||||
{
|
||||
size_t len, maxlen;
|
||||
char *str;
|
||||
@@ -942,7 +943,7 @@ yy48:
|
||||
ZVAL_STRINGL(*rval, str, len, 1);
|
||||
return 1;
|
||||
}
|
||||
#line 946 "ext/standard/var_unserializer.c"
|
||||
#line 947 "ext/standard/var_unserializer.c"
|
||||
yy53:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych <= '/') {
|
||||
@@ -1030,7 +1031,7 @@ yy61:
|
||||
}
|
||||
yy63:
|
||||
++YYCURSOR;
|
||||
#line 590 "ext/standard/var_unserializer.re"
|
||||
#line 591 "ext/standard/var_unserializer.re"
|
||||
{
|
||||
#if SIZEOF_LONG == 4
|
||||
use_double:
|
||||
@@ -1040,7 +1041,7 @@ use_double:
|
||||
ZVAL_DOUBLE(*rval, zend_strtod((const char *)start + 2, NULL));
|
||||
return 1;
|
||||
}
|
||||
#line 1044 "ext/standard/var_unserializer.c"
|
||||
#line 1045 "ext/standard/var_unserializer.c"
|
||||
yy65:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych <= ',') {
|
||||
@@ -1099,7 +1100,7 @@ yy73:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych != ';') goto yy18;
|
||||
++YYCURSOR;
|
||||
#line 575 "ext/standard/var_unserializer.re"
|
||||
#line 576 "ext/standard/var_unserializer.re"
|
||||
{
|
||||
*p = YYCURSOR;
|
||||
INIT_PZVAL(*rval);
|
||||
@@ -1114,7 +1115,7 @@ yy73:
|
||||
|
||||
return 1;
|
||||
}
|
||||
#line 1118 "ext/standard/var_unserializer.c"
|
||||
#line 1119 "ext/standard/var_unserializer.c"
|
||||
yy76:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych == 'N') goto yy73;
|
||||
@@ -1141,7 +1142,7 @@ yy79:
|
||||
if (yych <= '9') goto yy79;
|
||||
if (yych != ';') goto yy18;
|
||||
++YYCURSOR;
|
||||
#line 548 "ext/standard/var_unserializer.re"
|
||||
#line 549 "ext/standard/var_unserializer.re"
|
||||
{
|
||||
#if SIZEOF_LONG == 4
|
||||
int digits = YYCURSOR - start - 3;
|
||||
@@ -1168,7 +1169,7 @@ yy79:
|
||||
ZVAL_LONG(*rval, parse_iv(start + 2));
|
||||
return 1;
|
||||
}
|
||||
#line 1172 "ext/standard/var_unserializer.c"
|
||||
#line 1173 "ext/standard/var_unserializer.c"
|
||||
yy83:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych <= '/') goto yy18;
|
||||
@@ -1176,24 +1177,24 @@ yy83:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych != ';') goto yy18;
|
||||
++YYCURSOR;
|
||||
#line 541 "ext/standard/var_unserializer.re"
|
||||
#line 542 "ext/standard/var_unserializer.re"
|
||||
{
|
||||
*p = YYCURSOR;
|
||||
INIT_PZVAL(*rval);
|
||||
ZVAL_BOOL(*rval, parse_iv(start + 2));
|
||||
return 1;
|
||||
}
|
||||
#line 1187 "ext/standard/var_unserializer.c"
|
||||
#line 1188 "ext/standard/var_unserializer.c"
|
||||
yy87:
|
||||
++YYCURSOR;
|
||||
#line 534 "ext/standard/var_unserializer.re"
|
||||
#line 535 "ext/standard/var_unserializer.re"
|
||||
{
|
||||
*p = YYCURSOR;
|
||||
INIT_PZVAL(*rval);
|
||||
ZVAL_NULL(*rval);
|
||||
return 1;
|
||||
}
|
||||
#line 1197 "ext/standard/var_unserializer.c"
|
||||
#line 1198 "ext/standard/var_unserializer.c"
|
||||
yy89:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych <= ',') {
|
||||
@@ -1216,7 +1217,7 @@ yy91:
|
||||
if (yych <= '9') goto yy91;
|
||||
if (yych != ';') goto yy18;
|
||||
++YYCURSOR;
|
||||
#line 511 "ext/standard/var_unserializer.re"
|
||||
#line 512 "ext/standard/var_unserializer.re"
|
||||
{
|
||||
long id;
|
||||
|
||||
@@ -1239,7 +1240,7 @@ yy91:
|
||||
|
||||
return 1;
|
||||
}
|
||||
#line 1243 "ext/standard/var_unserializer.c"
|
||||
#line 1244 "ext/standard/var_unserializer.c"
|
||||
yy95:
|
||||
yych = *++YYCURSOR;
|
||||
if (yych <= ',') {
|
||||
@@ -1262,7 +1263,7 @@ yy97:
|
||||
if (yych <= '9') goto yy97;
|
||||
if (yych != ';') goto yy18;
|
||||
++YYCURSOR;
|
||||
#line 490 "ext/standard/var_unserializer.re"
|
||||
#line 491 "ext/standard/var_unserializer.re"
|
||||
{
|
||||
long id;
|
||||
|
||||
@@ -1283,9 +1284,9 @@ yy97:
|
||||
|
||||
return 1;
|
||||
}
|
||||
#line 1287 "ext/standard/var_unserializer.c"
|
||||
#line 1288 "ext/standard/var_unserializer.c"
|
||||
}
|
||||
#line 839 "ext/standard/var_unserializer.re"
|
||||
#line 840 "ext/standard/var_unserializer.re"
|
||||
|
||||
|
||||
return 0;
|
||||
|
||||
@@ -352,6 +352,7 @@ static inline int process_nested_data(UNSERIALIZE_PARAMETER, HashTable *ht, long
|
||||
zend_hash_update(ht, Z_STRVAL_P(key), Z_STRLEN_P(key) + 1, &data,
|
||||
sizeof data, NULL);
|
||||
}
|
||||
var_push_dtor(var_hash, &data);
|
||||
|
||||
zval_dtor(key);
|
||||
FREE_ZVAL(key);
|
||||
|
||||
@@ -101,7 +101,7 @@ _zip_cdir_new(int nentry, struct zip_error *error)
|
||||
return NULL;
|
||||
}
|
||||
|
||||
if ((cd->entry=(struct zip_dirent *)malloc(sizeof(*(cd->entry))*nentry))
|
||||
if ( nentry > ((size_t)-1)/sizeof(*(cd->entry)) || (cd->entry=(struct zip_dirent *)malloc(sizeof(*(cd->entry))*(size_t)nentry))
|
||||
== NULL) {
|
||||
_zip_error_set(error, ZIP_ER_MEMORY, 0);
|
||||
free(cd);
|
||||
|
||||
+2
-2
@@ -3,6 +3,6 @@
|
||||
#define PHP_MAJOR_VERSION 5
|
||||
#define PHP_MINOR_VERSION 5
|
||||
#define PHP_RELEASE_VERSION 23
|
||||
#define PHP_EXTRA_VERSION "-dev"
|
||||
#define PHP_VERSION "5.5.23-dev"
|
||||
#define PHP_EXTRA_VERSION ""
|
||||
#define PHP_VERSION "5.5.23"
|
||||
#define PHP_VERSION_ID 50523
|
||||
+1
-1
@@ -261,7 +261,7 @@ void UpdateIniFromRegistry(char *path TSRMLS_DC)
|
||||
zend_hash_get_current_data_ex(ht, (void**)&data, &pos) == SUCCESS &&
|
||||
zend_hash_get_current_key_ex(ht, &index, &index_len, &num, 0, &pos) == HASH_KEY_IS_STRING;
|
||||
zend_hash_move_forward_ex(ht, &pos)) {
|
||||
zend_alter_ini_entry(index, index_len, Z_STRVAL_PP(data), Z_STRLEN_PP(data), PHP_INI_SYSTEM, PHP_INI_STAGE_ACTIVATE);
|
||||
zend_alter_ini_entry(index, index_len, Z_STRVAL_PP(data), Z_STRLEN_PP(data), PHP_INI_USER, PHP_INI_STAGE_ACTIVATE);
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user