Class OpenAmAccessTokenResolver
- java.lang.Object
-
- org.forgerock.http.oauth2.resolver.OpenAmAccessTokenResolver
-
- All Implemented Interfaces:
AccessTokenResolver
@Deprecated public class OpenAmAccessTokenResolver extends Object implements AccessTokenResolver
Deprecated.The “/oauth2/tokeninfo” endpoint was deprecated in AM 6.5.OpenAmAccessTokenResolver
is deprecated and should not be used.AnOpenAmAccessTokenResolver
knows how to resolve a given token identifier against an OpenAm instance.Models an
AccessTokenInfo
as returned by the OpenAM tokeninfo endpoint.curl https://openam.example.com:8443/openam/oauth2/tokeninfo?access_token=70e5776c-b0fa-4c70-9962-defb0e9c3cd6
{ "scope": [ "email", "profile" ], "grant_type": "password", "realm": "/", "token_type": "Bearer", "expires_in": 471, "access_token": "70e5776c-b0fa-4c70-9962-defb0e9c3cd6", "email": "", "profile": "" }
- See Also:
as replacement.
-
-
Constructor Summary
Constructors Constructor Description OpenAmAccessTokenResolver(Handler client, Clock clock, String tokenInfoEndpoint)
Deprecated.Creates a newOpenAmAccessTokenResolver
configured to access the given /oauth2/tokeninfo OpenAm endpoint.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description Promise<AccessTokenInfo,AccessTokenException>
resolve(Context context, Supplier<Request,IOException> request, String token)
Deprecated.Resolves a given access token against an authorization server.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.forgerock.http.oauth2.AccessTokenResolver
resolve
-
-
-
-
Constructor Detail
-
OpenAmAccessTokenResolver
public OpenAmAccessTokenResolver(Handler client, Clock clock, String tokenInfoEndpoint)
Deprecated.Creates a newOpenAmAccessTokenResolver
configured to access the given /oauth2/tokeninfo OpenAm endpoint.- Parameters:
client
- Http client handler used to perform the requestclock
- Clock used to compute the token expiration timetokenInfoEndpoint
- full URL of the /oauth2/tokeninfo endpoint
-
-
Method Detail
-
resolve
public Promise<AccessTokenInfo,AccessTokenException> resolve(Context context, Supplier<Request,IOException> request, String token)
Deprecated.Description copied from interface:AccessTokenResolver
Resolves a given access token against an authorization server.- Specified by:
resolve
in interfaceAccessTokenResolver
- Parameters:
context
- Context chain used to keep a relationship between requests (tracking)request
- a supplier for the HTTP request the access token was presented on. The request should be defensively copied by the caller in case the resolver needs to consume the entity.token
- token identifier to be resolved- Returns:
- a promise completed either with a valid
AccessTokenInfo
(well-formed, known by the server), or by an exception
-
-