gluu
|
公開メンバ関数 | |
AuthorizationCode (int lifeTime) | |
AuthorizationCode (String code, Date creationDate, Date expirationDate) | |
boolean | isValid () |
boolean | isUsed () |
synchronized void | setUsed (boolean used) |
void | checkExpired () |
void | checkExpired (Date now) |
String | getCode () |
void | setCode (String code) |
Date | getCreationDate () |
void | setCreationDate (Date creationDate) |
Date | getExpirationDate () |
void | setExpirationDate (Date expirationDate) |
boolean | isRevoked () |
synchronized void | setRevoked (boolean revoked) |
boolean | isExpired () |
synchronized void | setExpired (boolean expired) |
String | getAuthMode () |
void | setAuthMode (String authMode) |
String | getSessionDn () |
void | setSessionDn (String sessionDn) |
int | getExpiresIn () |
String | getHash (SignatureAlgorithm signatureAlgorithm) |
非公開変数類 | |
boolean | used |
The authorization code is obtained by using an authorization server as an intermediary between the client and resource owner. Instead of requesting authorization directly from the resource owner, the client directs the resource owner to an authorization server (via its user- agent as defined in [RFC2616]), which in turn directs the resource owner back to the client with the authorization code.
Before directing the resource owner back to the client with the authorization code, the authorization server authenticates the resource owner and obtains authorization. Because the resource owner only authenticates with the authorization server, the resource owner's credentials are never shared with the client.
The authorization code provides a few important security benefits such as the ability to authenticate the client, and the transmission of the access token directly to the client without passing it through the resource owner's user-agent, potentially exposing it to others, including the resource owner.
|
inline |
Constructs an authorization code.
When created, a token is valid for a given lifetime, and after this period of time, it will be marked as expired automatically by a background process.
When required, the token can be marked as revoked.
lifeTime | The life time of the token. |
|
inline |
|
inlineinherited |
Checks whether the token has expired and if true, marks itself as expired.
|
inlineinherited |
Checks whether the token has expired and if true, marks itself as expired.
|
inlineinherited |
Returns the authentication mode.
|
inlineinherited |
Returns the token code.
|
inlineinherited |
Returns the creation date of the token.
|
inlineinherited |
Returns the expiration date of the token.
|
inlineinherited |
Returns the lifetime in seconds of the token.
|
inlineinherited |
|
inlineinherited |
|
inlineinherited |
Return true
if the token has expired.
true
if the token has expired.
|
inlineinherited |
Returns true
if the token has been revoked.
true
if the token has been revoked.
|
inline |
Returns whether an authorization code has been used.
true
if the authorization code has been used.
|
inline |
Checks whether a token is valid. An authorization code is valid if it has not been used before, not revoked and not expired.
|
inlineinherited |
Sets the authentication mode.
authMode | The authentication mode. |
|
inlineinherited |
Sets the token code.
code | The code of the token. |
|
inlineinherited |
Sets the creation date of the token.
creationDate | The creation date. |
|
inlineinherited |
Sets the expiration date of the token.
expirationDate | The expiration date. |
|
inlineinherited |
Sets the value of the expired flag to indicate whether the token has expired.
expired | Expire or not. |
|
inlineinherited |
Sets the value of the revoked flag to indicate whether the token has been revoked.
revoked | Revoke or not. |
|
inlineinherited |
|
inline |
Sets the flag to indicate whether a token has been used. The authorization code must be used only once and after it must be marked as used.
used | Used or not. |
|
private |