Skip to content
This repository was archived by the owner on Jul 24, 2023. It is now read-only.
This repository was archived by the owner on Jul 24, 2023. It is now read-only.

workaround for: problem with two factor authentication #894 #914

Open
@ivanomatteo

Description

@ivanomatteo

Login works, but automatic user import do not works.

/**
 * workaround for two factor auth
 */
class LaravelLdapUserProvider extends DatabaseUserProvider
{

    public function validateCredentials(Authenticatable $model, array $credentials)
    {
        if (!$this->retrieveByCredentials([
            config('fortify.username') => $model->name,
            'password' => $credentials['password'],
        ])) {
            return false;
        }
        return parent::validateCredentials($model, $credentials);
    }
}

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