all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Lars Ingebrigtsen <larsi@gnus.org>
To: "Jan Synáček" <jan.synacek@gmail.com>
Cc: 56336@debbugs.gnu.org
Subject: bug#56336: 28.1.90; [28.1] Emacs prompts for password when output from async command contains "password:"
Date: Mon, 04 Jul 2022 12:53:18 +0200	[thread overview]
Message-ID: <87czel87z5.fsf@gnus.org> (raw)
In-Reply-To: <CACA+5f3qCVp8nQgz3NAmLJp8m=fQhqyrNcX0-GW+OqmDxGuMRg@mail.gmail.com> ("Jan Synáček"'s message of "Sun, 3 Jul 2022 18:54:10 +0200")

Jan Synáček <jan.synacek@gmail.com> writes:

> Well, I know about one thing that might work well enough as an
> additional heuristic just for this case.
>
> It seems that if a command only outputs to stdout (and probably to
> stderr as well) and doesn't really ask for input, lsof -p <that async
> process> shows something like this:
> $ lsof -p 145475

[...]

> Note the /dev/tty in the output. I'm not sure, but I think this might
> be good enough.

It's not portable across operating systems, though.  (And the processes
may play shenanigans with detaching and spawning other processes that
then ask for a password (think xdg-open and friends), so it's not
reliable on Linux either.)

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





      reply	other threads:[~2022-07-04 10:53 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-01 12:03 bug#56336: 28.1.90; [28.1] Emacs prompts for password when output from async command contains "password:" Jan Synáček
2022-07-02 12:28 ` Lars Ingebrigtsen
2022-07-03  7:53   ` miha--- via Bug reports for GNU Emacs, the Swiss army knife of text editors
2022-07-03 12:19     ` Lars Ingebrigtsen
2022-08-02 11:02       ` Lars Ingebrigtsen
2022-07-03 16:54   ` Jan Synáček
2022-07-04 10:53     ` Lars Ingebrigtsen [this message]

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=87czel87z5.fsf@gnus.org \
    --to=larsi@gnus.org \
    --cc=56336@debbugs.gnu.org \
    --cc=jan.synacek@gmail.com \
    /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.