On Fri, May 15, 2026 at 01:05:30PM +0200, Michal Privoznik via Devel wrote:
> See 3/3 for in depth explanation.
> After this, there's still one problem - the ssh transport (tcp+ssh://...)
> because virNetSocketNewConnectSSH() does not really ask for
> virConnectAuthCallbackPtr. There should be a way to fix it though: from
> bash script parse URI and append ?no_tty=1 at the end of URI. This
> directs virNetSocketNewConnectSSH() to execute SSH binary with
> BatchMode=yes which is documented to suppress keyboard interaction.
>
> If we find this ^^ needed I can try to write a patch. But for now, let's
> fix other transports.
>
> Michal Prívozník (3):
> virnetsshsession: Don't check for auth callbacks in
> virNetSSHAuthenticatePassword()
> virnetlibsshsession: Check later for auth callback in
> virNetLibsshAuthenticatePassword()
> virsh: Provide no auth callbacks for bash completer
>
> src/rpc/virnetlibsshsession.c | 14 +++++++-------
> src/rpc/virnetsshsession.c | 7 -------
> tools/virsh.c | 10 +++++++++-
> 3 files changed, 16 insertions(+), 15 deletions(-)
I tested the series. I had to use 'build/run bash' to set shell
variables so that the virsh subcommand would use the patched version.
I also strace'd that bash so I could be doubly sure it was running the
'virsh complete' subcommand:
2600499 execve("/home/rjones/d/libvirt/build/tools/virsh", ["virsh", "-q",
"-c", "esx://root@[redacted]"..., "complete", "--", ""], 0x561fdfcd7000 /* 80
vars */) = 0
Anyhow it fixes the issue I was having, so:
Tested-by: Richrad W.M. Jones <[email protected]>
Rich.
--
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
Fedora Windows cross-compiler. Compile Windows programs, test, and
build Windows installers. Over 100 libraries supported.
http://fedoraproject.org/wiki/MinGW