xref: /PHP-5.3/ext/standard/tests/file/bug43008.phpt (revision cb9dad9d)
1--TEST--
2Bug #43008 (php://filter uris ignore url encoded filternames and can't handle slashes)
3--SKIPIF--
4<?php
5if (!extension_loaded("iconv")) die("skip iconv extension not available");
6?>
7--FILE--
8<?php
9$url = b""
10	. b"php://filter/read="
11	. urlencode(b"convert.iconv.ISO-8859-15/UTF-8")
12	. b'|' . urlencode(b"string.rot13")
13	. b'|' . urlencode(b"string.rot13")
14	. b'|' . urlencode(b"convert.iconv.UTF-8/ISO-8859-15")
15	. b"/resource=data://text/plain,foob%E2r";
16var_dump(urlencode(file_get_contents($url)));
17?>
18--EXPECTF--
19string(8) "foob%E2r"
20