Howdy All,
To learn more about my RedHat 9 firewall, I have been reading iptables man entry and this page:
http://www.groovyweb.uklinux.net/?pa...20Basics%20NHF
I have a more general question and then something more specific.
First, I read the following from the above page:
== start quote ==
Let's say that, like me, you have a local area network and then you have a connection to the internet. We're going to also say that the LAN is eth0 while the internet connection is called ppp0. Now suppose we wanted to allow telnet to run as a service to computers on the LAN but not on the insecure internet. Well there is an easy way to do this. We can use -i for the input interface and -o for the output interface. You could always block it on the OUTPUT chain, but we'd rather block it on the INPUT so that the telnet daemon never even sees the request. Therefore we'll use -i. This should set up just the rule:
iptables -A INPUT -p tcp --destination-port telnet -i ppp0 -j DROP
== end quote ==
So the above command specifies a rule:
- for the INPUT chain
- for any packet using the tcp protocol
- headed to the telnet port
- from the internet interface - ppp0
Does this rule imply that there are two network cards in the machine - one with a linux NIC interface called pp0 (for the internet) and one called etho (for the LAN?)?
What if I have only one NIC that connects me to both a LAN and the internet? How could I then specify a similar rule?
Now the specific question: how do I specify this rule for samba only?
I want to allow samba connections from one specific IP on the LAN and deny the connection for everything else.
Is samba a protocol? What is its name?
Thank you for any help!