mirror of
https://github.com/pgpainless/pgpainless.git
synced 2025-09-10 18:59:39 +02:00
Fix NPE when attempting to decrypt GNU_DUMMY_S2K keys
This commit is contained in:
parent
aef9ebfd7b
commit
d54a40196b
10 changed files with 45 additions and 48 deletions
|
@ -11,7 +11,6 @@ import org.bouncycastle.openpgp.PGPSecretKey;
|
|||
import org.bouncycastle.openpgp.PGPSecretKeyRing;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.pgpainless.PGPainless;
|
||||
import org.pgpainless.exception.WrongPassphraseException;
|
||||
import org.pgpainless.key.OpenPgpV4Fingerprint;
|
||||
import org.pgpainless.key.TestKeys;
|
||||
import org.pgpainless.key.protection.CachingSecretKeyRingProtector;
|
||||
|
@ -120,7 +119,7 @@ public class UnlockSecretKeys {
|
|||
}
|
||||
|
||||
private void assertProtectorUnlocksAllSecretKeys(PGPSecretKeyRing secretKey, SecretKeyRingProtector protector)
|
||||
throws WrongPassphraseException {
|
||||
throws PGPException {
|
||||
for (PGPSecretKey key : secretKey) {
|
||||
UnlockSecretKey.unlockSecretKey(key, protector);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue