Gck
Description:
Content:
Interfaces:
- ObjectCache - An interface implemented by derived
classes of [class
Object
] to indicate which attributes they'd like an enumerator to retrieve.
Classes:
- Attribute - This structure represents a PKCS#11 `CK_ATTRIBUTE`.
- Attributes - A set of [struct
Attribute
] structures. - Builder - A builder for a set of attributes.
- Enumerator - Can be used to enumerate through PKCS#11 objects.
- MechanismInfo - Represents information about a PKCS11 mechanism.
- Module - Holds a loaded PKCS#11 module.
- ModuleInfo - Holds information about the PKCS#11 module.
- Object - Holds a handle to a PKCS11 object such as a key or certificate.
- Password - Represents a password which is requested of the user.
- Session - Represents an open PKCS11 session.
- SessionInfo - Information about the session.
- Slot - Represents a PKCS#11 slot that can contain a token.
- SlotInfo - Represents information about a PKCS11 slot.
- TokenInfo - Represents information about a PKCS11 token.
- UriData - Information about the contents of a PKCS#11 URI.
Structs:
- Mechanism - Represents a mechanism used with crypto operations.
Enums:
- BuilderFlags - Flags to be used with a [method
Builder.init_full
] and [ctorBuilder.new
]. - Error - Various error codes.
- SessionOptions - Options for creating sessions.
- UriError - Various error codes used with PKCS#11 URIs
- UriFlags - Which parts of the PKCS#11 URI will be parsed or formatted.
Constants:
- public const ulong INVALID
Used as a terminator at the end of variable argument lists.
- public const int MAJOR_VERSION
The major version number of the Gck library.
- public const int MICRO_VERSION
The micro version number of the Gck library.
- public const int MINOR_VERSION
The minor version number of the Gck library.
- public const int URI_FOR_MODULE_WITH_VERSION
The URI will match specific version of modules.
- public const int URI_FOR_OBJECT_ON_TOKEN
The URI will match objects on a specific token.
- public const int URI_FOR_OBJECT_ON_TOKEN_AND_MODULE
The token inserted into a device with a specific module.
- public const int VENDOR_CODE
Custom PKCS#11 errors that originate from the gck library, are based at this error code.
Delegates:
- public delegate void* Allocator (void* data, size_t length)
An allocator used to allocate data for the attributes in this [struct
Attributes
] set.
Functions:
- public void builder_unref (void* builder)
Unreferences a builder.
- public Quark error_get_quark ()
- public Type list_get_boxed_type ()
- public bool mechanisms_check (Array<ulong> mechanisms, ...)
Check whether all the mechanism types are in the list.
- public unowned string message_from_rv (ulong rv)
Get a message for a PKCS#11 return value or error code.
- public Enumerator modules_enumerate_objects (List<Module> modules, Attributes attrs, SessionOptions session_options)
Setup an enumerator for listing matching objects on the modules.
- public Enumerator modules_enumerate_uri (List<Module> modules, string uri, SessionOptions session_options) throws Error
Enumerate objects that match a URI.
- public List<Slot> modules_get_slots (List<Module> modules, bool token_present)
Get a list of slots for across all of the modules.
- public List<Module> modules_initialize_registered (Cancellable? cancellable = null) throws Error
Load and initialize all the registered modules.
- public async List<Module> modules_initialize_registered_async (Cancellable? cancellable) throws Error
Load and initialize all the registered modules asynchronously.
- public Object? modules_object_for_uri (List<Module> modules, string uri, SessionOptions session_options) throws Error
Find an object that matches a URI.
- public List<Object> modules_objects_for_uri (List<Module> modules, string uri, SessionOptions session_options) throws Error
Find objects that match a URI.
- public Slot modules_token_for_uri (List<Module> modules, string uri) throws Error
Lookup a token that matches the URI.
- public List<Slot> modules_tokens_for_uri (List<Module> modules, string uri) throws Error
Lookup a token that matches the URI.
- public List<Object> objects_from_handle_array (Session session, ulong[] object_handles)
Initialize a list of GckObject from raw PKCS#11 handles.
- public Enumerator slots_enumerate_objects (List<Slot> slots, Attributes match, SessionOptions options)
Setup an enumerator for listing matching objects on the slots.
- public string uri_build (UriData uri_data, UriFlags flags)
Build a PKCS#11 URI.
- public Quark uri_error_get_quark ()
- public UriData uri_parse (string string, UriFlags flags) throws Error
Parse a PKCS#11 URI for use in a given context.
- public bool value_to_boolean (uint8[] value, out bool result)
Convert `CK_BBOOL` type memory to a boolean.
- public bool value_to_ulong (uint8[] value, out ulong result)
Convert `CK_ULONG` type memory to a boolean.