Class LDAPLoginModule
- java.lang.Object
-
- org.apache.activemq.artemis.spi.core.security.jaas.LDAPLoginModule
-
- All Implemented Interfaces:
LoginModule,AuditLoginModule
public class LDAPLoginModule extends Object implements AuditLoginModule
-
-
Field Summary
Fields Modifier and Type Field Description protected DirContextcontext
-
Constructor Summary
Constructors Constructor Description LDAPLoginModule()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanabort()protected voidaddRoles(DirContext context, String dn, String username, List<String> currentRoles)protected booleanauthenticate(String username, String password)protected booleanbindUser(DirContext context, String dn, String password)protected voidcloseContext()booleancommit()protected StringdoRFC2254Encoding(String inputString)protected voidextendInitialEnvironment(Set<LDAPLoginProperty> moduleConfig, Hashtable<String,String> initialContextEnv)voidinitialize(Subject subject, CallbackHandler callbackHandler, Map<String,?> sharedState, Map<String,?> options)booleanlogin()booleanlogout()protected voidopenContext()-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.activemq.artemis.spi.core.security.jaas.AuditLoginModule
registerFailureForAudit
-
-
-
-
Field Detail
-
context
protected DirContext context
-
-
Method Detail
-
initialize
public void initialize(Subject subject, CallbackHandler callbackHandler, Map<String,?> sharedState, Map<String,?> options)
- Specified by:
initializein interfaceLoginModule
-
login
public boolean login() throws LoginException- Specified by:
loginin interfaceLoginModule- Throws:
LoginException
-
logout
public boolean logout() throws LoginException- Specified by:
logoutin interfaceLoginModule- Throws:
LoginException
-
commit
public boolean commit() throws LoginException- Specified by:
commitin interfaceLoginModule- Throws:
LoginException
-
abort
public boolean abort() throws LoginException- Specified by:
abortin interfaceLoginModule- Throws:
LoginException
-
closeContext
protected void closeContext()
-
authenticate
protected boolean authenticate(String username, String password) throws LoginException
- Throws:
LoginException
-
addRoles
protected void addRoles(DirContext context, String dn, String username, List<String> currentRoles) throws NamingException
- Throws:
NamingException
-
bindUser
protected boolean bindUser(DirContext context, String dn, String password) throws NamingException
- Throws:
NamingException
-
extendInitialEnvironment
protected void extendInitialEnvironment(Set<LDAPLoginProperty> moduleConfig, Hashtable<String,String> initialContextEnv)
-
-