收到访问令牌后,我将其附加到我的Postman中,并测试在localhost中运行的样例REST API (在Spring Boot中开发
在执行此操作时,我收到以下错误消息
{
"error": "server_error",
"error_description": "Invalid JWK Set Object. The JWK Set MUST have a keys attribute."
}这是我的API
@RestController
@RequestMapping("/security/demo")
@EnableResourceServer
public class MyController {
@GetMapping
public String sayHello () {
return "Hello Friend" ;
}
}这是我的属性文件
# Security
security.oauth2.resource.id=783f0982-2134-4f98-8a15-c520a6737bbe
security.oauth2.resource.jwk.key-set-uri=https://*******.com/token_key
security.basic.enabled=false发布于 2018-04-11 21:27:40
我发现了错误。从我的角度来说这是一个巨大的错误。我必须设置这个属性来消除这个错误
security.oauth2.resource.jwt.key-urihttps://stackoverflow.com/questions/49776180
复制相似问题