http: handle auth challenge for non-proxy auth

This commit is contained in:
Pierre Tachoire
2026-03-09 19:23:36 +01:00
parent 9172e16e80
commit 37c34351ee
3 changed files with 11 additions and 1 deletions

View File

@@ -377,6 +377,10 @@ pub const Connection = struct {
try libcurl.curl_easy_setopt(self.easy, .proxy_user_pwd, creds.ptr);
}
pub fn setCredentials(self: *const Connection, creds: [:0]const u8) !void {
try libcurl.curl_easy_setopt(self.easy, .user_pwd, creds.ptr);
}
pub fn setCallbacks(
self: *const Connection,
comptime header_cb: libcurl.CurlHeaderFunction,