commit faa462bbf0a5ea5eecad49b274e78adaf300f5e0
Author: Kevan Carstensen <kacarstensen@csupomona.edu>
Date:   Thu Jul 28 14:32:41 2011 -0700

    Specify that we want to use the 'ldap' scheme to verify certificates.

diff --git a/lib/Net/LDAP.pm b/lib/Net/LDAP.pm
index 42fe946..f47c905 100644
--- a/lib/Net/LDAP.pm
+++ b/lib/Net/LDAP.pm
@@ -219,17 +219,18 @@ sub _SSL_context_init_args {
   }
 
   (
-    SSL_cipher_list => defined $arg->{'ciphers'} ? $arg->{'ciphers'} : 'ALL',
-    SSL_ca_file     => exists  $arg->{'cafile'}  ? $arg->{'cafile'}  : '',
-    SSL_ca_path     => exists  $arg->{'capath'}  ? $arg->{'capath'}  : '',
-    SSL_key_file    => $clientcert ? $clientkey : undef,
-    SSL_passwd_cb   => $passwdcb,
-    SSL_check_crl   => $arg->{'checkcrl'} ? 1 : 0,
-    SSL_use_cert    => $clientcert ? 1 : 0,
-    SSL_cert_file   => $clientcert,
-    SSL_verify_mode => $verify,
-    SSL_version     => defined $arg->{'sslversion'} ? $arg->{'sslversion'} :
-                       'sslv2/3',
+    SSL_cipher_list     => defined $arg->{'ciphers'} ? $arg->{'ciphers'} : 'ALL',
+    SSL_ca_file         => exists  $arg->{'cafile'}  ? $arg->{'cafile'}  : '',
+    SSL_ca_path         => exists  $arg->{'capath'}  ? $arg->{'capath'}  : '',
+    SSL_key_file        => $clientcert ? $clientkey : undef,
+    SSL_passwd_cb       => $passwdcb,
+    SSL_check_crl       => $arg->{'checkcrl'} ? 1 : 0,
+    SSL_use_cert        => $clientcert ? 1 : 0,
+    SSL_cert_file       => $clientcert,
+    SSL_verify_mode     => $verify,
+    SSL_version         => defined $arg->{'sslversion'} ? $arg->{'sslversion'} :
+                           'sslv2/3',
+    SSL_verifycn_scheme => "ldap",
   );
 }
 
