Bug 1066470
Summary: | (6.3.0) LdapExtended login module: LDAP referrals not working despite earlier fix | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | [JBoss] JBoss Enterprise Application Platform 6 | Reporter: | Tom Fonteyne <tfonteyn> | ||||||||||
Component: | Security | Assignee: | Peter Skopek <pskopek> | ||||||||||
Status: | CLOSED CURRENTRELEASE | QA Contact: | Josef Cacek <jcacek> | ||||||||||
Severity: | urgent | Docs Contact: | Russell Dickenson <rdickens> | ||||||||||
Priority: | urgent | ||||||||||||
Version: | 6.2.1 | CC: | asaldhan, bbaranow, darran.lofthouse, hmlnarik, kkhan, myarboro, pskopek, tiwillia | ||||||||||
Target Milestone: | ER6 | ||||||||||||
Target Release: | EAP 6.3.0 | ||||||||||||
Hardware: | Unspecified | ||||||||||||
OS: | Unspecified | ||||||||||||
Whiteboard: | |||||||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||||||
Doc Text: | Story Points: | --- | |||||||||||
Clone Of: | |||||||||||||
: | 1104976 (view as bug list) | Environment: | |||||||||||
Last Closed: | 2014-06-28 15:27:22 UTC | Type: | Bug | ||||||||||
Regression: | --- | Mount Type: | --- | ||||||||||
Documentation: | --- | CRM: | |||||||||||
Verified Versions: | Category: | --- | |||||||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||||||
Embargoed: | |||||||||||||
Bug Depends On: | |||||||||||||
Bug Blocks: | 1097859, 1101272, 1104976 | ||||||||||||
Attachments: |
|
Description
Tom Fonteyne
2014-02-18 13:43:04 UTC
Created attachment 864564 [details]
test war file
formlogin-LdapRealm.war used "/fl" as context
Created attachment 864565 [details]
standalone test program
standalone test app usage:
java -jar ldaptest.jar
-> prints usage
java -jar ldaptest.jar -u ldap://zen.usersys.redhat.com -b dc=example,dc=com -f uid=tomds3 -rf -p tomds3
-rf: follow referrals
-p : the password for the user as specified in the -f filter
Expected output:
Connected to: ldap://zen.usersys.redhat.com
---------------------------------------------
dn was: absolute
dn : uid=tomds3, ou=People, dc=example,dc=com
name : ldap://zen.usersys.redhat.com:391/uid=tomds3,%20ou=People,%20dc=example,dc=com
NameInNamespace: uid=tomds3, ou=People, dc=example,dc=com
------------attributes-----------------------
l=FAB
mail=tomf
uid=tomds3
ou=People
givenName=Tom
objectClass=top
objectClass=person
objectClass=organizationalPerson
objectClass=inetOrgPerson
sn=on ds3
cn=tomds3
---------------------------------------------
Following referral to: ldap://zen.usersys.redhat.com:391
Binding with principal: uid=tomds3, ou=People, dc=example,dc=com
Connected to: ldap://zen.usersys.redhat.com:391
authentication successful
Created attachment 864566 [details]
standalone test program main code
Created attachment 864567 [details]
standalone test program util class for certificates
see also bz-1066488 I have the fix on my workspace. Currently working on backport and release of related components PicketBox and JBoss Negotiation. PR for PicketBox part: https://github.com/jbossas/jboss-eap/pull/1366 as per above, re-opening The problem in C#17 is setup issue. rolesCtxDN is set to ou=Groups,dc=example,dc=com which causes that referral object exiting in context dc=example,dc=com is not examined by the query and therefore not followed nor throwing exception for further handling. The setup is also missing option: <module-option name="referralUserAttributeIDToCheck" value="uniqueMember"/> My working setup is: <security-domain name="LdapRealm" cache-type="default"> <authentication> <login-module code="LdapExtended" flag="required"> <module-option name="java.naming.provider.url" value="ldap://zen.usersys.redhat.com:389/"/> <module-option name="java.naming.factory.initial" value="com.sun.jndi.ldap.LdapCtxFactory"/> <module-option name="java.naming.security.authentication" value="simple"/> <module-option name="bindDN" value="cn=Directory Manager"/> <module-option name="bindCredential" value="**"/> <module-option name="baseCtxDN" value="dc=example,dc=com"/> <module-option name="baseFilter" value="(uid={0})"/> <module-option name="rolesCtxDN" value="dc=example,dc=com"/> <!-- module-option name="rolesCtxDN" value="ou=Groups,dc=example,dc=com"/ --> <module-option name="roleFilter" value="(uniqueMember={1})"/> <module-option name="roleAttributeID" value="cn"/> <module-option name="roleNameAttributeID" value="cn"/> <module-option name="roleRecursion" value="0"/> <module-option name="throwValidateError" value="true"/> <module-option name="java.naming.referral" value="follow"/> <module-option name="referralUserAttributeIDToCheck" value="uniqueMember"/> </login-module> </authentication> </security-domain> referralUserAttributeIDToCheck is not documented. I'll create a doc-bug Verified in 6.3.0.ER7 |