summaryrefslogtreecommitdiffstats
path: root/keyserver
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2014-05-16 20:58:58 +0200
committerWerner Koch <wk@gnupg.org>2014-05-16 21:01:08 +0200
commit8b90d79818355b81ce223e1cb96cd0c939096fe2 (patch)
tree74d1f37bc8ad5957ad4a77bfd8bbcce2285d336e /keyserver
parentgpg: Fix uninitialized access to search descindex with gpg keyboxes. (diff)
downloadgnupg2-8b90d79818355b81ce223e1cb96cd0c939096fe2.tar.xz
gnupg2-8b90d79818355b81ce223e1cb96cd0c939096fe2.zip
http: Allow overriding of the Host header.
* common/http.c (http_open): Add arg httphost. (http_open_document): Pass NULL for httphost. (send_request): Add arg httphost. If given, use HTTPHOST instead of SERVER. Use https with a proxy if requested. (http_verify_server_credentials): Do not stop at the first error message. * dirmngr/ocsp.c (do_ocsp_request): Adjust call to http_open. * keyserver/curl-shim.c (curl_easy_perform): Ditto. * dirmngr/ks-engine-http.c (ks_http_fetch): Ditto. * dirmngr/ks-engine-hkp.c (ks_hkp_help): Ditto.
Diffstat (limited to 'keyserver')
-rw-r--r--keyserver/curl-shim.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/keyserver/curl-shim.c b/keyserver/curl-shim.c
index 500d9f562..696efe2c7 100644
--- a/keyserver/curl-shim.c
+++ b/keyserver/curl-shim.c
@@ -198,7 +198,7 @@ curl_easy_perform(CURL *curl)
if(curl->flags.post)
{
- rc = http_open (&curl->hd, HTTP_REQ_POST, curl->url, curl->auth,
+ rc = http_open (&curl->hd, HTTP_REQ_POST, curl->url, NULL, curl->auth,
0, proxy, NULL, curl->srvtag,
curl->headers?curl->headers->list:NULL);
if (!rc)
@@ -222,7 +222,7 @@ curl_easy_perform(CURL *curl)
}
else
{
- rc = http_open (&curl->hd, HTTP_REQ_GET, curl->url, curl->auth,
+ rc = http_open (&curl->hd, HTTP_REQ_GET, curl->url, NULL, curl->auth,
0, proxy, NULL, curl->srvtag,
curl->headers?curl->headers->list:NULL);
if (!rc)
@@ -282,7 +282,7 @@ curl_easy_perform(CURL *curl)
err=CURLE_COULDNT_CONNECT;
break;
}
-
+
return handle_error(curl,err,errstr);
}