[jboss-jira] [JBoss JIRA] Created: (JBPORTAL-2268) profile directly from ldap
Luca Stancapiano (JIRA)
jira-events at lists.jboss.org
Tue Dec 30 17:17:54 EST 2008
profile directly from ldap
--------------------------
Key: JBPORTAL-2268
URL: https://jira.jboss.org/jira/browse/JBPORTAL-2268
Project: JBoss Portal
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: Portal Identity
Affects Versions: 2.7.0 Final
Environment: openldap server, jboss as 4.2.3.GA, jbossportal 2.7.0
Reporter: Luca Stancapiano
Assignee: Luca Stancapiano
Fix For: 2.7.1 Final
configuring ldap_identity-config.xml file , I tried to use this ldap module configuration:
<module>
<type>UserProfile</type>
<implementation>LDAP</implementation>
</module>
instead of this default configuration:
<module>
<type>UserProfile</type>
<implementation>DELEGATING</implementation>
<config>
<option>
<name>ldapModuleJNDIName</name>
<value>java:/portal/LDAPUserProfileModule</value>
</option>
</config>
</module>
and I used in standardidentity-config.xml this module:
<module>
<type>UserProfile</type>
<implementation>LDAP</implementation>
<service-name>portal:service=Module,type=UserProfile</service-name>
<class>org.jboss.portal.identity.ldap.LDAPUserProfileModuleImpl</class>
<config>
<option>
<name>jNDIName</name>
<value>java:/portal/UserProfileModule</value>
</option>
<option>
<name>connectionJNDIName</name>
<value>java:/portal/LDAPConnectionContext</value>
</option>
<option>
<name>profileConfigFile</name>
<value>conf/identity/profile-config.xml</value>
</option>
</config>
</module>
instead of:
<module>
<!--type used to correctly map in IdentityContext registry-->
<type>UserProfile</type>
<implementation>DELEGATING</implementation>
<!--name of service and class for creating mbean-->
<service-name>portal:service=Module,type=UserProfile</service-name>
<class>org.jboss.portal.identity.DelegatingUserProfileModuleImpl</class>
<!--set of options that are set in instantiated object-->
<config>
<option>
<name>jNDIName</name>
<value>java:/portal/UserProfileModule</value>
</option>
<option>
<name>dbModuleJNDIName</name>
<value>java:/portal/DBUserProfileModule</value>
</option>
<option>
<name>profileConfigFile</name>
<value>conf/identity/profile-config.xml</value>
</option>
</config>
</module>
so I can to use directly ldap profiles without DB Delegation.
org.jboss.portal.identity.auth.IdentityLoginModule class seems to get a little bug on a point because it would a 'enabled' attribute returning as java.lang.Boolean. But you can to get only java.lang.String attributes from LDAP. So you have always a 'enabled' attribute to false and the user always is disabled when you log into the portal. To resolve this problem you could to modify this code in org.jboss.portal.identity.auth.IdentityLoginModule: 259 :
if (enabledS != null && (enabledS instanceof Boolean)) {
enabled = ((Boolean)enabledS).booleanValue();
}
in this manner:
if (enabledS != null) {
enabled = new Boolean(enabledS.toString());
}
what do you think about it?
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list