Sebchr
New Around Here
Hello,
I am using Asus-Merlin on RT-n66u. (great firmware !) and I have trouble with turbo nat. My network is :
Internet----(1.2.3.4)Box-----RT-n66u(192.168.2.254) ----------Server(192.168.2.1)
|---------------Client(192.168.2.249)
Box is used as DMZ to RT-n66u and RT-n66u nat table redirects port 80 to Server
2 monthes ago, my internet provider released a new firmware for my box. In this firmware, loopback is disabled. So, "client" cannot access to Server by using address 1.2.3.4.
So I would like to configure RT-n66u in order to redirect packet from "client" to 1.2.3.4, to Server. So I set following iptabes rules :
iptables -t nat -I PREROUTING -i br0 -d 1.2.3.4 -j DNAT --to-destination 192.168.2.1
iptables -t nat -I POSTROUTING -s 192.168.2.0/24 -d 192.168.2.1 -j MASQUERADE
This configuration is OK if I disable Turbo nat. But if I enable Turbo nat some packet doesn't use Masquerade rule. In fact, I used tcpdump on server :
09:52:38.475055 IP 192.168.2.254.50516 > 192.168.2.1.8080: Flags, seq 3935963517, win 14600, options [mss 1460,sackOK,TS val 35107695 ecr 0,nop,wscale 7], length 0
09:52:38.475128 IP 192.168.2.1.8080 > 192.168.2.254.50516: Flags [S.], seq 1502534616, ack 3935963518, win 14480, options [mss 1460,sackOK,TS val 491531120 ecr 35107695,nop,wscale 6], length 0
09:52:38.475560 IP 192.168.2.254.50516 > 192.168.2.1.8080: Flags [.], ack 1, win 115, options [nop,nop,TS val 35107695 ecr 491531120], length 0
09:52:38.475705 IP 192.168.2.249.50516 > 192.168.2.1.8080: Flags [P.], seq 3935963518:3935964035, ack 1502534617, win 115, options [nop,nop,TS val 35107695 ecr 491531120], length 517
So last line notifies that RT-n66u doesn't apply masquerade rule. But previous packets use masquerade rule.
Why Turbo Nat disable masquerade on some packets?
Best regards
I am using Asus-Merlin on RT-n66u. (great firmware !) and I have trouble with turbo nat. My network is :
Internet----(1.2.3.4)Box-----RT-n66u(192.168.2.254) ----------Server(192.168.2.1)
|---------------Client(192.168.2.249)
Box is used as DMZ to RT-n66u and RT-n66u nat table redirects port 80 to Server
2 monthes ago, my internet provider released a new firmware for my box. In this firmware, loopback is disabled. So, "client" cannot access to Server by using address 1.2.3.4.
So I would like to configure RT-n66u in order to redirect packet from "client" to 1.2.3.4, to Server. So I set following iptabes rules :
iptables -t nat -I PREROUTING -i br0 -d 1.2.3.4 -j DNAT --to-destination 192.168.2.1
iptables -t nat -I POSTROUTING -s 192.168.2.0/24 -d 192.168.2.1 -j MASQUERADE
This configuration is OK if I disable Turbo nat. But if I enable Turbo nat some packet doesn't use Masquerade rule. In fact, I used tcpdump on server :
09:52:38.475055 IP 192.168.2.254.50516 > 192.168.2.1.8080: Flags
09:52:38.475128 IP 192.168.2.1.8080 > 192.168.2.254.50516: Flags [S.], seq 1502534616, ack 3935963518, win 14480, options [mss 1460,sackOK,TS val 491531120 ecr 35107695,nop,wscale 6], length 0
09:52:38.475560 IP 192.168.2.254.50516 > 192.168.2.1.8080: Flags [.], ack 1, win 115, options [nop,nop,TS val 35107695 ecr 491531120], length 0
09:52:38.475705 IP 192.168.2.249.50516 > 192.168.2.1.8080: Flags [P.], seq 3935963518:3935964035, ack 1502534617, win 115, options [nop,nop,TS val 35107695 ecr 491531120], length 517
So last line notifies that RT-n66u doesn't apply masquerade rule. But previous packets use masquerade rule.
Why Turbo Nat disable masquerade on some packets?
Best regards