httplib continuation packets
Haakon Riiser
hakonrk at fys.uio.no
Sat Nov 11 18:43:33 EST 2006
[Fredrik Lundh]
> Haakon Riiser wrote:
>
>> Yes, and it doesn't help.
>
> then the server is mostly likely broken beyond repair.
It's not in my power to upgrade the server, unfortunately.
Guess I'll have to use Perl.
> to see if this really is the problem, you could try moving the call to
> self._send_output() from the end of the endheaders() method to the end
> of the _send_request() method (around line 870 in httplib.py, at least
> in 2.5).
Tried this, but the tcpdump still looks the same (two packets: one
with the headers, one with the body), and now it fails with
urllib2.HTTPError: HTTP Error 501: Not Implemented
Nevertheless, I'm fairly sure that the packet fragmentation is
the culprit. It works perfectly with Perl, even when I make
no effort at all to spoof the browser (no user-agent, referer,
cookies, etc.).
--
Haakon
More information about the Python-list
mailing list