Fix SSH Key Permissions (Permissions are too open private key will be ignored)

Sometimes you’ll get an error on your ssh client when you’re working with a new ssh key and you’re trying to ssh into the server. To fix permissions that are too open you can do these 2 commands. Most likely you only need to fix the key itself and not the folder.

Fix key files themselves

chmod 600 ~/.ssh/id_you_private_key

Make sure the .ssh key folder is 700

chmod 700 ~/.ssh

Leave a Reply

Your email address will not be published. Required fields are marked *