remembering passwords on a non-GUI server

Karl Auer kauer at biplane.com.au
Fri Feb 3 07:58:03 UTC 2023


On Mon, 2023-01-30 at 13:14 +0100, Oliver Grawert wrote:
> yes, there are ... for ssh and gpg see:
> 
> $ ps ax|grep bin/[a-z]*-agent
>   52085 ?        SLs    0:02 /usr/bin/gpg-agent --supervised
>   75230 ?        S      0:00 /usr/bin/ssh-agent -D -a
> /run/user/1000/keyring/.ssh
> $

Thanks, Oliver.

Concentrating just on ssh: Simply running ssh-agent does not do the
trick (and why have you got -D" in your command there, that says "run
in foreground..."?).

I'm tantalisingly close. If I run ssh-agent it outputs some variables
that I then export (I could run eval `ssh-agent -s` too).

Then if I run ssh-add and specify an ssh private key file, I am
prompted for the passphrase.

"ssh-add -l" then shows me that it has indeed registered that key.

At this point I would have thought all the pieces are in place - but
when I then try to log on to a remote host using that key, I am still
prompted for the password for that key:-(

What am I missing?

I've started trying to understand gpg-agent, but its doco is even more
impenetrable.

It's hard to believe, in a world absolutely filled with GUI-less
servers being managed via ssh, that this is not a totally common thing
to want to do...

Regards, K.

-- 
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Karl Auer (kauer at biplane.com.au)
http://www.biplane.com.au/kauer






More information about the ubuntu-users mailing list