diff options
author | Stef Walter <stef@memberwebs.com> | 2008-12-08 20:34:49 +0000 |
---|---|---|
committer | Stef Walter <stef@memberwebs.com> | 2008-12-08 20:34:49 +0000 |
commit | c1e30395d8f4551a5f0fa253eefeefc9a9154f7e (patch) | |
tree | e25bca346a7c5a97118d11841741f96ae8be5002 /ckcapi-session.h | |
parent | dc864d999f72e966fb0f1e2bf5fd8a3185430b8d (diff) |
Support the concept of read-write and read-only sessions.
Diffstat (limited to 'ckcapi-session.h')
-rw-r--r-- | ckcapi-session.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/ckcapi-session.h b/ckcapi-session.h index 4fb68fa..7b71c07 100644 --- a/ckcapi-session.h +++ b/ckcapi-session.h @@ -34,6 +34,8 @@ typedef struct _CkCapiSession HCERTSTORE store; /* Handle to an open certificate store */ + BOOL read_write; /* A read-write session? */ + int operation_type; /* Whether an operation is happening or not */ void* operation_data; /* Data for this operation */ CkCapiSessionCancel operation_cancel; /* Callback to cancel operation when necessary */ @@ -62,9 +64,12 @@ void ckcapi_session_destroy (CkCapiSession* sess); CK_RV ckcapi_session_register (CkCapiSession* sess); /* Get a session from a handle, and lock it */ -CK_RV ckcapi_session_get_lock_ref (CK_ULONG id, int remove, +CK_RV ckcapi_session_get_lock_ref (CK_ULONG id, BOOL writable, CkCapiSession **sess); +/* Get a session from a handle, remove it from list, and lock it */ +CK_RV ckcapi_session_remove_lock_ref (CK_ULONG id, CkCapiSession **sess); + /* Unlock and unreference a session */ void ckcapi_session_unref_unlock (CkCapiSession* sess); |