Class OAuthContext
java.lang.Object
org.apache.cxf.rs.security.oauth2.common.OAuthContext
Captures the information about the current client request
which custom filters may use to further protect the endpoints
-
Constructor Summary
ConstructorsConstructorDescriptionOAuthContext(UserSubject resourceOwnerSubject, UserSubject clientSubject, List<OAuthPermission> perms, String tokenGrantType) -
Method Summary
Modifier and TypeMethodDescriptionReturns the client which obtained the access tokenGets theUserSubjectrepresenting the clientGets the list of the permissions assigned to the current access tokenGets theUserSubjectrepresenting the resource ownerReturns the grant type which was used to obtain the access token the client is using now during the current requestReturns the access token the client is using now during the current requestString[]booleanvoidsetClientConfidential(boolean isConfidential) voidsetClientId(String clientId) Sets the client which obtained the access tokenvoidsetTokenAudience(String audience) voidsetTokenExtraProperties(Map<String, String> tokenExtraProperties) voidsetTokenIssuer(String tokenIssuer) voidsetTokenKey(String tokenKey) Sets the access token the client is using now during the current requestvoidsetTokenRequestParts(String[] tokenRequestParts)
-
Constructor Details
-
OAuthContext
public OAuthContext(UserSubject resourceOwnerSubject, UserSubject clientSubject, List<OAuthPermission> perms, String tokenGrantType)
-
-
Method Details
-
getSubject
Gets theUserSubjectrepresenting the resource owner- Returns:
- the subject
-
getClientSubject
Gets theUserSubjectrepresenting the client- Returns:
- the subject
-
getPermissions
Gets the list of the permissions assigned to the current access token- Returns:
- the permissions
-
getTokenGrantType
Returns the grant type which was used to obtain the access token the client is using now during the current request- Returns:
- the grant type
-
getClientId
Returns the client which obtained the access token- Returns:
- the client id
-
setClientId
Sets the client which obtained the access token- Parameters:
clientId-
-
getTokenKey
Returns the access token the client is using now during the current request- Returns:
- the token
-
setTokenKey
Sets the access token the client is using now during the current request- Parameters:
tokenKey-
-
getTokenAudience
-
setTokenAudience
-
getTokenRequestParts
-
setTokenRequestParts
-
isClientConfidential
public boolean isClientConfidential() -
setClientConfidential
public void setClientConfidential(boolean isConfidential) -
getTokenIssuer
-
setTokenIssuer
-
getTokenExtraProperties
-
setTokenExtraProperties
-