如何在Apache Shiro中自定义身份验证逻辑?在Spring Security中,我在AuthenticationManager中的“authenticate()”方法中编写了自定义逻辑:
public Authentication authenticate(Authentication auth) { ... }
有没有办法在Apache Shiro中做同样的事情?
答案 0 :(得分:1)
以下是Shiro的authentication sequence和customizable realm authentication的概述。
根据您想要做的事情,您自己实施的CredentialsMatcher
可能是您正在寻找的钩子?您需要自定义哪些部分的详细答案取决于您的实际身份验证方案。