|
Barracuda Application Server C/C++ Reference
Native APIs, integration guides, and platform interfaces
|
An instance of the AuthInfo struct is created on the stack in the Barracuda authenticators and is used as a container object for sending information to the registered user callback methods.
#include <AuthenticatedUser.h>
Public Attributes | |
| struct LoginTracker * | tracker |
| Borrowed optional tracker; NULL when tracking is disabled. More... | |
| HttpCommand * | cmd |
| Borrowed command for normal authentication. More... | |
| const char * | username |
| Borrowed NUL-terminated input user name, or NULL when no login was supplied. More... | |
| const char * | upwd |
| Borrowed supplied password when available for Basic/Form; NULL when unavailable, including Digest. More... | |
| AuthenticatedUser * | user |
| Borrowed authenticated user when available, otherwise NULL. More... | |
| AuthenticatedUserType | type |
| Input authentication mechanism; Unknown is permitted for direct database lookup. More... | |
| AuthInfoCT | ct |
| Credential interpretation selected by UserIntf_GetPwd. More... | |
| void * | userObj |
| Application pointer shared between callbacks in this authentication flow; initially NULL. More... | |
| BaTime | maxInactiveInterval |
| This variable specifies the time, in seconds, between client requests before the user is automatically logged out. More... | |
| int | maxUsers |
| Maximum concurrent logins for the user; initially 3. More... | |
| int | loginAttempts |
| Tracker-derived login counter difference when access is denied; initially zero. More... | |
| BaBool | denied |
| Initially FALSE; set TRUE when the tracker validation callback denies a cached address. More... | |
| BaBool | recycle |
| Initially FALSE. More... | |
| U8 | password [100] |
| Output credential storage, initially empty. More... | |
| HttpCommand* AuthInfo::cmd |
Borrowed command for normal authentication.
May be NULL for a direct user-database lookup; check before accessing HTTP state.
| AuthInfoCT AuthInfo::ct |
Credential interpretation selected by UserIntf_GetPwd.
Initially AuthInfoCT_Password. HA1 requires a 32-character hexadecimal MD5 value in password. Valid/Invalid report a callback comparison for Basic/Form; they cannot replace Digest credential data.
| BaBool AuthInfo::denied |
Initially FALSE; set TRUE when the tracker validation callback denies a cached address.
| int AuthInfo::loginAttempts |
Tracker-derived login counter difference when access is denied; initially zero.
It is not updated on every callback path.
| BaTime AuthInfo::maxInactiveInterval |
This variable specifies the time, in seconds, between client requests before the user is automatically logged out.
The default value for HttpSession is used if this value is zero. The default value can be changed in UserIntf_GetPwd. The authenticator calls method HttpSession::setMaxInactiveInterval if this variable has a non-zero value.
| int AuthInfo::maxUsers |
Maximum concurrent logins for the user; initially 3.
UserIntf_GetPwd may set a positive value. Values less than 1 prevent a new login.
| U8 AuthInfo::password[100] |
Output credential storage, initially empty.
For Password, copy a nonempty NUL-terminated password of at most 99 bytes. For HA1, store the 32 hexadecimal MD5 characters and a terminator. Leave empty for a missing user. Basic/Form ct=Valid can instead report a successful comparison without returning the stored password. Do not infer user existence solely from this buffer in every credential mode.
| BaBool AuthInfo::recycle |
Initially FALSE.
UserIntf_GetPwd may set TRUE to permit removal of an existing unlocked session when the login limit is reached. This does not guarantee that an eligible session exists.
| struct LoginTracker* AuthInfo::tracker |
Borrowed optional tracker; NULL when tracking is disabled.
| AuthenticatedUserType AuthInfo::type |
Input authentication mechanism; Unknown is permitted for direct database lookup.
Use this to interpret available credential fields.
| const char* AuthInfo::upwd |
Borrowed supplied password when available for Basic/Form; NULL when unavailable, including Digest.
Valid only during the callback flow.
| AuthenticatedUser* AuthInfo::user |
Borrowed authenticated user when available, otherwise NULL.
Initially NULL during database lookup.
| const char* AuthInfo::username |
Borrowed NUL-terminated input user name, or NULL when no login was supplied.
Valid only during the callback flow.
| void* AuthInfo::userObj |
Application pointer shared between callbacks in this authentication flow; initially NULL.
BAS neither owns nor frees it.