RT::AuthToken - Represents an authentication token for a user
Create takes a hash of values and creates a row in the database. Available keys are:
The user ID for whom this token will authenticate. If it's not the AuthToken object's CurrentUser, then the AdminUsers permission is required.
A human-readable description of what this token will be used for.
Returns a tuple of (status, msg) on failure and (id, msg, authstring) on success. Note that this is the only time the authstring will be directly readable (as it is stored in the database hashed like a password, so use this opportunity to capture it.
Returns true if the current user can see the AuthToken
Not permitted
Checks ACL
Sets the "last used" time, without touching "last updated"
Class method that takes as input an authstring and provides a tuple of (user id, token) on success, or the empty list on failure.
Analogous to "IsPassword" in RT::User, without all of the legacy password forms.
"LastUsed" as an RT::Date object.
Documented for internal use only, do not call these from outside RT::AuthToken itself.
Checks if the current user can ManageAuthTokens before calling SUPER::_Set.
SUPER::_Set
Checks "CurrentUserCanSee" before calling SUPER::_Value.
SUPER::_Value
Generates an unpredictable auth token
Takes a user id and token and provides an authstring for use in place of a (username, password) combo.
To install RT::Authen::Token, copy and paste the appropriate command in to your terminal.
cpanm
cpanm RT::Authen::Token
CPAN shell
perl -MCPAN -e shell install RT::Authen::Token
For more information on module installation, please visit the detailed CPAN module installation guide.