There must be no .shosts files on RHEL 9.

STIG ID: RHEL-09-252075  |  SRG: SRG-OS-000480-GPOS-00227 | Severity: high |  CCI: CCI-000366

Vulnerability Discussion

The .shosts files are used to configure host-based authentication for individual users or the system via SSH. Host-based authentication is not sufficient for preventing unauthorized access to the system, as it does not require interactive identification and authentication of a connection request, or for the use of two-factor authentication.

Check

Verify there are no ".shosts" files on RHEL 9 with the following command:

$ sudo find / -name .shosts

If a ".shosts" file is found, this is a finding.

Fix

Remove any found ".shosts" files from the system.

$ sudo rm /[path]/[to]/[file]/.shosts