summaryrefslogtreecommitdiff
path: root/ext/phar/phar.c
diff options
context:
space:
mode:
authorStanislav Malyshev <stas@php.net>2016-03-28 23:55:05 -0700
committerStanislav Malyshev <stas@php.net>2016-03-28 23:55:05 -0700
commit67fbb0631109bf0dd82986a93838de0907a86869 (patch)
tree72ba95652bac0b5796efe7b591fd8e291dea0c06 /ext/phar/phar.c
parent57d170aae092a799d0fe486868e10f41667d5b40 (diff)
parent9c19a08b9daed6bae3071dd25742f59a59618823 (diff)
downloadphp-git-67fbb0631109bf0dd82986a93838de0907a86869.tar.gz
Merge branch 'PHP-5.5' into PHP-7.0.5
* PHP-5.5: Fixed bug #71704 php_snmp_error() Format String Vulnerability Fixed bug #71906: AddressSanitizer: negative-size-param (-1) in mbfl_strcut Fixed bug #71906: AddressSanitizer: negative-size-param (-1) in mbfl_strcut Fix bug #71798 - Integer Overflow in php_raw_url_encode Fix bug #71860: Require valid paths for phar filenames Going for 5.5.34 Conflicts: configure.in ext/phar/phar_object.c ext/phar/tests/badparameters.phpt ext/phar/tests/create_path_error.phpt ext/phar/tests/pharfileinfo_construct.phpt ext/snmp/snmp.c ext/standard/url.c main/php_version.h
Diffstat (limited to 'ext/phar/phar.c')
-rw-r--r--ext/phar/phar.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/phar/phar.c b/ext/phar/phar.c
index 08f480d303..860f5132d4 100644
--- a/ext/phar/phar.c
+++ b/ext/phar/phar.c
@@ -2200,6 +2200,10 @@ int phar_split_fname(const char *filename, int filename_len, char **arch, int *a
return FAILURE;
}
+ if (CHECK_NULL_PATH(filename, filename_len)) {
+ return FAILURE;
+ }
+
if (!strncasecmp(filename, "phar://", 7)) {
filename += 7;
filename_len -= 7;