public class LDAPLoginManagerImpl extends LDAPLoginManager implements GenericEventListener
LDAPLoginMangerImpl
限定符和类型 | 类和说明 |
---|---|
static interface |
LDAPLoginManagerImpl.LdapVisitor |
ldapSyncLockOres
限定符和类型 | 方法和说明 |
---|---|
boolean |
acquireSyncLock()
Acquire lock for administration jobs
|
javax.naming.ldap.LdapContext |
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)
|
boolean |
canChangePassword(Identity identity) |
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.
|
void |
event(Event event) |
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.ldap.LdapContext 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.ldap.LdapContext ctx)
Creates list of all LDAP Users or changed Users since syncTime Configuration: userAttr = olatextconfig.xml (property=userAttrs) LDAP Base = olatextconfig.xml
(property=ldapBase)
|
boolean |
isControllerAndNotDisposed() |
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
|
public void event(Event event)
event
在接口中 GenericEventListener
public javax.naming.ldap.LdapContext bindSystem()
bindSystem
在类中 LDAPLoginManager
javax.naming.NamingException
public javax.naming.directory.Attributes bindUser(java.lang.String uid, java.lang.String pwd, LDAPError errors)
bindUser
在类中 LDAPLoginManager
uid
- 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
在类中 LDAPLoginManager
public java.util.List<javax.naming.directory.Attributes> getUserAttributesModifiedSince(java.util.Date syncTime, javax.naming.ldap.LdapContext ctx)
getUserAttributesModifiedSince
在类中 LDAPLoginManager
syncTime
- 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 thrownjavax.naming.NamingException
public void deletIdentities(java.util.List<Identity> identityList)
deletIdentities
在类中 LDAPLoginManager
identityList
- List of Identities to deletepublic void syncUser(java.util.Map<java.lang.String,java.lang.String> olatPropertyMap, Identity identity)
syncUser
在类中 LDAPLoginManager
olatPropertyMap
- Map of changed OLAT properties (OLATProperty,LDAPValue)identity
- Identity to syncpublic void createAndPersistUser(javax.naming.directory.Attributes userAttributes)
createAndPersistUser
在类中 LDAPLoginManager
userAttributes
- Set of LDAP Attribute of User to be createdpublic java.util.Map<java.lang.String,java.lang.String> prepareUserPropertyForSync(javax.naming.directory.Attributes attributes, Identity identity)
prepareUserPropertyForSync
在类中 LDAPLoginManager
attributes
- Set of LDAP Attribute of Identityidentity
- Identity to comparepublic Identity findIdentyByLdapAuthentication(java.lang.String uid, LDAPError errors)
findIdentyByLdapAuthentication
在类中 LDAPLoginManager
uid
- Name of Identityerrors
- LDAPError Object if user exits but not member of LDAPSecurityGrouppublic java.util.List<Identity> getIdentitysDeletedInLdap(javax.naming.ldap.LdapContext ctx)
getIdentitysDeletedInLdap
在类中 LDAPLoginManager
syncTime
- 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 thrownjavax.naming.NamingException
public boolean doBatchSync(LDAPError errors)
doBatchSync
在类中 LDAPLoginManager
LDAPError
- public java.util.Date getLastSyncDate()
getLastSyncDate
在类中 LDAPLoginManager
public boolean acquireSyncLock()
acquireSyncLock
在类中 LDAPLoginManager
public void freeSyncLock()
freeSyncLock
在类中 LDAPLoginManager
public boolean isControllerAndNotDisposed()
isControllerAndNotDisposed
在接口中 GenericEventListener
public boolean canChangePassword(Identity identity)
canChangePassword
在类中 LDAPLoginManager