I am extending the ActiveDirectoryRealm and can authenticate and authorize
users fine. Their username is typically their initials, such as js for John
Smith. 

However, I'd like to retrieve more information about the user, such as their
email or phone number or whatever. I'm not able to find any documentation on
how to do this. Although I've managed to succeed in retrieving it by using a
static string in this manner:

ldapContextFactory.getSystemLdapContext().getAttributes("CN=John
Smith,CN=Users,DC=foo,DC=bar") 

But I do not have the name of the user and hence cannot do this dynamically.
What is the best way to search ldap?
Should I rather use JndiLdapRealm class?



--
View this message in context: 
http://shiro-user.582556.n2.nabble.com/Retrieve-attributes-from-LDAP-active-directory-tp7577728.html
Sent from the Shiro User mailing list archive at Nabble.com.

Reply via email to