1
package com.eucalyptus.auth.ldap.authentication;
3
import com.eucalyptus.auth.LdapException;
4
import com.eucalyptus.auth.ldap.LdapIntegrationConfiguration;
5
import com.eucalyptus.auth.ldap.LicParser;
7
public class LdapAuthenticatorFactory {
9
public static LdapAuthenticator getLdapAuthenticator( String authMethod ) throws LdapException {
10
if ( authMethod == null ) {
11
throw new LdapException( "Can not find LDAP authenticator for empty authentication method" );
13
if ( LicParser.LDAP_AUTH_METHOD_SASL_GSSAPI.equals( authMethod ) ) {
14
return new GssapiKrb5Authenticator( );
16
return new DefaultAuthenticator( );