mirror of
https://github.com/pgpainless/pgpainless.git
synced 2024-11-26 14:22:05 +01:00
Simplify integrity protection assignment of resultBuilder
This commit is contained in:
parent
dd976b7319
commit
2902c81b6c
1 changed files with 1 additions and 7 deletions
|
@ -191,13 +191,7 @@ public final class DecryptionStreamFactory {
|
||||||
LOGGER.log(LEVEL, "Message is encrypted using " + symmetricKeyAlgorithm);
|
LOGGER.log(LEVEL, "Message is encrypted using " + symmetricKeyAlgorithm);
|
||||||
resultBuilder.setSymmetricKeyAlgorithm(symmetricKeyAlgorithm);
|
resultBuilder.setSymmetricKeyAlgorithm(symmetricKeyAlgorithm);
|
||||||
|
|
||||||
if (encryptedSessionKey.isIntegrityProtected()) {
|
resultBuilder.setIntegrityProtected(encryptedSessionKey.isIntegrityProtected());
|
||||||
LOGGER.log(LEVEL, "Message is integrity protected");
|
|
||||||
resultBuilder.setIntegrityProtected(true);
|
|
||||||
} else {
|
|
||||||
LOGGER.log(LEVEL, "Message is not integrity protected");
|
|
||||||
resultBuilder.setIntegrityProtected(false);
|
|
||||||
}
|
|
||||||
|
|
||||||
return encryptedSessionKey.getDataStream(keyDecryptor);
|
return encryptedSessionKey.getDataStream(keyDecryptor);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue