Why is my .ssh/config file not readable?
I am trying to edit my ssh/config
file, but when I type emacs ~/.ssh/config
into Terminal, it says that the file is not readable and will not save my edits. When I try to overwrite, it says permission is denied. Why is this happening?
ls -la ~/.ssh/config
returns
-rw------- 1 root staff 1141 Jul 17 14:30 /Users/firestarter/.ssh/config
It says permission denied when I try to cat
it
Solution 1:
Looks like your config file got copied by somebody else. Log in as an admin user if you ain't one already and run
sudo chown firestarter /Users/firestarter/.ssh /Users/firestarter/.ssh/*
sudo chmod 700 /Users/firestarter/.ssh