diff -Nru gnupg2-2.2.19/debian/changelog gnupg2-2.2.19/debian/changelog --- gnupg2-2.2.19/debian/changelog 2020-03-10 18:50:46.000000000 +0000 +++ gnupg2-2.2.19/debian/changelog 2021-01-06 18:10:35.000000000 +0000 @@ -1,3 +1,10 @@ +gnupg2 (2.2.19-3ubuntu2.1) focal; urgency=medium + + * d/p/dirmngr-handle-EAFNOSUPPORT-at-connect_server.patch: + - Fix IPv6 connectivity for dirmngr (LP: #1910432) + + -- Heitor Alves de Siqueira Wed, 06 Jan 2021 18:10:35 +0000 + gnupg2 (2.2.19-3ubuntu2) focal; urgency=medium * Don't declare diffutils as a test dependency, this package is essential diff -Nru gnupg2-2.2.19/debian/patches/dirmngr-handle-EAFNOSUPPORT-at-connect_server.patch gnupg2-2.2.19/debian/patches/dirmngr-handle-EAFNOSUPPORT-at-connect_server.patch --- gnupg2-2.2.19/debian/patches/dirmngr-handle-EAFNOSUPPORT-at-connect_server.patch 1970-01-01 00:00:00.000000000 +0000 +++ gnupg2-2.2.19/debian/patches/dirmngr-handle-EAFNOSUPPORT-at-connect_server.patch 2021-01-06 18:10:35.000000000 +0000 @@ -0,0 +1,38 @@ +From ca937cf390662b830d4fc5d295e69b24b1778050 Mon Sep 17 00:00:00 2001 +From: NIIBE Yutaka +Date: Mon, 13 Jul 2020 10:00:58 +0900 +Subject: [PATCH] dirmngr: Handle EAFNOSUPPORT at connect_server. + +* dirmngr/http.c (connect_server): Skip server with EAFNOSUPPORT. + +-- + +GnuPG-bug-id: 4977 +Signed-off-by: NIIBE Yutaka + +Origin: backport, https://git.gnupg.org/cgi-bin/gitweb.cgi?p=gnupg.git;a=commit;h=109d16e8f644 +Bug-Ubuntu: https://bugs.launchpad.net/bugs/1910432 +--- + dirmngr/http.c | 9 +++++++++ + 1 file changed, 9 insertions(+) + +Index: gnupg2/dirmngr/http.c +=================================================================== +--- gnupg2.orig/dirmngr/http.c ++++ gnupg2/dirmngr/http.c +@@ -3005,6 +3005,15 @@ connect_server (const char *server, unsi + sock = my_sock_new_for_addr (ai->addr, ai->socktype, ai->protocol); + if (sock == ASSUAN_INVALID_FD) + { ++ if (errno == EAFNOSUPPORT) ++ { ++ if (ai->family == AF_INET) ++ v4_valid = 0; ++ if (ai->family == AF_INET6) ++ v6_valid = 0; ++ continue; ++ } ++ + err = gpg_err_make (default_errsource, + gpg_err_code_from_syserror ()); + log_error ("error creating socket: %s\n", gpg_strerror (err)); diff -Nru gnupg2-2.2.19/debian/patches/series gnupg2-2.2.19/debian/patches/series --- gnupg2-2.2.19/debian/patches/series 2020-03-10 09:58:47.000000000 +0000 +++ gnupg2-2.2.19/debian/patches/series 2021-01-06 18:10:35.000000000 +0000 @@ -21,3 +21,4 @@ gpg-drop-import-clean-from-default-keyserver-import-optio.patch from-master/gpg-Fix-output-of-with-secret-if-a-pattern-is-given.patch dirmngr-honor-http-proxy.patch +dirmngr-handle-EAFNOSUPPORT-at-connect_server.patch