shiro认证过程Authenticator到realm,然后进行认证的过程
来源:互联网 发布:java安卓模拟器 编辑:程序博客网 时间:2024/06/03 20:05
public final AuthenticationInfo getAuthenticationInfo(AuthenticationToken token) throws AuthenticationException { AuthenticationInfo info = getCachedAuthenticationInfo(token); if (info == null) { //otherwise not cached, perform the lookup: info = doGetAuthenticationInfo(token);//调用自定义realm认证方法 log.debug("Looked up AuthenticationInfo [{}] from doGetAuthenticationInfo", info); if (token != null && info != null) { cacheAuthenticationInfoIfPossible(token, info); } } else { log.debug("Using cached authentication info [{}] to perform credentials matching.", info); } if (info != null) { assertCredentialsMatch(token, info);//对token和info进行信息对比 } else { log.debug("No AuthenticationInfo found for submitted AuthenticationToken [{}]. Returning null.", token); } return info; }
AuthenticatingRealm抽象类中定义了这段代码显示了Authenticator调用自定义的realm,和realm返回AuthenticationInfo后,Authenticator再将用户提交的token信息和realm查询到的info信息进行对比,如果相同则认证成功。
0 0
- shiro认证过程Authenticator到realm,然后进行认证的过程
- shiro认证的过程
- Shiro 的身份认证-Realm
- Apache Shiro 认证过程
- Apache Shiro 认证过程
- shiro认证过程
- shiro身份认证过程
- shiro认证过程
- shiro权限认证过程
- shiro认证授权过程
- shiro-realm认证
- Shiro 自定义realm认证
- shiro的两种认证过程
- shiro 认证配置和认证过程理解
- Apache shiro(3)-认证过程
- java SE shiro认证过程
- Shiro之多Realm的认证及认证策略-yellowcong
- Shiro入门6:自定义realm查询数据库进行认证
- AOP(1)
- 电源地与信号地关系的详细解析
- WebView详解一:打造优雅的WebView
- 01-多线程01
- [BZOJ1179][Apio2009]Atm(tarjan+spfa)
- shiro认证过程Authenticator到realm,然后进行认证的过程
- 欢迎使用CSDN-markdown编辑器
- 八大排序算法(四) 直接选择排序
- PCB设计时遇到这些问题要留意
- 微信小程序一览
- 为什么高手离不了Linux系统?这就是我的理由。
- 关于《C和指针》的学习笔记
- 南阳理工学院在线评测系统-兄弟郊游问题
- 启动图片