iptables 端口轉發

ssh 也能實現本機的端口轉發,只不過原來的 1 條鏈接會變成 3 條。詳情見前一篇 ssh 端口轉發博文。而 iptables 的端口轉發則是在內核進行。bash 一、將本地的端口轉發到本機端口 將本機的 7777 端口轉發到 6666 端口。ssh iptables -t nat -A PREROUTING -p tcp --dport 7777 -j REDIRECT --to-port 6
相關文章
相關標籤/搜索