All .rhosts, .shosts, .netrc, or hosts.equiv files must be accessible by only root or the owner.

From Red Hat Enterprise Linux 5 Security Technical Implementation Guide

Part of GEN002060

Associated with IA controls: ECLP-1

Associated with: CCI-000225

SV-37385r1_rule All .rhosts, .shosts, .netrc, or hosts.equiv files must be accessible by only root or the owner.

Vulnerability discussion

If these files are accessible by users other than root or the owner, they could be used by a malicious user to set up a system compromise.

Check content

Fix text

Ensure the permission for these files is set to 600 or more restrictive and their owner is root or the same as the owner of the home directory in which they reside. Procedure: # chmod 600 /etc/hosts.equiv # chmod 600 /etc/ssh/shosts.equiv # chown root /etc/hosts.equiv # chown root /etc/ssh/shosts.equiv # find / -name .rhosts # chmod 600 //.rhosts # chown /.rhosts # find / -name .shosts # chmod 600 /.shosts # chown /.shosts # find / -name .netrc # chmod 600 /.netrc # chown /.netrc

Pro Tips

Lavender hyperlinks in small type off to the right (of CSS class id, if you view the page source) point to globally unique URIs for each document and item. Copy the link location and paste anywhere you need to talk unambiguously about these things.

You can obtain data about documents and items in other formats. Simply provide an HTTP header Accept: text/turtle or Accept: application/rdf+xml.

Powered by sagemincer