From: Stefan Kangas <stefan@marxist.se>
To: Marcin Borkowski <mbork@amu.edu.pl>
Cc: aurelien <aurelien@hackers.camp>,
Stefan Monnier <monnier@iro.umontreal.ca>,
20910@debbugs.gnu.org
Subject: bug#20910: 24.4; *shell* write the password in clear in the buffer on git push
Date: Sun, 6 Oct 2019 03:46:06 +0200 [thread overview]
Message-ID: <CADwFkmkGfKGVbw70q4AnGgtp-gFBe5SVY=hkZA5NaU3yJfcx=w@mail.gmail.com> (raw)
In-Reply-To: <87mvzlr55n.fsf@xload.home>
Marcin Borkowski <mbork@amu.edu.pl> writes:
> On 2015-06-27, at 10:51, Stefan Monnier <monnier@IRO.UMontreal.CA> wrote:
>
>>> M-x shell
>>> git add mysupersoftware.py
>>> git commit -m "pay attention of the pep8 thanks M-x py-pep8-run"
>>> git push
>>> shell $ request for the password of the git, and print it in clear in
>>> the buffer
>>
>> Can you show us the actual password prompt (which is the only info that
>> Emacs gets that a password is being requested, so it needs to recognize
>> it, and those prompts change with language settings and stuff, so it's
>> very heuristic and messy).
>
> I suspect that this might depend on Git version and configuration, and
> things like gpg-agent. In my case, it displayed a window (in WM sense,
> not in Emacs sense) asking for password, and only after clicking
> "Cancel", it asked within Emacs. The prompt was:
>
> Password for 'https://mbork@github.com':
>
> and indeed the characters of the password were visible.
>
>> Stefan
>
> Best,
Hi Marcin,
When I try the following on Emacs 26.1, I get no error:
(progn
(require 'comint)
(or
(string-match comint-password-prompt-regexp
"Password for 'https://foo@example.org: ")
(error "NO MATCH")))
This suggests to me that a prompt such as the above should work under
M-x shell, since that is built on top of comint.
Could you verify that this works for you on Emacs 26.1 or later?
Best regards,
Stefan Kangas
next prev parent reply other threads:[~2019-10-06 1:46 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-06-27 7:17 bug#20910: 24.4; *shell* write the password in clear in the buffer on git push aurelien
[not found] ` <handler.20910.B.143538951822696.ack@debbugs.gnu.org>
2015-06-27 7:32 ` bug#20910: Acknowledgement (24.4; *shell* write the password in clear in the buffer on git push) aurelien
2015-06-27 14:51 ` bug#20910: 24.4; *shell* write the password in clear in the buffer on git push Stefan Monnier
2016-04-23 8:45 ` Marcin Borkowski
2019-10-06 1:46 ` Stefan Kangas [this message]
2019-11-07 0:49 ` Stefan Kangas
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CADwFkmkGfKGVbw70q4AnGgtp-gFBe5SVY=hkZA5NaU3yJfcx=w@mail.gmail.com' \
--to=stefan@marxist.se \
--cc=20910@debbugs.gnu.org \
--cc=aurelien@hackers.camp \
--cc=mbork@amu.edu.pl \
--cc=monnier@iro.umontreal.ca \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.