Tomcat and LDAPS
Can anyone tell me if Apache Tomcat will connect to a realm using LDAPS开发者_JAVA技巧 ?
Looking at: http://tomcat.apache.org/tomcat-5.5-doc/realm-howto.html
it doesn't mention anything about LDAPS.
Thanks Andy
Use the JDNDI Realm
JNDIRealm is an implementation of the Tomcat Realm interface that looks up users in an LDAP directory server accessed by a JNDI provider (typically, the standard LDAP provider that is available with the JNDI API classes). The realm supports a variety of approaches to using a directory for authentication.
http://dahbura.com/ldap/ldaprealm_howto.html
JNDIRealm does exactly that, as stated in the other answer, or you can also use a JAASRealm and provide your own LoginModule that does your LDAP lookups for you.
We have written own LDAP adapter to provide authentication over LDAP.
精彩评论