Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
WITH LDAP authentication
if I set in cgi.cg
authorized_for_all_services=
authorized_for_all_hosts=
and I set in the host1.cfg contact user1
.... the user1 see only the host1
-------------------------------------------------------------------------------
WITH PASSWD authentication
if I set in cgi.cg
authorized_for_all_services=*
authorized_for_all_hosts=*
and I set in the host1.cfg contact user1
.... the user1 see only the host1
--------------------------------------------------------------
so behavior of cgi.cfg is different when I use LDAP then PASSWD
(the * (star) is interpreted in different way)
WITH LDAP authentication
if I set in cgi.cg
authorized_for_all_services=
authorized_for_all_hosts=
and I set in the host1.cfg contact user1
.... the user1 see only the host1
-------------------------------------------------------------------------------
WITH PASSWD authentication
if I set in cgi.cg
authorized_for_all_services=*
authorized_for_all_hosts=*
and I set in the host1.cfg contact user1
.... the user1 see only the host1
--------------------------------------------------------------
So either option allows user1 to view only host1?
I'll have to set up an LDAP server with Core to see if I'm seeing the same thing.
Yes you are in rigth
In both case user1 see the host 1
but the difference is big because the behaviour of cgi.cfg is difference
WITH LDAP authentication
I have to set in cgi.cg
authorized_for_all_services=
authorized_for_all_hosts=
while WITH PASSWD authentication I have to set
authorized_for_all_services=*
authorized_for_all_hosts=*
This create another difference
WITH LDAP the user2 can NOT see any hosts
WITH PASSWD the user2 can see ALL hosts
The * (star) in cgi.cfg has a differente behaviour when I use LDAP then when I use PASSWD
I like to get this situation
Use LDAP
show one or limited number of hosts to user1
show ALL hosts for all other users (user1,user2,user3 ..... user999)
set in cgi.cfg
authorized_for_all_services=*
authorized_for_all_hosts=*
emi65 wrote:Yes you are in rigth
In both case user1 see the host 1
but the difference is big because the behaviour of cgi.cfg is difference
WITH LDAP authentication
I have to set in cgi.cg
authorized_for_all_services=
authorized_for_all_hosts=
while WITH PASSWD authentication I have to set
authorized_for_all_services=*
authorized_for_all_hosts=*
This create another difference
WITH LDAP the user2 can NOT see any hosts
WITH PASSWD the user2 can see ALL hosts
The * (star) in cgi.cfg has a differente behaviour when I use LDAP then when I use PASSWD
I like to get this situation
Use LDAP
show one or limited number of hosts to user1
show ALL hosts for all other users (user1,user2,user3 ..... user999)
set in cgi.cfg
authorized_for_all_services=*
authorized_for_all_hosts=*
Does it possible to get this behaviour ?
Regards
Emilio
I am not sure why the behavior would be different between using basic auth or LDAP, the username should be the same to the backend either way.
That said you can feel free to investigate it further and if you find the Nagios Core code needs patching, the developers of the free open source Nagios Core would welcome the contribution https://github.com/NagiosEnterprises/nagioscore