Mac, ssh asks for passphrase repeatedly fix

Case: Trying to SSH into a Digital Ocean instance using a freshly generated Key and passphrase…

$ ssh -i ~/.ssh/id_rsa.pub [email protected]
Enter passphrase for key '/Users/me/.ssh/id_rsa.pub':
Enter passphrase for key '/Users/me/.ssh/id_rsa.pub':
Enter passphrase for key '/Users/me/.ssh/id_rsa.pub':
Permission denied (publickey).

This stores passphrases in your keychain…

/usr/bin/ssh-add -K

Try again and it should connect without any issues.

Back to Top