[sork] Tls support in ldap

tarjei+a_lists.phpgw at nu.no tarjei+a_lists.phpgw at nu.no
Sun Jan 26 14:38:30 PST 2003


36a37,38
>         $this->_params['tls']     = array_key_exists('tls', $params)     ? $params['tls'] : null;
> 
53c55,59
< 
---
> 	if (ldap_set_option($this->_ds, LDAP_OPT_PROTOCOL_VERSION, 3) && $this->_params['tls']) {
>  	    if (!ldap_start_tls($this->_ds)) {
> 	      return PEAR::raiseError(_("Ldap_start_tls failed "));
>   	    }	
> 				}
134c140
<                 return PEAR::raiseError(_("Incorect Password"));
---
>                 return PEAR::raiseError(_("Incorect Password, or dn $userdn"));
137a144,150
>        $smbcrypt = '/usr/local/bin/mkntpwd';
>        $command = @$smbcrypt ." ".  escapeshellarg($newPassword);
>        $smbpasswd = exec($command);
>        $smbpasswd = explode(':',$smbpasswd);
>        $newDetails['ntPassword'] = $smbpasswd[1];
>        $newDetails['lmPassword'] = $smbpasswd[0];
> 
-------------- next part --------------
--- backends.php.dist.orig	2003-01-26 14:15:24.000000000 +0100
+++ backends.php.dist	2003-01-26 14:16:31.000000000 +0100
@@ -114,7 +114,9 @@
         'realm' => '', // this will be appended to the username when
                        // looking for the userdn.
 //        'userdn' => 'uid=' . Auth::getAuth() . ',o=example.com',
-        'encryption' => 'crypt'
+        'encryption' => 'crypt',
+        'tls' => 0 // please make sure the host equals the cn in the server certificate!.
+
     )
 );
 


More information about the sork mailing list