Не работает redirect_port
Добавлено: 2014-05-01 0:23:41
Помогите!!!!
Не пойму что не так. Не работает redirect_port
С rinetd работает
Ядро:
rc.conf
Firewall:
Не пойму что не так. Не работает redirect_port
С rinetd работает
Ядро:
Код: Выделить всё
options IPFIREWALL
options IPFIREWALL_VERBOSE
options IPFIREWALL_VERBOSE_LIMIT=1000
options IPFIREWALL_NAT
options LIBALIAS
options ROUTETABLES=2
options HZ="1000"
options IPFIREWALL_FORWARD
options IPDIVERT
options DUMMYNET
options IPFIREWALL_DEFAULT_TO_ACCEPT
Код: Выделить всё
gateway_enable="YES"
ifconfig_em0="DHCP"
ifconfig_em1="inet 192.168.1.1 netmask 255.255.255.0"
defaultrouter="93.222.33.1"
firewall_enable="YES"
firewall_script="/etc/rc.firewall.firewall"
Код: Выделить всё
FwCMD="/sbin/ipfw"
LanOut="em0"
LanIn="em1"
IpOut="93.222.33.11"
IpIn="192.168.1.1"
${FwCMD} -f flush
${FwCMD} add 100 allow ip from any to any via lo0
${FwCMD} add 200 allow ip from any to any via ${LanIn}
${FwCMD} add 300 allow tcp from any to ${IpOut} 3389 via ${LanOut}
${FwCMD} nat 1 config log if ${LanOut} reset same_ports deny_in redirect_port tcp 192.168.1.39:3389 3389 redirect_port udp 192.168.1.39:3389 3389
${FwCMD} add 400 nat 1 ip from any to any via ${LanOut}
${FwCMD} add 65534 deny all from any to any