Debian Bug report logs -
#454554
sudo bug 343268 breaks comint M-x shell
Reported by: "Trent W\. Buck" <trentbuck@gmail.com>
Date: Thu, 6 Dec 2007 07:21:02 UTC
Severity: normal
Tags: fixed-upstream
Found in version emacs22/22.1+1-2.1
Fixed in version emacs22/22.2+1-1
Done: Sven Joachim <svenjoac@gmx.de>
Bug is archived. No further changes may be made.
Toggle useless messages
Report forwarded to debian-bugs-dist@lists.debian.org, Rob Browning <rlb@defaultvalue.org>:
Bug#454554; Package emacs22.
(full text, mbox, link).
Acknowledgement sent to "Trent W\. Buck" <trentbuck@gmail.com>:
New Bug report received and forwarded. Copy sent to Rob Browning <rlb@defaultvalue.org>.
(full text, mbox, link).
Message #5 received at submit@bugs.debian.org (full text, mbox, reply):
Package: emacs22
Version: 22.1+1-2.1
Severity: normal
As a result of http://bugs.debian.org/343268, sudo now uses a
grandiloquent prompt:
[sudo] password for twb:
This is not matched by M-x shell's password regexp, so the user is
suddenly faced with their passwords being echoed to the screen.
Either #343268 should be reverted, or shell.el's regexp should be
extended to work around this madness.
See function comint-watch-for-password-prompt and variable
comint-password-prompt-regexp.
PS: users can use M-x send invisible RET to supply a one-off hidden
password to non-matching regexps; this is what Emacs 21 users had to
do all the time.
PPS: this issue has affected Ubuntu Gutsy for some time. Because
Ubuntu makes it difficult for tty users to report bugs, I do not
report bugs to them, instead waiting until they can be reproduced on
Debian.
-- System Information:
Debian Release: lenny/sid
APT prefers unstable
APT policy: (990, 'unstable')
Architecture: amd64 (x86_64)
Kernel: Linux 2.6.22-3-amd64 (SMP w/1 CPU core)
Locale: LANG=en_AU.utf8, LC_CTYPE=en_AU.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Versions of packages emacs22 depends on:
ii emacs22-bin-common 22.1+1-2.1 The GNU Emacs editor's shared, arc
ii libc6 2.7-3 GNU C Library: Shared libraries
ii libice6 2:1.0.4-1 X11 Inter-Client Exchange library
ii libjpeg62 6b-14 The Independent JPEG Group's JPEG
ii libncurses5 5.6+20071124-1 Shared libraries for terminal hand
ii libpng12-0 1.2.15~beta5-3 PNG library - runtime
ii libsm6 2:1.0.3-1+b1 X11 Session Management library
ii libtiff4 3.8.2-7 Tag Image File Format (TIFF) libra
ii libungif4g 4.1.4-5+b1 shared library for GIF images
ii libx11-6 2:1.0.3-7 X11 client-side library
ii libxext6 1:1.0.3-2 X11 miscellaneous extension librar
ii libxmu6 1:1.0.3-1 X11 miscellaneous utility library
ii libxpm4 1:3.5.7-1 X11 pixmap library
ii libxt6 1:1.0.5-3 X11 toolkit intrinsics library
ii xaw3dg 1.5+E-15 Xaw3d widget set
ii zlib1g 1:1.2.3.3.dfsg-7 compression library - runtime
emacs22 recommends no packages.
-- no debconf information
Information forwarded to debian-bugs-dist@lists.debian.org, Rob Browning <rlb@defaultvalue.org>:
Bug#454554; Package emacs22.
(full text, mbox, link).
Acknowledgement sent to Martin Pitt <mpitt@debian.org>:
Extra info received and forwarded to list. Copy sent to Rob Browning <rlb@defaultvalue.org>.
(full text, mbox, link).
Message #10 received at 454554@bugs.debian.org (full text, mbox, reply):
[Message part 1 (text/plain, inline)]
Hi!
> As a result of http://bugs.debian.org/343268, sudo now uses a
> grandiloquent prompt:
>
> [sudo] password for twb:
>
> This is not matched by M-x shell's password regexp, so the user is
> suddenly faced with their passwords being echoed to the screen.
Just like gksu, everything that parses the output of sudo has to use
-p to set a custom prompt. Relying on "Password:" is doomed to fail:
- Users of sudo could configure a different prompt in earlier
versions, too.
- Current sudo is i18n'ed, and thus will output the translated
version of "Password:" now.
- If you use additional PAM modules (like pam-thinkfinger) these will
modify the password prompt, too.
So reverting #343268 wouldn't fix this at all.
> PPS: this issue has affected Ubuntu Gutsy for some time. Because
> Ubuntu makes it difficult for tty users to report bugs, I do not
> report bugs to them, instead waiting until they can be reproduced on
> Debian.
You can send Ubuntu bugs by mail [1] or use a text mode browser.
Or just mail me directly.
Thanks,
Martin
[1] https://help.launchpad.net/BugTrackerEmailInterface
--
Martin Pitt http://www.piware.de
Ubuntu Developer http://www.ubuntu.com
Debian Developer http://www.debian.org
[signature.asc (application/pgp-signature, inline)]
Information forwarded to debian-bugs-dist@lists.debian.org, Rob Browning <rlb@defaultvalue.org>:
Bug#454554; Package emacs22.
(full text, mbox, link).
Acknowledgement sent to Sven Joachim <svenjoac@gmx.de>:
Extra info received and forwarded to list. Copy sent to Rob Browning <rlb@defaultvalue.org>.
(full text, mbox, link).
Message #15 received at 454554@bugs.debian.org (full text, mbox, reply):
tags 454554 + fixed-upstream
thanks
On 2007-12-06 08:17 +0100, Trent W. Buck wrote:
> As a result of http://bugs.debian.org/343268, sudo now uses a
> grandiloquent prompt:
>
> [sudo] password for twb:
>
> This is not matched by M-x shell's password regexp, so the user is
> suddenly faced with their passwords being echoed to the screen.
>
> Either #343268 should be reverted, or shell.el's regexp should be
> extended to work around this madness.
>
> See function comint-watch-for-password-prompt and variable
> comint-password-prompt-regexp.
Thanks for the report, comint-password-prompt-regexp has been changed
upstream after a Gutsy user reported this. The fix will be in Emacs
22.2, here is how you can set comint-password-prompt-regexp:
(setq comint-password-prompt-regexp
"\\(\\([Oo]ld \\|[Nn]ew \\|'s \\|login \\|\
Kerberos \\|CVS \\|UNIX \\| SMB \\|LDAP \\|\\[sudo] \\|^\\)\
\[Pp]assword\\( (again)\\)?\\|\
pass phrase\\|\\(Enter \\|Repeat \\|Bad \\)?[Pp]assphrase\\)\
\\(?:, try again\\)?\\(?: for [^:]+\\)?:\\s *\\'")
Regards,
Sven
Tags added: fixed-upstream
Request was from Sven Joachim <svenjoac@gmx.de>
to control@bugs.debian.org.
(Thu, 06 Dec 2007 16:36:07 GMT) (full text, mbox, link).
Information forwarded to debian-bugs-dist@lists.debian.org, Rob Browning <rlb@defaultvalue.org>:
Bug#454554; Package emacs22.
(full text, mbox, link).
Acknowledgement sent to "Trent W\. Buck" <trentbuck@gmail.com>:
Extra info received and forwarded to list. Copy sent to Rob Browning <rlb@defaultvalue.org>.
(full text, mbox, link).
Message #22 received at 454554@bugs.debian.org (full text, mbox, reply):
[Message part 1 (text/plain, inline)]
On Thu, Dec 06, 2007 at 05:35:00PM +0100, Sven Joachim wrote:
>> As a result of http://bugs.debian.org/343268 [...] "[sudo]
>> password for twb:" is not matched by M-x shell's password regexp
>
> Thanks for the report, comint-password-prompt-regexp has been
> changed upstream after a Gutsy user reported this. The fix will be
> in Emacs 22.2, here is how you can set
> comint-password-prompt-regexp:
>
> (setq comint-password-prompt-regexp
> "\\(\\([Oo]ld \\|[Nn]ew \\|'s \\|login \\|\
> Kerberos \\|CVS \\|UNIX \\| SMB \\|LDAP \\|\\[sudo] \\|^\\)\
> \[Pp]assword\\( (again)\\)?\\|\
> pass phrase\\|\\(Enter \\|Repeat \\|Bad \\)?[Pp]assphrase\\)\
> \\(?:, try again\\)?\\(?: for [^:]+\\)?:\\s *\\'")
Thank you. Because I am an rx fan, I took a moment to translate this
to rx (hopefully correctly). I include it below for the benefit of
others trawling the BTS. The predicate attempts to apply the patch to
only those versions for which this has not been fixed upstream.
(when (or (< emacs-major-version 22)
(and (= emacs-major-version 22)
(< emacs-minor-version 2)))
(setq comint-password-prompt-regexp
(or "\\(?:\\(?:\\(?:\\(?:Old\\|old\\|New\\|new\\|'s \\|login \\|Kerberos \\|CVS \\|UNIX \\| SMB \\|LDAP \\|\\[sudo] \\|^\\)\\(?:[Pp]assword\\)\\(?: (again)\\)?\\)\\|pass phrase\\|\\(?:\\(?:\\(?:Bad\\|Enter\\|Repeat\\) \\)?\\(?:[Pp]assphrase\\)\\)\\)\\(?:, try again\\)?\\(?: for [^:]+\\)?:\\(?:\\s-\\)*\\'\\)"
;; pre-compiled above to avoid requiring rx at boot
(rx (| (: (| "Old" "old" "New" "new" "'s " "login "
"Kerberos " "CVS " "UNIX " " SMB "
"LDAP " "[sudo] " ; added
bol)
(| "Password" "password")
(? " (again)"))
"pass phrase"
;; changed
(: (? (| "Enter" "Repeat" "Bad") " ")
(| "Passphrase" "passphrase")))
(? ", try again")
(? " for " (+ (not (any ":"))))
":"
(* (syntax whitespace))
eos))))
[signature.asc (application/pgp-signature, inline)]
Reply sent to Sven Joachim <svenjoac@gmx.de>:
You have taken responsibility.
(full text, mbox, link).
Notification sent to "Trent W\. Buck" <trentbuck@gmail.com>:
Bug acknowledged by developer.
(full text, mbox, link).
Message #27 received at 454554-done@bugs.debian.org (full text, mbox, reply):
package: emacs22
version: 22.2+1-1
On 2007-12-06 17:35 +0100, Sven Joachim wrote:
> tags 454554 + fixed-upstream
> thanks
>
> On 2007-12-06 08:17 +0100, Trent W. Buck wrote:
>
>> As a result of http://bugs.debian.org/343268, sudo now uses a
>> grandiloquent prompt:
>>
>> [sudo] password for twb:
>>
>> This is not matched by M-x shell's password regexp, so the user is
>> suddenly faced with their passwords being echoed to the screen.
>>
>> Either #343268 should be reverted, or shell.el's regexp should be
>> extended to work around this madness.
>>
>> See function comint-watch-for-password-prompt and variable
>> comint-password-prompt-regexp.
>
> Thanks for the report, comint-password-prompt-regexp has been changed
> upstream after a Gutsy user reported this. The fix will be in Emacs
> 22.2,
Which has now been uploaded to Debian, so I'm closing the bug.
Cheers,
Sven
Bug archived.
Request was from Debbugs Internal Request <owner@bugs.debian.org>
to internal_control@bugs.debian.org.
(Thu, 31 Jul 2008 07:33:50 GMT) (full text, mbox, link).
Send a report that this bug log contains spam.
Debian bug tracking system administrator <owner@bugs.debian.org>.
Last modified:
Fri Jan 5 15:50:59 2018;
Machine Name:
buxtehude
Debian Bug tracking system
Debbugs is free software and licensed under the terms of the GNU
Public License version 2. The current version can be obtained
from https://bugs.debian.org/debbugs-source/.
Copyright © 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson,
2005-2017 Don Armstrong, and many other contributors.