|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.googlecode.fascinator.authentication.ldap.LdapAuthenticationHandler
public class LdapAuthenticationHandler
Very simple LDAP authentication Handler
| Constructor Summary | |
|---|---|
LdapAuthenticationHandler(String baseUrl,
String baseDn)
Creates an LDAP authenticator for the specified server and base DN, using the default identifier attribute "uid" |
|
LdapAuthenticationHandler(String baseUrl,
String baseDn,
String ldapRoleAttr,
String idAttr)
Creates an LDAP authenticator for the specified server, base DN and given identifier attribute |
|
LdapAuthenticationHandler(String baseUrl,
String baseDn,
String ldapRoleAttr,
String idAttr,
Map<String,List<String>> ldapRolesMap)
Creates an LDAP authenticator for the specified server, base DN and given identifier attribute |
|
LdapAuthenticationHandler(String baseUrl,
String baseDn,
String ldapRoleAttr,
String idAttr,
String filterPrefix,
String filterSuffix,
Map<String,List<String>> ldapRolesMap)
Creates an LDAP authenticator for the specified server, base DN and given identifier attribute |
|
| Method Summary | |
|---|---|
boolean |
authenticate(String username,
String password)
Tries to authenticate user by using default settings, otherwise searches for the DN of the user |
List<String> |
getAllAttrs(String username,
String attrName)
Tries to find the value(s) of the given attribute. |
String |
getAttr(String username,
String attrName)
Tries to find the value of the given attribute. |
List<String> |
getRoles(String username)
Get the list of roles that the user is a member of. |
boolean |
testIfInObjectClass(String username,
String testSubj)
Searches through the role attribute values and tries to match the given string. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public LdapAuthenticationHandler(String baseUrl,
String baseDn)
baseUrl - LDAP server URLbaseDn - LDAP base DN
public LdapAuthenticationHandler(String baseUrl,
String baseDn,
String ldapRoleAttr,
String idAttr)
baseUrl - LDAP server URLbaseDn - LDAP base DNldapRoleAttr - Name of the LDAP attribute that defines the roleidAttr - LDAP user identifier attribute
public LdapAuthenticationHandler(String baseUrl,
String baseDn,
String ldapRoleAttr,
String idAttr,
Map<String,List<String>> ldapRolesMap)
baseUrl - LDAP server URLbaseDn - LDAP base DNldapRoleAttr - Name of the LDAP attribute that defines the roleidAttr - LDAP user identifier attributeldapRolesMap - Maps relevant LDAP roles to Fascinator roles
public LdapAuthenticationHandler(String baseUrl,
String baseDn,
String ldapRoleAttr,
String idAttr,
String filterPrefix,
String filterSuffix,
Map<String,List<String>> ldapRolesMap)
baseUrl - LDAP server URLbaseDn - LDAP base DNldapRoleAttr - Name of the LDAP attribute that defines the roleidAttr - LDAP user identifier attributeldapRolesMap - Maps relevant LDAP roles to Fascinator roles| Method Detail |
|---|
public boolean authenticate(String username,
String password)
username - a usernamepassword - a password
true if authentication was successful,
false otherwise
public String getAttr(String username,
String attrName)
username - a usernameattrName - the name of the attribute to find
public List<String> getAllAttrs(String username,
String attrName)
username - a usernameattrName - the name of the attribute to find
public boolean testIfInObjectClass(String username,
String testSubj)
username - a usernametestSubj - the string to look for
true if string was found false
otherwisepublic List<String> getRoles(String username)
username - The username that identifies the user
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||