Configure public key authentication for new user, when password authentication is disabled

0

In an EC2 instance, with Amazon Linux AMI, "PasswordAuthentication" is disabled in "sshd_config" file, and "PubkeyAuthentication" is enabled, by default.

Incase "Linux System admin user" creates new Linux user on the EC2 instance, how the new Linux user ssh to the system? Because password authentication is already disabled.

And if the new Linux user generates public key in his local machine, and try to place it, in the EC2 instance, he could not place. Because currently both Public key authentication and password authentication will not work.

How to overcome this scenario?

1 réponse
0

When Linux system admin create a new user, ask them to create a SSH key for new user and share the private keys with respective user. Then the private key can be used to login to the instance as new user.

répondu il y a 2 ans

Vous n'êtes pas connecté. Se connecter pour publier une réponse.

Une bonne réponse répond clairement à la question, contient des commentaires constructifs et encourage le développement professionnel de la personne qui pose la question.

Instructions pour répondre aux questions