Add hint about mutli assignment

This commit is contained in:
Paul Schaub 2020-01-10 18:30:48 +01:00
parent db09a0ffbe
commit dd976b7319
Signed by: vanitasvitae
GPG Key ID: 62BEE9264BF17311
1 changed files with 1 additions and 0 deletions

View File

@ -173,6 +173,7 @@ public final class DecryptionStreamFactory {
PGPSecretKey secretKey = decryptionKeys.getSecretKey(keyId);
if (secretKey != null) {
LOGGER.log(LEVEL, "Found respective secret key " + Long.toHexString(keyId));
// Watch out! This assignment is possibly done multiple times.
encryptedSessionKey = encryptedData;
decryptionKey = secretKey.extractPrivateKey(decryptionKeyDecryptor.getDecryptor(keyId));
resultBuilder.setDecryptionFingerprint(new OpenPgpV4Fingerprint(secretKey));