mirror of
https://github.com/pgpainless/pgpainless.git
synced 2025-12-07 12:51:07 +01:00
First draft for SEIPD2 negotiation
This commit is contained in:
parent
de24da8698
commit
74067f644c
6 changed files with 124 additions and 49 deletions
|
|
@ -376,6 +376,7 @@ public class EncryptDecryptTest {
|
|||
eOut.write(testMessage.getBytes(StandardCharsets.UTF_8));
|
||||
eOut.close();
|
||||
|
||||
|
||||
ByteArrayInputStream bIn = new ByteArrayInputStream(bOut.toByteArray());
|
||||
DecryptionStream dIn = PGPainless.decryptAndOrVerify()
|
||||
.onInputStream(bIn)
|
||||
|
|
@ -389,7 +390,7 @@ public class EncryptDecryptTest {
|
|||
MessageMetadata metadata = dIn.getMetadata();
|
||||
MessageEncryptionMechanism encryptionMechanism = metadata.getEncryptionMechanism();
|
||||
assertEquals(
|
||||
MessageEncryptionMechanism.aead(SymmetricKeyAlgorithm.AES_128.getAlgorithmId(), AEADAlgorithm.OCB.getAlgorithmId()),
|
||||
MessageEncryptionMechanism.aead(SymmetricKeyAlgorithm.AES_192.getAlgorithmId(), AEADAlgorithm.OCB.getAlgorithmId()),
|
||||
encryptionMechanism);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue