public abstract class BaseSignatureAlgorithm extends AlgorithmInfo implements JsonWebSignatureAlgorithm
| Constructor and Description |
|---|
BaseSignatureAlgorithm(String id,
String javaAlgo,
String keyAlgo) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
isAvailable() |
protected void |
setAlgorithmParameterSpec(AlgorithmParameterSpec algorithmParameterSpec) |
byte[] |
sign(Key key,
byte[] securedInputBytes,
ProviderContext providerContext) |
abstract void |
validatePrivateKey(PrivateKey privateKey) |
abstract void |
validatePublicKey(PublicKey publicKey) |
void |
validateSigningKey(Key key) |
void |
validateVerificationKey(Key key) |
boolean |
verifySignature(byte[] signatureBytes,
Key key,
byte[] securedInputBytes,
ProviderContext providerContext) |
getAlgorithmIdentifier, getJavaAlgorithm, getKeyPersuasion, getKeyType, setAlgorithmIdentifier, setJavaAlgorithm, setKeyPersuasion, setKeyTypeclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetAlgorithmIdentifier, getJavaAlgorithm, getKeyPersuasion, getKeyTypeprotected void setAlgorithmParameterSpec(AlgorithmParameterSpec algorithmParameterSpec)
public boolean verifySignature(byte[] signatureBytes,
Key key,
byte[] securedInputBytes,
ProviderContext providerContext)
throws JoseException
verifySignature in interface JsonWebSignatureAlgorithmJoseExceptionpublic byte[] sign(Key key, byte[] securedInputBytes, ProviderContext providerContext) throws JoseException
sign in interface JsonWebSignatureAlgorithmJoseExceptionpublic abstract void validatePrivateKey(PrivateKey privateKey) throws InvalidKeyException
InvalidKeyExceptionpublic void validateSigningKey(Key key) throws InvalidKeyException
validateSigningKey in interface JsonWebSignatureAlgorithmInvalidKeyExceptionpublic abstract void validatePublicKey(PublicKey publicKey) throws InvalidKeyException
InvalidKeyExceptionpublic void validateVerificationKey(Key key) throws InvalidKeyException
validateVerificationKey in interface JsonWebSignatureAlgorithmInvalidKeyExceptionpublic boolean isAvailable()
isAvailable in interface AlgorithmCopyright © 2019. All rights reserved.