Skip to content
This repository was archived by the owner on Dec 23, 2020. It is now read-only.

Same results every time #12

@cyjobes

Description

@cyjobes

I have followed the instructions to the letter for ldaprecord in the authentication section using Laravel UI (deprecated).
https://ldaprecord.com/docs/laravel/auth/laravel-ui/

I am using Laravel 7x.

I am using username, not email for authentication.

At first I was getting an error about a model index not being present. So I revised the providers section of auth.php to this
` 'providers' => [
'ldap' => [
'driver' => 'ldap',
'model' => LdapRecord\Models\ActiveDirectory\User::class,

        'database' => [
            'model' => App\Ldap\User::class,
            'sync_attributes' => [
                'name' => 'cn',
                'username' => 'samaccountname',
                'email' => 'mail',
            ],
        ],
    ],

    'users' => [
        'driver' => 'eloquent',
        'model' => App\User::class,
    ],`

My LoginController has the following:
`use Illuminate\Http\Request;


public function username()
{
return 'username';
}

protected function credentials(Request $request)
{
    return [
        'samaccountname' => $request->username,
        'password' => $request->password,
    ];
}`

Like I said, I followed the instructions correctly up to before the "Fallback Authentication". No matter what I do I continue to get "These credentials do not match our records."

When I run the test (php artisan ldap:test) I get a successful connection. I know the credentials I am using are correct. I am at a loss on what I need to do.

Please help.

Cy

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions