I am trying to run openssh on my openwrt router. To test it, I start openssh via /usr/sbin/sshd -D
. When I try to connect from my computer I get asked for the password and then (if the password is correct) the connection drops and client_loop: send disconnect: Broken pipe
is shown in my terminal (bash, if someone is curious).
Now I tried to debug the problem, but when I run openssh in debug mode via /usr/sbin/sshd -D -d
, then connecting just works and no error is encountered!
What could be the issue and how to fix it?
EDIT: As suggested by Michael Hampton, I had a log at the log using logread.
Sun Sep 26 13:31:40 2021 auth.info sshd[14488]: Accepted password for root from 192.168.2.50 port 48292 ssh2
Sun Sep 26 13:31:40 2021 auth.crit sshd[14488]: fatal: privsep_preauth: preauth child terminated by signal 12
Any ideas of how to fix that?
EDIT2:
Information about the server, as suggested by Dennis Nolte:
OS: openwrt, built from master a couple of days ago
architecture: MIPS
CPU: MediaTek mt7621
kernel version: 5.10.x
openssl version: 1.1.1l
openssh version: 8.7p1
selinux enabled, but logs do not show any denials
PAM is available, but nothing changes if I select UsePAM=yes or no in sshd_config