SpringSecurity+OAuth2认证/oauth/token登录报错There is no client authentication

报错信息:

{

"error": "unauthorized",

"error_description": "There is no client authentication. Try adding an appropriate authentication filter."

}

找到这个问题原因后,发现自己被自己蠢哭了。

在自己的核心配置类里,把这个/oauth/token加入到忽略认证的路径里,这样还有个毛线的过滤器,

而springsecurity的核心就是过滤器,这样肯定是不行的。

把圈红部分去掉即可。

发布了40 篇原创文章 · 获赞 15 · 访问量 2万+

猜你喜欢

转载自blog.csdn.net/lvxiucai/article/details/100143697