R
R
Rocket-API
Search…
自定义登录鉴权
默认情况下,任意账号都可以登录成功
自定义登录,需要实现接口com.github.alenfive.rocketapi.extend.IUserAuthorization

默认实现:

1
@Component
2
public class DefaultUserAuthorization implements IUserAuthorization {
3
4
@Override
5
public String validate(String username, String password) {
6
return StringUtils.isEmpty(username)?"admin":username;
7
}
8
}
Copied!
Last modified 1yr ago
Copy link
Contents