Signature implementation
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| protected Signature | Returns: Thejava. instanceThe session, String SessionContext for calling this method - may be null if not
called within a session contextThe signature's algorithm name algo, Key the key, boolean Key that is provided for initialization - a PrivateKey for
signing and a PublicKey for verificationIf forSigning)true then it is being initialized for signing, otherwise for
verifying a signatureInitializes the internal signature instance |
| protected boolean | |
| protected Map. | Returns: ASimpleImmutableEntry where first value is the key type and second value is the
data - null if not encodedThe original signature sig, Collection<String> The expected encoded key types expectedTypes)Makes an attempt to detect if the signature is encoded or pure data |
| protected Map. | |
| public final String | |
| protected Signature | |
| public void | initSigner(SessionContext
The session, PrivateKey SessionContext for calling this method - may be null if not called within a
session contextThe key)PrivateKey to be used for signingImplements org.
|
| public void | initVerifier(SessionContext
The session, PublicKey SessionContext for calling this method - may be null if not called within a
session contextThe key)PublicKey to be used for verifying signaturesImplements org.
|
| public byte[] | sign(SessionContext
The session)SessionContext for calling this method - may be null if not called within a
session contextImplements org. Compute the signature |
| public String | |
| public void | update(SessionContext
The session, byte[] SessionContext for calling this method - may be null if not called within a
session contextThe hash data buffer hash, int Offset of hash data in buffer off, int Length of hash data len)Implements org. Update the computed signature with the given data |
| algorithm | back to summary |
|---|---|
| private final String algorithm | |
| signatureInstance | back to summary |
|---|---|
| private Signature signatureInstance | |
| AbstractSignature | back to summary |
|---|---|
| protected AbstractSignature(String algorithm) | |
| doInitSignature | back to summary |
|---|---|
| protected Signature doInitSignature(SessionContext session, String algo, Key key, boolean forSigning) throws GeneralSecurityException Initializes the internal signature instance
| |
| doVerify | back to summary |
|---|---|
| protected boolean doVerify(byte[] data) throws SignatureException | |
| extractEncodedSignature | back to summary |
|---|---|
| protected Map. Makes an attempt to detect if the signature is encoded or pure data
| |
| extractEncodedSignature | back to summary |
|---|---|
| protected Map. | |
| getAlgorithm | back to summary |
|---|---|
| public final String getAlgorithm() Implements org.
| |
| getSignature | back to summary |
|---|---|
protected Signature getSignature()
| |
| initSigner | back to summary |
|---|---|
| public void initSigner(SessionContext session, PrivateKey key) throws Exception Implements org.
| |
| initVerifier | back to summary |
|---|---|
| public void initVerifier(SessionContext session, PublicKey key) throws Exception Implements org.
| |
| sign | back to summary |
|---|---|
| public byte[] sign(SessionContext session) throws Exception Implements org. Doc from org. Compute the signature
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns a string representation of the object.
Satisfying this method's contract implies a non- | |
| update | back to summary |
|---|---|
| public void update(SessionContext session, byte[] hash, int off, int len) throws Exception Implements org. Doc from org. Update the computed signature with the given data
| |