private Cache<Object, AuthenticationInfo> getAuthenticationCacheLazy() {

        if (this.authenticationCache == null) {

            LOGGER.trace("No authenticationCache instance set.  Checking for a cacheManager...");

            CacheManager cacheManager = getCacheManager();

            if (cacheManager != null) {
                String cacheName = getAuthenticationCacheName();
                LOGGER.debug("CacheManager [{}] configured.  Building authentication cache '{}'", cacheManager, cacheName);
                this.authenticationCache = cacheManager.getCache(cacheName);
            }
        }

        return this.authenticationCache;
    }
Checks to see if the authenticationCache class attribute is null, and if so, attempts to acquire one from
any configured {@link #getCacheManager() cacheManager}.  If one is acquired, it is set as the class attribute.
The class attribute is then returned.

@return an available cache instance to be used for authentication caching or {@code null} if one is not available.
@since 1.2
core/src/main/java/org/apache/shiro/realm/AuthenticatingRealm.java