Author: nhosoi
Update of /cvs/dirsec/console/src/com/netscape/management/client/console
In directory
cvs1.fedora.phx.redhat.com:/tmp/cvs-serv29557/src/com/netscape/management/client/console
Modified Files:
Console.java
Log Message:
Resolves: 560827 - Admin Server: DistinguishName validation fails
Description: userPreferenceDN included a nested DN surrounded by unescaped
double quotes. Instead of escaping the double quotes, introduced a method
escapeDnString in LDPAUtil which escapes special characters in the nested DN.
Index: Console.java
===================================================================
RCS file: /cvs/dirsec/console/src/com/netscape/management/client/console/Console.java,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -r1.15 -r1.16
--- Console.java 29 Jan 2009 21:23:59 -0000 1.15
+++ Console.java 12 Feb 2010 16:53:00 -0000 1.16
@@ -937,12 +937,15 @@
// this *should* already be created at install time, but just in case
// note: if this entry is created here, then ACIs (for non-admins) will
break
+ String authDN = _info.getAuthenticationDN();
+ String escapedAuthDN = LDAPUtil.escapeDnString(authDN);
+ Debug.println("Console.initialize: authDN: "+authDN+
+ ", escaped: "+escapedAuthDN);
String userPreferenceDN = LDAPUtil.createEntry(ldc,
LDAPUtil.getUserPreferenceOU(),
LDAPUtil.getInstalledSoftwareDN());
userPreferenceDN = LDAPUtil.createEntry(ldc,
- "\""+_info.getAuthenticationDN() +
"\"",
- userPreferenceDN, true);
+ escapedAuthDN, userPreferenceDN, true);
_info.setUserPreferenceDN(userPreferenceDN);
}
// Always enable context help.