Package org.springframework.ldap.support

Examples of org.springframework.ldap.support.DirContextAdapter


    String ldapPassword = null;
    try {
      ldapPassword = (String) ldapTemplate.lookup(dn, new String[] { "userPassword" },
          new ContextMapper() {
            public Object mapFromContext(Object ctx) {
              DirContextAdapter context = (DirContextAdapter) ctx;
              return new String((byte[]) context.getObjectAttribute("userPassword"));
            }
          });
    } catch (EntryNotFoundException e) {
      logger.info("cannot found {} in ldap", userName);
      throw new AuthenticationException("ldap user " + userName + " not found");
View Full Code Here


    String ldapPassword = null;
    try {
      ldapPassword = (String) ldapTemplate.lookup(dn, new String[] { "userPassword" },
          new ContextMapper() {
            public Object mapFromContext(Object ctx) {
              DirContextAdapter context = (DirContextAdapter) ctx;
              return new String((byte[]) context.getObjectAttribute("userPassword"));
            }
          });
    } catch (EntryNotFoundException e) {
      logger.info("cannot found {} in ldap", username);
      throw new AuthenticationException("ldap user " + username + " not found");
View Full Code Here

TOP

Related Classes of org.springframework.ldap.support.DirContextAdapter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.