ID:               43008
 User updated by:  php at benjaminschulz dot com
-Summary:          php://filter uris ignore url encoded filternames
 Reported By:      php at benjaminschulz dot com
 Status:           Open
 Bug Type:         Feature/Change Request
 Operating System: linux
 PHP Version:      5.3CVS-2007-10-17 (CVS)
 New Comment:

If the filtername is not URL encoded than i get this:
Warning: readfile(): unable to create or locate filter
"convert.iconv.ISO-8859-15" in ...
Warning: readfile(): Unable to create filter
(convert.iconv.ISO-8859-15) in ...
Warning: readfile(): unable to locate filter "UTF-8" in ...
Warning: readfile(): Unable to create filter (UTF-8) in ...


Previous Comments:
------------------------------------------------------------------------

[2007-10-17 17:04:40] php at benjaminschulz dot com

Description:
------------
because filternames can contain slashes (convert.iconv.from-enc/to-enc)
it should be possible to pass URL-encodet filternames to php://filter

Reproduce code:
---------------
<?php
$str =
'php://filter/read=convert.iconv.ISO-8859-15%2FUTF-8/resource=data://text/plain,foobar';
                                             ^ url encoded slash

Expected result:
----------------
string(6) "foobar"


Actual result:
--------------
Warning:  file_get_contents(): unable to create or locate filter
"convert.iconv.ISO-8859-15%2FUTF-8" in /var/www/foo/a.php on line 34
Warning:  file_get_contents(): Unable to create filter
(convert.iconv.ISO-8859-15%2FUTF-8) in /var/www/foo/a.php on line 34


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=43008&edit=1

Reply via email to