Correctly configure spring security oauth2

别来无恙 提交于 2019-12-02 12:31:57
Oreste Viron

Actually it's a problem with spring security. The solution is in this thread :

https://github.com/spring-projects/spring-security-oauth/issues/980

This annotation should be added for the Adapter to be correctly called :

@Configuration 
@Order(SecurityProperties.ACCESS_OVERRIDE_ORDER) 
class WebSecurityConfiguration extends WebSecurityConfigurerAdapter { 
    // ...
}

Another solution is to implement ResourceServerConfigurerAdapter instead of WebSecurityConfigurerAdapter.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!