]> git.ipfire.org Git - thirdparty/elfutils.git/commit
debuginfod-client: Use CURLOPT_MAXREDIRS
authorMark Wielaard <mark@klomp.org>
Wed, 13 May 2026 13:57:57 +0000 (15:57 +0200)
committerMark Wielaard <mark@klomp.org>
Thu, 14 May 2026 00:31:22 +0000 (02:31 +0200)
commit882739dbfeacc1d2170157f51112a9cc4d148f38
tree40c1a551b6941dc2f135fb776119217e0d15ab51
parent5d00d9adef9b9da986b887adc029b3574d59a398
debuginfod-client: Use CURLOPT_MAXREDIRS

Guard against bad servers. Older libcurl allowed unlimited
redirects. Newer libcurl default to max 30. Explicitly set
CURLOPT_MAXREDIRS to 6 (twice the number of redirects that seems
"reasonable"). This guards against badly setup servers that keep
redirecting. https://curl.se/libcurl/c/CURLOPT_MAXREDIRS.html

* debuginfod/debuginfod-client.c (init_handle): Add
CURLOPT_MAXREDIRS curl_easy_setopt_ck.

Signed-off-by: Mark Wielaard <mark@klomp.org>
debuginfod/debuginfod-client.c