Hello,
In advance I apologize if I write in the wrong place and also for my English, because I use Google translation.
The current situation :
Asus rt-ac87u merlin firmware router 384_13_1
Qnap ts-251 +
On the qnap I use rtorrent-pro for downloads Like Vpn,
I use PureVpn with the port forwarding addon.
On the Qnap NAS, I see stability concerns for the VPN, so I decided to use the Asus Router for the VPN connection with PureVpn. I configured the client VPN part with the Openvpn files without worry. I have a "kill switch" rule only on the QNAP ip, everything works, well almost. I can download via rtorrent-pro, but sharing does not do it properly, the port use for rtorrent-pro remains closed or in an unknown status. So the shares do not do it correctly. I have obviously enabled port forwarding on the router, but that does not change anything. I also added the port in the Port Trigger tab, so that does not change anything.
After searching the internet I came across the site:
https://airvpn.org/forums/topic/11264-asus-merlin-wrt-port-forwarding-script-setup/
It provides a script to route asus to put in / jffs / script / nat-start
I modify it so that it corresponds to the interface vpn 5 (tun15) and I put the IP address of the NAS.
#!/bin/sh
iptables -I FORWARD -i br0 -o tun15 -j ACCEPT
iptables -I FORWARD -i tun15 -o br0 -j ACCEPT
iptables -I FORWARD -i br0 -o vlan1 -j DROP
iptables -I INPUT -i tun15 -j REJECT
iptables -t nat -A POSTROUTING -o tun15 -j MASQUERADE
iptables -I FORWARD -i tun15 -p udp -d 192.168.X.X --dport XXXXX -j ACCEPT
iptables -I FORWARD -i tun15 -p tcp -d 192.168.X.X --dport XXXXXX -j ACCEPT
iptables -t nat -I PREROUTING -i tun15 -p tcp --dport XXXXX -j DNAT --to-destination 192.168.X.X
iptables -t nat -I PREROUTING -i tun15 -p udp --dport XXXXX -j DNAT --to-destination 192.168.X.X
I make the script executable as indicated by the site, I restart the router and I finally have the port open for rtorrent-pro, the sharing is done correctly. Great ! But…. I do not have internet on the rest of the equipment of the house, Smartphone, PC ... Can you explain to me why? And how to enable port forwarding on the vpn interface, but not to filter / block the rest of the network?
Thank you a lot
In advance I apologize if I write in the wrong place and also for my English, because I use Google translation.
The current situation :
Asus rt-ac87u merlin firmware router 384_13_1
Qnap ts-251 +
On the qnap I use rtorrent-pro for downloads Like Vpn,
I use PureVpn with the port forwarding addon.
On the Qnap NAS, I see stability concerns for the VPN, so I decided to use the Asus Router for the VPN connection with PureVpn. I configured the client VPN part with the Openvpn files without worry. I have a "kill switch" rule only on the QNAP ip, everything works, well almost. I can download via rtorrent-pro, but sharing does not do it properly, the port use for rtorrent-pro remains closed or in an unknown status. So the shares do not do it correctly. I have obviously enabled port forwarding on the router, but that does not change anything. I also added the port in the Port Trigger tab, so that does not change anything.
After searching the internet I came across the site:
https://airvpn.org/forums/topic/11264-asus-merlin-wrt-port-forwarding-script-setup/
It provides a script to route asus to put in / jffs / script / nat-start
I modify it so that it corresponds to the interface vpn 5 (tun15) and I put the IP address of the NAS.
#!/bin/sh
iptables -I FORWARD -i br0 -o tun15 -j ACCEPT
iptables -I FORWARD -i tun15 -o br0 -j ACCEPT
iptables -I FORWARD -i br0 -o vlan1 -j DROP
iptables -I INPUT -i tun15 -j REJECT
iptables -t nat -A POSTROUTING -o tun15 -j MASQUERADE
iptables -I FORWARD -i tun15 -p udp -d 192.168.X.X --dport XXXXX -j ACCEPT
iptables -I FORWARD -i tun15 -p tcp -d 192.168.X.X --dport XXXXXX -j ACCEPT
iptables -t nat -I PREROUTING -i tun15 -p tcp --dport XXXXX -j DNAT --to-destination 192.168.X.X
iptables -t nat -I PREROUTING -i tun15 -p udp --dport XXXXX -j DNAT --to-destination 192.168.X.X
I make the script executable as indicated by the site, I restart the router and I finally have the port open for rtorrent-pro, the sharing is done correctly. Great ! But…. I do not have internet on the rest of the equipment of the house, Smartphone, PC ... Can you explain to me why? And how to enable port forwarding on the vpn interface, but not to filter / block the rest of the network?
Thank you a lot