| Package | Description |
|---|---|
| org.xipki.pkcs11.wrapper |
| Modifier and Type | Method and Description |
|---|---|
PKCS11Exception |
PKCS11Module.convertException(PKCS11Exception e) |
| Modifier and Type | Method and Description |
|---|---|
void |
Session.cancelFunction()
Legacy function that will normally throw an PKCS11Exception with the error-code
CKR_FUNCTION_NOT_PARALLEL.
|
void |
Session.closeSession()
Closes this session.
|
long |
Session.copyObject(long sourceObjectHandle,
AttributeVector template)
Copy an existing object.
|
long |
Session.createECPrivateKeyObject(AttributeVector template,
byte[] ecPoint)
Create EC private key object in the PKCS#11 device.
|
long |
Session.createObject(AttributeVector template)
Create a new object on the token (or in the session).
|
long |
Session.createPrivateKeyObject(AttributeVector template,
PublicKey publicKey) |
byte[] |
Session.decrypt(byte[] ciphertext)
Decrypts the given data with the key and mechanism given to the decryptInit method.
|
byte[] |
Session.decryptDigestUpdate(byte[] part)
Dual-function.
|
byte[] |
Session.decryptFinal()
This method finalizes a decryption operation and returns the final result.
|
void |
Session.decryptInit(Mechanism mechanism,
long keyHandle)
Initializes a new decryption operation.
|
byte[] |
Session.decryptMessage(CkParams params,
byte[] associatedData,
byte[] ciphertext)
Decrypts the given message with the key and mechanism given to the MessageDecryptInit method.
|
void |
Session.decryptMessageBegin(CkParams params,
byte[] associatedData)
Starts a multipart message-decryption operation.
|
byte[] |
Session.decryptMessageNext(CkParams params,
byte[] ciphertext,
boolean isLastOperation)
Decrypts one part of a multipart decryption operation.
|
byte[] |
Session.decryptSingle(Mechanism mechanism,
long keyHandle,
byte[] ciphertext) |
byte[] |
Session.decryptUpdate(byte[] ciphertextPart)
This method can be used to decrypt multiple pieces of data; e.g.
|
byte[] |
Session.decryptVerifyUpdate(byte[] encryptedPart)
Dual-function.
|
long |
Session.deriveKey(Mechanism mechanism,
long baseKeyHandle,
AttributeVector template)
Derives a new key from a specified base key using the given mechanism.
|
void |
Session.destroyObject(long objectHandle)
Destroy a certain object on the token (or in the session).
|
byte[] |
Session.digest(byte[] data)
Digests the given data with the mechanism given to the digestInit method.
|
byte[] |
Session.digestEncryptedUpdate(byte[] part)
Dual-function.
|
byte[] |
Session.digestFinal()
This method finalizes a digesting operation and returns the final result.
|
int |
Session.digestFinal(byte[] out,
int outOfs,
int outLen)
This method finalizes a digesting operation and returns the final result.
|
void |
Session.digestInit(Mechanism mechanism)
Initializes a new digesting operation.
|
void |
Session.digestKey(long keyHandle)
This method is similar to digestUpdate and can be combined with it during one digesting
operation.
|
byte[] |
Session.digestSingle(Mechanism mechanism,
byte[] data) |
void |
Session.digestUpdate(byte[] dataPart)
This method can be used to digest multiple pieces of data; e.g.
|
byte[] |
Session.encrypt(byte[] plaintext)
Encrypts the given data with the key and mechanism given to the encryptInit method.
|
byte[] |
Session.encryptFinal()
This method finalizes an encryption operation and returns the final result.
|
void |
Session.encryptInit(Mechanism mechanism,
long keyHandle)
Initializes a new encryption operation.
|
byte[] |
Session.encryptMessage(CkParams params,
byte[] associatedData,
byte[] plaintext)
Encrypts the given message with the key and mechanism given to the MessageEncryptInit method.
|
void |
Session.encryptMessageBegin(CkParams params,
byte[] associatedData)
Starts a multipart message-encryption operation.
|
byte[] |
Session.encryptMessageNext(CkParams params,
byte[] plaintext,
boolean isLastOperation)
Encrypts one part of a multipart encryption operation.
|
byte[] |
Session.encryptSingle(Mechanism mechanism,
long keyHandle,
byte[] plaintext) |
byte[] |
Session.encryptUpdate(byte[] plaintextPat)
This method can be used to encrypt multiple pieces of data; e.g.
|
void |
PKCS11Module.finalize(Object args)
Finalizes this module.
|
long[] |
Session.findAllObjectsSingle(AttributeVector template) |
long[] |
Session.findObjects(int maxObjectCount)
Finds objects that match the template object passed to findObjectsInit.
|
void |
Session.findObjectsFinal()
Finalizes a find operation.
|
void |
Session.findObjectsInit(AttributeVector template)
Initializes a find operations that provides means to find objects by passing a template object.
|
long[] |
Session.findObjectsSingle(AttributeVector template,
int maxObjectCount) |
long |
Session.generateKey(Mechanism mechanism,
AttributeVector template)
Generate a new secret key or a set of domain parameters.
|
PKCS11KeyPair |
Session.generateKeyPair(Mechanism mechanism,
KeyPairTemplate template)
Generate a new public key - private key key-pair and use the set attributes of the template
objects for setting the attributes of the new public key and private key objects.
|
byte[] |
Session.generateRandom(int numberOfBytesToGenerate)
Generates a certain number of random bytes.
|
AttributeVector |
Session.getAttrValues(long objectHandle,
List<Long> attributeTypes) |
AttributeVector |
Session.getAttrValues(long objectHandle,
long... attributeTypes) |
AttributeVector |
Session.getDefaultAttrValues(long objectHandle)
Return the default attributes, but without attributes which contain the sensitive values.
|
AttributeVector |
Session.getDefaultAttrValues(long objectHandle,
boolean withSensitiveVAttributes)
Return the default attributes
|
void |
Session.getFunctionStatus()
Legacy function that will normally throw an PKCS11Exception with the error-code
CKR_FUNCTION_NOT_PARALLEL.
|
Token |
Slot.getNullableToken()
Get an object for handling the token that is currently present in this
slot, or null, if there is no token present.
|
long |
Session.getObjectSize(long objectHandle)
Get the size of the specified object in bytes.
|
byte[] |
Session.getOperationState()
Get the current operation state.
|
SessionInfo |
Session.getSessionInfo()
Get information about this session.
|
SlotInfo |
Slot.getSlotInfo()
Get information about this slot object.
|
Slot[] |
PKCS11Module.getSlotList(boolean tokenPresent)
Gets a list of slots that can accept tokens that are compatible with this
module; e.g.
|
String |
Session.getStringAttrValue(long objectHandle,
long attributeType) |
TokenInfo |
Token.getTokenInfo()
Get information about this token.
|
byte[] |
KeyPairTemplate.id() |
void |
PKCS11Module.initialize()
Initializes the module.
|
void |
Session.initPIN(char[] pin)
Initializes the user-PIN.
|
boolean |
Session.isRwSession()
Determines if this session is an R/W session.
|
void |
Session.login(long userType,
char[] pin)
Logs in the user or the security officer to the session.
|
void |
Session.loginUser(long userType,
char[] pin,
char[] username)
Logs in the user or the security officer to the session.
|
void |
Session.logout()
Logs out this session.
|
void |
Session.messageDecryptFinal()
finishes multipart message decryption operation.
|
void |
Session.messageDecryptInit(Mechanism mechanism,
long keyHandle)
Initializes a new message decryption operation.
|
void |
Session.messageEncryptFinal()
Finishes a Message Encryption Operation which has previously been started with messageEncryptInit.
|
void |
Session.messageEncryptInit(Mechanism mechanism,
long keyHandle)
Initializes a new message encryption operation.
|
void |
Session.messageSignFinal()
finishes a message-based signing process.
|
void |
Session.messageSignInit(Mechanism mechanism,
long keyHandle) |
void |
Session.messageVerifyFinal()
finishes a message-based verification process.
|
void |
Session.messageVerifyInit(Mechanism mechanism,
long keyHandle)
Initiates a message verification operation, preparing a session for one or
more verification operations (where the signature is an appendix to the data) that use the same
verification mechanism and verification key.
|
Session |
Token.openSession(boolean rwSession)
Open a new session to perform operations on this token.
|
Session |
Token.openSession(boolean rwSession,
Object application)
Open a new session to perform operations on this token.
|
void |
Session.seedRandom(byte[] seed)
Mixes additional seeding material into the random number generator.
|
void |
Session.sessionCancel()
terminates active session based operations.
|
void |
Session.setAttributeValues(long objectToUpdateHandle,
AttributeVector template)
Gets all present attributes of the given template object and writes them to the object to update
on the token (or in the session).
|
void |
Session.setOperationState(byte[] operationState,
long encryptionKeyHandle,
long authenticationKeyHandle)
Sets the operation state of this session to a previously saved one.
|
void |
Session.setPIN(char[] oldPin,
char[] newPin)
Set the user-PIN to a new value.
|
byte[] |
Session.sign(byte[] data)
Signs the given data with the key and mechanism given to the signInit method.
|
byte[] |
Session.signEncryptUpdate(byte[] part)
Dual-function.
|
byte[] |
Session.signFinal()
This method finalizes a signing operation and returns the final result.
|
void |
Session.signInit(Mechanism mechanism,
long keyHandle)
Initializes a new signing operation.
|
byte[] |
Session.signMessage(CkParams params,
byte[] data) |
void |
Session.signMessageBegin(CkParams params)
SignMessageBegin begins a multiple-part message signature operation, where the signature is an
appendix to the message.
|
byte[] |
Session.signMessageNext(CkParams params,
byte[] data,
boolean isLastOperation)
SignMessageNext continues a multiple-part message signature operation, processing another data
part, or finishes a multiple-part message signature operation, returning the signature.
|
byte[] |
Session.signRecover(byte[] data)
Signs the given data with the key and mechanism given to the signRecoverInit method.
|
void |
Session.signRecoverInit(Mechanism mechanism,
long keyHandle)
Initializes a new signing operation for signing with recovery.
|
byte[] |
Session.signRecoverSingle(Mechanism mechanism,
long keyHandle,
byte[] data) |
byte[] |
Session.signSingle(Mechanism mechanism,
long keyHandle,
byte[] data) |
void |
Session.signUpdate(byte[] dataPart)
This method can be used to sign multiple pieces of data; e.g.
|
void |
Session.signUpdate(byte[] in,
int inOfs,
int inLen)
This method can be used to sign multiple pieces of data; e.g.
|
long |
Session.unwrapKey(Mechanism mechanism,
long unwrappingKeyHandle,
byte[] wrappedKey,
AttributeVector keyTemplate)
Unwraps (decrypts) the given encrypted key with the unwrapping key using the given mechanism.
|
void |
Session.verify(byte[] data,
byte[] signature)
Verifies the given signature against the given data with the key and mechanism given to the
verifyInit method.
|
void |
Session.verifyFinal(byte[] signature)
This method finalizes a verification operation.
|
void |
Session.verifyInit(Mechanism mechanism,
long keyHandle)
Initializes a new verification operation.
|
void |
Session.verifyMessage(CkParams params,
byte[] data,
byte[] signature)
Verifies a signature on a message in a single part operation.
|
void |
Session.verifyMessageBegin(CkParams params)
Begins a multipart message verification operation.
|
void |
Session.verifyMessageNext(CkParams params,
byte[] data,
byte[] signature)
continues a multiple-part message verification operation, processing another data
part, or finishes a multiple-part message verification operation, checking the signature.
|
byte[] |
Session.verifyRecover(byte[] data)
Verifies the given data with the key and mechanism given to the verifyRecoverInit method.
|
void |
Session.verifyRecoverInit(Mechanism mechanism,
long keyHandle)
Initializes a new verification operation for verification with data recovery.
|
byte[] |
Session.verifyRecoverSingle(Mechanism mechanism,
long keyHandle,
byte[] data) |
void |
Session.verifySingle(Mechanism mechanism,
long keyHandle,
byte[] data,
byte[] signature) |
void |
Session.verifyUpdate(byte[] dataPart)
This method can be used to verify a signature with multiple pieces of data; e.g.
|
Slot |
PKCS11Module.waitForSlotEvent(boolean dontBlock)
Waits for a slot event.
|
byte[] |
Session.wrapKey(Mechanism mechanism,
long wrappingKeyHandle,
long keyHandle)
Wraps (encrypts) the given key with the wrapping key using the given mechanism.
|
Copyright © 2023. All rights reserved.