all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Multi-hop access keeps asking for password on second machine
@ 2024-11-18 21:06 Luiz Romário Santana Rios
  2024-11-19  8:48 ` Michael Albinus
  0 siblings, 1 reply; 5+ messages in thread
From: Luiz Romário Santana Rios @ 2024-11-18 21:06 UTC (permalink / raw)
  To: help-gnu-emacs

(Please cc me when replying as I'm not subscribed to the list)

I use Tramp to access my remote work machine from home. Our machines are
only accessible through the comapny's internal network, so we either have
to use a VPN or double-hop to be able to access them. Both methods work
fine, but double-hopping doesn't seem to remember the password of the
second machine and Emacs keeps asking me for it multiple times per session
(every time I compile, every time eglot runs, etc). It seems
~/.authinfo.gpg only applies to the first hop not to any subsequent hops.

Can I solve this or is this a known limitation?


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Multi-hop access keeps asking for password on second machine
  2024-11-18 21:06 Multi-hop access keeps asking for password on second machine Luiz Romário Santana Rios
@ 2024-11-19  8:48 ` Michael Albinus
  2024-11-19 13:59   ` Luiz Romário Santana Rios
  0 siblings, 1 reply; 5+ messages in thread
From: Michael Albinus @ 2024-11-19  8:48 UTC (permalink / raw)
  To: Luiz Romário Santana Rios; +Cc: help-gnu-emacs

Luiz Romário Santana Rios <luizromario@tecgraf.puc-rio.br> writes:

Hi Luiz,

> I use Tramp to access my remote work machine from home. Our machines are
> only accessible through the comapny's internal network, so we either have
> to use a VPN or double-hop to be able to access them. Both methods work
> fine, but double-hopping doesn't seem to remember the password of the
> second machine and Emacs keeps asking me for it multiple times per session
> (every time I compile, every time eglot runs, etc). It seems
> ~/.authinfo.gpg only applies to the first hop not to any subsequent hops.
>
> Can I solve this or is this a known limitation?

Which Tramp version do you use?

~/.authinfo.gpg should handle multi-hops, but I'd like to know how it
looks like. Is a sudo hop part of it?

Anyway, a few days ago I rewrote Tramp password handling (due to a bug
found in context of bug#74105). It is also related to the multi-hop
scenario. So it might be worth to check this new version.

Do you have a chance to test a recent checkout of Emacs (aka 31.0.50) or
Tramp (aka 2.8.0-pre)? If not, you could wait some few days until the
end of this month. Tramp 2.7.1.5, containing this fix, will appear on
GNU ELPA then.

If you run already the current Tramp version, 2.7.1.4, from GNU ELPA, I
could send you the respective patch for test.

Best regards, Michael.



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Multi-hop access keeps asking for password on second machine
  2024-11-19  8:48 ` Michael Albinus
@ 2024-11-19 13:59   ` Luiz Romário Santana Rios
  2024-11-19 15:32     ` Luiz Romário Santana Rios
  0 siblings, 1 reply; 5+ messages in thread
From: Luiz Romário Santana Rios @ 2024-11-19 13:59 UTC (permalink / raw)
  To: Michael Albinus; +Cc: help-gnu-emacs

Em 19/11/2024 05:48, Michael Albinus escreveu:
> Which Tramp version do you use?

This has always happened to me regardless of version, but last time I've 
seen this behavior, I was on version 29. I do have a build of the master 
branch in my work PC, so I'll update Emacs to the latest commit and try 
it out again.

I'll be back soon to report results. Thanks for the help.

> ~/.authinfo.gpg should handle multi-hops, but I'd like to know how it
> looks like. Is a sudo hop part of it?

No. This is what I'm trying to do:

/ssh:luizromario@ssh-server.br|ssh:my-machine:~/

The password to ssh-server.br is asked once; the password to my-machine 
is asked multiple times.


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Multi-hop access keeps asking for password on second machine
  2024-11-19 13:59   ` Luiz Romário Santana Rios
@ 2024-11-19 15:32     ` Luiz Romário Santana Rios
  2024-11-19 16:55       ` Michael Albinus
  0 siblings, 1 reply; 5+ messages in thread
From: Luiz Romário Santana Rios @ 2024-11-19 15:32 UTC (permalink / raw)
  To: Michael Albinus; +Cc: help-gnu-emacs

Em 19/11/2024 10:59, Luiz Romário Santana Rios escreveu:
>
> I'll be back soon to report results. Thanks for the help.
>
It looks like your refactoring really did fix my bug. I've been running 
Emacs for a couple of hours now and Tramp still hasn't asked my password 
unnecessarily. Thanks!

When will this correction hit stable Emacs?


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: Multi-hop access keeps asking for password on second machine
  2024-11-19 15:32     ` Luiz Romário Santana Rios
@ 2024-11-19 16:55       ` Michael Albinus
  0 siblings, 0 replies; 5+ messages in thread
From: Michael Albinus @ 2024-11-19 16:55 UTC (permalink / raw)
  To: Luiz Romário Santana Rios; +Cc: help-gnu-emacs

Luiz Romário Santana Rios <luizromario@tecgraf.puc-rio.br> writes:

Hi Luiz,

> It looks like your refactoring really did fix my bug. I've been
> running Emacs for a couple of hours now and Tramp still hasn't asked
> my password unnecessarily. Thanks!

Thanks for the feedback.

> When will this correction hit stable Emacs?

Emacs 30.1 is in pretest, so it will be Emacs 30.2.

As said in the other message, you can install Tramp 2.7.1.5 from GNU
ELPA with your Emacs 29. It will be available end of this month, and it
contains the patch.

Best regards, Michael.



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2024-11-19 16:55 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-11-18 21:06 Multi-hop access keeps asking for password on second machine Luiz Romário Santana Rios
2024-11-19  8:48 ` Michael Albinus
2024-11-19 13:59   ` Luiz Romário Santana Rios
2024-11-19 15:32     ` Luiz Romário Santana Rios
2024-11-19 16:55       ` Michael Albinus

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.