Class OAuth2BearerFilter
- java.lang.Object
-
- ch.ivyteam.ivy.rest.client.oauth2.OAuth2BearerFilter
-
- All Implemented Interfaces:
javax.ws.rs.client.ClientRequestFilter
@Provider public class OAuth2BearerFilter extends Object implements javax.ws.rs.client.ClientRequestFilter
Filter to simplify OAUTH2 authorization flows.It initiates OAUTH2 authentication requests to resolve a 'Bearer' token which is sub-sequently added as 'Authorization' request header.
- Since:
- 9.2
- API:
- This is a public API.
-
-
Constructor Summary
Constructors Constructor Description OAuth2BearerFilter(OAuth2TokenRequester getToken, OAuth2UriProvider uriFactory)
-
-
-
Constructor Detail
-
OAuth2BearerFilter
public OAuth2BearerFilter(OAuth2TokenRequester getToken, OAuth2UriProvider uriFactory)
- Parameters:
getToken
- aOAuth2TokenRequester
implementation that actually does the 'accessToken' call to the OAUTH2 authority in case the current session has not already a valid accessToken.uriFactory
- anOAuth2UriProvider
to setup OAUTH2 authority URIs for the various requests that may must be fired (.e.g /auth, /token, /userinfo, ...)- API:
- This public API is available in Java.
-
-