curl / Mailing Lists / curl-library / Single Mail
Buy commercial curl support from WolfSSL. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder himself.

RE: CURLINFO_REDIRECT_COUNT

From: Mellergård, Daniel via curl-library <curl-library_at_lists.haxx.se>
Date: Fri, 9 Dec 2022 09:08:28 +0000

> To me, it sounded like you expressed the optimization libcurl already does.

That sounds great in that case. Then it's probably just some bug. Just to clarify, using CURLAUTH_ANY for transfers, when a "negotiation" has already been made with an origin, we have an existing connection to the host and have selected Basic as auth method in a previous transfer, libcurl seems to "negotiate" again (to find out that Basic should still be used). This causes an extra roundtrip. (https 1.1 is being used, if that might matter.)

So when a connection is reused, I /most often/ get two calls to CURLOPT_PREREQFUNCTION, but not always. For every transfer I can see that a very short namelookup is made (probably cached by libcurl). The first time a connection is used I can see that connect and auth is made as well, but not for continued use of the connection. (This is conclusions made by visualizing the libcurl time information after a transfer.)

When CURLAUTH_BASIC is explicitly set, I always get only one call to CURLOPT_PREREQFUNCTION per transfer, which is expected.

Is there any further logging I could enable, preferably without rebuilding libcurl?
-- 
Unsubscribe: https://lists.haxx.se/listinfo/curl-library
Etiquette:   https://curl.se/mail/etiquette.html
Received on 2022-12-09