Parcourir la source

dpkg-source: ensure trustedkeys.gpg is used to check signatures

Raphael Hertzog il y a 17 ans
Parent
commit
0a3d3fe21b
2 fichiers modifiés avec 6 ajouts et 0 suppressions
  1. 3 0
      debian/changelog
  2. 3 0
      scripts/Dpkg/Source/Package.pm

+ 3 - 0
debian/changelog

@@ -31,6 +31,9 @@ dpkg (1.15.3) UNRELEASED; urgency=low
     normally blacklisted. This can be useful for libgcc to include symbols
     normally blacklisted. This can be useful for libgcc to include symbols
     that the toolchain allows to be shared but that are often static (and
     that the toolchain allows to be shared but that are often static (and
     hence are blacklisted for this reason). Closes: #533642
     hence are blacklisted for this reason). Closes: #533642
+  * In dpkg-source, explicitely pass --keyring ~/.gnupg/trustedkeys.gpg to
+    gpgv as it does not use it if other --keyring parameters are given.
+    Closes: #530769
 
 
   [ Joachim Breitner ]
   [ Joachim Breitner ]
   * Warn about unused substvars in dpkg-gencontrol. Closes: #532760
   * Warn about unused substvars in dpkg-gencontrol. Closes: #532760

+ 3 - 0
scripts/Dpkg/Source/Package.pm

@@ -283,6 +283,9 @@ sub check_signature {
         push @exec, "gpg", "--no-default-keyring", "-q", "--verify";
         push @exec, "gpg", "--no-default-keyring", "-q", "--verify";
     }
     }
     if (scalar(@exec)) {
     if (scalar(@exec)) {
+        if (-r "$ENV{'HOME'}/.gnupg/trustedkeys.gpg") {
+            push @exec, "--keyring", "$ENV{'HOME'}/.gnupg/trustedkeys.gpg";
+        }
         foreach my $vendor_keyring (run_vendor_hook('keyrings')) {
         foreach my $vendor_keyring (run_vendor_hook('keyrings')) {
             if (-r $vendor_keyring) {
             if (-r $vendor_keyring) {
                 push @exec, "--keyring", $vendor_keyring;
                 push @exec, "--keyring", $vendor_keyring;