packet coming through one interface route out via another interface and SNAT also
I have box1 with ip 192.168.129.10 ang GW 192.168.129.1
This box also has an alias of 172.16.0.1
i have the ip of another box, box2 to 172.16.0.10 and the GW to 172.16.0.1, but box2 can not reach the internet. It can ping both ips of box1 but no internet.
the 172.16.0.0 network is not currently catered for in my company.
I am thinking that if i can create some iptable NAT rules on box1 that will accept any packets coming in on 172.16.0.1 and then send it out through 192.168.129.10, at the same time changing the source ip to 192.168.129.10 since 172.16.0 network is not catered for.
I dont know if my idea is possible, if it is how do i implement this on iptables.
If it doesn't work, other solutions are welcome.