]> source.dussan.org Git - jgit.git/commit
[gpg] Correct finding public keys from pubring.gpg 67/1184467/2
authorThomas Wolf <twolf@apache.org>
Sat, 9 Mar 2024 23:04:41 +0000 (00:04 +0100)
committerThomas Wolf <twolf@apache.org>
Mon, 8 Apr 2024 17:10:58 +0000 (19:10 +0200)
commitd24eee7d5c502dc63d13e5584b8df8a49c9251e1
treedcb76f7dcf208219975ae5bb22b064f8f32482f1
parented8c394eba244bcfdc78c40384c3edfb4d35e835
[gpg] Correct finding public keys from pubring.gpg

With a master key not enabled for signing, and a signing sub-key, key
lookup went wrong in several ways and might not find a suitable key for
signing or for signature verification. Fix the code so that it finds
the sub-key, even if user.signingKey is specified not with a key ID but
with an with an e-mail. (Sub-keys don't have user ids, those are
attached only on the master key.)

Change-Id: I9d1f641c49b173d4daffb3fd2e74f5aabd856e39
Signed-off-by: Thomas Wolf <twolf@apache.org>
org.eclipse.jgit.gpg.bc/resources/org/eclipse/jgit/gpg/bc/internal/BCText.properties
org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BCText.java
org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgKeyLocator.java
org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgPublicKey.java [new file with mode: 0644]
org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgSignatureVerifier.java