How can a root password be locked ?

< All Topics

sudo vi /etc/ssh/sshd_config

Change PermitRootLogin to no

Save and exit

sudo systemctl restart sshd (Centos)

sudo service ssh restart (Ubuntu)

For sudo commands, system will ask for password that will make the users to be conscience about what they do and it gives a kind of security

It is possible to log sudo commands and it facilitates to check and verify the commands executed.

Next The security can be fine-tuned for sudoers (sudo users) like
Table of Contents