Upayavira wrote:

I'm getting an HttpException: Unable to parse header: HTTP/1.0 200 OK Using a command like the following command:

curl -u user:pass -I -i "http://mysite:6998/page.exe?id=22222";

I got the following output:

HTTP/1.1 200 OK
Server: Microsoft-IIS/5.0
Date: Thu, 05 Aug 2004 10:20:32 GMT
Connection: close
HTTP/1.0 200 OK
content-type: text/html
content-length: 35079
Connection: Keep-Alive


Given the exception you are seeing, it is likely that the server really sends the above output. Naturally this sort of response is *completely* out of any HTTP spec. Not even is the response malformed, the headers are also contraditory.


God knows what causes the server to misbehave so badly. You might want to ask the manufacturer for support. Please don't ask for HttpClient supporting arbitrary garbage like that IIS response.

However the issue of duplicate HTTP respone lines or headers was raised before, I think. But I can't remember it's resolution at the moment. I guess we have built-in support for duplicate Connections headers, and the like. You may want to set HttpClient to lenien (non-strict) mode and retry.

HTH

Ortwin Glück

--
 _________________________________________________________________
 NOSE applied intelligence ag

 ortwin glück                      [www]      http://www.nose.ch
 software engineer
 hardturmstrasse 171               [pgp id]           0x81CF3416
 8005 zürich                       [office]      +41-1-277 57 35
 switzerland                       [fax]         +41-1-277 57 12

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to