Commit 6013ebf1 authored by Matt Tucker's avatar Matt Tucker Committed by matt

Blank adminDN should be same as null.


git-svn-id: http://svn.igniterealtime.org/svn/repos/messenger/trunk@900 b35dd754-fafc-0310-a699-88a17e54d16e
parent 4015cb93
...@@ -28,6 +28,7 @@ import javax.naming.directory.*; ...@@ -28,6 +28,7 @@ import javax.naming.directory.*;
* <li>ldap.host</li> * <li>ldap.host</li>
* <li>ldap.port</li> * <li>ldap.port</li>
* <li>ldap.baseDN</li> * <li>ldap.baseDN</li>
* <li>ldap.alternateBaseDN</li>
* <li>ldap.adminDN</li> * <li>ldap.adminDN</li>
* <li>ldap.adminPassword</li> * <li>ldap.adminPassword</li>
* <li>ldap.usernameField -- default value is "uid".</li> * <li>ldap.usernameField -- default value is "uid".</li>
...@@ -51,7 +52,7 @@ public class LdapManager { ...@@ -51,7 +52,7 @@ public class LdapManager {
private String emailField = "mail"; private String emailField = "mail";
private String baseDN = ""; private String baseDN = "";
private String alternateBaseDN = null; private String alternateBaseDN = null;
private String adminDN; private String adminDN = null;
private String adminPassword; private String adminPassword;
private boolean ldapDebugEnabled = false; private boolean ldapDebugEnabled = false;
private boolean sslEnabled = false; private boolean sslEnabled = false;
...@@ -103,6 +104,9 @@ public class LdapManager { ...@@ -103,6 +104,9 @@ public class LdapManager {
JiveGlobals.getXMLProperty("ldap.connectionPoolEnabled")).booleanValue(); JiveGlobals.getXMLProperty("ldap.connectionPoolEnabled")).booleanValue();
} }
this.adminDN = JiveGlobals.getXMLProperty("ldap.adminDN"); this.adminDN = JiveGlobals.getXMLProperty("ldap.adminDN");
if (adminDN != null && adminDN.trim().equals("")) {
adminDN = null;
}
this.adminPassword = JiveGlobals.getXMLProperty("ldap.adminPassword"); this.adminPassword = JiveGlobals.getXMLProperty("ldap.adminPassword");
this.ldapDebugEnabled = Boolean.valueOf(JiveGlobals.getXMLProperty( this.ldapDebugEnabled = Boolean.valueOf(JiveGlobals.getXMLProperty(
"ldap.ldapDebugEnabled")).booleanValue(); "ldap.ldapDebugEnabled")).booleanValue();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment