Wrong .ssh Directory Permissions

less than 1 minute read

Background/Problem

So, I had two laptops (let’s call them “A” and “B”). Both of which had Arch Linux installed as their operation sysetm. I simply wanted to be able to use either of these laptops to log into the other one via ssh. And I wanted to do so using public key authentication and not with a password. It seemed as if everything was set up correctly (search the internet for explanation on how to do that, it’s not that hard). But the ssh connection worked only in one direction. I was able to log into laptop “A” from laptop “B”, but now the other way around.

Solution

I can’t remember where I found the solution, but it took me quite some time to figure it out. Apparently the .ssh directory on the computer you want to log into, has to have the permissions set to 700. For whatever reason they were set to 775 and that caused the problem.

Change Log

2022-09-20:

  • Changed wording a little bit.



Take care,
Andreas

Updated:

Leave a comment