[Bug 2115177] Re: apt modernize adds wrong keyring

Julian Andres Klode 2115177 at bugs.launchpad.net
Fri Jul 11 07:12:37 UTC 2025


APT makes an educated guess for what the keyring could be but it's not a
100% certainty. It lower cases the Origin field in the Release file and
then uses /usr/share/keyrings/$lowerorigin-archive-keyring.gpg when
running modernize-sources.

I'm considering adding some quirks for "official" repositories (debian
backport has the same issue), but it's not going to be particularly
complete regardless.

** Changed in: apt (Ubuntu)
   Importance: Undecided => Wishlist

** Changed in: apt (Ubuntu)
       Status: New => Triaged

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to apt in Ubuntu.
https://bugs.launchpad.net/bugs/2115177

Title:
  apt modernize adds wrong keyring

Status in apt package in Ubuntu:
  Triaged

Bug description:
  I created /etc/apt/sources.list.d/ddebs.list with content

  deb http://ddebs.ubuntu.com questing main restricted universe multiverse
  deb http://ddebs.ubuntu.com questing-updates main restricted universe multiverse
  deb http://ddebs.ubuntu.com questing-proposed main restricted universe multiverse

  After running `apt modernize` I had a file

  /etc/apt/sources.list.d/ddebs.sources

  Types: deb
  URIs: http://ddebs.ubuntu.com/
  Suites: questing
  Components: main  restricted universe multiverse
  Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg

  Types: deb
  URIs: http://ddebs.ubuntu.com/
  Suites: questing-updates
  Components: main  restricted universe multiverse
  Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg

  Types: deb
  URIs: http://ddebs.ubuntu.com/
  Suites: questing-proposed
  Components: main  restricted universe multiverse
  Signed-By: /usr/share/keyrings/ubuntu-archive-keyring.gpg

  `apt-get update` fails with

  W: An error occurred during the signature verification. The repository
  is not updated and the previous index files will be used. OpenPGP
  signature verification failed: http://ddebs.ubuntu.com questing
  InRelease: The following signatures couldn't be verified because the
  public key is not available: NO_PUBKEY C8CAB6595FDFF622

  `apt modernize` should have added the correct keyring and possibly
  should have used a single entry:

  Types: deb
  URIs: http://ddebs.ubuntu.com/
  Suites: questing questing-updates questing-proposed
  Components: main  restricted universe multiverse
  Signed-by: /usr/share/keyrings/ubuntu-dbgsym-keyring.gpg

  Please, associate http://ddebs.ubuntu.com/ with the correct keyring.

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




More information about the foundations-bugs mailing list