mirror of
https://github.com/pgpainless/pgpainless.git
synced 2024-11-17 09:52:06 +01:00
Catch UnsupportedPacketVersionExceptions when parsing OnePassSignaturePackets
This commit is contained in:
parent
e9c57a9ed9
commit
0045f77551
1 changed files with 7 additions and 3 deletions
|
@ -197,9 +197,13 @@ class OpenPgpMessageInputStream(
|
|||
|
||||
private fun processOnePassSignature() {
|
||||
syntaxVerifier.next(InputSymbol.ONE_PASS_SIGNATURE)
|
||||
val ops = packetInputStream!!.readOnePassSignature()
|
||||
LOGGER.debug(
|
||||
"One-Pass-Signature Packet by key ${ops.keyID.openPgpKeyId()} at depth ${layerMetadata.depth} encountered.")
|
||||
val ops =
|
||||
try {
|
||||
packetInputStream!!.readOnePassSignature()
|
||||
} catch (e: UnsupportedPacketVersionException) {
|
||||
LOGGER.debug("Unsupported One-Pass-Signature packet version encountered.", e)
|
||||
return
|
||||
}
|
||||
signatures.addOnePassSignature(ops)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue