On Mon, 2008-06-09 at 11:25 -0500, Eduardo J. Ortega U. wrote:
> Hi, all:
> 
> I am trying to use HttpClient to authenticate to a website, and do a
> couple of GET and POST requests. I can submit the authentication form,
> get the cookie, and after getting the cookie,  I can make a GET
> request and I see that it sends the approrpiate Cookie header. Then I
> attempt to do a POST request, but this one does not send the Cookie,
> thus the server think I haven't authenticated and nothing works after
> that :-(
> 
> 
> 2008/06/09 11:04:19:182 GMT-05:00 [DEBUG] header - >> "POST
> http://www.fosyga.gov.co/CGI/buda_logon.asp HTTP/1.1[\r][\n]"
> ...
> 2008/06/09 11:04:19:245 GMT-05:00 [DEBUG] header - << "Set-Cookie:
> ASPSESSIONIDSSSDBQST=HPNJBJKCJOJJDBLKGMOLFCNC; path=/[\r][\n]"
> ...
> 2008/06/09 11:04:19:260 GMT-05:00 [DEBUG] HttpMethodBase - Cookie
> accepted: "$Version=0; ASPSESSIONIDSSSDBQST=HPNJBJKCJOJJDBLKGMOLFCNC;
> $Path=/"
> ...
> 2008/06/09 11:04:19:260 GMT-05:00 [DEBUG] DefaultHttpParams - Set
> parameter http.protocol.cookie-policy = rfc2109
> ...
> 2008/06/09 11:04:19:260 GMT-05:00 [DEBUG] header - >> "GET
> http://www.fosyga.gov.co/CGI/buda_consulta_afil.asp?sstat=0
> HTTP/1.1[\r][\n]"
> ...
> 2008/06/09 11:04:19:260 GMT-05:00 [DEBUG] header - >> "Cookie:
> $Version=0; ASPSESSIONIDSSSDBQST=HPNJBJKCJOJJDBLKGMOLFCNC;
> $Path=/[\r][\n]"
> ...
> 2008/06/09 11:04:19:417 GMT-05:00 [DEBUG] header - << "HTTP/1.1 200 
> OK[\r][\n]"
> ...
> 2008/06/09 11:04:19:511 GMT-05:00 [DEBUG] DefaultHttpParams - Set
> parameter http.protocol.cookie-policy = rfc2109
> ...
> 2008/06/09 11:04:19:557 GMT-05:00 [DEBUG] header - >> "POST
> http://fosyga.gov.co/CGI/buda_consulta_afil.asp HTTP/1.1[\r][\n]"
> ...
> NO Cookie: ... header sent here. server replies assigning new cookie:
> 2008/06/09 11:04:19:792 GMT-05:00 [DEBUG] header - << "Set-Cookie:
> ASPSESSIONIDSSSDBQST=IPNJBJKCOILAONHGOMJLIDCB; path=/[\r][\n]"
> 
> See attached full log file. Please ignore the exceptions at the end of
> the file, as they are a result of not getting the right web page from
> the server because of the cookie issue. Any help is greatly
> appreciated.
> 

Eduardo,

According to the RFC2109, cookies originated from the
host www.fosyga.gov.co with the default domain scope may not be sent to
the host fosyga.gov.co. Try using the browser compatibility mode.

Oleg


> Thanks,
> 
> 


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

Reply via email to