php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #27605 case sensitivity of attributes differs in ldap_search and ldap_add/modify
Submitted: 2004-03-15 09:42 UTC Modified: 2004-03-16 03:09 UTC
From: t dot hirsch at web dot de Assigned:
Status: Not a bug Package: LDAP related
PHP Version: 4.3.4 OS: Solaris 9
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: t dot hirsch at web dot de
New email:
PHP Version: OS:

 

 [2004-03-15 09:42 UTC] t dot hirsch at web dot de
Description:
------------
In my ldap tree are some attributes with upper case letters.
ldap_search finds them only when writing them in lower case. But ldap_add and ldap_modify need the attributes in the right case or they report an error.

Reproduce code:
---------------
// $info=ldap_get_entries...
// $i is the counter of the entry
// $j is the counter of the attribute
// in this case: attribute[$j]="lowerUpper";
// lowerUpper is a single-value attribute
$works=$info[$i][strtolower($attribute[$j])][0];
$fails=$info[$i][$attribute[$j]][0];

Expected result:
----------------
$fails should work, 
$work should fail if case sensitivity is on, or should still work

Actual result:
--------------
$works="thecontent"
$fails=""

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-03-15 09:48 UTC] sniper@php.net
PHP has no control over this, it's the underlying ldap library that handles this all. (openldap or whatever you compiled PHP with)

 [2004-03-15 09:50 UTC] t dot hirsch at web dot de
Looks like it's a bit different than I just reported. But now I see the whole problem clearer:

-ldap_get_entries returns the attributes in lower case
-ldap_get_attributes returns the attributes in the right case

I used ldap_get_entries on my search-page and ldap_get_attributes on my page for modifying one entry, that's why I messed up the things before.

However, I think this is still a bug, isn't it?
 [2004-03-15 11:01 UTC] sniper@php.net
Please do not submit the same bug more than once. An existing
bug report already describes this very problem. Even if you feel
that your issue is somewhat different, the resolution is likely
to be the same. 

Thank you for your interest in PHP.

see bug #19438
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri May 03 17:01:32 2024 UTC