I would like to create a custom user authentification with LDAP - this is how i should work:
User enters his credentials - ill check with LDAP is the user exists, if yes ill create a session in a database and return a valid token for an request. The token handler is not the problem, but i am not sure about the LDAP Authentification.
What ive already done:
activated php_ldap extension
Installed the php-ldap-module for L5 with the description from here:
So now ive got my new Authentification Provider, but when ill try with:
if (Auth::attempt(['email' => 'user', 'password' => 'password']))
{
.....
}
Nothing happens - no error, no warning. Can i use now Auth::attempt, oder is that another function for checking if a user exists in my LDAP Directory. Is it still "email" and "password" as properties for the login attempt?
Is there somebody who is working with this extension and can give me some more information about the usage?
Thanks in advance
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire