GNU bug report logs - #19047
Tramp reuses bad ssh passphrase several times without asking

Previous Next

Package: emacs;

Reported by: Stephane Chauveau <stephane <at> chauveau-central.net>

Date: Thu, 13 Nov 2014 18:33:02 UTC

Severity: normal

Done: Michael Albinus <michael.albinus <at> gmx.de>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 19047 <at> debbugs.gnu.org (full text, mbox):

From: Stephane Chauveau <stephane <at> chauveau-central.net>
To: 19047 <at> debbugs.gnu.org
Subject: Re: bug#19047: Acknowledgement (Tramp reuses bad ssh passphrase
 several times without asking)
Date: Thu, 13 Nov 2014 20:37:24 +0100
I am not an elisp nor a tramp expert but after looking at tramp.el I
believe that the problem is that OpenSSH is silent when a bad passphrase
is given.

A typical OpenSSH session with bad passphrase and passwords is

Enter passphrase for key '/home/chauveau/.ssh/id_rsa':
Enter passphrase for key '/home/chauveau/.ssh/id_rsa':
Enter passphrase for key '/home/chauveau/.ssh/id_rsa':
chauveau <at> hobb's password:
Permission denied, please try again.
chauveau <at> hobb's password:
Permission denied, please try again.
chauveau <at> hobb's password:
Permission denied (publickey,password).


In function tramp-action-password, some codes were added to clear the
'wrong' password:

 ;; Let's check whether a wrong password has been sent already.
 ;; Sometimes, the process returns a new password request
 ;; immediately after rejecting the previous (wrong) one.
 (goto-char (point-min))
 (when (search-forward-regexp tramp-wrong-passwd-regexp nil t)
   (tramp-clear-passwd vec))

That code probably does not work because there is nothing to match with
tramp-password-prompt-regexp after the Enter passphrase prompt.









This bug report was last modified 10 years and 184 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.