Module io.github.mmm.crypto.bc
Class SignatureProcessorImplEcBc<S extends SignatureEcBc>
- java.lang.Object
-
- io.github.mmm.crypto.asymmetric.sign.ec.bc.SignatureProcessorImplEcBc<S>
-
- Type Parameters:
S
- type ofSignatureEcBc
.
- All Implemented Interfaces:
CryptoAlgorithm
,SignatureProcessor
,CryptoChunker
,CryptoProcessor
- Direct Known Subclasses:
SignatureSignerImplEcBc
,SignatureVerifierImplEcBc
public abstract class SignatureProcessorImplEcBc<S extends SignatureEcBc> extends Object implements SignatureProcessor
Implementation ofSignatureSigner
.- Since:
- 1.0.0
-
-
Constructor Summary
Constructors Constructor Description SignatureProcessorImplEcBc(SignatureConfigEcDsa<S> config, org.bouncycastle.crypto.signers.ECDSASigner signer)
The constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getAlgorithm()
SignatureConfig<S>
getConfig()
SignatureFactoryEcBc<S>
getSignatureFactory()
void
reset()
Will reset the internal state of this object.void
update(byte[] input, int offset, int length)
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.github.mmm.crypto.CryptoChunker
update, update
-
Methods inherited from interface io.github.mmm.crypto.CryptoProcessor
process, process, process, process
-
-
-
-
Constructor Detail
-
SignatureProcessorImplEcBc
public SignatureProcessorImplEcBc(SignatureConfigEcDsa<S> config, org.bouncycastle.crypto.signers.ECDSASigner signer)
The constructor.- Parameters:
config
- theconfig
.signer
- the underlyingECDSASigner
.
-
-
Method Detail
-
getAlgorithm
public String getAlgorithm()
- Specified by:
getAlgorithm
in interfaceCryptoAlgorithm
- Returns:
- the name of the underlying algorithm (e.g. "RSA", "NONEwithECDSA", etc.).
- See Also:
Key.getAlgorithm()
,Signature.getAlgorithm()
,MessageDigest.getAlgorithm()
,SecureRandom.getAlgorithm()
,Cipher.getAlgorithm()
-
getConfig
public SignatureConfig<S> getConfig()
- Returns:
- the
SignatureConfig
.
-
getSignatureFactory
public SignatureFactoryEcBc<S> getSignatureFactory()
- Returns:
- the
SignatureFactoryEcBc
.
-
update
public void update(byte[] input, int offset, int length)
- Specified by:
update
in interfaceCryptoChunker
- Parameters:
input
- the next chunk of data.offset
- the index where to start reading data frominput
.length
- the number of bytes to read frominput
.- See Also:
MessageDigest.update(byte[], int, int)
,Signature.update(byte[], int, int)
-
reset
public void reset()
Description copied from interface:CryptoProcessor
Will reset the internal state of this object. Please note that complex algorithms especially forCryptor
may not reusable. It is therefore preferable to always create a fresh instance for each cryptographic task.- Specified by:
reset
in interfaceCryptoProcessor
- See Also:
MessageDigest.reset()
-
-