Hello, I can't find anything doing setsockopt on the DoH socket. Would it make sense to do something like this? Or would it make things worse? The reason is I'm trying to do policy based routing by setting mark/tos on requests. So I want everything from libcurl to go through the same routing rules. Or is there a reason for not doing it at all?
This is untested code, and mostly there for discussion. If it makes sense I could do a proper pull request, or if there is a will for a separate opt I could do that too. Regards, Magnus Röös diff --git a/lib/doh.c b/lib/doh.c index 7a38eab01..57d76ddb6 100644 --- a/lib/doh.c +++ b/lib/doh.c @@ -267,6 +267,10 @@ static CURLcode dohprobe(struct Curl_easy *data, ERROR_CHECK_SETOPT(CURLOPT_VERBOSE, 1L); if(data->set.no_signal) ERROR_CHECK_SETOPT(CURLOPT_NOSIGNAL, 1L); + if(data->set.fsockopt) + ERROR_CHECK_SETOPT(CURLOPT_SOCKOPTFUNCTION, data->set.fsockopt); + if(data->set.sockopt_client) + ERROR_CHECK_SETOPT(CURLOPT_SOCKOPTDATA, data->set.sockopt_client); ERROR_CHECK_SETOPT(CURLOPT_SSL_VERIFYHOST, data->set.doh_verifyhost ? 2L : 0L);
-- Unsubscribe: https://lists.haxx.se/mailman/listinfo/curl-library Etiquette: https://curl.se/mail/etiquette.html