AuthenticatingRealm.getAuthenticationInfo

This implementation functions as follows: <ol> <li>It attempts to acquire any cached {@link AuthenticationInfo} corresponding to the specified {@link AuthenticationToken} argument. If a cached value is found, it will be used for credentials matching, alleviating the need to perform any lookups with a data source.</li> <li>If there is no cached {@link AuthenticationInfo} found, delegate to the {@link #doGetAuthenticationInfo(hunt.shiro.authc.AuthenticationToken)} method to perform the actual lookup. If authentication caching is enabled and possible, any returned info object will be {@link #cacheAuthenticationInfoIfPossible(hunt.shiro.authc.AuthenticationToken, hunt.shiro.authc.AuthenticationInfo) cached} to be used in future authentication attempts.</li> <li>If an AuthenticationInfo instance is not found in the cache or by lookup, {@code null} is returned to indicate an account cannot be found.</li> <li>If an AuthenticationInfo instance is found (either cached or via lookup), ensure the submitted AuthenticationToken's credentials match the expected {@code AuthenticationInfo}'s credentials using the {@link #getCredentialsMatcher() credentialsMatcher}. This means that credentials are always verified for an authentication attempt.</li> </ol>

@param token the submitted account principal and credentials. @return the AuthenticationInfo corresponding to the given {@code token}, or {@code null} if no AuthenticationInfo could be found. @throws AuthenticationException if authentication failed.

class AuthenticatingRealm
final
getAuthenticationInfo

Meta