Information
RHEL 9 SSH server configuration files' permissions must not be modified.
GROUP ID: V-257999
RULE ID: SV-257999r1082182
Service configuration files enable or disable features of their respective services, that if configured incorrectly, can lead to insecure and vulnerable configurations. Therefore, service configuration files must have correct permissions (owner, group owner, mode) to prevent unauthorized changes.
Solution
Run the following commands to restore the correct permissions of OpenSSH server configuration files:
$ sudo dnf reinstall -y openssh-server
$ rpm --setugids openssh-server
$ rpm --setperms openssh-server