diff options
| author | Werner Koch <[email protected]> | 2019-11-18 16:22:45 +0000 |
|---|---|---|
| committer | Werner Koch <[email protected]> | 2019-11-18 17:24:02 +0000 |
| commit | ae9acb8745c1654b446b3cd5b9322b235723d9cb (patch) | |
| tree | c9d0e5a981f10d9dfe1b7cdf5f7e877ab1fd2417 /dirmngr/http.h | |
| parent | dirmngr: Fixed typo in recently added diagnostic. (diff) | |
| download | gnupg-ae9acb8745c1654b446b3cd5b9322b235723d9cb.tar.gz gnupg-ae9acb8745c1654b446b3cd5b9322b235723d9cb.zip | |
dirmngr: Forward http redirect warnings to gpg.
* dirmngr/http.c: Include dirmngr-status.h
(http_prepare_redirect): Emit WARNING status lines for redirection
problems.
* dirmngr/http.h: Include fwddecl.h.
(struct http_redir_info_s): Add field ctrl.
* dirmngr/ks-engine-hkp.c (send_request): Set it.
* dirmngr/ks-engine-http.c (ks_http_fetch): Set it.
* g10/call-dirmngr.c (ks_status_cb): Detect the two new warnings.
--
This should make it easier to diagnose problems with bad WKD servers.
Signed-off-by: Werner Koch <[email protected]>
Diffstat (limited to 'dirmngr/http.h')
| -rw-r--r-- | dirmngr/http.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/dirmngr/http.h b/dirmngr/http.h index 492e86726..01546374e 100644 --- a/dirmngr/http.h +++ b/dirmngr/http.h @@ -32,6 +32,7 @@ #define GNUPG_COMMON_HTTP_H #include <gpg-error.h> +#include "../common/fwddecl.h" struct uri_tuple_s { @@ -106,6 +107,7 @@ typedef struct http_context_s *http_t; struct http_redir_info_s { unsigned int redirects_left; /* Number of still possible redirects. */ + ctrl_t ctrl; /* The usual connection info or NULL. */ const char *orig_url; /* The original requested URL. */ unsigned int orig_onion:1; /* Original request was an onion address. */ unsigned int orig_https:1; /* Original request was a http address. */ |
