Description of problem: Even if cached entry should be used, new search is executed. See steps to reproduce. Steps to Reproduce: 1 - configure security realm to use cache with eviction by size strategy <security-realm name="authn-by-search-time-3-1"> <authentication> <ldap connection="ldap-connection" base-dn="ou=People,dc=jboss,dc=org" recursive="true"> <cache eviction-time="30" max-cache-size="1" cache-failures="false"/> <username-filter attribute="uid"/> </ldap> </authentication> </security-realm> 2 - configure http interface to be secured by this realm <http-interface security-realm="authn-by-search-time-3-1"> <http-upgrade enabled="true"/> <socket-binding http="management-http"/> </http-interface> access http://localhost:9990/console with existing user e.g. "jduke" access http://localhost:9990/console with non existing user e.g. "test" In log there is message "Entry with key 'jduke' evicted from cache due to cache being above maximum size." When you access http://localhost:9990/console again with "jduke", then Wireshark shows that LDAP call occured. Actual results: Expected results: 'jduke' should be found in cache. Additional info: