Hello!
I have tried to modify the samples tutorial 2.0.0 war file a bit to use the embedded ldap server instead of the default authentication-provider.
I did the following changes in the namespace xml after deploying the war file to my Tomcat:
One reason for my test of the embedded ldap server was that in the RC1 M2 release of Spring Security 2.0 it seemed like the embedded ldap server was part of the samples tutorial war, since it was just commented away in the namespace configuration xml.HTML Code:<ldap-server ldif="classpath:users.ldif" /> <ldap-authentication-provider /> <ldap-user-service user-search-filter="(uid={0}" group-search-filter="member={0}"/> <!-- <authentication-provider> <password-encoder hash="md5"/> <user-service> <user name="rod" password="a564de63c2d0da68cf47586ee05984d7" authorities="ROLE_SUPERVISOR, ROLE_USER, ROLE_TELLER" /> <user name="dianne" password="65d15fe9156f9c4bbffd98085992a44e" authorities="ROLE_USER,ROLE_TELLER" /> <user name="scott" password="2b58af6dddbd072ed27ffc86725d7d3a" authorities="ROLE_USER" /> <user name="peter" password="22b5c9accc6e1ba628cedc63a72d57f8" authorities="ROLE_USER" /> </user-service> </authentication-provider> -->
When changing the above configuration and restarting my Tomcat two problems occured:
- Additional jar files had to be put in to make embedded ldap work.
- Loading Authorities didnt work for the users located in the default users.ldif.
The first thing I solved by adding the following jar files (Im not specifying the versions just the missing jars):
- apache ds jars (multiple files)
- commons lang
- spring ldap
- shared ldap
- slf4j log4j
- slf4j api
- jdbm
- mina core
- mina filter ssl
- backport util concurrent
- antlr
- shared asn1
- shared asn1 codec
- avalon framework (not needed to make sample work?! but was included in the M2 release)
- logkit (not needed to make sample work?! but was included in the M2 release)
The other thing with the loading Authorites i havent solved, but I think it has to do with my other thread on this forum:
http://forum.springframework.org/showthread.php?t=52736
with kind regards
Anders


