current = new ServletSecurityConstraintHandler(securityPathMatches, current);
}
if (loginConfig != null) {
List<AuthenticationMechanism> authenticationMechanisms = new LinkedList<AuthenticationMechanism>();
authenticationMechanisms.add(new CachedAuthenticatedSessionMechanism());
String requestedMechanism = loginConfig.getAuthMethod();
if (requestedMechanism.equalsIgnoreCase(BASIC_AUTH)) {
// The mechanism name is passed in from the HttpServletRequest interface as the name reported needs to be comparable using '=='
authenticationMechanisms.add(new BasicAuthenticationMechanism(loginConfig.getRealmName(), BASIC_AUTH));