SSH Port Forwarding: Difference between revisions
Jump to navigation
Jump to search
Line 24: | Line 24: | ||
<source lang="ini" highlight="3" start="86" line> | <source lang="ini" highlight="3" start="86" line> | ||
#AllowAgentForwarding yes | #AllowAgentForwarding yes | ||
AllowTcpForwarding yes | |||
GatewayPorts clientspecified | GatewayPorts clientspecified | ||
X11Forwarding yes | X11Forwarding yes | ||
Line 44: | Line 44: | ||
systemctl restart sshd | systemctl restart sshd | ||
service sshd restart | service sshd restart | ||
</source> | |||
<source lang="bash"> | |||
ssh [email protected] -R 10.19.83.10:80:cdn.chorke.org:1983 | |||
ssh [email protected] -R 10.19.83.10:80:localhost:1983 | |||
ssh [email protected] -R 10.19.83.10:80:0.0.0.0:1983 | |||
ssh [email protected] -R 10.19.83.10:80::1983 | |||
ssh [email protected] -R localhost:80::1983 | |||
ssh [email protected] -R 80:1983 | |||
ssh [email protected] -R 80 | |||
</source> | </source> | ||
Revision as of 08:23, 30 May 2020
Local Forwarding
Python Flask ssh -L 5000:localhost:5000 [email protected] http://localhost:5000/
RabbitMQ ssh -L 15672:localhost:15672 [email protected] http://localhost:15672/ username: guest password: guest
Node Red ssh -L 1880:localhost:1880 [email protected] http://localhost:1880/
Mosquitto ssh -L 1883:localhost:1883 [email protected]
Remote Forwarding
nano /etc/ssh/sshd_config
GatewayPorts no|yes| clientspecified
#AllowAgentForwarding yes
AllowTcpForwarding yes
GatewayPorts clientspecified
X11Forwarding yes
#X11DisplayOffset 10
#X11UseLocalhost yes
#PermitTTY yes
PrintMotd no
#PrintLastLog yes
#TCPKeepAlive yes
Match User pi
AllowTcpForwarding yes
GatewayPorts yes
systemctl restart sshd
service sshd restart
ssh [email protected] -R 10.19.83.10:80:cdn.chorke.org:1983
ssh [email protected] -R 10.19.83.10:80:localhost:1983
ssh [email protected] -R 10.19.83.10:80:0.0.0.0:1983
ssh [email protected] -R 10.19.83.10:80::1983
ssh [email protected] -R localhost:80::1983
ssh [email protected] -R 80:1983
ssh [email protected] -R 80