From 86efc3ee53abaf1e22b53c1b360c51829e476115 Mon Sep 17 00:00:00 2001 From: Werner Koch Date: Thu, 1 Dec 2016 13:08:02 +0100 Subject: [PATCH] gpg: Let only Dirmngr decide whether CERT is supported. * g10/getkey.c (parse_auto_key_locate): Do not build parts depending on USE_DNS_CERT. -- This also removes USE_DNS_SRV from commented code. Signed-off-by: Werner Koch --- g10/getkey.c | 2 -- g10/keyserver.c | 4 ---- 2 files changed, 6 deletions(-) diff --git a/g10/getkey.c b/g10/getkey.c index 6eec087cf..e39de28ae 100644 --- a/g10/getkey.c +++ b/g10/getkey.c @@ -4153,10 +4153,8 @@ parse_auto_key_locate (char *options) akl->type = AKL_LDAP; else if (ascii_strcasecmp (tok, "keyserver") == 0) akl->type = AKL_KEYSERVER; -#ifdef USE_DNS_CERT else if (ascii_strcasecmp (tok, "cert") == 0) akl->type = AKL_CERT; -#endif else if (ascii_strcasecmp (tok, "pka") == 0) akl->type = AKL_PKA; else if (ascii_strcasecmp (tok, "dane") == 0) diff --git a/g10/keyserver.c b/g10/keyserver.c index 9148e7d97..c7363c98f 100644 --- a/g10/keyserver.c +++ b/g10/keyserver.c @@ -2084,11 +2084,9 @@ keyserver_import_ldap (ctrl_t ctrl, struct keyserver_spec *keyserver; strlist_t list=NULL; int rc,hostlen=1; -#ifdef USE_DNS_SRV struct srventry *srvlist=NULL; int srvcount,i; char srvname[MAXDNAME]; -#endif /* Parse out the domain */ domain=strrchr(name,'@'); @@ -2102,7 +2100,6 @@ keyserver_import_ldap (ctrl_t ctrl, keyserver->host=xmalloc(1); keyserver->host[0]='\0'; -#ifdef USE_DNS_SRV snprintf(srvname,MAXDNAME,"_pgpkey-ldap._tcp.%s",domain); FIXME("network related - move to dirmngr or drop the code"); @@ -2130,7 +2127,6 @@ keyserver_import_ldap (ctrl_t ctrl, } free(srvlist); -#endif /* If all else fails, do the PGP Universal trick of ldap://keys.(domain) */