Deny Root SSH
Hi everyone,
I was trying to deny root ssh, as usual I edited /etc/ssh/sshd_config file and set PermitRootLogin no, and then restarted sshd service, but still the root user was able to login through ssh.
I found that another file in /etc/ssh/sshd_config.d/01-permitrootlogin.conf is created during the installation of RHEL9 if we tick the "Allow Root ssh login with password" tick box, and this file has precedence over sshd_config file, therefore we need to edit this in order to deny rood ssh login.