You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have followed the database auth configuration documentation and I can successfully login with my active directory credentials using tinker. It does sync the user in the users table in the database.
However, trying to achieve the same thing in a controller, Auth::attempt($credentials) returns false.
My App\Models\User model implements LdapAuthenticatable and uses the trait AuthenticatesWithLdap.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
I have followed the database auth configuration documentation and I can successfully login with my active directory credentials using tinker. It does sync the user in the users table in the database.
However, trying to achieve the same thing in a controller,
Auth::attempt($credentials)
returns false.My
App\Models\User
model implementsLdapAuthenticatable
and uses the traitAuthenticatesWithLdap
.auth.php
LoginController
AuthService
The test that I've wrote also fails.
What can explain that I can login when in a tinker bash, but not from the controller?
Beta Was this translation helpful? Give feedback.
All reactions