#015240: Final LDAP bind uses wrong DN (patch)

Description:

The DN which is used in the final bind with password, is constructed by adding the user id to the base DN, like this:


uid=johndoe,dc=example,dc=com

This does not take into account that users can be placed in different subtrees:

uid=johndoe,ou=Editors,ou=Users,dc=example,dc=com
uid=foo,ou=Guests,ou=Users,dc=example,dc=com
uid=bar,ou=Superusers,dc=example,dc=com

The patch fixes this by fetching the DN for the user, and then using that in the final bind.


- Attachments
ldap_filter.php.diff (1.3 kb)
[Download] [Permanent Link]
ldap_test.php.diff (1.4 kb)
[Download] [Permanent Link]
Test for the provided patch
setup_accounts.php.diff (3 kb)
[Download] [Permanent Link]
Changes to setup_accounts.php that are also needed

- Comments

I have added a test for the issue. It's very simple, I just copied testLdapFetchExtraDataSubdirectory() and removed the part were it was working around the issue, i.e. where it changes 'self::$base;' in order to login with a user who is not placed in the base directory.

I have also added some changes to setup_accounts, to make it possible to insert johnny.doe with displayName, without changing the other inserted users. I also made sure $host is actually used :)

#262454 by Gunnstein Lye on August 5th, 2009 [Permanent Link]

Fixed (by GL) in rev. 10734

#262462 by Derick Rethans on August 5th, 2009 [Permanent Link]

- History
Properties
Type Bug
Priority Medium
Component Components » Authentication
Affects 1.3 - Authentication 1.3
2009.1.1 - eZ components 2009.1.1
Fix Versions 2009.2 sprint 2 - eZ components 2009.2 sprint 2
2009.2alpha1 - eZ components 2009.2alpha1
Reporter Gunnstein Lye
Responsible Derick Rethans
Status 0 Closed
Resolution Fixed
Created August 3rd, 2009
Updated August 5th, 2009
Resolved August 5th, 2009
 
Navigation [Permanent Link]
Previous Issue
Back to Issues List
Next Issue: #015537
  Graph shows to small and truncated rotated axis labels