Вобщем имееца железка D-link DIR 615 с установленным на нем линуксом dd-wrt. На борту WAN, 4 LAN, WLAN и поднят PPTP VPN сервер.
eth0 это wan br0 это обьединённые вайфай и лан ppp0 впн клиент
Народ из локалки прекрасно ходит в инет. Через впн в ван летает только ICMP. А мне надо, чтоб впн клиент коннектился, и без ограничений мог работать и с локалкой и с ваном. С ваном даже нужнее. Вот такая вот глупость, с вана цепляют впн и тудаже чтоб всё ходило.
ath0 Link encap:Ethernet HWaddr 00:18:E7:D0:D7:A0 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:1441 errors:0 dropped:0 overruns:0 frame:0 TX packets:1325 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:106934 (104.4 KiB) TX bytes:170661 (166.6 KiB)
br0 Link encap:Ethernet HWaddr 00:18:E7:D0:D7:A0 inet addr:192.168.1.1 Bcast:192.168.1.255 Mask:255.255.255.0 UP BROADCAST RUNNING PROMISC MULTICAST MTU:1500 Metric:1 RX packets:59791 errors:0 dropped:0 overruns:0 frame:0 TX packets:72215 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:5040496 (4.8 MiB) TX bytes:85553467 (81.5 MiB)
br0:0 Link encap:Ethernet HWaddr 00:18:E7:D0:D7:A0 inet addr:169.254.255.1 Bcast:169.254.255.255 Mask:255.255.0.0 UP BROADCAST RUNNING PROMISC MULTICAST MTU:1500 Metric:1
eth0 Link encap:Ethernet HWaddr 00:18:E7:D0:D7:A0 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:58458 errors:0 dropped:0 overruns:0 frame:0 TX packets:72051 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:5777156 (5.5 MiB) TX bytes:85636887 (81.6 MiB)
eth1 Link encap:Ethernet HWaddr 00:18:E7:D0:D7:A1 inet addr:83.172.21.192 Bcast:83.172.21.255 Mask:255.255.255.0 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:181200 errors:0 dropped:0 overruns:0 frame:0 TX packets:66359 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:95890524 (91.4 MiB) TX bytes:6311069 (6.0 MiB)
lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 UP LOOPBACK RUNNING MULTICAST MTU:16436 Metric:1 RX packets:0 errors:0 dropped:0 overruns:0 frame:0 TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:0 (0.0 B) TX bytes:0 (0.0 B)
ppp0 Link encap:Point-to-Point Protocol inet addr:192.168.1.2 P-t-P:192.168.1.105 Mask:255.255.255.255 UP POINTOPOINT RUNNING NOARP MULTICAST MTU:1400 Metric:1 RX packets:71 errors:0 dropped:0 overruns:0 frame:0 TX packets:40 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:3 RX bytes:6614 (6.4 KiB) TX bytes:5119 (4.9 KiB)
wifi0 Link encap:Ethernet HWaddr 00:18:E7:D0:D7:A0 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:5514 errors:0 dropped:0 overruns:0 frame:12077 TX packets:1651 errors:1 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:499 RX bytes:544602 (531.8 KiB) TX bytes:265486 (259.2 KiB) Interrupt:2 Memory:b80c0000-b8100000
root@DD-WRT:~# route Kernel IP routing table Destination Gateway Genmask Flags Metric Ref Use Iface 83.172.21.1 * 255.255.255.255 UH 0 0 0 eth1 192.168.1.105 * 255.255.255.255 UH 0 0 0 ppp0 192.168.1.0 * 255.255.255.0 U 0 0 0 br0 83.172.21.0 * 255.255.255.0 U 0 0 0 eth1 169.254.0.0 * 255.255.0.0 U 0 0 0 br0 127.0.0.0 * 255.0.0.0 U 0 0 0 lo default sib-gw.sibinet. 0.0.0.0 UG 0 0 0 eth1
root@DD-WRT:~# iptables -t nat -L Chain PREROUTING (policy ACCEPT) target prot opt source destination DNAT udp — anywhere anywhere udp spt:discard to:192.168.1.255 DNAT tcp — anywhere sib-192.sibinet.com tcp dpt:webcache to:192.168.1.1:80 DNAT tcp — anywhere sib-192.sibinet.com tcp dpt:telnet to:192.168.1.1:23 DNAT icmp — anywhere sib-192.sibinet.com to:192.168.1.1 TRIGGER 0 — anywhere sib-192.sibinet.com TRIGGER type:dnat match:0 relate:0
Chain POSTROUTING (policy ACCEPT) target prot opt source destination SNAT 0 — anywhere anywhere to:83.172.21.192 RETURN 0 — anywhere anywhere PKTTYPE = broadcast MASQUERADE 0 — 192.168.1.0/24 192.168.1.0/24
Chain OUTPUT (policy ACCEPT) target prot opt source destination
root@DD-WRT:~# iptables -L Chain INPUT (policy ACCEPT) target prot opt source destination ACCEPT 0 — anywhere anywhere DROP tcp — anywhere anywhere tcp dpt:ssh DROP tcp — anywhere anywhere tcp dpt:ssh
Chain FORWARD (policy ACCEPT) target prot opt source destination ACCEPT 0 — anywhere anywhere TCPMSS tcp — anywhere anywhere tcp flags:SYN,RST/SYN TCPMSS clamp to PMTU ACCEPT 0 — anywhere anywhere TCPMSS tcp — anywhere anywhere tcp flags:SYN,RST/SYN TCPMSS clamp to PMTU lan2wan 0 — anywhere anywhere ACCEPT 0 — anywhere anywhere state RELATED,ESTABLISHED TRIGGER 0 — anywhere anywhere TRIGGER type:in match:0 relate:0 trigger_out 0 — anywhere anywhere ACCEPT 0 — anywhere anywhere state NEW
Chain OUTPUT (policy ACCEPT) target prot opt source destination
Chain lan2wan (1 references) target prot opt source destination
Chain logaccept (0 references) target prot opt source destination ACCEPT 0 — anywhere anywhere
Chain logdrop (0 references) target prot opt source destination DROP 0 — anywhere anywhere
Chain logreject (0 references) target prot opt source destination REJECT tcp — anywhere anywhere tcp reject-with tcp-reset
Chain trigger_out (1 references) target prot opt source destination
какое долбаное правило надо добавить в iptables, чтоб впн ходил безпрепятственно в ван? 3 дня маюсь, перепробовал уже всё чо тока можно.