I have OpenVPN and PPTP installed on a VPS. I'm having a few questions that I can't seem to get a firm answer on.
I want to install OpenVPN on 184.108.40.206 (eth0, public IP address) and PPTP on 220.127.116.11 (eth0:1, public IP address). I was able to achieve this with SNAT. However, from all the tutorials I've been reading it recommends forwarding ppp+ to eth0 and vice versa and the same situation for the tun interface.
iptables -A FORWARD -i tun0 -o eth0 -j ACCEPT iptables -A FORWARD -i eth0 -o tun0 -j ACCEPT iptables -A FORWARD -i ppp+ -o eth0 -j ACCEPT iptables -A FORWARD -i eth0 -o ppp+ -j ACCEPT
My setup is CentOS, dedicated server.
For some reason I'm assuming iptables will route all traffic from eth0 to tun0 and stop at that.
- Will these forward rules conflict with each other?
- Will I need to forward the ppp+ to eth0:1 instead to avoid confliction? Is it even possible? I haven't figured out a way yet.
- Is iptables smart enough to route traffic that is specific to tun and ppp through these rules?