title: Java LDAP with SASL
body: <p>I am using Java 1.2 with the Netscape ldapjdk.jar and trying to make an LDAP connection to one of our servers that needs SASL.  I’m also relativity new to LDAP.  I do know that java EE has built in LDAP but I am not able to use it at this time.</p>
  
  <p>I have been able to make a connection to another server using regular LDAP but I am not sure what I need to put into the parameters.  If someone has a simple example that would be helpful.</p>
  
  <p>I think the class below is what I need to use:</p>
  
  <pre><code>String ldapUserDn = "cn=mycomputer,dc=Dcname";      
  String[]  mechanisms = {"DIGEST-MD5"};
  LDAPSaslBind saslBind = new LDAPSaslBind(
     String ldapUserDn, 
     mechanisms, 
     String packageName, 
     Hashtable props, 
     Object cbh);
  </code></pre>