포트포워딩을 통해 ssh로 접속하려고 합니다. 이것은 내 SSH 구성 파일입니다.
HOST A
HostName B
user C
DynamicForward 0.0.0.0:1081
"ssh A"를 실행하면 다음과 같은 결과가 나타납니다.
channel 5: open failed: administratively prohibited: open failed
channel 7: open failed: administratively prohibited: open failed
channel 10: open failed: administratively prohibited: open failed
channel 12: open failed: administratively prohibited: open failed
....
비슷한 질문을 보고 서버의 SSH 구성에서 이러한 플래그를 테스트했지만 그 중 아무 것도 작동하지 않았습니다.
PermitTunnel yes
AllowTcpForwarding yes
AllowTunnel yes
PermitOpen yes
이것은 "ssh -v A"의 결과입니다.
debug1: channel 3: new [dynamic-tcpip]
debug1: Connection to port 1081 forwarding to socks port 0 requested.
debug1: channel 5: new [dynamic-tcpip]
debug1: Connection to port 1081 forwarding to socks port 0 requested.
debug1: channel 6: new [dynamic-tcpip]
channel 5: open failed: administratively prohibited: open failed
debug1: channel 5: free: direct-tcpip: listening port 1081 for 2001:b28:f23f:f005::a port 443, connect from 127.0.0.1 port 53584 to 127.0.0.1 port 1081, nchannels 7
debug1: Connection to port 1081 forwarding to socks port 0 requested.
debug1: channel 5: new [dynamic-tcpip]
debug1: Connection to port 1081 forwarding to socks port 0 requested.
debug1: channel 7: new [dynamic-tcpip]
debug1: Connection to port 1081 forwarding to socks port 0 requested.
debug1: channel 8: new [dynamic-tcpip]
channel 7: open failed: administratively prohibited: open failed
debug1: channel 7: free: direct-tcpip: listening port 1081 for 2001:b28:f23f:f005::a port 443, connect from 127.0.0.1 port 53590 to 127.0.0.1 port 1081, nchannels 9
debug1: Connection to port 1081 forwarding to socks port 0 requested.
debug1: channel 7: new [dynamic-tcpip]
debug1: Connection to port 1081 forwarding to socks port 0 requested.
debug1: channel 9: new [dynamic-tcpip]
debug1: Connection to port 1081 forwarding to socks port 0 requested.
debug1: channel 10: new [dynamic-tcpip]
channel 9: open failed: administratively prohibited: open failed
debug1: channel 9: free: direct-tcpip: listening port 1081 for 2001:b28:f23d:f001::a port 443, connect from 127.0.0.1 port 53596 to 127.0.0.1 port 1081, nchannels 11
debug1: Connection to port 1081 forwarding to socks port 0 requested.
debug1: channel 9: new [dynamic-tcpip]
debug1: Connection to port 1081 forwarding to socks port 0 requested.
debug1: channel 11: new [dynamic-tcpip]
debug1: Connection to port 1081 forwarding to socks port 0 requested.
debug1: channel 12: new [dynamic-tcpip]
channel 11: open failed: administratively prohibited: open failed
debug1: channel 11: free: direct-tcpip: listening port 1081 for 2001:b28:f23d:f001::a port 443, connect from 127.0.0.1 port 53602 to 127.0.0.1 port 1081, nchannels 13
debug1: Connection to port 1081 forwarding to socks port 0 requested.
debug1: channel 11: new [dynamic-tcpip]
이것은 내 sshd_config 파일입니다.
ChallengeResponseAuthentication no
UsePAM yes
AllowTcpForwarding yes
X11Forwarding yes
PrintMotd no
Banner /etc/issue.net
AcceptEnv LANG LC_*
Subsystem sftp /usr/lib/openssh/sftp-server
ClientAliveInterval 120
PasswordAuthentication yes