Authen-Simple-LDAP

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

Revision history for Perl extension Authen::Simple::LDAP

0.3 2012-04-19
    - Corrected typos in arguments passed to Net::LDAP constructor (RT #65426)
    - Changed Perl module installer from Module::Build to Module::Install

0.2 2006-01-05
    - return dn on successful authentication
    - log using error level unless invalid credentials

0.1 2006-01-03
    - first release

README  view on Meta::CPAN


        *       binddn

                The distinguished name to bind to the server with, defaults
                to bind anonymously.

                    binddn => 'uid=proxy,cn=users,dc=company,dc=com'

        *       bindpw

                The credentials to bind with.

                    bindpw => 'secret'

        *       basedn

                The distinguished name of the search base.

                    basedn => 'cn=users,dc=company,dc=com'

        *       filter

lib/Authen/Simple/LDAP.pm  view on Meta::CPAN

    unless ( defined $connection ) {

        my $host = $self->host;

        $self->log->error( qq/Failed to connect to '$host'. Reason: '$@'/ )
          if $self->log;

        return 0;
    }

    my ( @credentials, $message, $search, $entry, $filter, $dn );

    @credentials = $self->binddn ? ( $self->binddn, password => $self->bindpw ) : ();
    $message     = $connection->bind(@credentials);

    if ( $message->is_error ) {

        my $error  = $message->error;
        my $binddn = $self->binddn;
        my $bind   = $binddn ? qq/with dn '$binddn'/ : "Anonymously";

        $self->log->error( qq/Failed to bind $bind. Reason: '$error'/ )
          if $self->log;

lib/Authen/Simple/LDAP.pm  view on Meta::CPAN


=item * binddn 

The distinguished name to bind to the server with, defaults to bind
anonymously.

    binddn => 'uid=proxy,cn=users,dc=company,dc=com'

=item * bindpw 

The credentials to bind with.

    bindpw => 'secret'

=item * basedn

The distinguished name of the search base.

    basedn => 'cn=users,dc=company,dc=com'

=item * filter



( run in 0.319 second using v1.01-cache-2.11-cpan-4d50c553e7e )