idx
int64
func_before
string
Vulnerability Classification
string
vul
int64
func_after
string
patch
string
CWE ID
string
lines_before
string
lines_after
string
3,400
PHP_FUNCTION(connection_aborted) { RETURN_LONG(PG(connection_status) & PHP_CONNECTION_ABORTED); }
Bypass
0
PHP_FUNCTION(connection_aborted) { RETURN_LONG(PG(connection_status) & PHP_CONNECTION_ABORTED); }
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,401
PHP_FUNCTION(connection_status) { RETURN_LONG(PG(connection_status)); }
Bypass
0
PHP_FUNCTION(connection_status) { RETURN_LONG(PG(connection_status)); }
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,402
PHP_FUNCTION(getservbyname) { char *name, *proto; int name_len, proto_len; struct servent *serv; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &name, &name_len, &proto, &proto_len) == FAILURE) { return; } /* empty string behaves like NULL on windows implementation of getservbyname. Let be por...
Bypass
0
PHP_FUNCTION(getservbyname) { char *name, *proto; int name_len, proto_len; struct servent *serv; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &name, &name_len, &proto, &proto_len) == FAILURE) { return; } /* empty string behaves like NULL on windows implementation of getservbyname. Let be por...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,403
PHP_FUNCTION(getservbyport) { char *proto; int proto_len; long port; struct servent *serv; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ls", &port, &proto, &proto_len) == FAILURE) { return; } serv = getservbyport(htons((unsigned short) port), proto); if (serv == NULL) { RETURN_FALSE; } RETURN...
Bypass
0
PHP_FUNCTION(getservbyport) { char *proto; int proto_len; long port; struct servent *serv; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ls", &port, &proto, &proto_len) == FAILURE) { return; } serv = getservbyport(htons((unsigned short) port), proto); if (serv == NULL) { RETURN_FALSE; } RETURN...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,404
PHP_FUNCTION(getprotobyname) { char *name; int name_len; struct protoent *ent; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &name, &name_len) == FAILURE) { return; } ent = getprotobyname(name); if (ent == NULL) { RETURN_FALSE; } RETURN_LONG(ent->p_proto); }
Bypass
0
PHP_FUNCTION(getprotobyname) { char *name; int name_len; struct protoent *ent; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &name, &name_len) == FAILURE) { return; } ent = getprotobyname(name); if (ent == NULL) { RETURN_FALSE; } RETURN_LONG(ent->p_proto); }
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,405
PHP_FUNCTION(getprotobynumber) { long proto; struct protoent *ent; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &proto) == FAILURE) { return; } ent = getprotobynumber(proto); if (ent == NULL) { RETURN_FALSE; } RETURN_STRING(ent->p_name, 1); }
Bypass
0
PHP_FUNCTION(getprotobynumber) { long proto; struct protoent *ent; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &proto) == FAILURE) { return; } ent = getprotobynumber(proto); if (ent == NULL) { RETURN_FALSE; } RETURN_STRING(ent->p_name, 1); }
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,406
PHP_FUNCTION(register_tick_function) { user_tick_function_entry tick_fe; int i; char *function_name = NULL; tick_fe.calling = 0; tick_fe.arg_count = ZEND_NUM_ARGS(); if (tick_fe.arg_count < 1) { WRONG_PARAM_COUNT; } tick_fe.arguments = (zval **) safe_emalloc(sizeof(zval *), tick_fe.arg_count, 0); if (zen...
Bypass
0
PHP_FUNCTION(register_tick_function) { user_tick_function_entry tick_fe; int i; char *function_name = NULL; tick_fe.calling = 0; tick_fe.arg_count = ZEND_NUM_ARGS(); if (tick_fe.arg_count < 1) { WRONG_PARAM_COUNT; } tick_fe.arguments = (zval **) safe_emalloc(sizeof(zval *), tick_fe.arg_count, 0); if (zen...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,407
PHP_FUNCTION(unregister_tick_function) { zval *function; user_tick_function_entry tick_fe; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "z/", &function) == FAILURE) { return; } if (!BG(user_tick_functions)) { return; } if (Z_TYPE_P(function) != IS_ARRAY && Z_TYPE_P(function) != IS_OBJECT) { conv...
Bypass
0
PHP_FUNCTION(unregister_tick_function) { zval *function; user_tick_function_entry tick_fe; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "z/", &function) == FAILURE) { return; } if (!BG(user_tick_functions)) { return; } if (Z_TYPE_P(function) != IS_ARRAY && Z_TYPE_P(function) != IS_OBJECT) { conv...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,408
PHP_FUNCTION(is_uploaded_file) { char *path; int path_len; if (!SG(rfc1867_uploaded_files)) { RETURN_FALSE; } if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &path, &path_len) == FAILURE) { return; } if (zend_hash_exists(SG(rfc1867_uploaded_files), path, path_len + 1)) { RETURN_TRUE; } else {...
Bypass
0
PHP_FUNCTION(is_uploaded_file) { char *path; int path_len; if (!SG(rfc1867_uploaded_files)) { RETURN_FALSE; } if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &path, &path_len) == FAILURE) { return; } if (zend_hash_exists(SG(rfc1867_uploaded_files), path, path_len + 1)) { RETURN_TRUE; } else {...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,409
PHP_FUNCTION(parse_ini_string) { char *string = NULL, *str = NULL; int str_len = 0; zend_bool process_sections = 0; long scanner_mode = ZEND_INI_SCANNER_NORMAL; zend_ini_parser_cb_t ini_parser_cb; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|bl", &str, &str_len, &process_sections, &scanner_mode) == FA...
Bypass
0
PHP_FUNCTION(parse_ini_string) { char *string = NULL, *str = NULL; int str_len = 0; zend_bool process_sections = 0; long scanner_mode = ZEND_INI_SCANNER_NORMAL; zend_ini_parser_cb_t ini_parser_cb; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|bl", &str, &str_len, &process_sections, &scanner_mode) == FA...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,410
PHP_FUNCTION(config_get_hash) /* {{{ */ { HashTable *hash = php_ini_get_configuration_hash(); array_init(return_value); zend_hash_apply_with_arguments(hash TSRMLS_CC, (apply_func_args_t) add_config_entry_cb, 1, return_value); } /* }}} */
Bypass
0
PHP_FUNCTION(config_get_hash) /* {{{ */ { HashTable *hash = php_ini_get_configuration_hash(); array_init(return_value); zend_hash_apply_with_arguments(hash TSRMLS_CC, (apply_func_args_t) add_config_entry_cb, 1, return_value); } /* }}} */
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,411
PHP_FUNCTION(sys_getloadavg) { double load[3]; if (zend_parse_parameters_none() == FAILURE) { return; } if (getloadavg(load, 3) == -1) { RETURN_FALSE; } else { array_init(return_value); add_index_double(return_value, 0, load[0]); add_index_double(return_value, 1, load[1]); add_index_double(return_val...
Bypass
0
PHP_FUNCTION(sys_getloadavg) { double load[3]; if (zend_parse_parameters_none() == FAILURE) { return; } if (getloadavg(load, 3) == -1) { RETURN_FALSE; } else { array_init(return_value); add_index_double(return_value, 0, load[0]); add_index_double(return_value, 1, load[1]); add_index_double(return_val...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,412
PHP_MINFO_FUNCTION(basic) /* {{{ */ { php_info_print_table_start(); PHP_MINFO(dl)(ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU); PHP_MINFO(mail)(ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU); php_info_print_table_end(); PHP_MINFO(assert)(ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU); } /* }}} */
Bypass
0
PHP_MINFO_FUNCTION(basic) /* {{{ */ { php_info_print_table_start(); PHP_MINFO(dl)(ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU); PHP_MINFO(mail)(ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU); php_info_print_table_end(); PHP_MINFO(assert)(ZEND_MODULE_INFO_FUNC_ARGS_PASSTHRU); } /* }}} */
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,413
PHP_MINIT_FUNCTION(basic) /* {{{ */ { #ifdef ZTS ts_allocate_id(&basic_globals_id, sizeof(php_basic_globals), (ts_allocate_ctor) basic_globals_ctor, (ts_allocate_dtor) basic_globals_dtor); #ifdef PHP_WIN32 ts_allocate_id(&php_win32_core_globals_id, sizeof(php_win32_core_globals), (ts_allocate_ctor)php_win32_core_glob...
Bypass
0
PHP_MINIT_FUNCTION(basic) /* {{{ */ { #ifdef ZTS ts_allocate_id(&basic_globals_id, sizeof(php_basic_globals), (ts_allocate_ctor) basic_globals_ctor, (ts_allocate_dtor) basic_globals_dtor); #ifdef PHP_WIN32 ts_allocate_id(&php_win32_core_globals_id, sizeof(php_win32_core_globals), (ts_allocate_ctor)php_win32_core_glob...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,414
PHP_MSHUTDOWN_FUNCTION(basic) /* {{{ */ { #ifdef HAVE_SYSLOG_H PHP_MSHUTDOWN(syslog)(SHUTDOWN_FUNC_ARGS_PASSTHRU); #endif #ifdef ZTS ts_free_id(basic_globals_id); #ifdef PHP_WIN32 ts_free_id(php_win32_core_globals_id); #endif #else basic_globals_dtor(&basic_globals TSRMLS_CC); #ifdef PHP_WIN32 php_win32_core_globa...
Bypass
0
PHP_MSHUTDOWN_FUNCTION(basic) /* {{{ */ { #ifdef HAVE_SYSLOG_H PHP_MSHUTDOWN(syslog)(SHUTDOWN_FUNC_ARGS_PASSTHRU); #endif #ifdef ZTS ts_free_id(basic_globals_id); #ifdef PHP_WIN32 ts_free_id(php_win32_core_globals_id); #endif #else basic_globals_dtor(&basic_globals TSRMLS_CC); #ifdef PHP_WIN32 php_win32_core_globa...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,415
PHP_NAMED_FUNCTION(php_inet_ntop) { char *address; int address_len, af = AF_INET; char buffer[40]; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &address, &address_len) == FAILURE) { RETURN_FALSE; } #ifdef HAVE_IPV6 if (address_len == 16) { af = AF_INET6; } else #endif if (address_len != 4) { ...
Bypass
0
PHP_NAMED_FUNCTION(php_inet_ntop) { char *address; int address_len, af = AF_INET; char buffer[40]; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &address, &address_len) == FAILURE) { RETURN_FALSE; } #ifdef HAVE_IPV6 if (address_len == 16) { af = AF_INET6; } else #endif if (address_len != 4) { ...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,416
PHP_NAMED_FUNCTION(php_inet_pton) { int ret, af = AF_INET; char *address; int address_len; char buffer[17]; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &address, &address_len) == FAILURE) { RETURN_FALSE; } memset(buffer, 0, sizeof(buffer)); #ifdef HAVE_IPV6 if (strchr(address, ':')) { af = ...
Bypass
0
PHP_NAMED_FUNCTION(php_inet_pton) { int ret, af = AF_INET; char *address; int address_len; char buffer[17]; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &address, &address_len) == FAILURE) { RETURN_FALSE; } memset(buffer, 0, sizeof(buffer)); #ifdef HAVE_IPV6 if (strchr(address, ':')) { af = ...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,417
PHP_RINIT_FUNCTION(basic) /* {{{ */ { memset(BG(strtok_table), 0, 256); BG(serialize_lock) = 0; memset(&BG(serialize), 0, sizeof(BG(serialize))); memset(&BG(unserialize), 0, sizeof(BG(unserialize))); BG(strtok_string) = NULL; BG(strtok_zval) = NULL; BG(strtok_last) = NULL; BG(locale_string) = NULL; BG(array_...
Bypass
0
PHP_RINIT_FUNCTION(basic) /* {{{ */ { memset(BG(strtok_table), 0, 256); BG(serialize_lock) = 0; memset(&BG(serialize), 0, sizeof(BG(serialize))); memset(&BG(unserialize), 0, sizeof(BG(unserialize))); BG(strtok_string) = NULL; BG(strtok_zval) = NULL; BG(strtok_last) = NULL; BG(locale_string) = NULL; BG(array_...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,418
PHP_RSHUTDOWN_FUNCTION(basic) /* {{{ */ { if (BG(strtok_zval)) { zval_ptr_dtor(&BG(strtok_zval)); } BG(strtok_string) = NULL; BG(strtok_zval) = NULL; #ifdef HAVE_PUTENV zend_hash_destroy(&BG(putenv_ht)); #endif if (BG(umask) != -1) { umask(BG(umask)); } /* Check if locale was changed and change it back ...
Bypass
0
PHP_RSHUTDOWN_FUNCTION(basic) /* {{{ */ { if (BG(strtok_zval)) { zval_ptr_dtor(&BG(strtok_zval)); } BG(strtok_string) = NULL; BG(strtok_zval) = NULL; #ifdef HAVE_PUTENV zend_hash_destroy(&BG(putenv_ht)); #endif if (BG(umask) != -1) { umask(BG(umask)); } /* Check if locale was changed and change it back ...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,419
PHPAPI int _php_error_log_ex(int opt_err, char *message, int message_len, char *opt, char *headers TSRMLS_DC) /* {{{ */ { php_stream *stream = NULL; switch (opt_err) { case 1: /*send an email */ if (!php_mail(opt, "PHP error_log message", message, headers, NULL TSRMLS_CC)) { return FAILURE; } break;...
Bypass
0
PHPAPI int _php_error_log_ex(int opt_err, char *message, int message_len, char *opt, char *headers TSRMLS_DC) /* {{{ */ { php_stream *stream = NULL; switch (opt_err) { case 1: /*send an email */ if (!php_mail(opt, "PHP error_log message", message, headers, NULL TSRMLS_CC)) { return FAILURE; } break;...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,420
static int add_config_entry_cb(zval *entry TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) { zval *retval = (zval *)va_arg(args, zval*); zval *tmp; if (Z_TYPE_P(entry) == IS_STRING) { if (hash_key->nKeyLength > 0) { add_assoc_stringl_ex(retval, hash_key->arKey, hash_key->nKeyLength, Z_STRVAL_P(...
Bypass
0
static int add_config_entry_cb(zval *entry TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) { zval *retval = (zval *)va_arg(args, zval*); zval *tmp; if (Z_TYPE_P(entry) == IS_STRING) { if (hash_key->nKeyLength > 0) { add_assoc_stringl_ex(retval, hash_key->arKey, hash_key->nKeyLength, Z_STRVAL_P(...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,421
PHPAPI zend_bool append_user_shutdown_function(php_shutdown_function_entry shutdown_function_entry TSRMLS_DC) /* {{{ */ { if (!BG(user_shutdown_function_names)) { ALLOC_HASHTABLE(BG(user_shutdown_function_names)); zend_hash_init(BG(user_shutdown_function_names), 0, NULL, (void (*)(void *)) user_shutdown_function_d...
Bypass
0
PHPAPI zend_bool append_user_shutdown_function(php_shutdown_function_entry shutdown_function_entry TSRMLS_DC) /* {{{ */ { if (!BG(user_shutdown_function_names)) { ALLOC_HASHTABLE(BG(user_shutdown_function_names)); zend_hash_init(BG(user_shutdown_function_names), 0, NULL, (void (*)(void *)) user_shutdown_function_d...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,422
static void basic_globals_ctor(php_basic_globals *basic_globals_p TSRMLS_DC) /* {{{ */ { BG(rand_is_seeded) = 0; BG(mt_rand_is_seeded) = 0; BG(umask) = -1; BG(next) = NULL; BG(left) = -1; BG(user_tick_functions) = NULL; BG(user_filter_map) = NULL; BG(serialize_lock) = 0; memset(&BG(serialize), 0, sizeof(BG(s...
Bypass
0
static void basic_globals_ctor(php_basic_globals *basic_globals_p TSRMLS_DC) /* {{{ */ { BG(rand_is_seeded) = 0; BG(mt_rand_is_seeded) = 0; BG(umask) = -1; BG(next) = NULL; BG(left) = -1; BG(user_tick_functions) = NULL; BG(user_filter_map) = NULL; BG(serialize_lock) = 0; memset(&BG(serialize), 0, sizeof(BG(s...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,423
static void basic_globals_dtor(php_basic_globals *basic_globals_p TSRMLS_DC) /* {{{ */ { if (BG(url_adapt_state_ex).tags) { zend_hash_destroy(BG(url_adapt_state_ex).tags); free(BG(url_adapt_state_ex).tags); } } /* }}} */
Bypass
0
static void basic_globals_dtor(php_basic_globals *basic_globals_p TSRMLS_DC) /* {{{ */ { if (BG(url_adapt_state_ex).tags) { zend_hash_destroy(BG(url_adapt_state_ex).tags); free(BG(url_adapt_state_ex).tags); } } /* }}} */
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,424
static void free_longopts(opt_struct *longopts) { opt_struct *p; if (longopts) { for (p = longopts; p && p->opt_char != '-'; p++) { if (p->opt_name != NULL) { efree((char *)(p->opt_name)); } } } }
Bypass
0
static void free_longopts(opt_struct *longopts) { opt_struct *p; if (longopts) { for (p = longopts; p && p->opt_char != '-'; p++) { if (p->opt_name != NULL) { efree((char *)(p->opt_name)); } } } }
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,425
static int parse_opts(char * opts, opt_struct ** result) { opt_struct * paras = NULL; unsigned int i, count = 0; for (i = 0; i < strlen(opts); i++) { if ((opts[i] >= 48 && opts[i] <= 57) || (opts[i] >= 65 && opts[i] <= 90) || (opts[i] >= 97 && opts[i] <= 122) ) { count++; } } paras = safe_emalloc(...
Bypass
0
static int parse_opts(char * opts, opt_struct ** result) { opt_struct * paras = NULL; unsigned int i, count = 0; for (i = 0; i < strlen(opts); i++) { if ((opts[i] >= 48 && opts[i] <= 57) || (opts[i] >= 65 && opts[i] <= 90) || (opts[i] >= 97 && opts[i] <= 122) ) { count++; } } paras = safe_emalloc(...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,426
void php_free_shutdown_functions(TSRMLS_D) /* {{{ */ { if (BG(user_shutdown_function_names)) zend_try { zend_hash_destroy(BG(user_shutdown_function_names)); FREE_HASHTABLE(BG(user_shutdown_function_names)); BG(user_shutdown_function_names) = NULL; } zend_catch { /* maybe shutdown method call exit, we j...
Bypass
0
void php_free_shutdown_functions(TSRMLS_D) /* {{{ */ { if (BG(user_shutdown_function_names)) zend_try { zend_hash_destroy(BG(user_shutdown_function_names)); FREE_HASHTABLE(BG(user_shutdown_function_names)); BG(user_shutdown_function_names) = NULL; } zend_catch { /* maybe shutdown method call exit, we j...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,427
ZEND_API void php_get_highlight_struct(zend_syntax_highlighter_ini *syntax_highlighter_ini) /* {{{ */ { syntax_highlighter_ini->highlight_comment = INI_STR("highlight.comment"); syntax_highlighter_ini->highlight_default = INI_STR("highlight.default"); syntax_highlighter_ini->highlight_html = INI_STR("highlight.ht...
Bypass
0
ZEND_API void php_get_highlight_struct(zend_syntax_highlighter_ini *syntax_highlighter_ini) /* {{{ */ { syntax_highlighter_ini->highlight_comment = INI_STR("highlight.comment"); syntax_highlighter_ini->highlight_default = INI_STR("highlight.default"); syntax_highlighter_ini->highlight_html = INI_STR("highlight.ht...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,428
PHPAPI double php_get_nan(void) /* {{{ */ { #if HAVE_HUGE_VAL_NAN return HUGE_VAL + -HUGE_VAL; #elif defined(__i386__) || defined(_X86_) || defined(ALPHA) || defined(_ALPHA) || defined(__alpha) double val = 0.0; ((php_uint32*)&val)[1] = PHP_DOUBLE_QUIET_NAN_HIGH; ((php_uint32*)&val)[0] = 0; return val; #elif HAVE_...
Bypass
0
PHPAPI double php_get_nan(void) /* {{{ */ { #if HAVE_HUGE_VAL_NAN return HUGE_VAL + -HUGE_VAL; #elif defined(__i386__) || defined(_X86_) || defined(ALPHA) || defined(_ALPHA) || defined(__alpha) double val = 0.0; ((php_uint32*)&val)[1] = PHP_DOUBLE_QUIET_NAN_HIGH; ((php_uint32*)&val)[0] = 0; return val; #elif HAVE_...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,429
static int php_ini_check_path(char *option_name, int option_len, char *new_option_name, int new_option_len) /* {{{ */ { if (option_len != (new_option_len - 1)) { return 0; } return !strncmp(option_name, new_option_name, option_len); } /* }}} */
Bypass
0
static int php_ini_check_path(char *option_name, int option_len, char *new_option_name, int new_option_len) /* {{{ */ { if (option_len != (new_option_len - 1)) { return 0; } return !strncmp(option_name, new_option_name, option_len); } /* }}} */
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,430
static int php_ini_get_option(zend_ini_entry *ini_entry TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) /* {{{ */ { zval *ini_array = va_arg(args, zval *); int module_number = va_arg(args, int); int details = va_arg(args, int); zval *option; if (module_number != 0 && ini_entry->module_number != mo...
Bypass
0
static int php_ini_get_option(zend_ini_entry *ini_entry TSRMLS_DC, int num_args, va_list args, zend_hash_key *hash_key) /* {{{ */ { zval *ini_array = va_arg(args, zval *); int module_number = va_arg(args, int); int details = va_arg(args, int); zval *option; if (module_number != 0 && ini_entry->module_number != mo...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,431
static void php_putenv_destructor(putenv_entry *pe) /* {{{ */ { if (pe->previous_value) { #if _MSC_VER >= 1300 /* VS.Net has a bug in putenv() when setting a variable that * is already set; if the SetEnvironmentVariable() API call * fails, the Crt will double free() a string. * We try to avoid this by setti...
Bypass
0
static void php_putenv_destructor(putenv_entry *pe) /* {{{ */ { if (pe->previous_value) { #if _MSC_VER >= 1300 /* VS.Net has a bug in putenv() when setting a variable that * is already set; if the SetEnvironmentVariable() API call * fails, the Crt will double free() a string. * We try to avoid this by setti...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,432
static void php_simple_ini_parser_cb(zval *arg1, zval *arg2, zval *arg3, int callback_type, zval *arr TSRMLS_DC) { zval *element; switch (callback_type) { case ZEND_INI_PARSER_ENTRY: if (!arg2) { /* bare string - nothing to do */ break; } ALLOC_ZVAL(element); MAKE_COPY_ZVAL(&arg2, element); ...
Bypass
0
static void php_simple_ini_parser_cb(zval *arg1, zval *arg2, zval *arg3, int callback_type, zval *arr TSRMLS_DC) { zval *element; switch (callback_type) { case ZEND_INI_PARSER_ENTRY: if (!arg2) { /* bare string - nothing to do */ break; } ALLOC_ZVAL(element); MAKE_COPY_ZVAL(&arg2, element); ...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,433
PHPAPI zend_bool register_user_shutdown_function(char *function_name, size_t function_len, php_shutdown_function_entry *shutdown_function_entry TSRMLS_DC) /* {{{ */ { if (!BG(user_shutdown_function_names)) { ALLOC_HASHTABLE(BG(user_shutdown_function_names)); zend_hash_init(BG(user_shutdown_function_names), 0, NULL...
Bypass
0
PHPAPI zend_bool register_user_shutdown_function(char *function_name, size_t function_len, php_shutdown_function_entry *shutdown_function_entry TSRMLS_DC) /* {{{ */ { if (!BG(user_shutdown_function_names)) { ALLOC_HASHTABLE(BG(user_shutdown_function_names)); zend_hash_init(BG(user_shutdown_function_names), 0, NULL...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,434
PHPAPI zend_bool remove_user_shutdown_function(char *function_name, size_t function_len TSRMLS_DC) /* {{{ */ { if (BG(user_shutdown_function_names)) { return zend_hash_del_key_or_index(BG(user_shutdown_function_names), function_name, function_len, 0, HASH_DEL_KEY) != FAILURE; } return 0; } /* }}} */
Bypass
0
PHPAPI zend_bool remove_user_shutdown_function(char *function_name, size_t function_len TSRMLS_DC) /* {{{ */ { if (BG(user_shutdown_function_names)) { return zend_hash_del_key_or_index(BG(user_shutdown_function_names), function_name, function_len, 0, HASH_DEL_KEY) != FAILURE; } return 0; } /* }}} */
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,435
static int user_shutdown_function_call(php_shutdown_function_entry *shutdown_function_entry TSRMLS_DC) /* {{{ */ { zval retval; char *function_name; if (!zend_is_callable(shutdown_function_entry->arguments[0], 0, &function_name TSRMLS_CC)) { php_error(E_WARNING, "(Registered shutdown functions) Unable to call %s(...
Bypass
0
static int user_shutdown_function_call(php_shutdown_function_entry *shutdown_function_entry TSRMLS_DC) /* {{{ */ { zval retval; char *function_name; if (!zend_is_callable(shutdown_function_entry->arguments[0], 0, &function_name TSRMLS_CC)) { php_error(E_WARNING, "(Registered shutdown functions) Unable to call %s(...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,436
static void user_tick_function_call(user_tick_function_entry *tick_fe TSRMLS_DC) /* {{{ */ { zval retval; zval *function = tick_fe->arguments[0]; /* Prevent reentrant calls to the same user ticks function */ if (! tick_fe->calling) { tick_fe->calling = 1; if (call_user_function( EG(function_table), NULL, ...
Bypass
0
static void user_tick_function_call(user_tick_function_entry *tick_fe TSRMLS_DC) /* {{{ */ { zval retval; zval *function = tick_fe->arguments[0]; /* Prevent reentrant calls to the same user ticks function */ if (! tick_fe->calling) { tick_fe->calling = 1; if (call_user_function( EG(function_table), NULL, ...
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,437
void user_tick_function_dtor(user_tick_function_entry *tick_function_entry) /* {{{ */ { int i; for (i = 0; i < tick_function_entry->arg_count; i++) { zval_ptr_dtor(&tick_function_entry->arguments[i]); } efree(tick_function_entry->arguments); } /* }}} */
Bypass
0
void user_tick_function_dtor(user_tick_function_entry *tick_function_entry) /* {{{ */ { int i; for (i = 0; i < tick_function_entry->arg_count; i++) { zval_ptr_dtor(&tick_function_entry->arguments[i]); } efree(tick_function_entry->arguments); } /* }}} */
@@ -5775,7 +5775,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, &n...
CWE-264
null
null
3,438
_zip_cdir_free(struct zip_cdir *cd) { int i; if (!cd) return; for (i=0; i<cd->nentry; i++) _zip_dirent_finalize(cd->entry+i); free(cd->comment); free(cd->entry); free(cd); }
DoS Exec Code Overflow
0
_zip_cdir_free(struct zip_cdir *cd) { int i; if (!cd) return; for (i=0; i<cd->nentry; i++) _zip_dirent_finalize(cd->entry+i); free(cd->comment); free(cd->entry); free(cd); }
@@ -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)) ...
CWE-189
null
null
3,439
_zip_cdir_grow(struct zip_cdir *cd, int nentry, struct zip_error *error) { struct zip_dirent *entry; if (nentry < cd->nentry) { _zip_error_set(error, ZIP_ER_INTERNAL, 0); return -1; } if ((entry=((struct zip_dirent *) realloc(cd->entry, sizeof(*(cd->entry))*nentry))) == NULL) { _zip_error_set(err...
DoS Exec Code Overflow
0
_zip_cdir_grow(struct zip_cdir *cd, int nentry, struct zip_error *error) { struct zip_dirent *entry; if (nentry < cd->nentry) { _zip_error_set(error, ZIP_ER_INTERNAL, 0); return -1; } if ((entry=((struct zip_dirent *) realloc(cd->entry, sizeof(*(cd->entry))*nentry))) == NULL) { _zip_error_set(err...
@@ -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)) ...
CWE-189
null
null
3,440
_zip_cdir_write(struct zip_cdir *cd, FILE *fp, struct zip_error *error) { int i; cd->offset = ftello(fp); for (i=0; i<cd->nentry; i++) { if (_zip_dirent_write(cd->entry+i, fp, 0, error) != 0) return -1; } cd->size = ftello(fp) - cd->offset; /* clearerr(fp); */ fwrite(EOCD_MAGIC...
DoS Exec Code Overflow
0
_zip_cdir_write(struct zip_cdir *cd, FILE *fp, struct zip_error *error) { int i; cd->offset = ftello(fp); for (i=0; i<cd->nentry; i++) { if (_zip_dirent_write(cd->entry+i, fp, 0, error) != 0) return -1; } cd->size = ftello(fp) - cd->offset; /* clearerr(fp); */ fwrite(EOCD_MAGIC...
@@ -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)) ...
CWE-189
null
null
3,441
_zip_d2u_time(int dtime, int ddate) { struct tm tm; memset(&tm, 0, sizeof(tm)); /* let mktime decide if DST is in effect */ tm.tm_isdst = -1; tm.tm_year = ((ddate>>9)&127) + 1980 - 1900; tm.tm_mon = ((ddate>>5)&15) - 1; tm.tm_mday = ddate&31; tm.tm_hour = (dtime>>11)&31; ...
DoS Exec Code Overflow
0
_zip_d2u_time(int dtime, int ddate) { struct tm tm; memset(&tm, 0, sizeof(tm)); /* let mktime decide if DST is in effect */ tm.tm_isdst = -1; tm.tm_year = ((ddate>>9)&127) + 1980 - 1900; tm.tm_mon = ((ddate>>5)&15) - 1; tm.tm_mday = ddate&31; tm.tm_hour = (dtime>>11)&31; ...
@@ -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)) ...
CWE-189
null
null
3,442
_zip_dirent_finalize(struct zip_dirent *zde) { if (zde->filename_len > 0) { free(zde->filename); } zde->filename = NULL; if (zde->extrafield_len > 0) { free(zde->extrafield); } zde->extrafield = NULL; if (zde->comment_len > 0) { free(zde->comment); } zde->comm...
DoS Exec Code Overflow
0
_zip_dirent_finalize(struct zip_dirent *zde) { if (zde->filename_len > 0) { free(zde->filename); } zde->filename = NULL; if (zde->extrafield_len > 0) { free(zde->extrafield); } zde->extrafield = NULL; if (zde->comment_len > 0) { free(zde->comment); } zde->comm...
@@ -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)) ...
CWE-189
null
null
3,443
_zip_dirent_init(struct zip_dirent *de) { de->version_madeby = 0; de->version_needed = 20; /* 2.0 */ de->bitflags = 0; de->comp_method = 0; de->last_mod = 0; de->crc = 0; de->comp_size = 0; de->uncomp_size = 0; de->filename = NULL; de->filename_len = 0; de->extrafield = NULL;...
DoS Exec Code Overflow
0
_zip_dirent_init(struct zip_dirent *de) { de->version_madeby = 0; de->version_needed = 20; /* 2.0 */ de->bitflags = 0; de->comp_method = 0; de->last_mod = 0; de->crc = 0; de->comp_size = 0; de->uncomp_size = 0; de->filename = NULL; de->filename_len = 0; de->extrafield = NULL;...
@@ -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)) ...
CWE-189
null
null
3,444
_zip_dirent_read(struct zip_dirent *zde, FILE *fp, unsigned char **bufp, zip_uint32_t *leftp, int local, struct zip_error *error) { unsigned char buf[CDENTRYSIZE]; unsigned char *cur; unsigned short dostime, dosdate; zip_uint32_t size; if (local) size = LENTRYSIZE; else size = CDENTRYSI...
DoS Exec Code Overflow
0
_zip_dirent_read(struct zip_dirent *zde, FILE *fp, unsigned char **bufp, zip_uint32_t *leftp, int local, struct zip_error *error) { unsigned char buf[CDENTRYSIZE]; unsigned char *cur; unsigned short dostime, dosdate; zip_uint32_t size; if (local) size = LENTRYSIZE; else size = CDENTRYSI...
@@ -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)) ...
CWE-189
null
null
3,445
_zip_dirent_torrent_normalize(struct zip_dirent *de) { static struct tm torrenttime; static time_t last_mod = 0; if (last_mod == 0) { #ifdef HAVE_STRUCT_TM_TM_ZONE time_t now; struct tm *l; #endif torrenttime.tm_sec = 0; torrenttime.tm_min = 32; torrenttime.tm_hour = 23; torrenttime.tm_mday = 24; t...
DoS Exec Code Overflow
0
_zip_dirent_torrent_normalize(struct zip_dirent *de) { static struct tm torrenttime; static time_t last_mod = 0; if (last_mod == 0) { #ifdef HAVE_STRUCT_TM_TM_ZONE time_t now; struct tm *l; #endif torrenttime.tm_sec = 0; torrenttime.tm_min = 32; torrenttime.tm_hour = 23; torrenttime.tm_mday = 24; t...
@@ -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)) ...
CWE-189
null
null
3,446
_zip_dirent_write(struct zip_dirent *zde, FILE *fp, int localp, struct zip_error *error) { unsigned short dostime, dosdate; fwrite(localp ? LOCAL_MAGIC : CENTRAL_MAGIC, 1, 4, fp); if (!localp) _zip_write2(zde->version_madeby, fp); _zip_write2(zde->version_needed, fp); _zip_write2(zde->bitflag...
DoS Exec Code Overflow
0
_zip_dirent_write(struct zip_dirent *zde, FILE *fp, int localp, struct zip_error *error) { unsigned short dostime, dosdate; fwrite(localp ? LOCAL_MAGIC : CENTRAL_MAGIC, 1, 4, fp); if (!localp) _zip_write2(zde->version_madeby, fp); _zip_write2(zde->version_needed, fp); _zip_write2(zde->bitflag...
@@ -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)) ...
CWE-189
null
null
3,447
_zip_read2(unsigned char **a) { unsigned short ret; ret = (*a)[0]+((*a)[1]<<8); *a += 2; return ret; }
DoS Exec Code Overflow
0
_zip_read2(unsigned char **a) { unsigned short ret; ret = (*a)[0]+((*a)[1]<<8); *a += 2; return ret; }
@@ -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)) ...
CWE-189
null
null
3,448
_zip_read4(unsigned char **a) { unsigned int ret; ret = ((((((*a)[3]<<8)+(*a)[2])<<8)+(*a)[1])<<8)+(*a)[0]; *a += 4; return ret; }
DoS Exec Code Overflow
0
_zip_read4(unsigned char **a) { unsigned int ret; ret = ((((((*a)[3]<<8)+(*a)[2])<<8)+(*a)[1])<<8)+(*a)[0]; *a += 4; return ret; }
@@ -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)) ...
CWE-189
null
null
3,449
_zip_readfpstr(FILE *fp, unsigned int len, int nulp, struct zip_error *error) { char *r, *o; r = (char *)malloc(nulp ? len+1 : len); if (!r) { _zip_error_set(error, ZIP_ER_MEMORY, 0); return NULL; } if (fread(r, 1, len, fp)<len) { free(r); _zip_error_set(error, ZIP_ER_READ, errno); return NUL...
DoS Exec Code Overflow
0
_zip_readfpstr(FILE *fp, unsigned int len, int nulp, struct zip_error *error) { char *r, *o; r = (char *)malloc(nulp ? len+1 : len); if (!r) { _zip_error_set(error, ZIP_ER_MEMORY, 0); return NULL; } if (fread(r, 1, len, fp)<len) { free(r); _zip_error_set(error, ZIP_ER_READ, errno); return NUL...
@@ -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)) ...
CWE-189
null
null
3,450
_zip_readstr(unsigned char **buf, int len, int nulp, struct zip_error *error) { char *r, *o; r = (char *)malloc(nulp ? len+1 : len); if (!r) { _zip_error_set(error, ZIP_ER_MEMORY, 0); return NULL; } memcpy(r, *buf, len); *buf += len; if (nulp) { /* replace any in-string NUL charact...
DoS Exec Code Overflow
0
_zip_readstr(unsigned char **buf, int len, int nulp, struct zip_error *error) { char *r, *o; r = (char *)malloc(nulp ? len+1 : len); if (!r) { _zip_error_set(error, ZIP_ER_MEMORY, 0); return NULL; } memcpy(r, *buf, len); *buf += len; if (nulp) { /* replace any in-string NUL charact...
@@ -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)) ...
CWE-189
null
null
3,451
_zip_u2d_time(time_t time, unsigned short *dtime, unsigned short *ddate) { struct tm *tm; tm = localtime(&time); *ddate = ((tm->tm_year+1900-1980)<<9) + ((tm->tm_mon+1)<<5) + tm->tm_mday; *dtime = ((tm->tm_hour)<<11) + ((tm->tm_min)<<5) + ((tm->tm_sec)>>1); return; }
DoS Exec Code Overflow
0
_zip_u2d_time(time_t time, unsigned short *dtime, unsigned short *ddate) { struct tm *tm; tm = localtime(&time); *ddate = ((tm->tm_year+1900-1980)<<9) + ((tm->tm_mon+1)<<5) + tm->tm_mday; *dtime = ((tm->tm_hour)<<11) + ((tm->tm_min)<<5) + ((tm->tm_sec)>>1); return; }
@@ -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)) ...
CWE-189
null
null
3,452
_zip_write2(unsigned short i, FILE *fp) { putc(i&0xff, fp); putc((i>>8)&0xff, fp); return; }
DoS Exec Code Overflow
0
_zip_write2(unsigned short i, FILE *fp) { putc(i&0xff, fp); putc((i>>8)&0xff, fp); return; }
@@ -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)) ...
CWE-189
null
null
3,453
_zip_write4(unsigned int i, FILE *fp) { putc(i&0xff, fp); putc((i>>8)&0xff, fp); putc((i>>16)&0xff, fp); putc((i>>24)&0xff, fp); return; }
DoS Exec Code Overflow
0
_zip_write4(unsigned int i, FILE *fp) { putc(i&0xff, fp); putc((i>>8)&0xff, fp); putc((i>>16)&0xff, fp); putc((i>>24)&0xff, fp); return; }
@@ -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)) ...
CWE-189
null
null
3,454
PHP_METHOD(Phar, running) { char *fname, *arch, *entry; int fname_len, arch_len, entry_len; zend_bool retphar = 1; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|b", &retphar) == FAILURE) { return; } fname = (char*)zend_get_executed_filename(TSRMLS_C); fname_len = strlen(fname); if (fname_len > 7 &...
DoS
0
PHP_METHOD(Phar, running) { char *fname, *arch, *entry; int fname_len, arch_len, entry_len; zend_bool retphar = 1; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|b", &retphar) == FAILURE) { return; } fname = (char*)zend_get_executed_filename(TSRMLS_C); fname_len = strlen(fname); if (fname_len > 7 &...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,455
PHP_METHOD(Phar, webPhar) { zval *mimeoverride = NULL, *rewrite = NULL; char *alias = NULL, *error, *index_php = NULL, *f404 = NULL, *ru = NULL; int alias_len = 0, ret, f404_len = 0, free_pathinfo = 0, ru_len = 0; char *fname, *path_info, *mime_type = NULL, *entry, *pt; const char *basename; int fname_len, entry_...
DoS
0
PHP_METHOD(Phar, webPhar) { zval *mimeoverride = NULL, *rewrite = NULL; char *alias = NULL, *error, *index_php = NULL, *f404 = NULL, *ru = NULL; int alias_len = 0, ret, f404_len = 0, free_pathinfo = 0, ru_len = 0; char *fname, *path_info, *mime_type = NULL, *entry, *pt; const char *basename; int fname_len, entry_...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,456
PHP_METHOD(Phar, mungServer) { zval *mungvalues; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "a", &mungvalues) == FAILURE) { return; } if (!zend_hash_num_elements(Z_ARRVAL_P(mungvalues))) { zend_throw_exception_ex(phar_ce_PharException, 0 TSRMLS_CC, "No values passed to Phar::mungServer(), expecting ...
DoS
0
PHP_METHOD(Phar, mungServer) { zval *mungvalues; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "a", &mungvalues) == FAILURE) { return; } if (!zend_hash_num_elements(Z_ARRVAL_P(mungvalues))) { zend_throw_exception_ex(phar_ce_PharException, 0 TSRMLS_CC, "No values passed to Phar::mungServer(), expecting ...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,457
PHP_METHOD(Phar, createDefaultStub) { char *index = NULL, *webindex = NULL, *stub, *error; int index_len = 0, webindex_len = 0; size_t stub_len; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|ss", &index, &index_len, &webindex, &webindex_len) == FAILURE) { return; } stub = phar_create_default_stub(ind...
DoS
0
PHP_METHOD(Phar, createDefaultStub) { char *index = NULL, *webindex = NULL, *stub, *error; int index_len = 0, webindex_len = 0; size_t stub_len; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|ss", &index, &index_len, &webindex, &webindex_len) == FAILURE) { return; } stub = phar_create_default_stub(ind...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,458
PHP_METHOD(Phar, mapPhar) { char *alias = NULL, *error; int alias_len = 0; long dataoffset = 0; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|s!l", &alias, &alias_len, &dataoffset) == FAILURE) { return; } phar_request_initialize(TSRMLS_C); RETVAL_BOOL(phar_open_executed_filename(alias, alias_len, &...
DoS
0
PHP_METHOD(Phar, mapPhar) { char *alias = NULL, *error; int alias_len = 0; long dataoffset = 0; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|s!l", &alias, &alias_len, &dataoffset) == FAILURE) { return; } phar_request_initialize(TSRMLS_C); RETVAL_BOOL(phar_open_executed_filename(alias, alias_len, &...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,459
PHP_METHOD(Phar, apiVersion) { if (zend_parse_parameters_none() == FAILURE) { return; } RETURN_STRINGL(PHP_PHAR_API_VERSION, sizeof(PHP_PHAR_API_VERSION)-1, 1); }
DoS
0
PHP_METHOD(Phar, apiVersion) { if (zend_parse_parameters_none() == FAILURE) { return; } RETURN_STRINGL(PHP_PHAR_API_VERSION, sizeof(PHP_PHAR_API_VERSION)-1, 1); }
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,460
PHP_METHOD(Phar, canCompress) { long method = 0; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|l", &method) == FAILURE) { return; } phar_request_initialize(TSRMLS_C); switch (method) { case PHAR_ENT_COMPRESSED_GZ: if (PHAR_G(has_zlib)) { RETURN_TRUE; } else { RETURN_FALSE; } case PHAR_EN...
DoS
0
PHP_METHOD(Phar, canCompress) { long method = 0; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|l", &method) == FAILURE) { return; } phar_request_initialize(TSRMLS_C); switch (method) { case PHAR_ENT_COMPRESSED_GZ: if (PHAR_G(has_zlib)) { RETURN_TRUE; } else { RETURN_FALSE; } case PHAR_EN...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,461
PHP_METHOD(Phar, canWrite) { if (zend_parse_parameters_none() == FAILURE) { return; } RETURN_BOOL(!PHAR_G(readonly)); }
DoS
0
PHP_METHOD(Phar, canWrite) { if (zend_parse_parameters_none() == FAILURE) { return; } RETURN_BOOL(!PHAR_G(readonly)); }
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,462
PHP_METHOD(Phar, isValidPharFilename) { char *fname; const char *ext_str; int fname_len, ext_len, is_executable; zend_bool executable = 1; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b", &fname, &fname_len, &executable) == FAILURE) { return; } is_executable = executable; RETVAL_BOOL(phar_detect_...
DoS
0
PHP_METHOD(Phar, isValidPharFilename) { char *fname; const char *ext_str; int fname_len, ext_len, is_executable; zend_bool executable = 1; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|b", &fname, &fname_len, &executable) == FAILURE) { return; } is_executable = executable; RETVAL_BOOL(phar_detect_...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,463
PHP_METHOD(Phar, __construct) { #if !HAVE_SPL zend_throw_exception_ex(zend_exception_get_default(TSRMLS_C), 0 TSRMLS_CC, "Cannot instantiate Phar object without SPL extension"); #else char *fname, *alias = NULL, *error, *arch = NULL, *entry = NULL, *save_fname; int fname_len, alias_len = 0, arch_len, entry_len, is_d...
DoS
0
PHP_METHOD(Phar, __construct) { #if !HAVE_SPL zend_throw_exception_ex(zend_exception_get_default(TSRMLS_C), 0 TSRMLS_CC, "Cannot instantiate Phar object without SPL extension"); #else char *fname, *alias = NULL, *error, *arch = NULL, *entry = NULL, *save_fname; int fname_len, alias_len = 0, arch_len, entry_len, is_d...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,464
PHP_METHOD(Phar, getSupportedSignatures) { if (zend_parse_parameters_none() == FAILURE) { return; } array_init(return_value); add_next_index_stringl(return_value, "MD5", 3, 1); add_next_index_stringl(return_value, "SHA-1", 5, 1); #ifdef PHAR_HASH_OK add_next_index_stringl(return_value, "SHA-256", 7, 1); add...
DoS
0
PHP_METHOD(Phar, getSupportedSignatures) { if (zend_parse_parameters_none() == FAILURE) { return; } array_init(return_value); add_next_index_stringl(return_value, "MD5", 3, 1); add_next_index_stringl(return_value, "SHA-1", 5, 1); #ifdef PHAR_HASH_OK add_next_index_stringl(return_value, "SHA-256", 7, 1); add...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,465
PHP_METHOD(Phar, getSupportedCompression) { if (zend_parse_parameters_none() == FAILURE) { return; } array_init(return_value); phar_request_initialize(TSRMLS_C); if (PHAR_G(has_zlib)) { add_next_index_stringl(return_value, "GZ", 2, 1); } if (PHAR_G(has_bz2)) { add_next_index_stringl(return_value, "BZIP...
DoS
0
PHP_METHOD(Phar, getSupportedCompression) { if (zend_parse_parameters_none() == FAILURE) { return; } array_init(return_value); phar_request_initialize(TSRMLS_C); if (PHAR_G(has_zlib)) { add_next_index_stringl(return_value, "GZ", 2, 1); } if (PHAR_G(has_bz2)) { add_next_index_stringl(return_value, "BZIP...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,466
PHP_METHOD(Phar, unlinkArchive) { char *fname, *error, *zname, *arch, *entry; int fname_len, zname_len, arch_len, entry_len; phar_archive_data *phar; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &fname, &fname_len) == FAILURE) { RETURN_FALSE; } if (!fname_len) { zend_throw_exception_ex(phar_ce_...
DoS
0
PHP_METHOD(Phar, unlinkArchive) { char *fname, *error, *zname, *arch, *entry; int fname_len, zname_len, arch_len, entry_len; phar_archive_data *phar; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &fname, &fname_len) == FAILURE) { RETURN_FALSE; } if (!fname_len) { zend_throw_exception_ex(phar_ce_...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,467
PHP_METHOD(Phar, __destruct) { phar_archive_object *phar_obj = (phar_archive_object*)zend_object_store_get_object(getThis() TSRMLS_CC); if (phar_obj->arc.archive && phar_obj->arc.archive->is_persistent) { zend_hash_del(&PHAR_GLOBALS->phar_persist_map, (const char *) phar_obj->arc.archive, sizeof(phar_obj->arc.arch...
DoS
0
PHP_METHOD(Phar, __destruct) { phar_archive_object *phar_obj = (phar_archive_object*)zend_object_store_get_object(getThis() TSRMLS_CC); if (phar_obj->arc.archive && phar_obj->arc.archive->is_persistent) { zend_hash_del(&PHAR_GLOBALS->phar_persist_map, (const char *) phar_obj->arc.archive, sizeof(phar_obj->arc.arch...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,468
PHP_METHOD(Phar, buildFromDirectory) { char *dir, *error, *regex = NULL; int dir_len, regex_len = 0; zend_bool apply_reg = 0; zval arg, arg2, *iter, *iteriter, *regexiter = NULL; struct _phar_t pass; PHAR_ARCHIVE_OBJECT(); if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl...
DoS
0
PHP_METHOD(Phar, buildFromDirectory) { char *dir, *error, *regex = NULL; int dir_len, regex_len = 0; zend_bool apply_reg = 0; zval arg, arg2, *iter, *iteriter, *regexiter = NULL; struct _phar_t pass; PHAR_ARCHIVE_OBJECT(); if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,469
PHP_METHOD(Phar, isFileFormat) { long type; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &type) == FAILURE) { RETURN_FALSE; } switch (type) { case PHAR_FORMAT_TAR: RETURN_BOOL(phar_obj->arc.archive->is_tar); case PHAR_FORMAT_ZIP: RETURN_BOOL(phar_obj->arc.archive->...
DoS
0
PHP_METHOD(Phar, isFileFormat) { long type; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &type) == FAILURE) { RETURN_FALSE; } switch (type) { case PHAR_FORMAT_TAR: RETURN_BOOL(phar_obj->arc.archive->is_tar); case PHAR_FORMAT_ZIP: RETURN_BOOL(phar_obj->arc.archive->...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,470
PHP_METHOD(Phar, convertToExecutable) { char *ext = NULL; int is_data, ext_len = 0; php_uint32 flags; zval *ret; /* a number that is not 0, 1 or 2 (Which is also Greg's birthday, so there) */ long format = 9021976, method = 9021976; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|...
DoS
0
PHP_METHOD(Phar, convertToExecutable) { char *ext = NULL; int is_data, ext_len = 0; php_uint32 flags; zval *ret; /* a number that is not 0, 1 or 2 (Which is also Greg's birthday, so there) */ long format = 9021976, method = 9021976; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,471
PHP_METHOD(Phar, convertToData) { char *ext = NULL; int is_data, ext_len = 0; php_uint32 flags; zval *ret; /* a number that is not 0, 1 or 2 (Which is also Greg's birthday so there) */ long format = 9021976, method = 9021976; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|lls", &...
DoS
0
PHP_METHOD(Phar, convertToData) { char *ext = NULL; int is_data, ext_len = 0; php_uint32 flags; zval *ret; /* a number that is not 0, 1 or 2 (Which is also Greg's birthday so there) */ long format = 9021976, method = 9021976; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|lls", &...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,472
PHP_METHOD(Phar, isCompressed) { PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } if (phar_obj->arc.archive->flags & PHAR_FILE_COMPRESSED_GZ) { RETURN_LONG(PHAR_ENT_COMPRESSED_GZ); } if (phar_obj->arc.archive->flags & PHAR_FILE_COMPRESSED_BZ2) { RETURN_LONG(PHAR_ENT_COMPRE...
DoS
0
PHP_METHOD(Phar, isCompressed) { PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } if (phar_obj->arc.archive->flags & PHAR_FILE_COMPRESSED_GZ) { RETURN_LONG(PHAR_ENT_COMPRESSED_GZ); } if (phar_obj->arc.archive->flags & PHAR_FILE_COMPRESSED_BZ2) { RETURN_LONG(PHAR_ENT_COMPRE...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,473
PHP_METHOD(Phar, getPath) { PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } RETURN_STRINGL(phar_obj->arc.archive->fname, phar_obj->arc.archive->fname_len, 1); }
DoS
0
PHP_METHOD(Phar, getPath) { PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } RETURN_STRINGL(phar_obj->arc.archive->fname, phar_obj->arc.archive->fname_len, 1); }
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,474
PHP_METHOD(Phar, setAlias) { char *alias, *error, *oldalias; phar_archive_data **fd_ptr; int alias_len, oldalias_len, old_temp, readd = 0; PHAR_ARCHIVE_OBJECT(); if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0 TSRMLS_CC, "Cannot write out...
DoS
0
PHP_METHOD(Phar, setAlias) { char *alias, *error, *oldalias; phar_archive_data **fd_ptr; int alias_len, oldalias_len, old_temp, readd = 0; PHAR_ARCHIVE_OBJECT(); if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0 TSRMLS_CC, "Cannot write out...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,475
PHP_METHOD(Phar, getVersion) { PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } RETURN_STRING(phar_obj->arc.archive->version, 1); }
DoS
0
PHP_METHOD(Phar, getVersion) { PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } RETURN_STRING(phar_obj->arc.archive->version, 1); }
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,476
PHP_METHOD(Phar, isBuffering) { PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } RETURN_BOOL(phar_obj->arc.archive->donotflush); }
DoS
0
PHP_METHOD(Phar, isBuffering) { PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } RETURN_BOOL(phar_obj->arc.archive->donotflush); }
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,477
PHP_METHOD(Phar, stopBuffering) { char *error; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0 TSRMLS_CC, "Cannot write out phar archive, phar is read-onl...
DoS
0
PHP_METHOD(Phar, stopBuffering) { char *error; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0 TSRMLS_CC, "Cannot write out phar archive, phar is read-onl...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,478
PHP_METHOD(Phar, setDefaultStub) { char *index = NULL, *webindex = NULL, *error = NULL, *stub = NULL; int index_len = 0, webindex_len = 0, created_stub = 0; size_t stub_len = 0; PHAR_ARCHIVE_OBJECT(); if (phar_obj->arc.archive->is_data) { if (phar_obj->arc.archive->is_tar) { zend_throw_exception_ex(spl_ce_Un...
DoS
0
PHP_METHOD(Phar, setDefaultStub) { char *index = NULL, *webindex = NULL, *error = NULL, *stub = NULL; int index_len = 0, webindex_len = 0, created_stub = 0; size_t stub_len = 0; PHAR_ARCHIVE_OBJECT(); if (phar_obj->arc.archive->is_data) { if (phar_obj->arc.archive->is_tar) { zend_throw_exception_ex(spl_ce_Un...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,479
PHP_METHOD(Phar, setSignatureAlgorithm) { long algo; char *error, *key = NULL; int key_len = 0; PHAR_ARCHIVE_OBJECT(); if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0 TSRMLS_CC, "Cannot set signature algorithm, phar is read-only"); retu...
DoS
0
PHP_METHOD(Phar, setSignatureAlgorithm) { long algo; char *error, *key = NULL; int key_len = 0; PHAR_ARCHIVE_OBJECT(); if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0 TSRMLS_CC, "Cannot set signature algorithm, phar is read-only"); retu...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,480
PHP_METHOD(Phar, getSignature) { PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } if (phar_obj->arc.archive->signature) { char *unknown; int unknown_len; array_init(return_value); add_assoc_stringl(return_value, "hash", phar_obj->arc.archive->signature, phar_obj->arc.arc...
DoS
0
PHP_METHOD(Phar, getSignature) { PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } if (phar_obj->arc.archive->signature) { char *unknown; int unknown_len; array_init(return_value); add_assoc_stringl(return_value, "hash", phar_obj->arc.archive->signature, phar_obj->arc.arc...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,481
PHP_METHOD(Phar, getModified) { PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } RETURN_BOOL(phar_obj->arc.archive->is_modified); }
DoS
0
PHP_METHOD(Phar, getModified) { PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } RETURN_BOOL(phar_obj->arc.archive->is_modified); }
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,482
PHP_METHOD(Phar, decompress) { char *ext = NULL; int ext_len = 0; zval *ret; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|s", &ext, &ext_len) == FAILURE) { return; } if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_UnexpectedValueExc...
DoS
0
PHP_METHOD(Phar, decompress) { char *ext = NULL; int ext_len = 0; zval *ret; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|s", &ext, &ext_len) == FAILURE) { return; } if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_UnexpectedValueExc...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,483
PHP_METHOD(Phar, compressFiles) { char *error; php_uint32 flags; long method; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &method) == FAILURE) { return; } if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0...
DoS
0
PHP_METHOD(Phar, compressFiles) { char *error; php_uint32 flags; long method; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &method) == FAILURE) { return; } if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,484
PHP_METHOD(Phar, decompressFiles) { char *error; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "Phar is readonly, cannot change compression"); ...
DoS
0
PHP_METHOD(Phar, decompressFiles) { char *error; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "Phar is readonly, cannot change compression"); ...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,485
PHP_METHOD(Phar, copy) { char *oldfile, *newfile, *error; const char *pcr_error; int oldfile_len, newfile_len; phar_entry_info *oldentry, newentry = {0}, *temp; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &oldfile, &oldfile_len, &newfile, &newfile_len) == FAILURE) { retur...
DoS
0
PHP_METHOD(Phar, copy) { char *oldfile, *newfile, *error; const char *pcr_error; int oldfile_len, newfile_len; phar_entry_info *oldentry, newentry = {0}, *temp; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &oldfile, &oldfile_len, &newfile, &newfile_len) == FAILURE) { retur...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,486
PHP_METHOD(Phar, offsetExists) { char *fname; int fname_len; phar_entry_info *entry; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &fname, &fname_len) == FAILURE) { return; } if (zend_hash_exists(&phar_obj->arc.archive->manifest, fname, (uint) fname_len)) { if (SUCCESS =...
DoS
0
PHP_METHOD(Phar, offsetExists) { char *fname; int fname_len; phar_entry_info *entry; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &fname, &fname_len) == FAILURE) { return; } if (zend_hash_exists(&phar_obj->arc.archive->manifest, fname, (uint) fname_len)) { if (SUCCESS =...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,487
PHP_METHOD(Phar, offsetGet) { char *fname, *error; int fname_len; zval *zfname; phar_entry_info *entry; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &fname, &fname_len) == FAILURE) { return; } /* security is 0 here so that we can get a better error message than "entry doe...
DoS
0
PHP_METHOD(Phar, offsetGet) { char *fname, *error; int fname_len; zval *zfname; phar_entry_info *entry; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &fname, &fname_len) == FAILURE) { return; } /* security is 0 here so that we can get a better error message than "entry doe...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,488
PHP_METHOD(Phar, offsetSet) { char *fname, *cont_str = NULL; int fname_len, cont_len; zval *zresource; PHAR_ARCHIVE_OBJECT(); if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "Write operations disabled by the php.ini setting phar.read...
DoS
0
PHP_METHOD(Phar, offsetSet) { char *fname, *cont_str = NULL; int fname_len, cont_len; zval *zresource; PHAR_ARCHIVE_OBJECT(); if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "Write operations disabled by the php.ini setting phar.read...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,489
PHP_METHOD(Phar, offsetUnset) { char *fname, *error; int fname_len; phar_entry_info *entry; PHAR_ARCHIVE_OBJECT(); if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "Write operations disabled by the php.ini setting phar.readonly"); r...
DoS
0
PHP_METHOD(Phar, offsetUnset) { char *fname, *error; int fname_len; phar_entry_info *entry; PHAR_ARCHIVE_OBJECT(); if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "Write operations disabled by the php.ini setting phar.readonly"); r...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,490
PHP_METHOD(Phar, addEmptyDir) { char *dirname; int dirname_len; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &dirname, &dirname_len) == FAILURE) { return; } if (dirname_len >= sizeof(".phar")-1 && !memcmp(dirname, ".phar", sizeof(".phar")-1)) { zend_throw_exception_ex(sp...
DoS
0
PHP_METHOD(Phar, addEmptyDir) { char *dirname; int dirname_len; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &dirname, &dirname_len) == FAILURE) { return; } if (dirname_len >= sizeof(".phar")-1 && !memcmp(dirname, ".phar", sizeof(".phar")-1)) { zend_throw_exception_ex(sp...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,491
PHP_METHOD(Phar, addFile) { char *fname, *localname = NULL; int fname_len, localname_len = 0; php_stream *resource; zval *zresource; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|s", &fname, &fname_len, &localname, &localname_len) == FAILURE) { return; } #if PHP_API_VERSION ...
DoS
0
PHP_METHOD(Phar, addFile) { char *fname, *localname = NULL; int fname_len, localname_len = 0; php_stream *resource; zval *zresource; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|s", &fname, &fname_len, &localname, &localname_len) == FAILURE) { return; } #if PHP_API_VERSION ...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,492
PHP_METHOD(Phar, addFromString) { char *localname, *cont_str; int localname_len, cont_len; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &localname, &localname_len, &cont_str, &cont_len) == FAILURE) { return; } phar_add_file(&(phar_obj->arc.archive), localname, localname_l...
DoS
0
PHP_METHOD(Phar, addFromString) { char *localname, *cont_str; int localname_len, cont_len; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "ss", &localname, &localname_len, &cont_str, &cont_len) == FAILURE) { return; } phar_add_file(&(phar_obj->arc.archive), localname, localname_l...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,493
PHP_METHOD(Phar, getStub) { size_t len; char *buf; php_stream *fp; php_stream_filter *filter = NULL; phar_entry_info *stub; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } if (phar_obj->arc.archive->is_tar || phar_obj->arc.archive->is_zip) { if (SUCCESS == zend_hash_fin...
DoS
0
PHP_METHOD(Phar, getStub) { size_t len; char *buf; php_stream *fp; php_stream_filter *filter = NULL; phar_entry_info *stub; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } if (phar_obj->arc.archive->is_tar || phar_obj->arc.archive->is_zip) { if (SUCCESS == zend_hash_fin...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,494
PHP_METHOD(Phar, delMetadata) { char *error; PHAR_ARCHIVE_OBJECT(); if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "Write operations disabled by the php.ini setting phar.readonly"); return; } if (phar_obj->arc.archive->metadata)...
DoS
0
PHP_METHOD(Phar, delMetadata) { char *error; PHAR_ARCHIVE_OBJECT(); if (PHAR_G(readonly) && !phar_obj->arc.archive->is_data) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "Write operations disabled by the php.ini setting phar.readonly"); return; } if (phar_obj->arc.archive->metadata)...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,495
PHP_METHOD(Phar, extractTo) { char *error = NULL; php_stream *fp; php_stream_statbuf ssb; phar_entry_info *entry; char *pathto, *filename, *actual; int pathto_len, filename_len; int ret, i; int nelems; zval *zval_files = NULL; zend_bool overwrite = 0; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_...
DoS
0
PHP_METHOD(Phar, extractTo) { char *error = NULL; php_stream *fp; php_stream_statbuf ssb; phar_entry_info *entry; char *pathto, *filename, *actual; int pathto_len, filename_len; int ret, i; int nelems; zval *zval_files = NULL; zend_bool overwrite = 0; PHAR_ARCHIVE_OBJECT(); if (zend_parse_parameters(ZEND_...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,496
PHP_METHOD(PharFileInfo, __construct) { char *fname, *arch, *entry, *error; int fname_len, arch_len, entry_len; phar_entry_object *entry_obj; phar_entry_info *entry_info; phar_archive_data *phar_data; zval *zobj = getThis(), arg1; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &fname, &fname_len) == ...
DoS
0
PHP_METHOD(PharFileInfo, __construct) { char *fname, *arch, *entry, *error; int fname_len, arch_len, entry_len; phar_entry_object *entry_obj; phar_entry_info *entry_info; phar_archive_data *phar_data; zval *zobj = getThis(), arg1; if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &fname, &fname_len) == ...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,497
PHP_METHOD(PharFileInfo, __destruct) { phar_entry_object *entry_obj = (phar_entry_object*)zend_object_store_get_object(getThis() TSRMLS_CC); \ if (entry_obj->ent.entry && entry_obj->ent.entry->is_temp_dir) { if (entry_obj->ent.entry->filename) { efree(entry_obj->ent.entry->filename); entry_obj->ent.entry->fi...
DoS
0
PHP_METHOD(PharFileInfo, __destruct) { phar_entry_object *entry_obj = (phar_entry_object*)zend_object_store_get_object(getThis() TSRMLS_CC); \ if (entry_obj->ent.entry && entry_obj->ent.entry->is_temp_dir) { if (entry_obj->ent.entry->filename) { efree(entry_obj->ent.entry->filename); entry_obj->ent.entry->fi...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,498
PHP_METHOD(PharFileInfo, isCompressed) { /* a number that is not Phar::GZ or Phar::BZ2 */ long method = 9021976; PHAR_ENTRY_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|l", &method) == FAILURE) { return; } switch (method) { case 9021976: RETURN_BOOL(entry_obj->ent.entry->flags & PHAR_...
DoS
0
PHP_METHOD(PharFileInfo, isCompressed) { /* a number that is not Phar::GZ or Phar::BZ2 */ long method = 9021976; PHAR_ENTRY_OBJECT(); if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "|l", &method) == FAILURE) { return; } switch (method) { case 9021976: RETURN_BOOL(entry_obj->ent.entry->flags & PHAR_...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null
3,499
PHP_METHOD(PharFileInfo, getCRC32) { PHAR_ENTRY_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } if (entry_obj->ent.entry->is_dir) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, \ "Phar entry is a directory, does not have a CRC"); \ return; } if (entry_obj->en...
DoS
0
PHP_METHOD(PharFileInfo, getCRC32) { PHAR_ENTRY_OBJECT(); if (zend_parse_parameters_none() == FAILURE) { return; } if (entry_obj->ent.entry->is_dir) { zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, \ "Phar entry is a directory, does not have a CRC"); \ return; } if (entry_obj->en...
@@ -2139,8 +2139,8 @@ static zval *phar_rename_archive(phar_archive_data *phar, char *ext, zend_bool c } its_ok: if (SUCCESS == php_stream_stat_path(newpath, &ssb)) { - efree(oldpath); zend_throw_exception_ex(spl_ce_BadMethodCallException, 0 TSRMLS_CC, "phar \"%s\" exists ...
null
null
null