Skip to content

Instantly share code, notes, and snippets.

@justinc1
justinc1 / ssho2o.py
Created February 20, 2024 16:58
VPN over SSH port forward helper. It generates opts for ssh binary.
#!/usr/bin/env python3
import sys
from dataclasses import dataclass
_help_text="""VPN over SSH port forward helper. It generates opts for ssh binary.
Usage1: {sys.argv[0]} -L hostA port1 port2 -R hostB port3
Usage2 - ssh to bastionA to gain "direct" access to hostA ports 8080 and 8443