← Back to team overview

sts-sponsors team mailing list archive

[Bug 1910432] Re: dirmngr doesn't work with kernel parameter ipv6.disable=1

 

Hello Heitor, or anyone else affected,

Accepted gnupg2 into groovy-proposed. The package will build now and be
available at
https://launchpad.net/ubuntu/+source/gnupg2/2.2.20-1ubuntu1.1 in a few
hours, and then in the -proposed repository.

Please help us by testing this new package.  See
https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how
to enable and use -proposed.  Your feedback will aid us getting this
update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug,
mentioning the version of the package you tested, what testing has been
performed on the package and change the tag from verification-needed-
groovy to verification-done-groovy. If it does not fix the bug for you,
please add a comment stating that, and change the tag to verification-
failed-groovy. In either case, without details of your testing we will
not be able to proceed.

Further information regarding the verification process can be found at
https://wiki.ubuntu.com/QATeam/PerformingSRUVerification .  Thank you in
advance for helping!

N.B. The updated package will be released to -updates after the bug(s)
fixed by this package have been verified and the package has been in
-proposed for a minimum of 7 days.

** Changed in: gnupg2 (Ubuntu Groovy)
       Status: In Progress => Fix Committed

** Tags added: verification-needed-groovy

-- 
You received this bug notification because you are a member of STS
Sponsors, which is subscribed to the bug report.
https://bugs.launchpad.net/bugs/1910432

Title:
  dirmngr doesn't work with kernel parameter ipv6.disable=1

Status in gnupg2 package in Ubuntu:
  Fix Released
Status in gnupg2 source package in Bionic:
  In Progress
Status in gnupg2 source package in Focal:
  Fix Committed
Status in gnupg2 source package in Groovy:
  Fix Committed
Status in gnupg2 source package in Hirsute:
  Fix Released

Bug description:
  [Impact]
  apt-key fails to fetch keys with "Address family not supported by protocol"

  [Description]
  We've had users report issues about apt-key being unable to fetch keys when IPv6 is disabled. As the mentioned kernel command line parameter disables IPV6 socket support, servers that allow/respond with IPv6 will cause connect_server() to fail with EAFNOSUPPORT.

  As this error is not being handled in some version of dirmngr, it'll
  simply fail the connection and could cause other processes to fail as
  well. In the test scenario below, it's easy to demonstrate this
  behaviour through apt-key.

  This has been reported upstream, and has been fixed with the following commit:
  - dirmngr: Handle EAFNOSUPPORT at connect_server. (109d16e8f644)

  The fix has been present upstream starting with GnuPG 2.22, so it's
  not currently available in any Ubuntu releases.

  [Test Case]
  1. Spin up Focal VM

  2. Disable IPv6:
  $ sudo vi /etc/default/grub
  (...)
  GRUB_CMDLINE_LINUX="ipv6.disable=1"
  $ sudo update-grub

  3. Reboot the VM

  4. Try to fetch a key:
  sudo apt-key adv --fetch-keys https://www.postgreSQL.org/media/keys/ACCC4CF8.asc

  You'll get the following error:
  gpg: WARNING: unable to fetch URI https://www.postgresql.org/media/keys/ACCC4CF8.asc: Address family not supported by protocol

  [Regression Potential]
  The patch introduces additional error handling when connecting to servers, to properly mark remote hosts as having valid IPv4 and/or IPv6 connectivity. We should look out for potential regressions when connecting to servers with exclusive IPv4 or IPv6 connectivity, to make sure the server is not getting marked as 'dead' due to missing one of the versions.
  This commit has also been tested in the corresponding Ubuntu series, and has been deemed safe for backporting to stable branches of upstream GnuPG. The overall regression potential for this change should be fairly low, and breakage should be easily spotted.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gnupg2/+bug/1910432/+subscriptions