Interface SigningIdentity
-
- All Superinterfaces:
Identity
- All Known Implementing Classes:
IdemixSigningIdentity
,X509SigningIdentity
public interface SigningIdentity extends Identity
SigningIdentity extends Identity with signing capabilities. It is used by a client to sign transactions in a linkable or unlinkable fashion.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description byte[]
sign(byte[] msg)
Sings a message with the secret key and the corresponding certificateboolean
verifySignature(byte[] msg, byte[] sig)
Verifies a signature on a message-
Methods inherited from interface org.hyperledger.fabric.sdk.identity.Identity
createSerializedIdentity
-
-
-
-
Method Detail
-
sign
byte[] sign(byte[] msg) throws CryptoException, InvalidArgumentException
Sings a message with the secret key and the corresponding certificate- Parameters:
msg
-- Returns:
- signature
- Throws:
CryptoException
InvalidArgumentException
-
verifySignature
boolean verifySignature(byte[] msg, byte[] sig) throws CryptoException, InvalidArgumentException
Verifies a signature on a message- Parameters:
msg
-sig
-- Returns:
- true/false
- Throws:
CryptoException
InvalidArgumentException
-
-