public class BcTlsSM2Signer extends BcTlsSigner
| Modifier and Type | Field and Description |
|---|---|
protected byte[] |
identifier |
crypto, privateKey| Constructor and Description |
|---|
BcTlsSM2Signer(BcTlsCrypto crypto,
org.bouncycastle.crypto.params.ECPrivateKeyParameters privateKey,
byte[] identifier) |
| Modifier and Type | Method and Description |
|---|---|
byte[] |
generateRawSignature(SignatureAndHashAlgorithm algorithm,
byte[] hash)
Generate an encoded signature based on the passed in hash.
|
TlsStreamSigner |
getStreamSigner(SignatureAndHashAlgorithm algorithm) |
public BcTlsSM2Signer(BcTlsCrypto crypto, org.bouncycastle.crypto.params.ECPrivateKeyParameters privateKey, byte[] identifier)
public byte[] generateRawSignature(SignatureAndHashAlgorithm algorithm, byte[] hash) throws java.io.IOException
TlsSigneralgorithm - the signature algorithm to use.hash - the hash calculated for the signature.java.io.IOException - in case of an exception processing the hash.public TlsStreamSigner getStreamSigner(SignatureAndHashAlgorithm algorithm)
getStreamSigner in interface TlsSignergetStreamSigner in class BcTlsSigner