From: vasso dot spam at gmail dot com
Operating system: Windows
PHP version: 5.2.2
PHP Bug Type: HTTP related
Bug description: HTTP proxying bug
Description:
------------
HTTP proxing (after 5.1.0) works only if request_fulluri is set to true.
And there is no documentation about this.
Reproduce code:
---------------
$context = stream_context_create(
array('http'=>
array(
'proxy' => 'tcp://proxy.domain.com:3128/',
//'request_fulluri' => true,//Works if uncommented
)
)
);
$data = file_get_contents('http://google.com/', false, $context);
var_export($data);
Expected result:
----------------
+
Actual result:
--------------
Warning: file_get_contents(http://google.com/): failed to open stream:
HTTP request failed! HTTP/1.0 400 Bad Request
in http_proxy_bug.php on line 10
-
--
Edit bug report at http://bugs.php.net/?id=41413&edit=1
--
Try a CVS snapshot (PHP 4.4):
http://bugs.php.net/fix.php?id=41413&r=trysnapshot44
Try a CVS snapshot (PHP 5.2):
http://bugs.php.net/fix.php?id=41413&r=trysnapshot52
Try a CVS snapshot (PHP 6.0):
http://bugs.php.net/fix.php?id=41413&r=trysnapshot60
Fixed in CVS: http://bugs.php.net/fix.php?id=41413&r=fixedcvs
Fixed in release:
http://bugs.php.net/fix.php?id=41413&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=41413&r=needtrace
Need Reproduce Script: http://bugs.php.net/fix.php?id=41413&r=needscript
Try newer version: http://bugs.php.net/fix.php?id=41413&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=41413&r=support
Expected behavior: http://bugs.php.net/fix.php?id=41413&r=notwrong
Not enough info:
http://bugs.php.net/fix.php?id=41413&r=notenoughinfo
Submitted twice:
http://bugs.php.net/fix.php?id=41413&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=41413&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=41413&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=41413&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=41413&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=41413&r=gnused
Floating point limitations: http://bugs.php.net/fix.php?id=41413&r=float
No Zend Extensions: http://bugs.php.net/fix.php?id=41413&r=nozend
MySQL Configuration Error: http://bugs.php.net/fix.php?id=41413&r=mysqlcfg