gpg-agent and ~/.ssh/config IdentityFile

Muri Nicanor muri+gnupg-users at immerda.ch
Wed Jul 6 14:06:52 CEST 2016


Hi,

On 07/05/2016 11:23 PM, Daniel Kahn Gillmor wrote:
> You're right, this really is a better question for OpenSSH users.
> 
> On Mon 2016-07-04 09:15:07 -0400, Muri Nicanor wrote:
>> at the beginning of my ~/.ssh/config. when authenticating to a host i
>> only want to use the one identity/key i've created for that host instead
>> of sending all of them to the server...
> 
> Do you have a .pub file of the public part of your identity?  try
> pointing Identities to that file.
> 
> if you don't have such a file, you should be able to do:
> 
>    ssh-add -L
> 
> filter the output to the line you want, save the filtered output to a
> file named "foo.pub" and then try with "ssh -i foo.pub remotehost"

Thanks a lot! I didn't know that i can use the public key for the
IdentityFile.
As Peter already wrote, that works, and i can now use my openpgp card
for ssh auth without disclosing all my other keys to the server ;)

thanks,
muri



More information about the Gnupg-users mailing list