php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #44238 Using LDAP causes script crash
Submitted: 2008-02-24 22:55 UTC Modified: 2008-03-04 01:00 UTC
Votes:1
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:0 (0.0%)
From: BenBE at omorphia dot de Assigned:
Status: No Feedback Package: LDAP related
PHP Version: 5.2.5 OS: Debian Etch
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: BenBE at omorphia dot de
New email:
PHP Version: OS:

 

 [2008-02-24 22:55 UTC] BenBE at omorphia dot de
Description:
------------
When updating PHP5 to the latest version (5.2.5-2 or newer), using the LDAP extension produces a crash, causing the script to abort.

Version 5.2.4-2 was latest version, that didn't crash that way. Also tried with 5.2.5-2, but same problem.

Reproduce code:
---------------
function get_ldap_name($unix)
{
	$ds = ldap_connect("ldap.example.com");
	$ldap_arr = get_ldap_info($unix, $ds);
	if ((is_array($ldap_arr)) && array_key_exists(0, $ldap_arr)) {
		$data = $ldap_arr[0]['cn'][0];
		ldap_close($ds);
		return $data;
	}
	ldap_close($ds);
	return false;
}


Expected result:
----------------
Script returns the full name of the user specified

Actual result:
--------------
tail -f /var/log/apache2/error.log

apache2: getattr.c:80: ldap_first_attribute: Assertion `len != 0' failed.
[Sun Feb 24 23:23:09 2008] [notice] child pid 1578 exit signal Aborted (6)
apache2: getattr.c:80: ldap_first_attribute: Assertion `len != 0' failed.
[Sun Feb 24 23:23:14 2008] [notice] child pid 1580 exit signal Aborted (6)


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2008-03-04 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 Dec 21 17:01:58 2024 UTC