From charlesreid1

This guide assumes you're using SSH on local port 2222 to connect to stunnel on port 443 with the remote stunnel server.

Steps for starting up a Raspberry Pi Stunnel SSH chain. Also see Stunnel/SSH

Server side:

  • (Optionally, use docker to run stunnel and ssh servers.)
  • Fire up ssh server (locally bound port only), listening on port 22 (or ssh docker container)
  • Fire up stunnel server, listening on port 443 and forwarding to local port 22 (or stunnel docker container)
  • Open firewall script

For dockerfile for stunnel see https://git.charlesreid1.com/docker/d-stunnel

Client side:

  • Configure stunnel using SSH over 443 config file (see git repo link below or Stunnel/SSH)
  • Fire up stunnel client, listening on local port 2222 and forwarding to port 443
  • Connect to local port 2222 via ssh, logging in with whatever credentials on the remote machine you want (or have, depending on who ran the stunnel server).

Connect to localhost, not the remote server:

$ ssh -p 2222 root@localhost

Note: to debug, see Stunnel/Debugging.

For stunnel config on raspberry pi see https://git.charlesreid1.com/rpi/pi-stunnel

For stunnel config on mac see https://git.charlesreid1.com/mac/m-stunnel


Flags