mirror of
https://github.com/pgpainless/pgpainless.git
synced 2024-11-16 09:22:05 +01:00
OpenPgpMessageInputStream: Ignore non-integrity-protected data if configured
This commit is contained in:
parent
7be12b0aaa
commit
94d9efa1e7
1 changed files with 4 additions and 2 deletions
|
@ -409,8 +409,10 @@ public class OpenPgpMessageInputStream extends DecryptionStream {
|
||||||
PGPEncryptedDataList encDataList = packetInputStream.readEncryptedDataList();
|
PGPEncryptedDataList encDataList = packetInputStream.readEncryptedDataList();
|
||||||
|
|
||||||
if (!encDataList.isIntegrityProtected()) {
|
if (!encDataList.isIntegrityProtected()) {
|
||||||
LOGGER.debug("Symmetrically Encrypted Data Packet is not integrity-protected and is therefore rejected.");
|
LOGGER.warn("Symmetrically Encrypted Data Packet is not integrity-protected.");
|
||||||
throw new MessageNotIntegrityProtectedException();
|
if (!options.isIgnoreMDCErrors()) {
|
||||||
|
throw new MessageNotIntegrityProtectedException();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
SortedESKs esks = new SortedESKs(encDataList);
|
SortedESKs esks = new SortedESKs(encDataList);
|
||||||
|
|
Loading…
Reference in a new issue