Neko Docs

iptables

NAT

iptables 映射保留源IP (不要snat)

入口:

iptables -F -t nat
iptables -t nat -A PREROUTING -p tcp --dport 1024:65000 -j DNAT --to-destination <出口IP>
iptables -t nat -A PREROUTING -p udp --dport 1024:65000 -j DNAT --to-destination <出口IP>

出口:

ip ru add from <入口cidr> lookup 101 && ip ro add default via <入口IP> table 101

On this page