Security concerns with XI user/group/mode on files & dirs
Posted: Mon Oct 01, 2018 9:33 am
I've been auditing our XI servers for filesystem-related security issues (using things like rpm -V -a) and I'm disturbed by a few findings.
First, I found the following to be set to group nagios and made group-writable:
Why is XI (or components thereof) able to - or why does it need to - modify important base OS configurations like LDAP??
Next:
If the nagios account is compromised, editing that file could allow a remote attack by having xinetd call a binary or script other than /usr/local/nagios/bin/nrpe
Finally, the most troublesome:
Since that is executed by root, if the nagios account is compromised that file could be edited to allow local privilege escalation to root.
I'm prepared to remove the group-write from all these files and deal with limited functionality in XI unless / until someone can help me understand why these files are set this way.
Thanks in advance!
First, I found the following to be set to group nagios and made group-writable:
Code: Select all
drwxrwxr-x. 4 root nagios 4096 Aug 17 2017 /etc/openldap
drwxrwxr-x. 2 root nagios 4096 Feb 8 2017 /etc/openldap/cacerts
drwxrwxr-x. 2 root nagios 4096 Dec 6 2016 /etc/openldap/certs
-rw-rw-r--. 1 root nagios 600 Aug 17 2017 /etc/openldap/ldap.conf
Next:
Code: Select all
-rw-rw-r-- 1 root nagios 323 Sep 24 16:38 /etc/xinetd.d/nrpe
Finally, the most troublesome:
Code: Select all
-rwxrwxr-x. 1 root nagios 394 Aug 17 2017 /etc/sysconfig/nagios
I'm prepared to remove the group-write from all these files and deal with limited functionality in XI unless / until someone can help me understand why these files are set this way.
Thanks in advance!