use ssl connection to upstream ldap
authorDobrica Pavlinusic <dpavlin@rot13.org>
Sun, 15 Mar 2009 21:20:35 +0000 (21:20 +0000)
committerDobrica Pavlinusic <dpavlin@rot13.org>
Sun, 15 Mar 2009 21:20:35 +0000 (21:20 +0000)
bin/ldap-rewrite.pl

index b3080f8..58c8222 100755 (executable)
@@ -9,6 +9,7 @@ use warnings;
 
 use IO::Select;
 use IO::Socket;
+use IO::Socket::SSL;
 use warnings;
 use Data::Dump qw/dump/;
 use Convert::ASN1 qw(asn_read);
@@ -144,6 +145,8 @@ my $targetsock = new IO::Socket::INET (
        PeerPort => 389,
 );
 
+$targetsock = IO::Socket::SSL->new("ldap.ffzg.hr:ldaps");
+
 run_proxy($listenersock,$targetsock);
 
 1;