Subject: bug#75746: closed (Re: bug#75746: 31.0.50; Can't get password promote from plink 0.82)

From: [email-masked] (GNU bug Tracking System)
Date: Fri, 14 Feb 2025 14:31:02 +0000

Your bug report

#75746: 31.0.50; Can't get password promote from plink 0.82

which was filed against the emacs package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to [email-masked].

-- 
75746: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=75746
GNU Bug Tracking System
Contact [email-masked] with problems

Subject: Re: bug#75746: 31.0.50; Can't get password promote from plink 0.82
From: Michael Albinus <[email-masked]>
To: Eli Zaretskii <[email-masked]>
Cc: [email-masked], [email-masked], [email-masked]
Date: Fri, 14 Feb 2025 15:29:49 +0100
List-Id: <debbugs-submit.debbugs.gnu.org>

Version: 30.2

>> If I call the very same command in a native cmd.exe terminal, evrything
>> works as expected. And so it did inside Emacs prior PuTTY 0.82.
>
> This was a deliberate behaviour change in 0.82, described in the
> following link, which also describes how to restore the old behaviour.
> https://www.chiark.greenend.org.uk/~sgtatham/putty/wishlist/windows-stdio-prompts.html
>
> The proposed option works as expected.

I've adapted the call of plink, pscp, and psftp accordingly. This
requires now at least PuTTY 0.82.

Pushed to the master branch. It will appear also with Tramp 2.7.2.2 on
GNU ELPA, later this month. Closing the bug

Best regards, Michael.

Subject: 31.0.50; Can't get password promote from plink 0.82
From: 孙曙光(Sun Shuguang) <[email-masked]>
To: "[email-masked]" <[email-masked]>
Cc: Shuguang Sun <[email-masked]>
Date: Wed, 22 Jan 2025 01:38:30 +0000
List-Id: <debbugs-submit.debbugs.gnu.org>

Dear,

Emacs (31.0.50, UCRT) can't get the promote for password (and user) from plink 0.82 and pre-release 0.83 in Windows. So that Tramp using plink from windows will not work.

- Emacs -q
- shell (cmd)
- plink -l username -P 22 -ssh -t 192.168.x.x " env 'TERM=dumb' 'PROMPT_COMMAND=' 'PS1=#$ ' /bin/sh " && exit || exit
  The shell echo the username and wait and wait.
- plink -P 22 -ssh -t 192.168.x.x " env 'TERM=dumb' 'PROMPT_COMMAND=' 'PS1=#$ ' /bin/sh " && exit || exit
  The shell has no echo and wait and wait.

In Tramp, it falls into the loop of waiting for promote of password.

Best Regards,
Shuguang

Below is the system info:

In GNU Emacs 31.0.50 (build 1, x86_64-w64-mingw32)
Repository revision: 299a1fbef886dba654f58a0c55b373f8b43d383b
Repository branch: HEAD
Windowing system distributor 'Microsoft Corp.', version 10.0.26100
System Description: Microsoft Windows 10 Home China (v10.0.2009.26100.2894)

Configured using:
 'configure
 --prefix=/d/a/emacs-build/emacs-build/pkg/299a1fb-ucrt-x86_64
 'CFLAGS=-O2 -fno-semantic-interposition -floop-parallelize-all
 -ftree-parallelize-loops=4 -g3 ' --disable-build-details --without-dbus
 --enable-link-time-optimization --with-compress-install
 --with-small-ja-dic --with-gif --with-gnutls --with-harfbuzz
 --with-jpeg --with-json --with-lcms2 --with-native-compilation
 --with-png --with-rsvg --with-tree-sitter --with-xml2 --with-xpm
 --with-zlib --without-cairo --without-mps --without-tiff'

Configured features:
ACL GIF GMP GNUTLS HARFBUZZ JPEG LCMS2 LIBXML2 MODULES NATIVE_COMP
NOTIFY W32NOTIFY PDUMPER PNG RSVG SOUND SQLITE3 THREADS
TOOLKIT_SCROLL_BARS TREE_SITTER WEBP XPM ZLIB