-
Notifications
You must be signed in to change notification settings - Fork 69
Open
Description
1.5.X可以运行 你少了一些代码 参考
https://blog.csdn.net/u012040869/article/details/80140515
修改 AuthorizationServerConfiguration 类即可
@OverRide
public void configure(AuthorizationServerSecurityConfigurer oauthServer) throws Exception {
oauthServer.tokenKeyAccess("isAnonymous() || hasAuthority('ROLE_TRUSTED_CLIENT')");
oauthServer.checkTokenAccess("hasAuthority('ROLE_TRUSTED_CLIENT')");
//如果没有支持allowFormAuthenticationForClients或者有支持但是url中没有client_id和client_secret的,走basic认证保护
//https://blog.csdn.net/u012040869/article/details/80140515
//springboot 1.5.x 版本必须
oauthServer.allowFormAuthenticationForClients();
}
Metadata
Metadata
Assignees
Labels
No labels