|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.olat.ldap.LDAPLoginManager
org.olat.ldap.LDAPLoginManagerImpl
public class LDAPLoginManagerImpl
Description: This manager handles communication between LDAP and OLAT. LDAP access is done by JNDI.
LDAPLoginMangerImpl
| Method Summary | |
|---|---|
boolean |
acquireSyncLock()
Acquire lock for administration jobs |
javax.naming.directory.InitialDirContext |
bindSystem()
Connect to the LDAP server with System DN and Password Configuration: LDAP URL = olatextconfig.xml (property=ldapURL) System DN = olatextconfig.xml (property=ldapSystemDN) System PW = olatextconfig.xml (property=ldapSystemPW) |
javax.naming.directory.Attributes |
bindUser(java.lang.String uid,
java.lang.String pwd,
LDAPError errors)
Connect to LDAP with the User-Name and Password given as parameters Configuration: LDAP URL = olatextconfig.xml (property=ldapURL) LDAP Base = olatextconfig.xml (property=ldapBase) LDAP Attributes Map = olatextconfig.xml (property=userAttrs) |
void |
changePassword(Identity identity,
java.lang.String pwd,
LDAPError errors)
Change the password on the LDAP server. |
void |
createAndPersistUser(javax.naming.directory.Attributes userAttributes)
Creates User in OLAT and ads user to LDAP securityGroup Required Attributes have to be checked before this method. |
void |
deletIdentities(java.util.List<Identity> identityList)
Delete all Identities in List and removes them from LDAPSecurityGroup |
boolean |
doBatchSync(LDAPError errors)
Execute Batch Sync. |
Identity |
findIdentyByLdapAuthentication(java.lang.String uid,
LDAPError errors)
Searches for Identity in OLAT. |
void |
freeSyncLock()
Release lock for administration jobs |
java.util.List<Identity> |
getIdentitysDeletedInLdap(javax.naming.directory.InitialDirContext ctx)
Creates list of all OLAT Users which have been deleted out of the LDAP directory but still exits in OLAT Configuration: Required Attributes = olatextconfig.xml (property=reqAttrs) LDAP Base = olatextconfig.xml (property=ldapBase) |
java.util.Date |
getLastSyncDate()
|
java.util.List<javax.naming.directory.Attributes> |
getUserAttributesModifiedSince(java.util.Date syncTime,
javax.naming.directory.InitialDirContext ctx)
Creates list of all LDAP Users or changed Users since syncTime Configuration: userAttr = olatextconfig.xml (property=userAttrs) LDAP Base = olatextconfig.xml (property=ldapBase) |
java.util.Map<java.lang.String,java.lang.String> |
prepareUserPropertyForSync(javax.naming.directory.Attributes attributes,
Identity identity)
Checks if LDAP properties are different then OLAT properties of a User. |
void |
syncUser(java.util.Map<java.lang.String,java.lang.String> olatPropertyMap,
Identity identity)
Sync all OLATPropertys in Map of Identity |
| Methods inherited from class org.olat.ldap.LDAPLoginManager |
|---|
getInstance |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method Detail |
|---|
public javax.naming.directory.InitialDirContext bindSystem()
bindSystem in class LDAPLoginManagerjavax.naming.NamingException
public javax.naming.directory.Attributes bindUser(java.lang.String uid,
java.lang.String pwd,
LDAPError errors)
bindUser in class LDAPLoginManageruid - The users LDAP login name (can't be null)pwd - The users LDAP password (can't be null)
javax.naming.NamingException
public void changePassword(Identity identity,
java.lang.String pwd,
LDAPError errors)
changePassword in class LDAPLoginManagerLDAPLoginManager.changePassword(org.olat.core.id.Identity, java.lang.String, org.olat.ldap.LDAPError)
public java.util.List<javax.naming.directory.Attributes> getUserAttributesModifiedSince(java.util.Date syncTime,
javax.naming.directory.InitialDirContext ctx)
getUserAttributesModifiedSince in class LDAPLoginManagersyncTime - The time to search in LDAP for changes since this time.
SyncTime has to formatted: JJJJMMddHHmmctx - The LDAP system connection, if NULL or closed NamingExecpiton is
thrown
javax.naming.NamingExceptionpublic void deletIdentities(java.util.List<Identity> identityList)
deletIdentities in class LDAPLoginManageridentityList - List of Identities to delete
public void syncUser(java.util.Map<java.lang.String,java.lang.String> olatPropertyMap,
Identity identity)
syncUser in class LDAPLoginManagerolatPropertyMap - Map of changed OLAT properties
(OLATProperty,LDAPValue)identity - Identity to syncpublic void createAndPersistUser(javax.naming.directory.Attributes userAttributes)
createAndPersistUser in class LDAPLoginManageruserAttributes - Set of LDAP Attribute of User to be created
public java.util.Map<java.lang.String,java.lang.String> prepareUserPropertyForSync(javax.naming.directory.Attributes attributes,
Identity identity)
prepareUserPropertyForSync in class LDAPLoginManagerattributes - Set of LDAP Attribute of Identityidentity - Identity to compare
public Identity findIdentyByLdapAuthentication(java.lang.String uid,
LDAPError errors)
findIdentyByLdapAuthentication in class LDAPLoginManageruid - Name of Identityerrors - LDAPError Object if user exits but not member of
LDAPSecurityGroup
public java.util.List<Identity> getIdentitysDeletedInLdap(javax.naming.directory.InitialDirContext ctx)
getIdentitysDeletedInLdap in class LDAPLoginManagersyncTime - The time to search in LDAP for changes since this time.
SyncTime has to formatted: JJJJMMddHHmmctx - The LDAP system connection, if NULL or closed NamingExecpiton is
thrown
javax.naming.NamingExceptionpublic boolean doBatchSync(LDAPError errors)
doBatchSync in class LDAPLoginManagerLDAPError - public java.util.Date getLastSyncDate()
getLastSyncDate in class LDAPLoginManagerLDAPLoginManager.getLastSyncDate()public boolean acquireSyncLock()
acquireSyncLock in class LDAPLoginManagerpublic void freeSyncLock()
freeSyncLock in class LDAPLoginManager
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||