help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

tramp access to ssh agent


From: GUEZ Lionel
Subject: tramp access to ssh agent
Date: Tue, 11 Oct 2022 21:41:53 +0200

Hello. I am using GNU Emacs 27.1 on Linux Mint 21. I am experiencing a
problem that I did not have with my previous setup: Emacs 26.3 on
Linux Mint 20.3. I have an SSH key, protected by a passphrase, that I
use to connect to a remote host. As the key is in my .ssh directory
with a standard name, it is automatically detected and unlocked at
login by gnome-keyring-daemon. So when I ssh to the remote host from a
terminal, the ssh agent provides the passphrase and I do not have to
enter it.

Now here is the strange part. When I try to connect to the
remote host from Emacs, Emacs may or may not ask me the passphrase. It
seems to depend on how long ago I logged in. If I try the connection
in Emacs immediately after login, Emacs does not ask me the
passphrase, and Emacs never asks the passphrase from then on in this
session. If I try the connection in Emacs for the first time in my
session, say, a few hours after login, Emacs asks me the passphrase. So
it seems that tramp has access to the ssh agent or not depending on how
long has elapsed since login. Note that there is no such problem from
the Gnome terminal. Even when Emacs asks me the passphrase, the
terminal does not. The ssh agent is here (I see it in the list of
processes) and the terminal has access to it.

Does anybody understand this? Is there a timeout period after which
gnome-keyring is not able to communicate with Emacs? And why is this
different in Linux Mint 20.3 and 21?

-- 
Lionel GUEZ
Laboratoire de météorologie dynamique
École normale supérieure
24 rue Lhomond, 75005 Paris



reply via email to

[Prev in Thread] Current Thread [Next in Thread]