|
| AuthorizationCodeGrant () |
|
| AuthorizationCodeGrant (User user, Client client, Date authenticationTime) |
|
void | init (User user, Client client, Date authenticationTime) |
|
void | revokeAllTokens () |
|
void | checkExpiredTokens () |
|
boolean | isCachedWithNoPersistence () |
|
boolean | isImplicitFlow () |
|
void | init (User user, AuthorizationGrantType authorizationGrantType, Client client, Date authenticationTime) |
|
IdToken | createIdToken (IAuthorizationGrant grant, String nonce, AuthorizationCode authorizationCode, AccessToken accessToken, Set< String > scopes, boolean includeIdTokenClaims, Function< JsonWebResponse, Void > preProcessing) throws Exception |
|
IdToken | createIdToken (String nonce, AuthorizationCode authorizationCode, AccessToken accessToken, AuthorizationGrant authorizationGrant, boolean includeIdTokenClaims, Function< JsonWebResponse, Void > preProcessing) throws SignatureException, StringEncrypter.EncryptionException, InvalidJwtException, InvalidJweException |
|
String | checkScopesPolicy (String scope) |
|
void | save () |
|
AccessToken | createAccessToken () |
|
RefreshToken | createRefreshToken () |
|
void | persist (TokenLdap p_token) |
|
void | persist (AuthorizationCode p_code) |
|
TokenLdap | asToken (IdToken p_token) |
|
TokenLdap | asToken (RefreshToken p_token) |
|
TokenLdap | asToken (AuthorizationCode p_authorizationCode) |
|
TokenLdap | asToken (AccessToken p_accessToken) |
|
String | getScopesAsString () |
|
TokenLdap | asTokenLdap (AbstractToken p_token) |
|
boolean | isValid () |
|
String | getSub () |
|
void | setIsCachedWithNoPersistence (boolean isCachedWithNoPersistence) |
|
synchronized String | getGrantId () |
|
synchronized void | setGrantId (String p_grantId) |
|
AuthorizationCode | getAuthorizationCode () |
|
void | setAuthorizationCode (AuthorizationCode authorizationCode) |
|
String | getTokenBindingHash () |
|
void | setTokenBindingHash (String tokenBindingHash) |
|
String | getNonce () |
|
void | setNonce (String nonce) |
|
String | getCodeChallenge () |
|
void | setCodeChallenge (String codeChallenge) |
|
String | getCodeChallengeMethod () |
|
void | setCodeChallengeMethod (String codeChallengeMethod) |
|
String | getClaims () |
|
void | setClaims (String claims) |
|
Set< String > | getRefreshTokensCodes () |
|
Set< String > | getAccessTokensCodes () |
|
List< AccessToken > | getAccessTokens () |
|
void | setScopes (Collection< String > scopes) |
|
AccessToken | getLongLivedAccessToken () |
|
void | setLongLivedAccessToken (AccessToken longLivedAccessToken) |
|
IdToken | getIdToken () |
|
void | setIdToken (IdToken idToken) |
|
TokenLdap | getTokenLdap () |
|
void | setTokenLdap (TokenLdap p_tokenLdap) |
|
User | getUser () |
|
String | getAcrValues () |
|
void | setAcrValues (String acrValues) |
|
String | getSessionDn () |
|
void | setSessionDn (String sessionDn) |
|
String | getUserId () |
|
String | getUserDn () |
|
AuthorizationGrantType | getAuthorizationGrantType () |
|
Client | getClient () |
|
String | getClientId () |
|
String | getClientDn () |
|
Date | getAuthenticationTime () |
|
void | setAuthenticationTime (Date authenticationTime) |
|
Set< String > | getScopes () |
|
JwtAuthorizationRequest | getJwtAuthorizationRequest () |
|
void | setJwtAuthorizationRequest (JwtAuthorizationRequest p_jwtAuthorizationRequest) |
|
void | setAccessTokens (List< AccessToken > accessTokens) |
|
List< RefreshToken > | getRefreshTokens () |
|
void | setRefreshTokens (List< RefreshToken > refreshTokens) |
|
RefreshToken | getRefreshToken (String refreshTokenCode) |
|
AbstractToken | getAccessToken (String tokenCode) |
|
String | toString () |
|
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.
- 著者
- Javier Rojas Blum Date: 09.29.2011
-
Yuriy Movchan