Skip to content

Instantly share code, notes, and snippets.

View Ansen's full-sized avatar
🐶
Working all day

An Ansen

🐶
Working all day
View GitHub Profile
@Ansen
Ansen / port_forward_ipv4_ipv6.sh
Created November 16, 2022 02:22 — forked from dmazzer/port_forward_ipv4_ipv6.sh
Forwarding IPv4 Ports to IPv6 Hosts
#!/bin/bash
# UDP:
socat UDP4-LISTEN:5683,fork,su=nobody UDP6:[aaaa::212:4b00:615:a1f7]:5683
# TCP:
socat TCP4-LISTEN:22,fork,su=nobody TCP6:[2a01:198:79d:1::8]:22
# UDP, IPv6
socat UDP6-LISTEN:5683,fork,su=nobody UDP6:[aaaa::212:4b00:615:a1f7]:5683