Tiny Core Linux
Tiny Core Extensions => TCE Q&A Forum => Topic started by: rout3rx on July 08, 2009, 06:40:50 AM
-
hi all
is anybody know how we can restrict internet shared in a LAN network just for 2 ip? [using iptables]
these 2 ip has the same range as other node in LAN.
thanks
-
If I understand your question, correctly, you have a network of systems and you wish to restrict Internet access to only two machines. The answer depends on your network setup, in particular:
1) Do you have a DHCP server which assigns addresses to all systems? If so,
2) Are the IP addresses for the two systems randomly chosen or reserved?
3) Do any or all systems reference the Internet gateway as their default router?
Iptables references machines using IP addresses. If those machines are assigned an address via DHCP (and IP addresses are not reserved for them) their IP address can change. It is easier to configure iptables if the IP addresses do not change, either via a static configuration or by reserving the address in the DHCP server.
At a minimum, you will need to configure the Internet gateway for NAT. This web page has a lot of extra info, but it is very good: http://iptables-tutorial.frozentux.net/iptables-tutorial.html (http://iptables-tutorial.frozentux.net/iptables-tutorial.html)
Post additional info regarding the above questions if you need more help.
Daniel
-
The above iptables tutorial link has been changed to:
http://www.frozentux.net/iptables-tutorial/iptables-tutorial.html