curl-and-php
Re: double headers when doing NTLM auth
From: Daniel Stenberg <daniel_at_haxx.se>
Date: Tue, 1 Nov 2005 22:56:00 +0100 (CET)
Date: Tue, 1 Nov 2005 22:56:00 +0100 (CET)
On Tue, 1 Nov 2005, Martin Sarsale wrote:
> I've found that, when using NTLM authentication I get double headers in the
> response: the first is the 401 and the 2nd is the 200.
That is quite expected. If you use 'anyauth' you'll even get two 401 and one
200.
> How can I know how many headers are being returned?
Why not simply count them?
> As Im receiving this headers duplicated on every request,
Only if you don't re-use the request and only if you use NTLM the same way all
the time.
> Im using this to get just the 2nd header and the body, but I would like
> something more stable.
You know that when you get the 200 code that is the start of the "final" set
of headers.
-- Commercial curl and libcurl Technical Support: http://haxx.se/curl.html _______________________________________________ http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-phpReceived on 2005-11-01