#40197 [Opn->Bgs]: Cannot access remote files
| From: | tony2001@php.net | Date: | Thu, 25 Jan 2007 15:03:46 +0000 |
| Subject: | #40197 [Opn->Bgs]: Cannot access remote files | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-108048@lists.php.net to get a copy of this message | ||
ID: 40197
Updated by: tony2001@php.net
Reported By: ddrewery at gmail dot com
-Status: Open
+Status: Bogus
Bug Type: HTTP related
Operating System: Fedora Core 6
PHP Version: 5.2.0
Assigned To: tony2001
New Comment:
>She had me uncheck a box in the internal settings of the
>firewall labled "Enforce Host Tag Search with for CFS"
>and suddently everything works.
So this is the answer to the question why fsockopen() worked.
As I said, PHP uses HTTP/1.0 for http streams by default and "Host: "
header is required only by HTTP/1.1.
Previous Comments:
------------------------------------------------------------------------
[2007-01-25 14:54:59] ddrewery at gmail dot com
Ok, I finally go ahold of sonic wall tech support and they have
resolved the issue. Maybe you can help me understand what this means.
She had me uncheck a box in the internal settings of the firewall
labled "Enforce Host Tag Search with for CFS" and suddently everything
works. She rambled off something about header packet size being
limited to 32.. but lost me from there.
With that information, can you tell me what fsocketopen and fopen would
be sending differently to change the header response?
------------------------------------------------------------------------
[2007-01-23 18:13:18] tony2001@php.net
Use a sniffer. tcpdump, for example.
------------------------------------------------------------------------
[2007-01-23 18:03:39] ddrewery at gmail dot com
Yes, it works without the firewall. That is why I agreed with you in
my earlier post. However, my question is now about fsocketopen vs
fopen.. what is the actual code that drives file_get_contents()? There
is obviously something differnt in the headers that my firewall doesn't
like.. how do I see what headers php is sending?
------------------------------------------------------------------------
[2007-01-23 17:55:20] tony2001@php.net
Let's try another route.
Please try to run the same code on a machine, which is 100% NOT behind
a firewall and see if it works for you.
------------------------------------------------------------------------
[2007-01-23 17:46:47] ddrewery at gmail dot com
I just change the fsocket example to
$out = "GET / HTTP/1.0\r\n";
It still works fine. What method does the wrapper use? Does it
literally open a socket just like fsocketopen would?
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
http://bugs.php.net/40197
--
Edit this bug report at http://bugs.php.net/?id=40197&edit=1