mirror of
https://github.com/bdnugget/php-src.git
synced 2026-11-12 19:50:50 +00:00
Compare commits
9
Commits
PHP-7.3
...
PHP-5.4.29
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5b0b760f1f | ||
|
|
2396ed466a | ||
|
|
37a4ebaa34 | ||
|
|
22736b7c56 | ||
|
|
68ce2d0ea6 | ||
|
|
41f01c28bc | ||
|
|
4dbe191b61 | ||
|
|
41cc924083 | ||
|
|
6e49313d72 |
No files matched your search
@@ -1,6 +1,6 @@
|
||||
PHP NEWS
|
||||
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||||
?? ??? 2014, PHP 5.4.29
|
||||
29 May 2014, PHP 5.4.29
|
||||
|
||||
- COM:
|
||||
. Fixed bug #66431 (Special Character via COM Interface (CP_UTF8)). (Anatol)
|
||||
@@ -12,6 +12,7 @@ PHP NEWS
|
||||
. Fixed bug #67245 (usage of memcpy() with overlapping src and dst in
|
||||
zend_exceptions.c). (Bob)
|
||||
. Fixed bug #67247 (spl_fixedarray_resize integer overflow). (Stas)
|
||||
. Fixed bug #67249 (printf out-of-bounds read). (Stas)
|
||||
. Fixed bug #67250 (iptcparse out-of-bounds read). (Stas)
|
||||
. Fixed bug #67252 (convert_uudecode out-of-bounds read). (Stas)
|
||||
|
||||
@@ -24,6 +25,13 @@ PHP NEWS
|
||||
. Fixed bug #67081 (DOMDocumentType->internalSubset returns entire DOCTYPE tag,
|
||||
not only the subset). (Anatol)
|
||||
|
||||
- Fileinfo:
|
||||
. Fixed bug #66307 (Fileinfo crashes with powerpoint files). (Anatol)
|
||||
. Fixed bug #67327 (fileinfo: CDF infinite loop in nelements DoS).
|
||||
(CVE-2014-0238)
|
||||
. Fixed bug #67328 (fileinfo: fileinfo: numerous file_printf calls resulting in
|
||||
performance degradation). (CVE-2014-0237)
|
||||
|
||||
- FPM:
|
||||
. Fixed bug #66908 (php-fpm reload leaks epoll_create() file descriptor).
|
||||
(Julio Pintos)
|
||||
|
||||
+1
-1
@@ -120,7 +120,7 @@ int zend_sprintf(char *buffer, const char *format, ...);
|
||||
PHP_MAJOR_VERSION=5
|
||||
PHP_MINOR_VERSION=4
|
||||
PHP_RELEASE_VERSION=29
|
||||
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`
|
||||
|
||||
|
||||
+11
-13
@@ -823,6 +823,10 @@ cdf_read_property_info(const cdf_stream_t *sst, const cdf_header_t *h,
|
||||
i, inp[i].pi_id, inp[i].pi_type, q - p, offs));
|
||||
if (inp[i].pi_type & CDF_VECTOR) {
|
||||
nelements = CDF_GETUINT32(q, 1);
|
||||
if (nelements == 0) {
|
||||
DPRINTF(("CDF_VECTOR with nelements == 0\n"));
|
||||
goto out;
|
||||
}
|
||||
o = 2;
|
||||
} else {
|
||||
nelements = 1;
|
||||
@@ -897,7 +901,9 @@ cdf_read_property_info(const cdf_stream_t *sst, const cdf_header_t *h,
|
||||
}
|
||||
DPRINTF(("nelements = %" SIZE_T_FORMAT "u\n",
|
||||
nelements));
|
||||
for (j = 0; j < nelements; j++, i++) {
|
||||
for (j = 0; j < nelements && i < sh.sh_properties;
|
||||
j++, i++)
|
||||
{
|
||||
uint32_t l = CDF_GETUINT32(q, o);
|
||||
inp[i].pi_str.s_len = l;
|
||||
inp[i].pi_str.s_buf = (const char *)
|
||||
@@ -942,7 +948,7 @@ int
|
||||
cdf_unpack_summary_info(const cdf_stream_t *sst, const cdf_header_t *h,
|
||||
cdf_summary_info_header_t *ssi, cdf_property_info_t **info, size_t *count)
|
||||
{
|
||||
size_t i, maxcount;
|
||||
size_t maxcount;
|
||||
const cdf_summary_info_header_t *si =
|
||||
CAST(const cdf_summary_info_header_t *, sst->sst_tab);
|
||||
const cdf_section_declaration_t *sd =
|
||||
@@ -957,21 +963,13 @@ cdf_unpack_summary_info(const cdf_stream_t *sst, const cdf_header_t *h,
|
||||
ssi->si_os = CDF_TOLE2(si->si_os);
|
||||
ssi->si_class = si->si_class;
|
||||
cdf_swap_class(&ssi->si_class);
|
||||
ssi->si_count = CDF_TOLE2(si->si_count);
|
||||
ssi->si_count = CDF_TOLE4(si->si_count);
|
||||
*count = 0;
|
||||
maxcount = 0;
|
||||
*info = NULL;
|
||||
for (i = 0; i < CDF_TOLE4(si->si_count); i++) {
|
||||
if (i >= CDF_LOOP_LIMIT) {
|
||||
DPRINTF(("Unpack summary info loop limit"));
|
||||
errno = EFTYPE;
|
||||
if (cdf_read_property_info(sst, h, CDF_TOLE4(sd->sd_offset), info,
|
||||
count, &maxcount) == -1)
|
||||
return -1;
|
||||
}
|
||||
if (cdf_read_property_info(sst, h, CDF_TOLE4(sd->sd_offset),
|
||||
info, count, &maxcount) == -1) {
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
@@ -56,6 +56,8 @@ cdf_file_property_info(struct magic_set *ms, const cdf_property_info_t *info,
|
||||
const char *s;
|
||||
int len;
|
||||
|
||||
memset(&ts, 0, sizeof(ts));
|
||||
|
||||
for (i = 0; i < count; i++) {
|
||||
cdf_print_property_name(buf, sizeof(buf), info[i].pi_id);
|
||||
switch (info[i].pi_type) {
|
||||
@@ -142,11 +144,13 @@ cdf_file_property_info(struct magic_set *ms, const cdf_property_info_t *info,
|
||||
return -1;
|
||||
} else {
|
||||
char *c, *ec;
|
||||
const time_t sec = ts.tv_sec;
|
||||
if (cdf_timestamp_to_timespec(&ts, tp) == -1) {
|
||||
return -1;
|
||||
}
|
||||
c = cdf_ctime(&ts.tv_sec, tbuf);
|
||||
if ((ec = strchr(c, '\n')) != NULL)
|
||||
c = cdf_ctime(&sec, tbuf);
|
||||
if (c != NULL &&
|
||||
(ec = strchr(c, '\n')) != NULL)
|
||||
*ec = '\0';
|
||||
|
||||
if (NOTMIME(ms) && file_printf(ms,
|
||||
|
||||
@@ -18,7 +18,7 @@ ksort($results);
|
||||
var_dump($results);
|
||||
?>
|
||||
--EXPECTF--
|
||||
array(8) {
|
||||
array(9) {
|
||||
["%s/resources/dir.zip"]=>
|
||||
string(15) "application/zip"
|
||||
["%s/resources/test.awk"]=>
|
||||
@@ -35,4 +35,6 @@ array(8) {
|
||||
string(15) "application/pdf"
|
||||
["%s/resources/test.png"]=>
|
||||
string(9) "image/png"
|
||||
["%s/resources/test.ppt"]=>
|
||||
string(29) "application/vnd.ms-powerpoint"
|
||||
}
|
||||
Binary file not shown.
@@ -376,6 +376,7 @@ php_formatted_print(int ht, int *len, int use_array, int format_offset TSRMLS_DC
|
||||
int alignment, currarg, adjusting, argnum, width, precision;
|
||||
char *format, *result, padding;
|
||||
int always_sign;
|
||||
int format_len;
|
||||
|
||||
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "+", &args, &argc) == FAILURE) {
|
||||
return NULL;
|
||||
@@ -414,11 +415,12 @@ php_formatted_print(int ht, int *len, int use_array, int format_offset TSRMLS_DC
|
||||
|
||||
convert_to_string_ex(args[format_offset]);
|
||||
format = Z_STRVAL_PP(args[format_offset]);
|
||||
format_len = Z_STRLEN_PP(args[format_offset]);
|
||||
result = emalloc(size);
|
||||
|
||||
currarg = 1;
|
||||
|
||||
while (inpos<Z_STRLEN_PP(args[format_offset])) {
|
||||
while (inpos<format_len) {
|
||||
int expprec = 0, multiuse = 0;
|
||||
zval *tmp;
|
||||
|
||||
@@ -473,7 +475,7 @@ php_formatted_print(int ht, int *len, int use_array, int format_offset TSRMLS_DC
|
||||
/* space padding, the default */
|
||||
} else if (format[inpos] == '+') {
|
||||
always_sign = 1;
|
||||
} else if (format[inpos] == '\'') {
|
||||
} else if (format[inpos] == '\'' && inpos+1<format_len) {
|
||||
padding = format[++inpos];
|
||||
} else {
|
||||
PRINTF_DEBUG(("sprintf: end of modifiers\n"));
|
||||
|
||||
@@ -0,0 +1,8 @@
|
||||
--TEST--
|
||||
Bug #67249 (printf out-of-bounds read)
|
||||
--FILE--
|
||||
<?php
|
||||
var_dump(sprintf("%'", "foo"));
|
||||
?>
|
||||
--EXPECT--
|
||||
string(0) ""
|
||||
+2
-2
@@ -3,6 +3,6 @@
|
||||
#define PHP_MAJOR_VERSION 5
|
||||
#define PHP_MINOR_VERSION 4
|
||||
#define PHP_RELEASE_VERSION 29
|
||||
#define PHP_EXTRA_VERSION "-dev"
|
||||
#define PHP_VERSION "5.4.29-dev"
|
||||
#define PHP_EXTRA_VERSION ""
|
||||
#define PHP_VERSION "5.4.29"
|
||||
#define PHP_VERSION_ID 50429
|
||||
Reference in new issue
Block a user