-1

This morning I applied permission 0777 to a folder (with .ssh) on AWS. After that, SSH access does not work, without any error or message - just hung screen. Anyone help me.

3
4

SSH does not allow you to fully open permissions on its folder. Period. Permissions set to 777 means that others can hi-jack your private keys.

Why in the world would you even consider opening a directory containing ssh keys with full permissions?

You DID get messages about this in the log on your server. I would suggest it is a bad idea to provide messages to the user about permissions since it would help the person trying to invade your system. And yes, that also includes protecting you from yourself.

2

The better and only the solution is to:

Take a new- temporary ec2 instance, and attach your old server's volume to it & then revert the permissions of .SSH to default. And then re-attach the volume back to it's old server, then you can able to access your server.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.