@Bean public DefaultTokenServices tokenServices(ClientDetailsService clientDetailsService) { DefaultTokenServices services = new DefaultTokenServices(); services.setTokenStore(tokenStore()); services.setTokenEnhancer(tokenEnhancer()); services.setSupportRefreshToken(true); services.setClientDetailsService(clientDetailsService); return services; }
@Bean public ApprovalStoreUserApprovalHandler userApprovalHandler() { ApprovalStoreUserApprovalHandler handler = new ApprovalStoreUserApprovalHandler(); handler.setApprovalStore(approvalStore()); handler.setClientDetailsService(clientDetailsService); handler.setRequestFactory(new DefaultOAuth2RequestFactory(clientDetailsService)); return handler; }
@Override public void configure(AuthorizationServerEndpointsConfigurer endpoints) throws Exception { endpoints.authenticationManager(authenticationManager).tokenStore(tokenStore()); }
@Bean public ApprovalStore approvalStore() throws Exception { TokenApprovalStore store = new TokenApprovalStore(); store.setTokenStore(tokenStore()); return store; }
@Bean public ApprovalStore approvalStore() { TokenApprovalStore store = new TokenApprovalStore(); store.setTokenStore(tokenStore()); return store; }
@Override public void configure(AuthorizationServerSecurityConfigurer oauthServer) throws Exception { oauthServer.authenticationEntryPoint(authenticationEntryPoint()).accessDeniedHandler(accessDeniedHandler()); }
@Override public void configure(AuthorizationServerEndpointsConfigurer endpoints) throws Exception { endpoints.authorizationCodeServices(authorizationCodeServices()) .authenticationManager(auth).tokenStore(tokenStore()) .approvalStoreDisabled(); }
@Bean public DefaultTokenServices tokenServices() { DefaultTokenServices services = new DefaultTokenServices(); services.setClientDetailsService(clientDetailsService()); services.setSupportRefreshToken(true); services.setTokenStore(tokenStore()); return services; }
@Bean public DefaultTokenServices tokenServices() { DefaultTokenServices services = new DefaultTokenServices(); services.setClientDetailsService(clientDetailsService); services.setSupportRefreshToken(true); services.setTokenStore(tokenStore()); return services; }
@Override public void configure(AuthorizationServerEndpointsConfigurer endpoints) throws Exception { endpoints.authenticationManager(authenticationManager).accessTokenConverter(accessTokenConverter()); }