1
0
Fork 0
mirror of https://github.com/pgpainless/pgpainless.git synced 2025-09-10 02:39:39 +02:00

Change return type of KeyRingBuilder.build() to OpenPGPKey

This commit is contained in:
Paul Schaub 2025-02-10 13:34:07 +01:00
parent dd4a989606
commit 53053cf3fc
Signed by: vanitasvitae
GPG key ID: 62BEE9264BF17311
74 changed files with 319 additions and 188 deletions

View file

@ -252,7 +252,8 @@ public class ModifiedPublicKeysInvestigation {
@Test
public void assertUnmodifiedRSAKeyDoesNotThrow() {
PGPSecretKeyRing secretKeys = PGPainless.generateKeyRing()
.simpleRsaKeyRing("Unmodified", RsaLength._4096, "987654321");
.simpleRsaKeyRing("Unmodified", RsaLength._4096, "987654321")
.getPGPSecretKeyRing();
SecretKeyRingProtector protector = SecretKeyRingProtector.unlockAnyKeyWith(Passphrase.fromPassword("987654321"));
for (PGPSecretKey secretKey : secretKeys) {
@ -264,7 +265,8 @@ public class ModifiedPublicKeysInvestigation {
@Test
public void assertUnmodifiedECKeyDoesNotThrow() {
PGPSecretKeyRing secretKeys = PGPainless.generateKeyRing()
.simpleEcKeyRing("Unmodified", "987654321");
.simpleEcKeyRing("Unmodified", "987654321")
.getPGPSecretKeyRing();
SecretKeyRingProtector protector = SecretKeyRingProtector.unlockAnyKeyWith(Passphrase.fromPassword("987654321"));
for (PGPSecretKey secretKey : secretKeys) {
@ -276,7 +278,8 @@ public class ModifiedPublicKeysInvestigation {
@Test
public void assertUnmodifiedModernKeyDoesNotThrow() {
PGPSecretKeyRing secretKeys = PGPainless.generateKeyRing()
.modernKeyRing("Unmodified", "987654321");
.modernKeyRing("Unmodified", "987654321")
.getPGPSecretKeyRing();
SecretKeyRingProtector protector = SecretKeyRingProtector.unlockAnyKeyWith(Passphrase.fromPassword("987654321"));
for (PGPSecretKey secretKey : secretKeys) {