php-src/main
Wez Furlong c484eb8c97 Fix segfault in wrapper error log mechanism when errors are logged on
second and subsequent events.
Implement very simple recursion protection for user streams written
like this:
class urlEncodeStream {
    var $fp = NULL;

    function stream_open($path, $mode, $options, &$opened_path)
    {
        $this->fp = fopen($path, $mode); // <-- this recurses infinitely
        return is_resource($this->fp);
    }
}

file_register_wrapper('urlencode', 'urlEncodeStream');
$fp = fopen('urlencode:///tmp/outputfile.txt', 'w');

Noticed by: Yasuo.
2002-09-26 12:12:27 +00:00
..
alloca.c - Don't wrap lines... this is annoying while coding. 2001-09-09 13:29:31 +00:00
build-defs.h.in @New constants: PHP_PREFIX and PHP_SHLIB_SUFFIX (Stig) 2002-06-07 12:19:26 +00:00
config.nw.h NetWare related changes 2002-05-31 04:49:45 +00:00
config.w32.h.in --enable-mbstr-enc-trans is abolished to prevent some problems about POST/GET/Cookie variables. the same functionality is controllable in php.ini option mbstring.encoding_translation (default:Off). 2002-09-03 05:18:20 +00:00
fopen_wrappers.c Fixed bug #19395 2002-09-22 18:30:38 +00:00
fopen_wrappers.h Fix a few warnings 2002-08-19 20:47:55 +00:00
internal_functions_registry.h Update headers. 2001-12-11 15:32:16 +00:00
internal_functions_win32.c Don't build ext/overload with Zend Engine 2. 2002-09-04 13:55:52 +00:00
internal_functions.c.in New PHP streams... 2002-03-15 21:03:08 +00:00
logos.h *** empty log message *** 2000-04-19 23:18:15 +00:00
main.c We are about to enter 2003, sending two-digit years does not make too 2002-09-25 16:11:31 +00:00
memory_streams.c Revise buffer/seek code a little. 2002-09-23 13:22:10 +00:00
mergesort.c NetWare related changes/modifications 2002-09-09 11:17:40 +00:00
network.c Implement persistent streams. (for pfsockopen). 2002-09-25 15:25:12 +00:00
output.c Fix bug #19525 2002-09-23 14:18:42 +00:00
php3_compat.h Move the macro wrappers from the compatibility header to php.h 2001-08-11 01:13:31 +00:00
php_compat.h NetWare related changes 2002-05-31 04:49:45 +00:00
php_content_types.c made sapi_register_treat_data() to support multibyte input encoding translation without MBSTR_ENC_TRANS and changed php_treat_data to php_default_treat_data. 2002-08-02 06:53:48 +00:00
php_content_types.h fix SAPI_POST_* exports 2001-08-15 18:01:48 +00:00
php_globals.h Per discussion on #php.bugs (+1 from at least Derick and Jani), revert double_buffering. 2002-09-01 11:33:19 +00:00
php_ini.c Compat fix 2002-09-23 12:10:07 +00:00
php_ini.h Revert to the old php_ini.c, and reimplement the binary-path searching. 2002-05-11 03:41:17 +00:00
php_logos.c Maintain headers. 2002-02-28 08:29:35 +00:00
php_logos.h More TSRMLS_FETCH work. Got it under 400 now. 2001-07-31 06:28:05 +00:00
php_main.h another startup initialization fix - only ISAPI and CGI SAPI's tested, 2002-09-18 21:57:42 +00:00
php_memory_streams.h -defined php_stream_temp_new() for standard temp streams 2002-03-23 17:51:20 +00:00
php_network.h Implement persistent streams. (for pfsockopen). 2002-09-25 15:25:12 +00:00
php_open_temporary_file.c NetWare related changes/modifications 2002-09-09 12:03:36 +00:00
php_open_temporary_file.h Maintain headers. 2002-02-28 08:29:35 +00:00
php_output.h Per discussion on #php.bugs (+1 from at least Derick and Jani), revert double_buffering. 2002-09-01 11:33:19 +00:00
php_realpath.c - Try and fix problem with opening wrong file. 2000-08-27 18:01:17 +00:00
php_reentrancy.h Maintain headers. 2002-02-28 08:29:35 +00:00
php_regex.h Protect us from Apache 2.0's pcre-posix stuff 2000-10-26 18:15:56 +00:00
php_sprintf.c Maintain headers. 2002-02-28 08:29:35 +00:00
php_streams.h Rename file_get_wrapper_data -> file_get_meta_data. 2002-09-26 10:14:41 +00:00
php_syslog.h NetWare related changes/modifications 2002-09-09 12:03:36 +00:00
php_ticks.c Silence a warning under Solaris 8 (WorkShop Compilers 5.0 98/12/15 C 5.0). 2002-03-04 20:57:36 +00:00
php_ticks.h Maintain headers. 2002-02-28 08:29:35 +00:00
php_variables.c Fix last commit. This line isn't supposed to be replaced. 2002-09-08 00:27:05 +00:00
php_variables.h Update headers. 2001-12-11 15:32:16 +00:00
php_version.h sync with PHP_MAJOR_VERSION changes to configure.in 2002-04-11 15:50:32 +00:00
php.h Implement persistent streams. (for pfsockopen). 2002-09-25 15:25:12 +00:00
reentrancy.c NetWare related changes/modifications 2002-09-11 09:30:01 +00:00
rfc1867.c IE does not use quotes but now we are safe... 2002-08-17 11:48:21 +00:00
rfc1867.h - Added predefined constants for the upload errors. 2002-07-12 01:49:58 +00:00
safe_mode.c use php_error_docref() 2002-08-25 18:45:02 +00:00
safe_mode.h o Fixed Bug #12121: chdir and safe_mode 2001-07-13 18:21:21 +00:00
SAPI.c Added missing charset. 2002-09-08 01:06:29 +00:00
SAPI.h made sapi_register_treat_data() to support multibyte input encoding translation without MBSTR_ENC_TRANS and changed php_treat_data to php_default_treat_data. 2002-08-02 06:53:48 +00:00
snprintf.c make snprintf and f,g,G converions of snprintf/spprintf C99 complient 2002-08-21 01:11:50 +00:00
snprintf.h explain difference between sprintf, snprintf and spprintf 2002-06-23 22:16:35 +00:00
spprintf.c increase allocation chunks 2002-08-12 14:02:51 +00:00
spprintf.h Export spprintf() so that extension can link properly on win32. 2002-08-12 09:07:26 +00:00
streams.c Fix segfault in wrapper error log mechanism when errors are logged on 2002-09-26 12:12:27 +00:00
strlcat.c - Don't wrap lines... this is annoying while coding. 2001-09-09 13:29:31 +00:00
strlcpy.c - Don't wrap lines... this is annoying while coding. 2001-09-09 13:29:31 +00:00
user_streams.c Fix segfault in wrapper error log mechanism when errors are logged on 2002-09-26 12:12:27 +00:00
win95nt.h silencing some windows build warnings 2002-08-15 00:41:35 +00:00