Commit Graph

225 Commits

Author SHA1 Message Date
Andi Gutmans
dbeb4158d2 - A belated happy holidays and PHP 5 2004-01-08 08:18:22 +00:00
Derick Rethans
74eed61504 - Fix the default SAPI filter too; all weird problems should be gone again. 2003-12-01 19:25:07 +00:00
Derick Rethans
750b0338bf - Fix sapi_input_filter patch. Returning 1 from the filter handler should
make PHP register the variable, returning 0 shouldn't. The new length of
  the variables being filtered is now returned in the new_val_len argument
  of the function.
2003-11-29 15:24:35 +00:00
Derick Rethans
370dfd39a9 - Prevent registration of the variable when a zero-length is returned
from the sapi_input_filter.
2003-11-26 09:53:22 +00:00
Ilia Alshanetsky
3c84c0eefc Fixed bug #25836 (last key of multi-dimensional array passed via GPC
not being escaped when magic_quotes_gpc is on).
2003-10-14 03:49:13 +00:00
Stanislav Malyshev
dd7bdcf4b1 Fix $_SERVER['argv'] and $_SERVER['argc'] 2003-10-07 08:46:16 +00:00
Andrei Zmievski
b3920d5012 Made the $argc and $argv always available as globals in CLI, and not as
$_SERVER vars which depended on variables_order anyway. No more
silliness.
2003-10-01 23:11:59 +00:00
Ilia Alshanetsky
de7f7658cf Only register server variables when needed. 2003-07-31 22:56:57 +00:00
Ilia Alshanetsky
0eb76eb2ec Fixed bug #24883 (variables created through register_globals, ignore
gpc_order and variables_order).
Prevent multiple registration of ENV & SERVER variables when more then one
is specified.
Prevent multiple addition of GET/POST/COOKIE variables when building
_REQUEST.
2003-07-31 22:29:32 +00:00
Zeev Suraski
0a49c033d0 - Use the new infrastructure of zend_symtable_*() (fixes bug #24565)
- Fix bogus use of get_current_key()
2003-07-22 16:08:50 +00:00
Zeev Suraski
023c8a7d95 Fix register_globals 2003-07-21 17:42:24 +00:00
Ilia Alshanetsky
e40142047b Fixed bug #24208 2003-06-16 19:24:56 +00:00
Ilia Alshanetsky
93a5238465 Fixed bug #24007 (Problem with register_globals & arrays) 2003-06-14 15:08:27 +00:00
James Cox
f68c7ff249 updating license information in the headers. 2003-06-10 20:04:29 +00:00
Zeev Suraski
ce40bc9073 Make $_FILES auto global (bug #23680) 2003-06-08 15:30:33 +00:00
Shane Caraveo
0f3a0dfa52 _SERVER also should not be quoted by magic_quotes_GPC
also remove an empty if statement
2003-03-30 01:06:54 +00:00
Moriyoshi Koizumi
e1eb238cf2 On 64bit platforms, pointers are 64bit long.. 2003-03-28 17:09:04 +00:00
Moriyoshi Koizumi
961ad8e24a Improved php_import_environment_variables: avoid emalloc()ing in most cases 2003-03-27 21:13:47 +00:00
Sebastian Bergmann
5ca078779a Eliminate some TSRMLS_FETCH() calls. Tested with Win32 build of SAPI/CGI and SAPI/CLI on Win32. 2003-03-25 08:07:13 +00:00
Shane Caraveo
456b6cbeab The environment should *never* be magic quoted. 2003-03-23 19:30:31 +00:00
Ilia Alshanetsky
66c05f7035 Fixed compiler warnings. 2003-03-03 19:37:09 +00:00
Zeev Suraski
1f63fba1b7 Fix old variable names 2003-03-02 15:41:12 +00:00
Zeev Suraski
622da33231 - Optimize $_REQUEST
- Fix phpinfo()
2003-03-02 13:35:01 +00:00
Zeev Suraski
4e55747a2b Add JIT initialization for _SERVER and _ENV
(it's less important for the others, even though it should be fairly
easy now too)
2003-03-02 10:19:15 +00:00
Rasmus Lerdorf
d08a0e99c8 An input filter might not simply strip stuff, it might also turn things
into entities or use some other mechanism which causes the filtered data
to be longer than the original data.  Ergo, pass in the address of the
buffer instead so the filter is free to reallocate it.
2003-02-20 22:21:49 +00:00
Rasmus Lerdorf
7429c2dc3f Input Filter support. See README.input_filter for details.
@- Input Filter support added. See  README.input_filter. (Rasmus)
2003-02-19 19:41:09 +00:00
foobar
8e3f23e3c0 ws fixes + missing $Id$ tags, headers added 2003-02-19 08:40:19 +00:00
Sebastian Bergmann
2c5d4b8c23 Bump year. 2002-12-31 15:59:15 +00:00
Ilia Alshanetsky
1f50681813 Fixed bug #21149 (fixed handling of unterminated '['). 2002-12-29 21:02:17 +00:00
Ilia Alshanetsky
683251eba3 Fixed bug #20796. $_GET/$_POST/$_COOKIE data can get overwritten when
register_globals are on and input contains arrays.
2002-12-07 16:05:27 +00:00
Shane Caraveo
96b9c0a523 make php_import_environment_variables overwritable so fastcgi can correctly
set $_ENV.
2002-10-13 08:38:09 +00:00
Yasuo Ohgaki
b83255aab0 Fix last commit. This line isn't supposed to be replaced. 2002-09-08 00:27:05 +00:00
Yasuo Ohgaki
17e0d9c642 MFB 2002-09-07 21:04:14 +00:00
Marcus Boerger
a1f7bb12f1 use php_error_docref() 2002-08-25 18:45:02 +00:00
Yasuo Ohgaki
6ad0dbf5fa Add some assertion 2002-08-08 03:08:54 +00:00
Rui Hirokawa
7527bf0c58 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
Zeev Suraski
a842e12ad2 Fix for non-mbstring builds. Bad Yasuo! :) 2002-07-31 16:25:12 +00:00
Yasuo Ohgaki
92e542db27 Fixed some.php?a&b&c does not initilize $_GET['a'], $_GET['b'], $_GET['c']
when mbstr-enc-trans is disabled.
# There is a bug in php_mbstr_encoding_handler() alo, I'll fix it later.
2002-07-28 04:18:40 +00:00
Stefan Esser
5b3ee5f27a break out if there is no data to work on. 2002-07-24 11:25:36 +00:00
Sascha Schumann
c998176089 free_index is set but never used 2002-05-04 17:34:41 +00:00
Sebastian Bergmann
38933514e1 Update headers. 2001-12-11 15:32:16 +00:00
Zeev Suraski
a25ccbec2e whitespace 2001-11-24 16:05:22 +00:00
Jeroen van Wolffelaar
c033288573 Back-substitute for Z_* macro's. If it breaks some extension (the script isn't optimal, it parses for example var->zval.value incorrect) please let me know. 2001-09-25 21:58:48 +00:00
Derick Rethans
78747bd2df - Don't wrap lines... this is annoying while coding. 2001-09-09 13:29:31 +00:00
Daniel Beulshausen
0dab84d065 fix SAPI_POST_* exports 2001-08-15 18:01:48 +00:00
Sascha Schumann
23b9300fd1 more tsrm cleanup 2001-08-06 03:50:52 +00:00
Zeev Suraski
d87cc976e1 Redesigned thread safety mechanism - nua nua 2001-07-28 11:36:37 +00:00
Zeev Suraski
fe6f8712a4 - Get rid of ELS_*(), and use TSRMLS_*() instead.
- Move to the new ts_allocate_id() API
This patch is *bound* to break some files, as I must have had typos somewhere.
If you use any uncommon extension, please try to build it...
2001-07-27 10:16:41 +00:00
Rasmus Lerdorf
81e2cf03ac Fix folding and clean up some extensions 2001-06-06 13:06:12 +00:00
Rasmus Lerdorf
25c3a3a39d vim-6 does folding - clean up a bunch of missing folding tags plus
some misguided RINIT and RSHUTDOWN calls in a few fringe extensions
2001-06-05 13:12:10 +00:00
foobar
349b2bebe3 fixed typo in CVS id 2001-04-06 01:50:40 +00:00
foobar
c34d2b91da Added new configuration directives:
arg_separator.input and arg_separator.output
2001-04-04 20:46:26 +00:00
foobar
460293fbdc Cookies use ; as argument separator.
# And also the first step for the possible configure option
2001-04-04 00:37:06 +00:00
foobar
8c97f5c04d Fix the arg_separator behaviour. Only & or ; is allowed as separators so no need to use the ini setting here. 2001-03-27 11:34:51 +00:00
Andi Gutmans
eb6ba01d1c - Fix copyright notices with 2001 2001-02-26 06:11:02 +00:00
Stanislav Malyshev
0731f54d35 Fix #7987: POST/GET: string with \0(%00) values not parsed correctly 2000-12-12 10:47:47 +00:00
Zeev Suraski
9e40204f00 @- In CGI mode, $HTTP_SERVER_VARS now includes all of the environment variables
@  as well (Zeev)
2000-11-07 18:25:29 +00:00
Sascha Schumann
43ff395b65 Const'ify part of sapi_request_info.
query_string, post_data, path_translated, request_uri, auth_user,
auth_password and argv0 are modified, so they cannot become const.
2000-11-02 15:47:02 +00:00
Stanislav Malyshev
1ccac6ed55 Add additional parameter to parse_str for saving result (thanks to
John Bafford <dshadow@zort.net>)
@ Added second parameter for parse_str to save result (John Bafford)
2000-09-11 14:50:26 +00:00
Zeev Suraski
eb32144902 - Remove track_vars - it is now always on
- Make the various $HTTP_*_VARS[] arrays be defined always,
  even if they're empty
- Fix Win32 build and warnings
2000-09-05 19:06:29 +00:00
Sascha Schumann
8e0ae5d152 Cleaning up some mess 2000-08-21 09:50:53 +00:00
Zeev Suraski
e043439ff6 Update the license with the new clause 6 2000-05-18 15:34:45 +00:00
Sascha Schumann
d0f3764ee2 Change reentrancy API to always use the php prefix.
Check for the declaration of reentrant functions, so that we can use
them in non-ZTS mode on all platforms.
2000-05-04 10:38:17 +00:00
Andi Gutmans
5b2bad3825 - Nuke hash_*_ptr() functions 2000-03-24 11:16:24 +00:00
Zeev Suraski
583556a3c2 @- Switched back to the old $HTTP_*_VARS[] behavior - $HTTP_GET_VARS["foo"]
@  and $foo are no longer references to each other, but separate variables
@  like they were prior to PHP 4.0 Beta 4 (Zeev)
2000-02-28 05:33:43 +00:00
Zeev Suraski
0e90b9dc83 @- The various $HTTP_*_VARS[] are now protected, and cannot be manipulated by
@  user input (Zeev)
This patch is untested!  I'll only have time to test it thoroughly in a couple of hours...
2000-02-26 16:36:57 +00:00
Thies C. Arntzen
361ae6886e @- Fixed crash when magic_quotes were switched off. (Thies) 2000-02-21 12:13:27 +00:00
Zeev Suraski
9b621d1c8f Get the license right... (this won't make it to RC1 of B4) 2000-02-19 23:21:46 +00:00
Zeev Suraski
739bdec582 Worked on beautifying rfc1867.c a bit
@- Introduced $HTTP_POST_FILES[], that contains information about files uploaded
@  through HTTP upload (Zeev)
2000-02-19 20:12:26 +00:00
Zeev Suraski
a6393de6f7 Make POST handling the way it should be. RFC1867, and any future POST handlers we might
have in the future now obey to the variables_order directive, and there's a real way modular
way to handle POST content.
This is all untested, BEFORE_SAPI_POST_PATCH_17_FEB_2000 tagged before submission
@- Made multipart/form-data content obey to the variables_order directive (Zeev)
2000-02-17 20:23:59 +00:00
Zeev Suraski
4a211a80fb @- Fixed RFC1867 file upload under Windows (Zeev)
Fixed a memory leak
2000-02-15 22:51:18 +00:00
Andi Gutmans
3811b58a7d - Improve startup speed a bit by using the hash_*_ptr() functions 2000-02-13 13:25:01 +00:00
Zeev Suraski
b2449f929c - Change the argument order of php_register_variable() to something more
intuitive.
- Make the authentication variables be a part of the HTTP_SERVER_VARS[] array
2000-01-29 11:55:44 +00:00
Zeev Suraski
99f079a349 - A few fixes
- Added register_argv_argc directive to allow disabling of argv/argc
2000-01-28 18:29:37 +00:00
Zeev Suraski
9ab35ae393 Tried to centralize global variable registration as much as possible:
- Added $HTTP_ENV_VARS[] and $HTTP_SERVER_VARS[] support, which similarly
  to $HTTP_GET_VARS[], contain environment and server variables.  Setting
  register_globals to Off will now also prevent registration of the
  environment and server variables into the global scope (Zeev)
- Renamed gpc_globals to register_globals (Zeev)
- Introduced variables_order that deprecates gpc_order, and allows control
  over the server and environment variables, in addition to GET/POST/Cookies
  (Zeev)
2000-01-28 17:24:53 +00:00