*filter
:INPUT DROP [2:80]
:FORWARD DROP [2:104]
:OUTPUT ACCEPT [7824:1650359]
:l - [0:0]
-A INPUT -i lo -j ACCEPT
-A INPUT -m state --state RELATED,ESTABLISHED -j ACCEPT
-A INPUT -p tcp -m tcp --dport 22 -j ACCEPT
-A INPUT -p tcp -m tcp --dport 4444 -j ACCEPT
-A INPUT -p tcp -m tcp --dport 80 -j ACCEPT
-A INPUT -p tcp -m tcp --dport 443 -j ACCEPT
-A INPUT -p tcp -m tcp --dport 8095 -j ACCEPT
-A INPUT -p udp -m udp --dport 5060 -j ACCEPT
-A INPUT -p udp -m udp --dport 5061 -j ACCEPT
-A INPUT -p udp -m udp --dport 5090 -j ACCEPT
-A INPUT -p udp -m udp --dport 5080 -j ACCEPT
-A INPUT -p udp -m udp --dport 5085 -j ACCEPT
-A INPUT -p tcp -m tcp --dport 5060 -j ACCEPT
-A INPUT -p tcp -m tcp --dport 5061 -j ACCEPT
-A INPUT -p udp -m udp --dport 10000:20000 -j ACCEPT
-A INPUT -p tcp -m tcp --dport 5432 -j ACCEPT
-A INPUT -p tcp -m tcp --dport 9090 -j ACCEPT
-A INPUT -p tcp -m tcp --dport 2222 -j ACCEPT
-A INPUT -p tcp -m tcp --dport 3306 -j ACCEPT
-A FORWARD -m state --state RELATED,ESTABLISHED -j ACCEPT
-A FORWARD -p tcp -m tcp --dport 4444 -j ACCEPT
COMMIT
# Completed on Sat Nov 11 19:57:24 2017
# Generated by iptables-save v1.4.21 on Sat Nov 11 19:57:24 2017
*nat
:PREROUTING ACCEPT [2:695]
:INPUT ACCEPT [1:655]
:OUTPUT ACCEPT [0:0]
:POSTROUTING ACCEPT [0:0]
-A PREROUTING -i eno16777984 -p tcp -m tcp --dport 4444 -j DNAT --to-destination 192.168.1.2:22
-A POSTROUTING -d 192.168.1.2/32 -p tcp -m tcp --sport 22 -j SNAT --to-source 192.168.1.6:22
-A POSTROUTING -s 192.168.1.6/32 -p tcp -m tcp --sport 4444 -j SNAT --to-source 192.168.1.2:22
COMMIT
# Completed on Sat Nov 11 19:57:24 2017
Вопрос переделал но проблема с вложенными файлами неккоректно отображаються
https://play.golang.com/p/Hke6YpA33xQ