Download src/php/php-src/ext/session/tests/021.phpt from meddyrat/dis-bench: direct link, hf CLI and curl.
- Browser
- Download file 1.86 kB
-
https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/ext/session/tests/021.phpt
- Command line
-
hf download hf://datasets/meddyrat/dis-bench/src/php/php-src/ext/session/tests/021.phpt
-
curl -L -o 021.phpt https://huggingface.co/datasets/meddyrat/dis-bench/resolve/main/src/php/php-src/ext/session/tests/021.phpt
1.86 kB
| --TEST-- | |
| rewriter handles form and fieldset tags correctly | |
| --EXTENSIONS-- | |
| session | |
| --SKIPIF-- | |
| include('skipif.inc'); | |
| --INI-- | |
| session.use_cookies=0 | |
| session.use_only_cookies=0 | |
| session.use_strict_mode=0 | |
| session.cache_limiter= | |
| session.use_trans_sid=1 | |
| url_rewriter.tags="a=href,area=href,frame=src,input=src,form=,fieldset=" | |
| session.name=PHPSESSID | |
| session.serialize_handler=php | |
| session.save_handler=files | |
| --FILE-- | |
| error_reporting(E_ALL); | |
| ini_set('session.trans_sid_hosts', 'php.net'); | |
| $_SERVER['HTTP_HOST'] = 'php.net'; | |
| session_id("test021"); | |
| session_start(); | |
| <form action="//bad.net/do.php"> | |
| <fieldset> | |
| <form action="//php.net/do.php"> | |
| <fieldset> | |
| ob_flush(); | |
| ini_set("url_rewriter.tags", "a=href,area=href,frame=src,input=src,form="); | |
| <form action="../do.php"> | |
| <fieldset> | |
| ob_flush(); | |
| ini_set("url_rewriter.tags", "a=href,area=href,frame=src,input=src,form=fakeentry"); | |
| <form action="/do.php"> | |
| <fieldset> | |
| ob_flush(); | |
| ini_set("url_rewriter.tags", "a=href,fieldset=,area=href,frame=src,input=src"); | |
| <form action="/foo/do.php"> | |
| <fieldset> | |
| session_destroy(); | |
| --EXPECTF-- | |
| Deprecated: PHP Startup: Disabling session.use_only_cookies INI setting is deprecated in Unknown on line 0 | |
| Deprecated: PHP Startup: Enabling session.use_trans_sid INI setting is deprecated in Unknown on line 0 | |
| Deprecated: ini_set(): Usage of session.trans_sid_hosts INI setting is deprecated in %s on line 4 | |
| <form action="//bad.net/do.php"> | |
| <fieldset> | |
| <form action="//php.net/do.php"><input type="hidden" name="PHPSESSID" value="test021" /> | |
| <fieldset> | |
| <form action="../do.php"><input type="hidden" name="PHPSESSID" value="test021" /> | |
| <fieldset> | |
| <form action="/do.php"><input type="hidden" name="PHPSESSID" value="test021" /> | |
| <fieldset> | |
| <form action="/foo/do.php"><input type="hidden" name="PHPSESSID" value="test021" /> | |
| <fieldset> | |