org.eclipse.emf.emfstore.internal.server.accesscontrol.authentication.verifiers
Class LDAPVerifier

java.lang.Object
  extended by org.eclipse.emf.emfstore.internal.server.accesscontrol.authentication.verifiers.AbstractAuthenticationControl
      extended by org.eclipse.emf.emfstore.internal.server.accesscontrol.authentication.verifiers.LDAPVerifier
All Implemented Interfaces:
AuthenticationControl

public class LDAPVerifier
extends AbstractAuthenticationControl

Verifies username/password using LDAP.

Author:
Wesendonk

Constructor Summary
LDAPVerifier(String ldapUrl, String ldapBase, String searchDn, String authUser, String authPassword)
          Default constructor.
 
Method Summary
 boolean verifyPassword(ACUser resolvedUser, String username, String password)
          This method must be implemented by subclasses in order to verify a pair of username and password.
 
Methods inherited from class org.eclipse.emf.emfstore.internal.server.accesscontrol.authentication.verifiers.AbstractAuthenticationControl
logIn, logout
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LDAPVerifier

public LDAPVerifier(String ldapUrl,
                    String ldapBase,
                    String searchDn,
                    String authUser,
                    String authPassword)
Default constructor.

Parameters:
ldapUrl - url, if url starts with ldaps:// SSL is used.
ldapBase - base
searchDn - dn
authUser - user to allow access to server
authPassword - password of user to allow access to server
Method Detail

verifyPassword

public boolean verifyPassword(ACUser resolvedUser,
                              String username,
                              String password)
                       throws AccessControlException
This method must be implemented by subclasses in order to verify a pair of username and password. When using authentication you should use AuthenticationControl.logIn(ACUser, String, String, ClientVersionInfo) in order to gain a session id.

Parameters:
resolvedUser - the user instance that has been resolved by the user
username - the username as entered by the client; may differ from the user name of the resolvedUser
password - the password as entered by the client
Returns:
boolean true if authentication was successful, false if not
Throws:
AccessControlException - if an exception occurs during the verification process
See Also:
AbstractAuthenticationControl.verifyPassword(org.eclipse.emf.emfstore.internal.server.model.accesscontrol.ACUser, java.lang.String, java.lang.String)


Copyright © 2015. All Rights Reserved.