Page 1 of 1

xampp connect ldaps server

PostPosted: 12. October 2010 12:51
by Spleshmen
i am trying to connect to a ldap over ssl server from windows xp sp3 using xampps default configuration.
the data i need to connect to the ldaps server is correct and here is the code i am using
Code: Select all
<?php
$config = array(
   'host'   =>   'ldaps://***.com',
   'port'   =>   some int,
   'bind'   =>   'uid=***,dc=***,dc=***,dc=***',
   'pass'   =>   '***',
   'dbase'   =>   'dc=***,dc=***,dc=***'
);

$c = ldap_connect($config['host'],$config['port']);
if ($c==FALSE) {
   echo 'Error ldap_connect';
}
else {
   $action = ldap_bind($c,$config['bind'],$config['pass']);
   if ($action==FALSE) {
      echo 'LDAP bind fail <br/> ';      
      echo 'ldap_error : <b>'.ldap_error($c).'</b>  <br/>';
   }
   else {
      echo 'LDAP bind true';
   }
}
?>

the error i am getting is this one : Can't contact LDAP server
with the data for the ldaps server i get 2 certificates ... a SSL CA certificate and a ROOT CA certificate
the problem could be becose i am not using those certificates and if so how can i use them? i search on google but no results...please help
thanks

Re: xampp connect ldaps server

PostPosted: 13. October 2010 01:49
by JonB
Is the target autentication server an AD(active DIrectory) server?

and your prupose is to use Windows authentication method?

:?:

Re: xampp connect ldaps server

PostPosted: 13. October 2010 09:24
by Spleshmen
yes the target server is ldap server and i am trying to make a connection on that server from my computer wich is running windows xp

Re: xampp connect ldaps server

PostPosted: 13. October 2010 11:45
by JonB
you didn't answer the part about Active Directory and Windows authentication?

:shock: