Package: lbdb Version: 0.30 Tags: patch Hi!
Within our corporate network, I need to supply a password. I didn't manage to figure out how this can be done with the current mutt_ldap_query script, so I patched it. Here's the patch: --- mutt_ldap_query.upstream 2005-08-23 13:39:08.131578528 +0200 +++ mutt_ldap_query 2005-08-23 13:39:12.418926752 +0200 @@ -48,6 +48,13 @@ our $ldap_result_realname = '${givenname} ${sn}'; # format of the comment result based on the expected answers of the ldap query our $ldap_result_comment = '(${o})'; +# bind name for LDAP +our $ldap_bind_name = ''; +# password for LDAP access +our $ldap_bind_password = ''; +# LDAP version +our $ldap_version = '2'; + # use ignorant (wildcard searching): our $ignorant = 0; @@ -173,8 +180,8 @@ $query = "(|" . $query . ")"; print "DEBUG: perl ldap module processing filter:\nDEBUG: $query\n" if ($DEBUG); - my $ldap = Net::LDAP->new($ldap_server, DN => "", Password => "", Port => 389, Debug => 3,) or die $@; - $ldap->bind; + my $ldap = Net::LDAP->new($ldap_server, DN => "", Password => "", Port => 389, Debug => 3) or die $@; + $ldap->bind("$ldap_bind_name", password => "$ldap_bind_password", version => "$ldap_version"); my $mesg = $ldap->search( base => $search_base, filter => $query ) or die $@; $mesg->code && die "Search failed. LDAP server returned an error : ", $mesg->code, ", description: ", $mesg->error; my @entries = $mesg->entries; Missing is additional documentation for the three new items, as well as example entried in /etc/lbdb_ldap.rc file. It would be nice to see this installed in the next Debian package of lbdb. Thanks, JBG -- Telefónica Deutschland GmbH | Jan-Benedict Glaw Hülshorstweg 30 | Problem Management 33415 Verl | E-Mail: [EMAIL PROTECTED] http://www.telefonica.de/ | Tel.: +49-5246-80-1869 -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]