Class HawaiiResourceServerConfigurerAdapter
- java.lang.Object
-
- org.springframework.security.oauth2.config.annotation.web.configuration.ResourceServerConfigurerAdapter
-
- org.hawaiiframework.security.oauth2.config.HawaiiResourceServerConfigurerAdapter
-
- All Implemented Interfaces:
org.springframework.security.oauth2.config.annotation.web.configuration.ResourceServerConfigurer
@EnableWebSecurity @EnableResourceServer public class HawaiiResourceServerConfigurerAdapter extends org.springframework.security.oauth2.config.annotation.web.configuration.ResourceServerConfigurerAdapterConfiguration class for theHawaiiTokenServices.- Since:
- 3.0.0
- Author:
- Wouter Eerdekens, Jules Houben
-
-
Constructor Summary
Constructors Constructor Description HawaiiResourceServerConfigurerAdapter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.springframework.security.oauth2.provider.token.TokenStorejwkTokenStore(org.springframework.boot.autoconfigure.security.oauth2.resource.ResourceServerProperties properties)Bean configuration of aJwkTokenStorewhich does the actual Jwk checks.org.springframework.security.oauth2.client.OAuth2RestOperationsoAuth2RestOperations(org.springframework.security.oauth2.client.resource.OAuth2ProtectedResourceDetails resource, org.springframework.security.oauth2.client.OAuth2ClientContext clientContext)Bean configuration of theOAuth2RestTemplateto use to access the user info endpoint.org.springframework.security.oauth2.provider.token.ResourceServerTokenServicesresourceServerTokenServices(org.springframework.security.oauth2.provider.token.TokenStore jwkTokenStore, org.springframework.security.oauth2.client.OAuth2RestOperations restTemplate, org.springframework.boot.autoconfigure.security.oauth2.resource.ResourceServerProperties properties, org.springframework.boot.autoconfigure.security.oauth2.resource.PrincipalExtractor principalExtractor, Cache<org.springframework.security.core.Authentication> authenticationCache)Bean configuration of theHawaiiTokenServicesto use.
-
-
-
Method Detail
-
jwkTokenStore
@Bean public org.springframework.security.oauth2.provider.token.TokenStore jwkTokenStore(org.springframework.boot.autoconfigure.security.oauth2.resource.ResourceServerProperties properties)
Bean configuration of aJwkTokenStorewhich does the actual Jwk checks.- Parameters:
properties- the ResourceServerProperties- Returns:
- the bean
-
oAuth2RestOperations
@Bean @Primary public org.springframework.security.oauth2.client.OAuth2RestOperations oAuth2RestOperations(org.springframework.security.oauth2.client.resource.OAuth2ProtectedResourceDetails resource, org.springframework.security.oauth2.client.OAuth2ClientContext clientContext)Bean configuration of theOAuth2RestTemplateto use to access the user info endpoint.- Parameters:
resource- the protected resource detailsclientContext- the client context- Returns:
- the bean
-
resourceServerTokenServices
@Bean public org.springframework.security.oauth2.provider.token.ResourceServerTokenServices resourceServerTokenServices(org.springframework.security.oauth2.provider.token.TokenStore jwkTokenStore, org.springframework.security.oauth2.client.OAuth2RestOperations restTemplate, org.springframework.boot.autoconfigure.security.oauth2.resource.ResourceServerProperties properties, org.springframework.boot.autoconfigure.security.oauth2.resource.PrincipalExtractor principalExtractor, Cache<org.springframework.security.core.Authentication> authenticationCache)Bean configuration of theHawaiiTokenServicesto use.- Parameters:
jwkTokenStore- the jwk token storerestTemplate- the rest templateproperties- the resource server propertiesprincipalExtractor- the principal extractorauthenticationCache- the cache to store the user info authentication- Returns:
- the bean
-
-