Getting started with 1Password for your growing team, or refining your setup? Our Secured Success quickstart guide is for you.
Forum Discussion
neun34tel
3 years agoNew Contributor
Multiple private keys not handled correctly?
Hi!
I have three SSH keys in 1Password. The SSH agent is set up correctly (according to 1Password itself).
My problem is, that two different devices I have ask for two specific SSH keys for the...
Jack_P_1P
1Password Team
3 years agoHi neun34tel:
Generally speaking, this would depend on the specific configuration of the SSH server you're connecting to. OpenSSH's default is 6 keys can be presented before disconnecting, but this can be changed, and it seems like this server has been configured to accept less keys before disconnecting. In this case, your best bet would be to configure SSH on your machine to always use that key for that server.
To do this, first download the public key for the keypair you'd like to use from 1Password for Linux.
Place the public key in your ~/.ssh/
directory, and give it a name like thirdkey.pub
. In your ~/.ssh/config
file, add a snippet that looks something like this:
Host <mythirdrepo.com>
IdentityFile ~/.ssh/thirdkey.pub
IdentitiesOnly yes
At this point, the remote of git@
If all of your repos are on the same host, the snippet would instead need to look something like this:
Host thirdrepo
HostName <example.com>
User git
IdentityFile ~/.ssh/thirdkey.pub
IdentitiesOnly yes
Then for your Git remote, rather than using git@
Jack