Router with multiple public IPs
I've recently got a block of 8 IPs from my ISP. I'm looking to use some of these IPs on another machine of mine, which will no longer be using NAT, and thus publically accessible via the newly aquired IP addresses.
For ease of presenting my problem, I've constructed a diagram to show my current and proposed setup.
It can be viewed here: http://www.mytheril.com/misc/files/images/setup.gif
My ISP provided me with the following information in an email:
Currently, when I connect to the Internet (via a BeWan ADSL PCI ST modem, under slackware) I am assigned my static IP via DHCP:
My friend has a ADSL modem/router combo which assigns public IP addresses to the computers connected to it, and that's basically what I want to achieve with Linux. I'm not sure how common this function is, or what the proper terminology for it is (bridging?), maybe someone could shed some light on that also :)
(ps. I already searched Google and the forums here, with no resolution (atleast understandable by me).
Alright, I now have everything sorted!
Here's how it goes:
1. echo "1" > /proc/sys/net/ipv4/ip_forward
2. [initiate connection to inet if not already done]
3. Set IP on eth0 (or whatever interface goes to your switch/rest of network) to one in your block (ie. 126.96.36.199).
4. Set the IPs on your other machines to the ones assigned to you by your ISP.
I then wrote myself a new iptables script and had to apply some of my existing rules to my FORWARD chain. Here's an example:
$IPTABLES -A FORWARD -p tcp -d 188.8.131.52 --dport 139 -j DROP
Hope that's of some use to someone :)
|All times are GMT -5. The time now is 07:15 AM.|