mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-03 22:56:33 +02:00
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>
This commit is contained in:
parent
cd32ebd152
commit
a74902cccd
6 changed files with 58 additions and 23 deletions
|
@ -76,7 +76,8 @@ ks_http_fetch (ctrl_t ctrl, const char *url, estream_t *r_fp)
|
|||
once_more:
|
||||
/* Note that we only use the system provided certificates with the
|
||||
* fetch command. */
|
||||
err = http_session_new (&session, NULL, NULL, HTTP_FLAG_TRUST_SYS);
|
||||
err = http_session_new (&session, NULL, HTTP_FLAG_TRUST_SYS,
|
||||
NULL, ctrl);
|
||||
if (err)
|
||||
goto leave;
|
||||
http_session_set_log_cb (session, cert_log_cb);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue