Permission denied (publickey, gssapi-keyex, gssapi-with-mic)

0

Hi AWS, I am trying to SSH into my private EC2 instance with my OpenVPN EC2 instance. The user I am logged into the openvpn instance is openvpnas but when I am running the command I am getting the error I attached in the screenshot. I know it's a straightforward thing like exchange of SSH keys but just want to double check.

Please refer to the screenshot below:

Permission denied

profile picture
Arjun
asked 8 months ago805 views
1 Answer
2
Accepted Answer

Does the user openvpnas have read permission on the key?

$ ls -l privateserver-poc-aws.pem
profile picture
EXPERT
Steve_M
answered 8 months ago
profile pictureAWS
EXPERT
reviewed 8 months ago
  • Yes it does. Here is the output: -r-------- 1 root root 1679 Aug 23 03:52 privateserver-poc-aws.pem

  • The owner of the key is root and only root has read access to the key.

    To make the key readable by openvpnas run sudo chmod o+r privateserver-poc-aws.pem

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions