cURL / Mailing Lists / curl-library / Single Mail

curl-library

Infinite loop using libcurl with NTLM

From: Paras S <livetestid_at_live.in>
Date: Tue, 25 Sep 2012 17:48:46 +0530

I am using libcurl 7.24, with OpenSSL 1.0.0g.

I am using curl to do a HTTP POST to an IIS 7.5 server.
I initialize curl with a connect timeout of 60s, and total timeout (CURLOPT_TIMEOUT) of 180s.

The server initially responds with 401, and curl does the NTLM request response, after which the server responds with HTTP 302.

curl now attempts to follow the location, which returns 401. So curl retries to attempt the NTLM authentication, starting with the NTLM type 1 message. The server does not respond, and after a timeout, curl retries the same, infinitely.

curl gets stuck in this loop, and does not honor the timeout set for CURLOPT_TIMEOUT.
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2012-09-25