public class OpenAmAccessTokenResolver extends Object implements AccessTokenResolver
OpenAmAccessTokenResolver
knows how to resolve a given token identifier against an OpenAm instance.Constructor and Description |
---|
OpenAmAccessTokenResolver(Handler client,
OpenAmAccessToken.Builder builder,
String tokenInfoEndpoint)
Creates a new
OpenAmAccessTokenResolver configured to access the given /oauth2/tokeninfo
OpenAm endpoint. |
OpenAmAccessTokenResolver(Handler client,
org.forgerock.util.time.TimeService time,
String tokenInfoEndpoint)
Creates a new
OpenAmAccessTokenResolver configured to access the given /oauth2/tokeninfo
OpenAm endpoint. |
public OpenAmAccessTokenResolver(Handler client, org.forgerock.util.time.TimeService time, String tokenInfoEndpoint)
OpenAmAccessTokenResolver
configured to access the given /oauth2/tokeninfo
OpenAm endpoint.client
- Http client handler used to perform the requesttime
- Time service used to compute the token expiration timetokenInfoEndpoint
- full URL of the /oauth2/tokeninfo endpointpublic OpenAmAccessTokenResolver(Handler client, OpenAmAccessToken.Builder builder, String tokenInfoEndpoint)
OpenAmAccessTokenResolver
configured to access the given /oauth2/tokeninfo
OpenAm endpoint.client
- Http client handler used to perform the requestbuilder
- AccessToken buildertokenInfoEndpoint
- full URL of the /oauth2/tokeninfo endpointpublic AccessToken resolve(String token) throws OAuth2TokenException
AccessTokenResolver
resolve
in interface AccessTokenResolver
token
- token identifier to be resolvedAccessToken
(well formed, known by the server)OAuth2TokenException
- if the token is unknown by the serverCopyright © 2014 ForgeRock AS. All rights reserved.