0

So I have a centos 7 server with 2 users.

User1 has the ~/.ssh/authorized_keys file with proper permissions and with externaluser's public key in it.

User2 has the ~/.ssh/authorized_keys file with proper permissions and with the same externaluser's public key in it.

Externaluser can ssh to User1 with no problems, however, he gets Permission denied (publickey,gssapi-keyex,gssapi-with-mic) error when trying to ssh to User2.

Why does this happen? It's literally the same public key, properly pasted into the authorized_keys file of each user, using the same method.

iamAguest
  • 483

1 Answers1

0

Thank you RalfFriedl for your useful comment, the problem was the .ssh folder permissions.

Check the owner and permissions on .ssh and on authorized_keys.

iamAguest
  • 483