diff options
author | Werner Koch <wk@gnupg.org> | 2017-02-18 16:09:16 +0100 |
---|---|---|
committer | Werner Koch <wk@gnupg.org> | 2017-02-18 16:39:02 +0100 |
commit | a74902cccde539ee2bd216caec0da6eb54b67c1b (patch) | |
tree | daa1f4d3c39dd1ce5a26b1349e593ca893679520 /dirmngr/ks-engine-hkp.c | |
parent | dirmngr: Strip the default https port from the Host: header. (diff) | |
download | gnupg2-a74902cccde539ee2bd216caec0da6eb54b67c1b.tar.xz gnupg2-a74902cccde539ee2bd216caec0da6eb54b67c1b.zip |
dirmngr: Add per-session verify callback to http.c
* dirmngr/http.h (http_verify_cb_t): New type.
* dirmngr/http.c (http_session_s): Add fields flags, verify_cb, and
verify_cb_value.
(http_session_new): Remove arg tls_priority. Add args verify_cb and
verify-cb_value. Store them in the session object.
(send_request): Use per-session verify callback.
(http_verify_server_credentials) [HTTP_USE_NTBTLS]: Return
GPG_ERR_NOT_IMPLEMENTED.
* dirmngr/ks-engine-hkp.c (send_request): Adjust for changed
http_session_new.
* dirmngr/ks-engine-http.c (ks_http_fetch): Ditto.
* dirmngr/t-http.c (main): Ditto.
* dirmngr/server.c (do_get_cert_local): Replace xmalloc by malloc.
Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'dirmngr/ks-engine-hkp.c')
-rw-r--r-- | dirmngr/ks-engine-hkp.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/dirmngr/ks-engine-hkp.c b/dirmngr/ks-engine-hkp.c index e39d60ee6..b342f0968 100644 --- a/dirmngr/ks-engine-hkp.c +++ b/dirmngr/ks-engine-hkp.c @@ -1123,7 +1123,8 @@ send_request (ctrl_t ctrl, const char *request, const char *hostportstr, *r_fp = NULL; - err = http_session_new (&session, NULL, httphost, HTTP_FLAG_TRUST_DEF); + err = http_session_new (&session, httphost, HTTP_FLAG_TRUST_DEF, + NULL, ctrl); if (err) goto leave; http_session_set_log_cb (session, cert_log_cb); |