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
when multiple LDAP authentication are created, and group is mandatory, the code copy the default user template, not the one define into the 'User Domain' settings.
on Cacti 1.2.8
Looking into the code I think the error is on auth_login.php, line 505 and following:
If it's the first time the user login in, we go enter the IF function
on Line 500 we where able to qet the right 'template_user' from the 'User Domain' definition.
But on line 509 it make a query on the DB using the get_template_account() function (taken from functions.php line 2358) and this one look into the setting, so the simple LDAP auth. This record is not even visible on Cacti GUI when selecting multip LDAP auth.
Changing the line 512: array(get_template_account()));
to : array($template_user));
I think It will fix the problem!
The text was updated successfully, but these errors were encountered:
I think 1.3 did get a bit of a rejig on the auth code to make it more streamlined/efficient. However, I would need to examine that properly before I decide to make modifications again because of its compound effect.
So I've reviewed what you have stated and I do agree with you. If you have used multi domain auth, the template user isn't being picked from the domain record but from the settings table which really only appears to simple auth or cacti auth.
There also isn't an option on the domain record to say, use the global setting so you have it only set in one place but that would be an enhancement and no ones actually asked for that yet.
netniV
changed the title
Wrong user template on multiple LDAP login access
When using User Domains, global template user is used instead of the configured domain template user
Feb 22, 2020
when multiple LDAP authentication are created, and group is mandatory, the code copy the default user template, not the one define into the 'User Domain' settings.
on Cacti 1.2.8
Looking into the code I think the error is on auth_login.php, line 505 and following:
If it's the first time the user login in, we go enter the IF function
on Line 500 we where able to qet the right 'template_user' from the 'User Domain' definition.
But on line 509 it make a query on the DB using the get_template_account() function (taken from functions.php line 2358) and this one look into the setting, so the simple LDAP auth. This record is not even visible on Cacti GUI when selecting multip LDAP auth.
Changing the line 512: array(get_template_account()));
to : array($template_user));
I think It will fix the problem!
The text was updated successfully, but these errors were encountered: