HSM user management.
See the HSM technical documentation.
Type Definitions | |
typedef int(AAP_API * | funcListUsersCallback) (char *szUserName, void *pParam, BOOL bFinal) |
Functions | |
int AAP_API | DCreateUser(HSESSIONCTX hSession, struct USER_INFO userInfo) |
int AAP_API | DRemoveUser(HSESSIONCTX hSession, char *szUserId) |
int AAP_API | DSetUserParam(HSESSIONCTX hSession, DWORD dwParam, BYTE *pbData, DWORD dwDataLen, DWORD dwFlags) |
int AAP_API | DGetUserParam(HSESSIONCTX hSession, DWORD dwParam, BYTE *pbData, DWORD *pdwDataLen, DWORD dwFlags) |
int AAP_API | DListUsers(HSESSIONCTX hSession, funcListUsersCallback fncallback, void *pParam) |
int AAP_API | DAssignToken (const HSESSIONCTX hSession, const char *szUserId, const DWORD dwParam, BYTE *pbData, const DWORD dwDataLen) |
int AAP_API | DUnassignToken (const HSESSIONCTX hSession, const DWORD dwParam, const char *szUserId) |
int AAP_API | DOATHResync (const HSESSIONCTX hSession, char *szUser, char *szOTP1, char *szOTP2, DWORD dwParam) |
#include <dinamo.h>
Pointer to callback function for listing users.
[in] | szUserName | User name. |
[in] | pParam | Pointer to a parameter passed to the DListUsers() function. |
[in] | bFinal | Flag indicating the last record. |
int AAP_API DCreateUser | ( | HSESSIONCTX | hSession, |
struct USER_INFO | userInfo ) |
#include <dinamo.h>
Create a user in HSM according to the information provided.
[in] | hSession | Context acquired through the DOpenSession() function. |
[in] | userInfo | Structure containing information for user creation. For more details, see the comments. |
Value | Meaning |
---|---|
ACL_NOP | User with ordinary authorizations only. |
ACL_OBJ_CREATE | Permission to create objects. Read permission(ACL_OBJ_READ) is assigned implicitly. |
ACL_OBJ_DEL | Permission to remove objects. Read permission(ACL_OBJ_READ) is assigned implicitly. |
ACL_OBJ_READ | Permission to read the contents of objects. |
ACL_OBJ_UPDATE ACL_OBJ_WRITE | Permission to update object attributes. ACL_OBJ_UPDATE = ACL_OBJ_WRITE |
ACL_USR_CREATE ACL_USR_DELETE | Permission to create and remove users. ACL_USR_CREATE = ACL_USR_DELETE |
ACL_USR_REMOTE_INFO | Permission to receive remote log notifications. |
ACL_USR_LIST | Permission to list users. |
ACL_SYS_OPERATOR | Permission to operate as the user 'master'. |
ACL_SYS_BACKUP ACL_SYS_RESTORE | Permission to create and restore backup copies of HSM data. ACL_SYS_BACKUP = ACL_SYS_RESTORE |
ACL_SYS_UDATE_HSM | Permission to update the firmware. |
ACL_NS_AUTHORIZATION | Enables the M of N partition. Authorization of the partition is done via M of N through the local console. |
ACL_LOCAL_CRYPTO | Enable Local-crypto. The encryption operations of the partition keys will be performed by the local console. |
int AAP_API DRemoveUser | ( | HSESSIONCTX | hSession, |
char * | szUserId ) |
#include <dinamo.h>
Removes a user from HSM.
[in] | hSession | Context acquired through the DOpenSession() function. |
[in] | szUserId | User identifier within the HSM. This identifier must not contain spaces or special characters. Uppercase and lowercase characters are case-sensitive. |
int AAP_API DSetUserParam | ( | HSESSIONCTX | hSession, |
DWORD | dwParam, | ||
BYTE * | pbData, | ||
DWORD | dwDataLen, | ||
DWORD | dwFlags ) |
#include <dinamo.h>
Change user settings on Dinamo.
[in] | hSession | Context acquired through the DOpenSession() function. | ||||||||||||||||
[in] | dwParam | Specifies the session parameter to be configured and consequently the data structure passed in the parameter pbData .
| ||||||||||||||||
[in] | pbData | Pointer to the data or structures specified in dwParam . | ||||||||||||||||
[in] | dwDataLen | Size of data or structure specified in dwParam . | ||||||||||||||||
[in] | dwFlags | Reserved for future use (must be 0). |
dwParam
is equal to UP_PASSWORD, the user's new password takes effect as soon as the function returns, so all subsequent authentications must be done with the new value.int AAP_API DGetUserParam | ( | HSESSIONCTX | hSession, |
DWORD | dwParam, | ||
BYTE * | pbData, | ||
DWORD * | pdwDataLen, | ||
DWORD | dwFlags ) |
#include <dinamo.h>
Recover user settings from Dinamo.
[in] | hSession | Context acquired through the DOpenSession() function. | ||||||||
[in] | dwParam | Consult dwParam in DSetUserParam(). The table below describes the specific flags for this API.
| ||||||||
[in] | pbData | Pointer to the data or structures specified in dwParam . | ||||||||
[in] | pdwDataLen | Size of data or structure specified in dwParam . | ||||||||
[in] | dwFlags | Reserved for future use (must be 0). |
int AAP_API DListUsers | ( | HSESSIONCTX | hSession, |
funcListUsersCallback | fncallback, | ||
void * | pParam ) |
#include <dinamo.h>
Lists the users of Dinamo.
[in] | hSession | Context acquired through the DOpenSession() function. |
[in] | fncallback | Pointer to a callback function used to list user names (identifiers). |
[in] | pParam | Pointer to any parameter that will be passed to the callback function |
int AAP_API DAssignToken | ( | const HSESSIONCTX | hSession, |
const char * | szUserId, | ||
const DWORD | dwParam, | ||
BYTE * | pbData, | ||
const DWORD | dwDataLen ) |
#include <dinamo.h>
It associates a standard OTP (time or event) token OATH with a user. After this call, the user will only authenticate with user, password and OTP.
[in] | hSession | Context acquired through the DOpenSession() function. | ||||||
[in] | dwParam | The following table is accepted:
| ||||||
[in] | szUserId | Name of the user who will have the token associated. | ||||||
[in] | pbData | Data containing the token parameters. Must be specified as defined in the dwParam parameter. | ||||||
[in] | dwDataLen | Size, in bytes, of the data passed in pbData. |
int AAP_API DUnassignToken | ( | const HSESSIONCTX | hSession, |
const DWORD | dwParam, | ||
const char * | szUserId ) |
#include <dinamo.h>
Disassociates OTP authentication from a user. After this call, the user will only authenticate with username and password.
[in] | hSession | Context acquired through the DOpenSession() function. | ||||
[in] | dwParam | The following table is accepted:
| ||||
[in] | szUserId | Name of the user who will have their token disassociated. |
int AAP_API DOATHResync | ( | const HSESSIONCTX | hSession, |
char * | szUser, | ||
char * | szOTP1, | ||
char * | szOTP2, | ||
DWORD | dwParam ) |
#include <dinamo.h>
Re-synchronizes an event token, standard OATH, associated with an HSM user. It receives two consecutive OTPs, generated by the token, to synchronize the state of the token in the HSM user.
[in] | hSession | Context acquired through the DOpenSession() function. |
[in] | szUser | Name of the user who will have their token re-synchronized. |
[in] | szOTP1 | First OTP, for synchronization, generated by the token. |
[in] | szOTP2 | Second OTP, for synchronization, generated by the token. |
[in] | dwParam | Reserved for future use (must be 0). |