Subject: | Add SASL support |
It would be nice if Apache::AuthLDAPBind had optional SASL support. The
code would roughly look like this:
if ($use_sasl) {
require Authen::SASL;
my $sasl = Authen::SASL->new(mechanism => 'CRAM-MD5', callback
=> { user=> $username, pass => $password });
$mesg = $ldap->bind($base_dn, sasl=>$sasl);
} else {
... non-sasl code ...
}
The mechanism value should be set in a PerlSetVar (e.g.
ldap_sasl_mechanisms). $use_sasl should probably only be true if
mechanism is set.
I think also that usage of start_tls should be configurable.
Regards,
Slaven