Skip to content

Instantly share code, notes, and snippets.

@jlis
Created September 29, 2021 10:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jlis/a1eeb97d2b3b01298fb5215029dacc2e to your computer and use it in GitHub Desktop.
Save jlis/a1eeb97d2b3b01298fb5215029dacc2e to your computer and use it in GitHub Desktop.
HTTP tunnel via SSH
# Install asyncssh (https://github.com/ronf/asyncssh) via Pip
pip3 install asyncssh
# Install pproxy (https://github.com/qwj/python-proxy) via Pip
pip3 install pproxy
# Start pproxy to connect to remote host via SSH using username and private key, listening on localhost:8080
pproxy -l http://:8080 -r ssh://<REMOTE HOST IP/HOSTNAME>/#<SSH USER NAME>::<ABSOLUTE PATH TO SSH PRIVATE KEY>
# Start pproxy to connect to remote host via SSH using username and password, listening on localhost:8080
#pproxy -l http://:8080 -r ssh://<REMOTE HOST IP/HOSTNAME>/#<SSH USER NAME>:<SSH PASSWORD>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment