解决@EnableOAuth2Sso在SpringBoot2.X搭建的单点登录项目启动报错 |
您所在的位置:网站首页 › enableoauth2sso注解的作用 › 解决@EnableOAuth2Sso在SpringBoot2.X搭建的单点登录项目启动报错 |
在Springboot2.x中,@EnableOAuth2Sso开启webclient的OAuth2认证协议需要引入的jar包为: org.springframework.security.oauth spring-security-oauth2 2.2.2.RELEASE org.springframework.security.oauth.boot spring-security-oauth2-autoconfigure 2.0.3.RELEASE在SecurityConfigure中扩展WebSecurityConfigurerAdapter方法时,开启EnableOAuth2Sso @Configuration @EnableOAuth2Sso public class SecurityConfigure extends WebSecurityConfigurerAdapter { }使用SpringBoot2.1.x版本将会报错误如下 The bean ‘ScopedTarget.OAuth2ClientContext’ Error将SpringBoot版本改为2.0.X版本后,项目正常启动 |
今日新闻 |
推荐新闻 |
CopyRight 2018-2019 办公设备维修网 版权所有 豫ICP备15022753号-3 |