I'm currently working on implementing an Authorization Server using Spring Security OAuth. While configuring the OAuth server, I've encountered that the AuthorizationServerConfigurerAdapter class itself has been deprecated.
Here's a segment of the code where I extend AuthorizationServerConfigurerAdapter:
@Configuration @EnableAuthorizationServer protected static class OAuthConfig extends AuthorizationServerConfigurerAdapter{ @Autowired private AuthenticationManager authenticationManager; @Autowired private WebAdminCredentials webadminCredentials; @Override public void configure(AuthorizationServerEndpointsConfigurer endpoints) throws Exception { endpoints.authenticationManager(authenticationManager).allowedTokenEndpointRequestMethods(HttpMethod.GET, HttpMethod.POST); } @Override public void configure(AuthorizationServerSecurityConfigurer security) throws Exception { super.configure(security); } @Override public void configure(ClientDetailsServiceConfigurer clients) throws Exception { // Configure clients } } Considering the deprecation of AuthorizationServerConfigurerAdapter, I have a couple of questions:
What alternatives are available for AuthorizationServerConfigurerAdapter? How can I migrate my current implementation to accommodate the deprecation?
I couldn't find any suitable replacement code for this anywhere.
spring-security-oauth2is end of life since 2022, last version was 2.5.x. There is a new Spring Authoritation sever project, which you can use.