Q34

Question 34. How To Disable Password-based Logins For Root In Amazon Ec2 Instance ?

Answer :

Using a fixed root password for a public AMI is a security risk that can quickly become known. Even relying on users to change the password after the first login opens a small window of opportunity for potential abuse.

Following are the steps to disable password-based remote logins for the root user:

Open the /etc/ssh/sshd_config file with a text editor and locate the following line:
#PermitRootLogin yes
Change the line to:
PermitRootLogin without-password
The location of this configuration file might differ for your distribution.

Comments

Popular posts from this blog

Q48 & 49

Q31