Logon logon;
if(!SystemConfiguration.getInstance().getBooleanValue(SystemConfiguration.Key.LDAP_AUTHENTICATION_ENABLED)){
if(log.isDebugEnabled())
log.debug("do local login");
logon = new LocalLogon();
} else {
if(log.isDebugEnabled())
log.debug("do ldap login");
logon = new LdapLogon();
}