Hi,
on my server, I am running lsh-server 2.1-12 and trying to connect via OpenSSH_8.2p1 on client side.
On server, a user with passwordless sudo exists.
--------------------------- user ALL=(ALL) NOPASSWD:ALL ---------------------------
From client side, I try (in different combinations)
$ sshpass -p xxx ssh -t -i /tmp/test_id_rsa.pub -o KexAlgorithms=diffie-hellman-group1-sha1 -o Ciphers=aes256-cbc user@$server 'sudo shutdown -h now'
I have to mention, that an ssh-copy-id with...
$ sshpass -p xxx ssh-copy-id -i /tmp/test_id_rsa.pub -o KexAlgorithms=diffie-hellman-group1-sha1 -o Ciphers=aes256-cbc user@$server
...seems not to work, too.
What I get:
[sudo] password for user:
or
sudo: a password is required
or
sudo: no tty present and no askpass program specified
Does someone in the group have the knowledge hot to connect correctly?
Many thanks! Will Code
"will.code.for.pizza@gmail.com" will.code.for.pizza@gmail.com writes:
on my server, I am running lsh-server 2.1-12 and trying to connect via OpenSSH_8.2p1 on client side.
Hi, I think tty support should be enabled by default in lshd version 2.1. The option to explicitly disable it is --no-pty-support.
Can't say why that doesn't work for you, without more information.
(That said, lsh and lshd aren't well maintained these days).
Regards, /Niels