[exo-jcr-commits] exo-jcr SVN: r4354 - in core/branches/2.3.x: patch/2.3.9/COR-236 and 1 other directory.
do-not-reply at jboss.org
do-not-reply at jboss.org
Tue May 10 05:21:30 EDT 2011
Author: paristote
Date: 2011-05-10 05:21:30 -0400 (Tue, 10 May 2011)
New Revision: 4354
Added:
core/branches/2.3.x/patch/2.3.9/COR-236/readme.txt
Modified:
core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/ADUserDAOImpl.java
core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/LDAPAttributeMapping.java
Log:
COR-236
What is the problem to fix?
Using Oracle Virtual Directory + MS SQL Server, there are problems with upper-case LDAP prefix "OU".
Queries must be lower-cased to avoid such problems.
How is the problem fixed?
Replace uppercased "OU" and "CN" by lower cased on "ou" and "cn" respectively.
Modified: core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/ADUserDAOImpl.java
===================================================================
--- core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/ADUserDAOImpl.java 2011-05-10 09:16:39 UTC (rev 4353)
+++ core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/ADUserDAOImpl.java 2011-05-10 09:21:30 UTC (rev 4354)
@@ -75,7 +75,7 @@
@Override
public void createUser(User user, boolean broadcast) throws Exception
{
- String userDN = "CN=" + user.getUserName() + "," + ldapAttrMapping.userURL;
+ String userDN = ldapAttrMapping.userDNKey + "=" + user.getUserName() + "," + ldapAttrMapping.userURL;
Attributes attrs = ldapAttrMapping.userToAttributes(user);
attrs.put("userAccountControl", Integer.toString(UF_NORMAL_ACCOUNT + UF_PASSWD_NOTREQD + UF_PASSWORD_EXPIRED
+ UF_ACCOUNTDISABLE));
Modified: core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/LDAPAttributeMapping.java
===================================================================
--- core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/LDAPAttributeMapping.java 2011-05-10 09:16:39 UTC (rev 4353)
+++ core/branches/2.3.x/exo.core.component.organization.ldap/src/main/java/org/exoplatform/services/organization/ldap/LDAPAttributeMapping.java 2011-05-10 09:21:30 UTC (rev 4354)
@@ -67,14 +67,12 @@
// TODO remove initialization in major release. It may be not initialized from
// for AD.
- String userDNKey = "CN";
+ String userDNKey = "cn";
//TODO remove initialization in major release. Should be initialized from
// configuration.
- String groupDNKey = "OU";
+ String groupDNKey = "ou";
- //
-
String userUsernameAttr;
String userPassword;
Added: core/branches/2.3.x/patch/2.3.9/COR-236/readme.txt
===================================================================
--- core/branches/2.3.x/patch/2.3.9/COR-236/readme.txt (rev 0)
+++ core/branches/2.3.x/patch/2.3.9/COR-236/readme.txt 2011-05-10 09:21:30 UTC (rev 4354)
@@ -0,0 +1,78 @@
+Summary
+
+ Status: Case sensitivity Problem with Oracle Virtual Directory and SQL Server
+ CCP Issue: CCP-910, Product Jira Issue: COR-236. Backport of COR-233.
+ Complexity: Low
+
+The Proposal
+Problem description
+
+What is the problem to fix?
+Using Oracle Virtual Directory + MS SQL Server, there are problems with upper-case LDAP prefix "OU".
+Queries must be lower-cased to avoid such problems.
+Fix description
+
+How is the problem fixed?
+
+ Replace uppercased "OU" and "CN" by lower cased on "ou" and "cn" respectively.
+
+Patch information:
+Patch files: COR-236.patch
+
+Tests to perform
+
+Reproduction test
+
+ Reproduction can be only performed manually with Oracle Virtual Directory + MS SQL Server
+
+Tests performed at DevLevel
+
+ Tomcat AS + LDAP Organization service + AD
+
+Tests performed at QA/Support Level
+*
+
+Documentation changes
+
+Documentation changes:
+ No
+
+Configuration changes
+
+Configuration changes:
+
+ By default, group and user DN keys are in lower case, but it is possible to configure via initialization params if needed:
+
+ <value-param>
+ <name>ldap.userDN.key</name>
+ <description>The key used to compose user DN</description>^
+ <value>cn</value>
+ </value-param>
+ <value-param>
+ <name>ldap.groupDN.key</name>
+ <description>The key used to compose group DN</description>^
+ <value>ou</value>
+ </value-param>
+
+Will previous configuration continue to work?
+ Yes
+
+Risks and impacts
+
+Can this bug fix have any side effects on current client projects?
+ No
+
+Is there a performance risk/cost?
+ No
+
+Validation (PM/Support/QA)
+
+PM Comment
+* Approved
+
+Support Comment
+* Validated
+
+QA Feedbacks
+*
+
More information about the exo-jcr-commits
mailing list