|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2006-02-28 16:24 UTC] joseph dot r dot gruber at lmco dot com
[2006-03-02 15:32 UTC] joseph dot r dot gruber at lmco dot com
[2006-06-14 16:34 UTC] sniper@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Wed Oct 29 17:00:02 2025 UTC |
Description: ------------ When attempting to search a Windows 2000 Active Directory via LDAP, PHP will crash with an Access Violation. This will only occur during certain (reproducible) LDAP queries. For example: Works: $s = ldap_search($conn,"DC=u,DC=contoso,DC=com","(&(objectCategory=group)(name=group.name.domain))",array("cn","samaccountname")); Doesn't Work: $s = ldap_search($conn,"DC=u,DC=contoso,DC=com","(&(objectCategory=group)(name=group.name.domain2))",array("cn","samaccountname")); Where the only difference is in the filter. Server: IIS 5.1 on Windows 2000 with PHP 5.1.2. Attempted 5.1.3 (latest snapshot) and issue still occurs. Reproduce code: --------------- <? $conn = ldap_connect("rootdc.contoso.com"); ldap_set_option($conn, LDAP_OPT_PROTOCOL_VERSION, 3); $bind = ldap_bind($conn, "user@contoso.com", "paSSw0rd"); $filter = "(&(objectCategory=group)(name=group.name.domain2))"; $fields = array("member","cn","description","distinguishedname","objectcategory","samaccountname","canonicalname"); $search = ldap_search($conn,"DC=u,DC=contoso,DC=com",$filter,$fields); $entries = ldap_get_entries($conn, $search); var_dump($entries); ?> Expected result: ---------------- Expected to return fields listed in the $fields array in the $entries array. Actual result: -------------- The page load terminates and reports: "PHP has encountered an Access Violation at 01CE5CE6" Backtrace (NOTE: php.exe used for debugging. Normally use IIS5.1 w/php5isapi.dll): Unhandled exception in php.exe (PHP_LDAP.dll): 0xC0000005: Access Violation Call Stack: PHP_LDAP! 00f95ce6() Disassembly: 00F95CE6 mov eax,dword ptr [esi+18h]