From a0dead5edce07838cf5ff3ec7205a3bff2a6ef70 Mon Sep 17 00:00:00 2001 From: Werner Koch Date: Tue, 21 Apr 2015 17:14:53 +0200 Subject: dirmngr: Add http proxy support for keyservers. * dirmngr/dirmngr.h (server_control_s): Add field http_proxy. * dirmngr/dirmngr.c (dirmngr_init_default_ctrl): Copy http_proxy value from OPT. (dirmngr_deinit_default_ctrl): New. (main): Call dirmngr_deinit_default_ctrl. * dirmngr/server.c (start_command_handler): Ditto. (option_handler): Add option "http-proxy". * dirmngr/crlfetch.c (crl_fetch): Take http_proxy from CTRL. * dirmngr/ocsp.c (do_ocsp_request): Ditto. * dirmngr/ks-engine-hkp.c (send_request): Add proxy support. * dirmngr/ks-engine-http.c (ks_http_fetch): Ditto. Signed-off-by: Werner Koch --- dirmngr/dirmngr.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'dirmngr/dirmngr.h') diff --git a/dirmngr/dirmngr.h b/dirmngr/dirmngr.h index 56abc86d4..4f037e714 100644 --- a/dirmngr/dirmngr.h +++ b/dirmngr/dirmngr.h @@ -99,7 +99,7 @@ struct int disable_http; /* Do not use HTTP at all. */ int disable_ldap; /* Do not use LDAP at all. */ int honor_http_proxy; /* Honor the http_proxy env variable. */ - const char *http_proxy; /* Use given HTTP proxy. */ + const char *http_proxy; /* The default HTTP proxy. */ const char *ldap_proxy; /* Use given LDAP proxy. */ int only_ldap_proxy; /* Only use the LDAP proxy; no fallback. */ int ignore_http_dp; /* Ignore HTTP CRL distribution points. */ @@ -174,12 +174,14 @@ struct server_control_s response. */ int audit_events; /* Send audit events to client. */ + char *http_proxy; /* The used http_proxy or NULL. */ }; /*-- dirmngr.c --*/ void dirmngr_exit( int ); /* Wrapper for exit() */ void dirmngr_init_default_ctrl (ctrl_t ctrl); +void dirmngr_deinit_default_ctrl (ctrl_t ctrl); void dirmngr_sighup_action (void); -- cgit v1.2.3