------=_NextPart_000_0013_01C9141C.BB02C310
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Good morning all,
System platform:
Server with W2K3, IIS6 and PHP 5
Workstation with XP SP3.
I make a search into my LDAP.
It works but I need to make the bind with a username/password couple
Code below:
<?php
$ldap_user =3D substr($_SERVER['AUTH_USER'],7)." [at] domaine.com";
$ldap_pass); //here putting the password for ^$ldap_user;
$ldap_host =3D 'ldap.domaine.com';
$ldap_domain=3D 'ldap-domain';
$base_dn=3D'ou=3DUSER,OU=3DOrgUnit,dc=3Ddomain,dc=3Dcom';
$filter=3D'(cn=3D*)';
$connect=3Dldap_connect($ldap_host,389) or exit('>>Could not connect to =
LDAP server<<');
$bind=3Dldap_bind($connect,$ldap_user,$ldap_pass) or exit('<<Could not =
bind to $ldap_host<<');
$read=3Dldap_search($connect,$base_dn,$filter);
$info=3Dldap_get_entries($connect,$read);
echo $info['count'].' entries returned<p>';
echo "<br>";
for ($i=3D0;$i<$info['count']; $i++)
{
$info_cn =3D $info[$i]['initials'][0];
echo 'cn =3D '.$info_cn.'<BR>';
}
?>
I want use the Windows Integrated Authentication to send to my ldap_bind =
command the current user/password instead of hardcoded it into the php =
script.
Regards,
C.B
------=_NextPart_000_0013_01C9141C.BB02C310--
