public class EcdsaUsingShaAlgorithm extends BaseSignatureAlgorithm implements JsonWebSignatureAlgorithm
| Modifier and Type | Class and Description |
|---|---|
static class |
EcdsaUsingShaAlgorithm.EcdsaP256UsingSha256 |
static class |
EcdsaUsingShaAlgorithm.EcdsaP384UsingSha384 |
static class |
EcdsaUsingShaAlgorithm.EcdsaP521UsingSha512 |
static class |
EcdsaUsingShaAlgorithm.EcdsaSECP256K1UsingSha256 |
| Constructor and Description |
|---|
EcdsaUsingShaAlgorithm(String id,
String javaAlgo,
String curveName,
int signatureByteLength) |
| Modifier and Type | Method and Description |
|---|---|
static byte[] |
convertConcatenatedToDer(byte[] concatenatedSignatureBytes) |
static byte[] |
convertDerToConcatenated(byte[] derEncodedBytes,
int outputLength) |
String |
getCurveName() |
byte[] |
sign(CryptoPrimitive cryptoPrimitive,
byte[] securedInputBytes) |
void |
validatePrivateKey(PrivateKey privateKey) |
void |
validatePublicKey(PublicKey publicKey) |
boolean |
verifySignature(byte[] signatureBytes,
Key key,
byte[] securedInputBytes,
ProviderContext providerContext) |
isAvailable, prepareForSign, setAlgorithmParameterSpec, validateSigningKey, validateVerificationKeygetAlgorithmIdentifier, getJavaAlgorithm, getKeyPersuasion, getKeyType, setAlgorithmIdentifier, setJavaAlgorithm, setKeyPersuasion, setKeyType, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitprepareForSign, validateSigningKey, validateVerificationKeygetAlgorithmIdentifier, getJavaAlgorithm, getKeyPersuasion, getKeyType, isAvailablepublic boolean verifySignature(byte[] signatureBytes,
Key key,
byte[] securedInputBytes,
ProviderContext providerContext)
throws JoseException
verifySignature in interface JsonWebSignatureAlgorithmverifySignature in class BaseSignatureAlgorithmJoseExceptionpublic byte[] sign(CryptoPrimitive cryptoPrimitive, byte[] securedInputBytes) throws JoseException
sign in interface JsonWebSignatureAlgorithmsign in class BaseSignatureAlgorithmJoseExceptionpublic static byte[] convertConcatenatedToDer(byte[] concatenatedSignatureBytes)
throws IOException
IOExceptionpublic static byte[] convertDerToConcatenated(byte[] derEncodedBytes,
int outputLength)
throws IOException
IOExceptionpublic void validatePrivateKey(PrivateKey privateKey) throws InvalidKeyException
validatePrivateKey in class BaseSignatureAlgorithmInvalidKeyExceptionpublic void validatePublicKey(PublicKey publicKey) throws InvalidKeyException
validatePublicKey in class BaseSignatureAlgorithmInvalidKeyExceptionpublic String getCurveName()
Copyright © 2022. All rights reserved.