LDAP Groups override role of existing users?
-
authLdap has an option called “LDAP Groups override role of existing users?”.
I think this is rather misleading, because no matter how this setting is set, UserRoleHandler.php will remove already assigned user roles, that are not mapped with LDAP.
<span style=”text-decoration: underline;”>So here’s my use case:</span>
I need to auth my users against an AD/LDAP i can’t admin myself. To gain some control on my side, i need to be able to assign WP user roles, separate from whats mapped with LDAP (again, because i can’t change LDAP). So if a mapping is there, the user should be assigned the mapped roles, but if the user already has roles that are not mapped, they should keep these as well.
The way authLdap is written, thats not possible straight away, because it will remove any user roles that are not mapped with LDAP.
<span style=”text-decoration: underline;”>Here’s my solution:</span>
Just comment the lines that remove user roles in UserRoleHandler.php.
It’s just weird, because i thought that’s what uncheckig “LDAP Groups override role of existing users?” was supposed to do.
Cheers
- The topic ‘LDAP Groups override role of existing users?’ is closed to new replies.