小编raj*_*wal的帖子

无法解析 OpenID 配置 spring boot(安全)java.net.ConnectException:连接被拒绝:连接

我正在学习 spring security,并试图运行这个项目,但它给了我一个错误。

我不明白该怎么办。这是我正在关注的Github链接、Youtube 视频 [链接] ( https://www.youtube.com/watch?v=1N-xwmoN83w )。

当我尝试运行客户端应用程序时,它运行良好,但是当我尝试运行资源服务器时,它没有运行,它给了我错误:

  1. 无法使用提供的颁发者“ http://localhost:8090/uaa/oauth/token ”解析 OpenID 配置
  2. “ http://localhost:8090/uaa/oauth/token/.well-known/openid-configuration ”的 GET 请求出现 I/O 错误:连接被拒绝:连接;嵌套异常是 java.net.ConnectException:连接被拒绝:连接

堆栈跟踪如下:

org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'springSecurityFilterChain' defined in class path resource [org/springframework/security/config/annotation/web/configuration/WebSecurityConfiguration.class]: Bean instantiation via factory method failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [javax.servlet.Filter]: Factory method 'springSecurityFilterChain' threw exception; nested exception is java.lang.IllegalArgumentException: Unable to resolve the OpenID Configuration with the provided Issuer of "http://localhost:8090/uaa/oauth/token"
    at org.springframework.beans.factory.support.ConstructorResolver.instantiate(ConstructorResolver.java:624) ~[spring-beans-5.1.0.RC3.jar:5.1.0.RC3]
    at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:455) ~[spring-beans-5.1.0.RC3.jar:5.1.0.RC3] …
Run Code Online (Sandbox Code Playgroud)

spring spring-security oauth-2.0 jwt spring-boot

5
推荐指数
1
解决办法
6730
查看次数

标签 统计

jwt ×1

oauth-2.0 ×1

spring ×1

spring-boot ×1

spring-security ×1