til icon indicating copy to clipboard operation
til copied to clipboard

OSX SSH 저장

Open raycon opened this issue 3 years ago • 0 comments

https://apple.stackexchange.com/questions/48502/how-can-i-permanently-add-my-ssh-private-key-to-keychain-so-it-is-automatically

ssh-add -K ~/.ssh/[your-private-key]
ssh-add -K ~/.ssh/key.pem
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
@         WARNING: UNPROTECTED PRIVATE KEY FILE!          @
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@
Permissions 0644 for '/Users/raegon/.ssh/LightsailDefaultKey-ap-northeast-2.pem' are too open.
It is required that your private key files are NOT accessible by others.
This private key will be ignored.

권한 조정 필요

chmod 600 ~/.ssh/your-key.pem

올바른 퍼미션

chmod 700 ~/.ssh
chmod 600 ~/.ssh/id_rsa
chmod 644 ~/.ssh/id_rsa.pub  
chmod 644 ~/.ssh/authorized_keys
chmod 644 ~/.ssh/known_hosts

raycon avatar Feb 06 '22 03:02 raycon