SSH 터널링을 위한 간단한 bash 스크립트가 있습니다.
createTunnel() {
/usr/bin/ssh -i /home/miner/EC2.pem -f -N -R 10022:localhost:22 -L 19922:[email protected]:22 [email protected]
if [[ $? -eq 0 ]]; then
echo Tunnel created successfully
else
echo An error occurred
fi
}
/usr/bin/ssh -p 19922 localhost ls > /dev/null
if [[ $? -ne 0 ]]; then
echo Creating new tunnel
createTunnel
fi
실행하면 다음 오류가 발생합니다. 가능한 이유는 무엇입니까?
channel_setup_fwd_listener: cannot listen to port: 10022
channel_setup_fwd_listener_tcpip: cannot listen to port: 19922
channel 2: open failed: administratively prohibited: open failed
channel 3: open failed: administratively prohibited: open failed