|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #44534 ldap_add() does not work
Submitted: 2008-03-25 19:12 UTC Modified: 2008-04-03 01:00 UTC
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:0 (0.0%)
Same OS:0 (0.0%)
From: thegner at trilliumit dot com Assigned: fb-req-jani (profile)
Status: No Feedback Package: LDAP related
PHP Version: 5.2.5 OS: ubuntu gutsy server
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please — but make sure to vote on the bug!
Your email address:
Solve the problem:
46 - 10 = ?
Subscribe to this entry?

 [2008-03-25 19:12 UTC] thegner at trilliumit dot com
when doing an ldap_add() with "Die" as a persons last name, the server returns unwilling to perform. If I change only the last name to "Die2" it operates as expected. In our environment the following user attributes are associated with the last name.


The ldap directory is Microsoft Active Directory on Windows Server 2003

Reproduce code:
$user_attributes['sAMAccountName'] = "tdie";
$user_attributes['mailNickname'] = "tdie";
$user_attributes['userPrincipalName'] = "";
$user_attributes['unicodePwd'] = "\"\000t\000d\000i\000e\000\"\000";
$user_attributes['givenName'] = "Test";
$user_attributes['sn'] = "Die";
$user_attributes['cn'] = "Die, Test";
$user_attributes['displayName'] = "Die, Test";
$user_attributes['objectClass'][0] = "top";
$user_attributes['objectClass'][1] = "person";
$user_attributes['objectClass'][2] = "organizationalPerson";
$user_attributes['objectClass'][3] = "user";
//$gc_con previously set to valid ldap_connect()
ldap_add($gc_con, "CN=Die\, Test,OU=Users,DC=Domain,DC=Com", $user_attributes);

Expected result:
We should expect the object to be added to the directory.

Actual result:
Error: Add: Server unwilling to perform...


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2008-03-25 19:15 UTC] thegner at trilliumit dot com

This Line: ldap_add($gc_con, "CN=Die\, Test,OU=Users,DC=Domain,DC=Com", $user_attributes);

should be: ldap_add($gc_con, "CN=Die\\, Test,OU=Users,DC=Domain,DC=Com",
 [2008-03-25 19:29 UTC]
If it crashes, you should be seeing something in the webserver's logs?
And if it really crashes, you should be able to provide a GDB backtrace.
 [2008-03-25 19:47 UTC] thegner at trilliumit dot com
Perhaps I am using the word "crash" too loosely. To me, if it doesn't do what I expect, then it's crashed :).

Sorry for the mixup.
 [2008-03-26 11:49 UTC]
So it doesn't crash. Then what the actual problem is? What error do you get? (EXACTLY!) Did you check the ldap server's logs for possible reason?
 [2008-04-03 01:00 UTC] php-bugs at lists dot php dot net
No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Jul 20 15:01:28 2024 UTC