jotaelesalinas / laravel-adminless-ldap-auth

Authenticate users in Laravel against an adminless LDAP server
MIT License
210 stars 33 forks source link

Active Directory I am connecting to does not have the attributes property #17

Closed joebertj closed 6 years ago

joebertj commented 6 years ago

I am new to laravel (1 week)

$ldapuser_attrs = self::accessProtected($ldapuser, 'attributes');

"Property attributes does not exist"

I am still figuring out what is the correct property name. Any ideas?

joebertj commented 6 years ago

The solution is to remove entire function retrieveSyncAttributes($username) and use instead

$user->name = $ldapuser->getCommonName();

This is because cn is actually commonName on the model.