mirror of
https://github.com/pgpainless/pgpainless.git
synced 2025-09-09 10:19:39 +02:00
Clean up OnePassSignatureCheck
This commit is contained in:
parent
7c22d32a11
commit
01c112770a
1 changed files with 0 additions and 18 deletions
|
@ -7,9 +7,6 @@ package org.pgpainless.signature.consumer
|
||||||
import org.bouncycastle.openpgp.PGPOnePassSignature
|
import org.bouncycastle.openpgp.PGPOnePassSignature
|
||||||
import org.bouncycastle.openpgp.PGPSignature
|
import org.bouncycastle.openpgp.PGPSignature
|
||||||
import org.bouncycastle.openpgp.api.OpenPGPCertificate
|
import org.bouncycastle.openpgp.api.OpenPGPCertificate
|
||||||
import org.bouncycastle.openpgp.api.OpenPGPCertificate.OpenPGPComponentKey
|
|
||||||
import org.pgpainless.bouncycastle.extensions.getSigningKeyFor
|
|
||||||
import org.pgpainless.key.SubkeyIdentifier
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Tuple-class that bundles together a [PGPOnePassSignature] object, an [OpenPGPCertificate]
|
* Tuple-class that bundles together a [PGPOnePassSignature] object, an [OpenPGPCertificate]
|
||||||
|
@ -24,19 +21,4 @@ data class OnePassSignatureCheck(
|
||||||
) {
|
) {
|
||||||
|
|
||||||
var signature: PGPSignature? = null
|
var signature: PGPSignature? = null
|
||||||
|
|
||||||
constructor(
|
|
||||||
onePassSignature: PGPOnePassSignature,
|
|
||||||
verificationKey: OpenPGPComponentKey
|
|
||||||
) : this(onePassSignature, verificationKey.certificate)
|
|
||||||
|
|
||||||
val signingKey: OpenPGPComponentKey? = verificationKeys.getSigningKeyFor(onePassSignature)
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Return an identifier for the signing key.
|
|
||||||
*
|
|
||||||
* @return signing key fingerprint
|
|
||||||
*/
|
|
||||||
val signingKeyIdentifier: SubkeyIdentifier?
|
|
||||||
get() = signingKey?.let { SubkeyIdentifier(it) }
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue