|
gwenhywfar 5.10.1
|

Go to the source code of this file.
Functions | |
| static int | GWEN_Gui__HashPair (const char *token, const char *pin, GWEN_BUFFER *buf) |
| int | GWEN_Gui_GetPassword (uint32_t flags, const char *token, const char *title, const char *text, char *buffer, int minLen, int maxLen, GWEN_GUI_PASSWORD_METHOD methodId, GWEN_DB_NODE *methodParams, uint32_t guiid) |
| static int GWENHYWFAR_CB | GWEN_Gui_Internal_GetPassword (GWEN_GUI *gui, uint32_t flags, const char *token, const char *title, const char *text, char *buffer, int minLen, int maxLen, GWEN_UNUSED GWEN_GUI_PASSWORD_METHOD methodId, GWEN_UNUSED GWEN_DB_NODE *methodParams, uint32_t guiid) |
| static int GWENHYWFAR_CB | GWEN_Gui_Internal_SetPasswordStatus (GWEN_GUI *gui, const char *token, const char *pin, GWEN_GUI_PASSWORD_STATUS status, GWEN_UNUSED uint32_t guiid) |
| int | GWEN_Gui_SetPasswordStatus (const char *token, const char *pin, GWEN_GUI_PASSWORD_STATUS status, uint32_t guiid) |
|
static |
Definition at line 29 of file gui_passwd.c.
References DBG_ERROR, GWEN_LOGDOMAIN, GWEN_MDigest_Begin(), GWEN_MDigest_End(), GWEN_MDigest_free(), GWEN_MDigest_GetDigestPtr(), GWEN_MDigest_GetDigestSize(), GWEN_MDigest_Md5_new(), GWEN_MDigest_Update(), and GWEN_Text_ToHexBuffer().
Referenced by GWEN_Gui_Internal_GetPassword(), and GWEN_Gui_Internal_SetPasswordStatus().


| int GWEN_Gui_GetPassword | ( | uint32_t | flags, |
| const char * | token, | ||
| const char * | title, | ||
| const char * | text, | ||
| char * | buffer, | ||
| int | minLen, | ||
| int | maxLen, | ||
| GWEN_GUI_PASSWORD_METHOD | methodId, | ||
| GWEN_DB_NODE * | methodParams, | ||
| uint32_t | guiid | ||
| ) |
This function retrieves a password or pin. The implementation might want to use a cache or a password file. The default implementation simply asks the user for input. The function GWEN_Gui_SetPasswordStatus() is used to communicate the status of a password. So if this function here uses a password cache then the callback for GWEN_Gui_SetPasswordStatus() should also be implemented.
NOTE: AqBanking uses GWEN_Gui_PasswordMethod_OpticalHHD as methodId for all optical TAN input methods like "chipTAN optisch" and others. To determine which optical method is actually requested see the DB variable "tanMethodId" inside the methodParams parameter. The data to send to the TAN generator can be found in the toplevel variable "challenge".
| flags | flags, see GWEN_GUI_INPUT_FLAGS_CONFIRM ff. |
| token | unique identification for the password or pin. This can be used to read the password from a cache or file. |
| title | title of the input box |
| text | Text of the box: UTF-8, with both a normal text and a HTML variant of the text in the same string. See text restrictions note above. |
| buffer | buffer to store the response in. Must have at least room for maxLen bytes |
| minLen | minimal length of the password (if 0 then there is no low limit) |
| maxLen | size of the buffer including the trailing NULL character. This means that if you want to ask the user for a PIN of at most 4 characters you need to supply a buffer of at least 5 bytes and provide a 5 as maxLen. |
| methodId | Id of the pin/password/tan entry. |
| methodParams | additional parameters for the pin/password/tan entry, content depends on the methodId (my be NULL for simple text input) |
| guiid | id as returned by GWEN_Gui_ProgressStart or GWEN_Gui_ShowBox) |
Definition at line 271 of file gui_passwd.c.
References GWEN_ERROR_NOT_IMPLEMENTED, and GWEN_Gui_GetGui().
Referenced by GWEN_Crypt_Token_GetPin(), and test10().


|
static |
Definition at line 60 of file gui_passwd.c.
References DBG_ERROR, DBG_INFO, DBG_WARN, GWEN_Buffer_free(), GWEN_Buffer_GetStart(), GWEN_Buffer_new(), GWEN_DB_FLAGS_OVERWRITE_VARS, GWEN_DB_GetCharValue(), GWEN_DB_SetCharValue(), GWEN_ERROR_NO_DATA, GWEN_ERROR_NOT_FOUND, GWEN_ERROR_USER_ABORTED, GWEN_Gui__HashPair(), GWEN_GUI_FLAGS_NONINTERACTIVE, GWEN_GUI_INPUT_FLAGS_CONFIRM, GWEN_GUI_INPUT_FLAGS_DIRECT, GWEN_GUI_INPUT_FLAGS_TAN, GWEN_Gui_InputBox(), GWEN_Gui_MessageBox(), GWEN_GUI_MSG_FLAGS_CONFIRM_B1, GWEN_GUI_MSG_FLAGS_SEVERITY_DANGEROUS, GWEN_GUI_MSG_FLAGS_TYPE_ERROR, GWEN_LOGDOMAIN, GWEN_PasswordStore_GetPassword(), GWEN_PasswordStore_SetPassword(), GWEN_StringList_HasString(), GWEN_StringList_RemoveString(), GWEN_Text_EscapeToBufferTolerant(), I18N, and NULL.
Referenced by GWEN_Gui_new().


|
static |
Definition at line 216 of file gui_passwd.c.
References DBG_WARN, GWEN_Buffer_free(), GWEN_Buffer_GetStart(), GWEN_Buffer_new(), GWEN_DB_ClearGroup(), GWEN_DB_DeleteVar(), GWEN_Gui__HashPair(), GWEN_Gui_PasswordStatus_Bad, GWEN_Gui_PasswordStatus_Ok, GWEN_Gui_PasswordStatus_Remove, GWEN_LOGDOMAIN, GWEN_PasswordStore_ClearStoragePasswd(), GWEN_PasswordStore_SetPassword(), GWEN_StringList_AppendString(), GWEN_StringList_RemoveString(), GWEN_Text_EscapeToBufferTolerant(), and NULL.
Referenced by GWEN_Gui_new().


| int GWEN_Gui_SetPasswordStatus | ( | const char * | token, |
| const char * | pin, | ||
| GWEN_GUI_PASSWORD_STATUS | status, | ||
| uint32_t | guiid | ||
| ) |
This functions sets the status of a password.
| guiid | id as returned by GWEN_Gui_ProgressStart or GWEN_Gui_ShowBox) |
Definition at line 296 of file gui_passwd.c.
References GWEN_ERROR_NOT_IMPLEMENTED, and GWEN_Gui_GetGui().
Referenced by GWEN_Crypt_Token_SetPinStatus().

