public class BouncyCastleGpgSignatureVerifier extends Object implements GpgSignatureVerifier
GpgSignatureVerifier to verify GPG signatures using BouncyCastle.GpgSignatureVerifier.SignatureVerification, GpgSignatureVerifier.TrustLevel| Constructor and Description |
|---|
BouncyCastleGpgSignatureVerifier()
Creates a new instance and registers the BouncyCastle security provider
if needed.
|
| Modifier and Type | Method and Description |
|---|---|
void |
clear()
A
GpgSignatureVerifier may cache public keys to speed up
verifying signatures on multiple objects. |
String |
getName()
Retrieves the name of this verifier.
|
GpgSignatureVerifier.SignatureVerification |
verify(byte[] data,
byte[] signatureData)
Verifies a given signature for given data.
|
GpgSignatureVerifier.SignatureVerification |
verifySignature(RevObject object,
GpgConfig config)
Verifies the signature on a signed commit or tag.
|
public BouncyCastleGpgSignatureVerifier()
public String getName()
GpgSignatureVerifiergetName in interface GpgSignatureVerifier@Nullable public GpgSignatureVerifier.SignatureVerification verifySignature(@NonNull RevObject object, @NonNull GpgConfig config) throws IOException
GpgSignatureVerifierverifySignature in interface GpgSignatureVerifierobject - to verifyconfig - the GpgConfig to useGpgSignatureVerifier.SignatureVerification describing the outcome of the
verification, or null if the object was not signedIOException - if an error occurs getting a public keypublic GpgSignatureVerifier.SignatureVerification verify(byte[] data, byte[] signatureData) throws IOException
GpgSignatureVerifierverify in interface GpgSignatureVerifierdata - the signature is forsignatureData - the ASCII-armored signatureGpgSignatureVerifier.SignatureVerification describing the outcomeIOException - if the signature cannot be parsedpublic void clear()
GpgSignatureVerifierGpgSignatureVerifier may cache public keys to speed up
verifying signatures on multiple objects. This clears this cache, if any.clear in interface GpgSignatureVerifierCopyright © 2024 Eclipse JGit Project. All rights reserved.