Gustavo, Example of configuring LdapPasswordAuthenticationDao (the older code) would be: LdapPasswordAuthenticationDao dao = new LdapPasswordAuthenticationDao(); dao.setURL("ldap://localhost:389/ou=system"); dao.setUserContext("uid={0},ou=users,ou=system"); dao.setDefaultRole(DEFAULT_ROLE); For more information the Javadoc LdapPasswordAuthenticationDao contains some decent examples. I am currently working on LdapPassword2AuthenticationDao; however it is NOT yet ready for use - it's is missing a couple of features needed to make it work properly. For the curious example code (not freak out, when setup using Spring it will be relatively short) would be: UserSearchBean searchBean = new UserSearchBean(); searchBean.setSubContext("ou=Users"); searchBean.setSearchSubtree(false); searchBean.setUsernameFilter("uid={0}"); searchBean.afterPropertiesSet(); LdapSupport ldapSupport = new LdapSupport(); ldapSupport.setRootContext("dc=mycompany,dc=com"); ldapSupport.setURL("ldap://ldap.mycompnay.com:389/"); LdapPassword2AuthenticationDao dao = new LdapPassword2AuthenticationDao(); dao.setUserSearchBean( searchBean ); dao.setLdapSupport( ldapSupport ); dao.setDefaultRole("user"); Good luck. Gustavo Faerman wrote: Robert and Joseph, -- Robert r. Sanders Chief Technologist iPOV (334) 821-5412 www.ipov.net |
- [Acegisecurity-developer] Re: ldap & LdapPasswordAut... Gustavo Faerman
- Re: [Acegisecurity-developer] Re: ldap & LdapPa... Robert r. Sanders
- [Acegisecurity-developer] Re: ldap & LdapPasswo... Gustavo Faerman
- Re: [Acegisecurity-developer] Re: ldap & Ld... Robert r. Sanders
- Re: [Acegisecurity-developer] Re: ldap &... Gustavo Faerman