Technology Sharing

Mac OS ssh connection prompts Permission denied (publickey)

2024-07-08

한어Русский языкEnglishFrançaisIndonesianSanskrit日本語DeutschPortuguêsΕλληνικάespañolItalianoSuomalainenLatina

This error is a bit weird. The IDE (vscode and pycharm) on MacBook cannot connect remotely, but the terminal can connect, and the pycharm on Windows can connect. What the hell, so it must not be a key problem. After checking for a long time, I found that it was a permission problem.

chmod 400 ~/.ssh/id_rsa

https://stackoverflow.com/questions/29933918/ssh-key-permissions-0644-for-id-rsa-pub-are-too-open-on-mac