Пример #1
0
 @Override
 protected void configure(AuthenticationManagerBuilder auth) throws Exception {
   auth.ldapAuthentication()
       .userDnPatterns("uid={0},ou=people")
       .groupSearchBase("ou=groups")
       .contextSource()
       .ldif("classpath:test-server.ldif");
 }
Пример #2
0
 @SuppressWarnings("unused")
 private void configureTestLdap(AuthenticationManagerBuilder auth) throws Exception {
   // @formatter:off
   auth.ldapAuthentication()
       .userDnPatterns("uid={0},ou=people")
       .groupSearchBase("ou=groups")
       .contextSource()
       .ldif("classpath:test-server.ldif");
   // @formatter:on
 }