<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.linuxquestions.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Bmfmyth</id>
	<title>LQWiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.linuxquestions.org/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Bmfmyth"/>
	<link rel="alternate" type="text/html" href="https://wiki.linuxquestions.org/wiki/Special:Contributions/Bmfmyth"/>
	<updated>2026-04-10T14:39:23Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.37.0</generator>
	<entry>
		<id>https://wiki.linuxquestions.org/index.php?title=Set_up_a_router_or_default_gateway_with_Redhat_9.0&amp;diff=12257</id>
		<title>Set up a router or default gateway with Redhat 9.0</title>
		<link rel="alternate" type="text/html" href="https://wiki.linuxquestions.org/index.php?title=Set_up_a_router_or_default_gateway_with_Redhat_9.0&amp;diff=12257"/>
		<updated>2004-08-31T21:37:30Z</updated>

		<summary type="html">&lt;p&gt;Bmfmyth: Setting up Router/Default Gateway with Redhat 9.0 Tutorial&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''Setting up Router/Default Gateway with Redhat 9.0 Tutorial'''&lt;br /&gt;
&lt;br /&gt;
By: Brant Freidank (darkmyth at [H]ardForum) ( myth + admin at http://darkmyth.proboards27.com) (bmfmyth at linuxquestions.org) &lt;br /&gt;
&lt;br /&gt;
First off you need to download these things &lt;br /&gt;
&lt;br /&gt;
Redhat 9.0 distro disks one two and three: http://linuxiso.org/distro.php?distro=7 &lt;br /&gt;
&lt;br /&gt;
You then need to burn these disks as an image. I use Nero 6.0 to do this. You can find a demo of Nero 6.0 at nero’s web-site. http://www.nero.com/us/nero6-ultraedition.php &lt;br /&gt;
&lt;br /&gt;
Nano- (editor program for text documents) http://www.nano-editor.org/dist/v1.....2.3-1.i386.rpm &lt;br /&gt;
&lt;br /&gt;
Firestarter- (Easy setup firewall and NAT setup.) http://prdownloads.sourceforge.net/...86.rpm?download &lt;br /&gt;
&lt;br /&gt;
Then select a mirror from that page that’s closest to you. &lt;br /&gt;
&lt;br /&gt;
Dhp-3.0pl2 this is the dhcp server that you will config to give out ip’s to your lan network. http://www.binarycode.org/isc/dhcp/dhcp-3.0pl2.tar.gz &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
During setup you’ll need to set eth0 as assign by dhcp and start at startup but eth1 you’ll just click start at startup. You then go down to the manual setting for the nic card setup as 10.0.0.1 netmask will be set when you hit enter to go down to the next line. Then put default the gateway as 10.0.0.1 and leave dns and everything below that blank. &lt;br /&gt;
&lt;br /&gt;
Once you are done installing redhat 9.0 on your machine you must install the various programs above and create some files. &lt;br /&gt;
&lt;br /&gt;
First you must install nano by doing this in a terminal &lt;br /&gt;
&lt;br /&gt;
rpm –i nano-1.2.3-1.i386.rpm &lt;br /&gt;
&lt;br /&gt;
Nano is then installed. &lt;br /&gt;
&lt;br /&gt;
Then you must untar dhcp by doing this in a terminal &lt;br /&gt;
&lt;br /&gt;
tar xzvf dhcp-3.0pl2.tar.gz &lt;br /&gt;
&lt;br /&gt;
then cd into dhcp-3.0pl2 directory that is created &lt;br /&gt;
&lt;br /&gt;
type in ./configure then make then make install you now need to get out of the dhcp-3.0pl2 directory by typing this &lt;br /&gt;
&lt;br /&gt;
cd .. &lt;br /&gt;
&lt;br /&gt;
now you should be in a prompt with &lt;br /&gt;
&lt;br /&gt;
root@localhost root# &lt;br /&gt;
&lt;br /&gt;
Now you need to make a few files. You do this by the touch command in your terminal. &lt;br /&gt;
&lt;br /&gt;
touch /etc/dhcpd.conf &lt;br /&gt;
&lt;br /&gt;
you then need to make a directory. You do this by using the mkdir command in your terminal &lt;br /&gt;
&lt;br /&gt;
mkdir /var/state/dhcp &lt;br /&gt;
&lt;br /&gt;
you then make a text file in this directory while still in root &lt;br /&gt;
&lt;br /&gt;
touch /var/state/dhcp/dhcpd.leases &lt;br /&gt;
&lt;br /&gt;
Now you must configure your /etc/dhcpd.conf file. You do this by using nano. &lt;br /&gt;
&lt;br /&gt;
nano /etc/dhcpd.conf &lt;br /&gt;
&lt;br /&gt;
when you are done editing the file press ctrl + x in order to exit and press y to save changes to the file &lt;br /&gt;
&lt;br /&gt;
An example of the my /etc/dhcpd.conf file would be this. (My network is a class A network.) &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
/etc/dhcpd.conf &lt;br /&gt;
ddns-update-style interim; &lt;br /&gt;
subnet 10.0.0.0 netmask 255.255.0.0 { default-lease-time 63000; max-lease-time 72000; option routers 10.0.0.1; option subnet-mask 255.255.0.0; option domain-name-servers this is provided by your isp if there are more than one dns server separate by a comma; range 10.0.0.2 10.0.0.253; } &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You now need to make the file /etc/sysconfig/iptables &lt;br /&gt;
&lt;br /&gt;
You again use the touch command to do this. &lt;br /&gt;
&lt;br /&gt;
touch /etc/sysconfig/iptables &lt;br /&gt;
&lt;br /&gt;
once you have created this file you need to go into it and place your iptables rules. &lt;br /&gt;
&lt;br /&gt;
Again nano into the file and enter the following data by using this command &lt;br /&gt;
&lt;br /&gt;
nano /etc/sysconfig/iptables &lt;br /&gt;
&lt;br /&gt;
when you are done editing the file press ctrl + x in order to exit and press y to save changes to the file &lt;br /&gt;
&lt;br /&gt;
An example of my file is: &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
iptables - configuration files for iptables in Red Hat Linux 8.0 &lt;br /&gt;
&lt;br /&gt;
This is appropriate for protecting a single workstation. &lt;br /&gt;
&lt;br /&gt;
The script could be a lot more rigorous, e.g., only allow &lt;br /&gt;
selected outbound ports, rather than allowing all outbound &lt;br /&gt;
traffic, use REJECT rather than DROP, etc. However, the &lt;br /&gt;
goal of this script was to provide some protection for ports &lt;br /&gt;
while minimizing the number of checks made on each packet. &lt;br /&gt;
&lt;br /&gt;
This file should be owned by user root, group root. &lt;br /&gt;
The permissions on this file should be set to 600. &lt;br /&gt;
&lt;br /&gt;
Edit lines as necessary, then uncomment (remove hash mark) the &lt;br /&gt;
lines you wish to use. &lt;br /&gt;
&lt;br /&gt;
Although every precaution has been taken in the preparation of this &lt;br /&gt;
file, the author assumes no responsibility for errors or omissions. &lt;br /&gt;
Neither is any liability assumed for damages resulting from the use of &lt;br /&gt;
the information contained herein. &lt;br /&gt;
&lt;br /&gt;
m-woo@uiuc.edu 9 Jan 2003 &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
filter &lt;br /&gt;
INPUT DROP [0:0] &lt;br /&gt;
FORWARD DROP [0:0] &lt;br /&gt;
OUTPUT DROP [0:0] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Drop all incoming fragments &lt;br /&gt;
-A INPUT -i eth0 -f -j DROP &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Drop outside packets with localhost address - anti-spoofing measure &lt;br /&gt;
-A INPUT -s 10.0.0.1/255.0.0.0 -i ! lo -j DROP &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Pass all locally-originating packets &lt;br /&gt;
-A INPUT -i lo -j ACCEPT -A OUTPUT -o lo -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Accept ICMP ping echo request packets &lt;br /&gt;
(this allows other people to ping your machine, among other things), &lt;br /&gt;
-A INPUT -p icmp --icmp-type echo-request -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Accept all traffic from a specific machine with IP x.x.x.x &lt;br /&gt;
replace x.x.x.x with the desired IP, then uncomment the line. &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn -s 10.0.0.0 -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Accept traffic on port p from a specific machine with IP x.x.x.x &lt;br /&gt;
replace p with the desired port number, and replace x.x.x.x with &lt;br /&gt;
the desired IP, then uncomment the line. &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn -s 10.0.0.1 --dport 80 -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Accept all inbound ssh traffic &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 22 -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Accept all inbound identd &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 113 -j ACCEPT &lt;br /&gt;
or you can reject and send back a TCP RST packet instead &lt;br /&gt;
-A INPUT -p tcp -m tcp --dport 113 -j REJECT --reject-with tcp-reset &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Allow all sendmail SMTP traffic &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 25 -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Allow all sendmail MSA traffic &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 587 -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Allow all web server access (port 80) &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 80 -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Allow all secure web server access (port 443) &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 443 -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Allow inbound established and related outside communication &lt;br /&gt;
-A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Drop outside initiated connections &lt;br /&gt;
-A INPUT -m state --state NEW -j REJECT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Allow all outbound tcp, udp, icmp traffic with state &lt;br /&gt;
-A OUTPUT -p tcp -m state --state NEW,ESTABLISHED -j ACCEPT -A OUTPUT -p udp -m state --state NEW,ESTABLISHED -j ACCEPT -A OUTPUT -p icmp -m state --state NEW,ESTABLISHED,RELATED -j ACCEPT COMMIT &lt;br /&gt;
You also need to add the line &lt;br /&gt;
&lt;br /&gt;
echo 1 &amp;gt; /proc/sys/net/ipv4/ip_forward &lt;br /&gt;
&lt;br /&gt;
to your /etc/rc.d/rc.local file &lt;br /&gt;
&lt;br /&gt;
also hit enter twice after the above line and put &lt;br /&gt;
&lt;br /&gt;
dhcpd &lt;br /&gt;
&lt;br /&gt;
This will automatically start your dhcpd server for you on startup of your machine. &lt;br /&gt;
&lt;br /&gt;
Now you need to install firestarter. &lt;br /&gt;
&lt;br /&gt;
You do this using the rpm command &lt;br /&gt;
&lt;br /&gt;
rpm –i firestarter-0.9.2-3.i386.rpm &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go into your terminal and run the firestarter setup by typing firestarter and hitting enter. &lt;br /&gt;
&lt;br /&gt;
Setup Guide: 1. A gui setup should pop up. 2. Click Forward 3. There should be two nics detected eth0 and eth1 4. Unclick start at dial out 5. But put a check in IP address assigned via DHCP 6. Then click forward 7. On the next screen click Enable Network Address Translation 8. Then set your internal device as eth1 9. Then click Specify internal network IP range manually 10. Internal network address range 10.0.0.1/8 11. Now click forward 12. Click Enable Public access to the following services: 13. Put a check in www, dns, dhcp, ftp, SSL web, Xwindows, NTP, and POP 14. Now click forward 15. On the next screen click Enable ToS filtering related to the following packets 16. Check everything on the left and then check throughput on the right 17. Now click forward 18. On the next screen click Enable ICMP filtering related to the following packets: 19. Check Echo, Traceroute, MS Traceroute, address masking, and Redirection 20. Now click forward 21. And click save 22. Once you save it and firestarter starts up go into the tab that says Rules. 23. Go to Open ports and double click. Add the ports 80, and 53 24. You can add more ports as you need later on by doing the same thing. &lt;br /&gt;
&lt;br /&gt;
Now reboot your machine by going to your terminal and typing shutdown –r now &lt;br /&gt;
&lt;br /&gt;
Once it reboots log in as root and then go to the redhat toolbar and click the redhat icon go up till you have your mouse over run program. A box will pop up and you need to type in firestarter to run the firestarter program. &lt;br /&gt;
&lt;br /&gt;
Congratulations you have now setup a default gateway and router for your home network. The nic you setup as eth0 will have a strait through cat5 cable going from your cable modem to that nic card. You then Have a crossover cable going from your eth1 card to either your switch if you want to connect more than one computer or directly to the back of your computer if you want to just have one client for the time being, or for just testing purposes. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Comment: &lt;br /&gt;
&lt;br /&gt;
Brant Freidank – Use this and distribute this tutorial to anyone you see fit. You can modify this tutorial to your needs if you wish. But please give credit where it is due for the tutorial.&lt;/div&gt;</summary>
		<author><name>Bmfmyth</name></author>
	</entry>
	<entry>
		<id>https://wiki.linuxquestions.org/index.php?title=Setting_up_a_router_(Red_Hat)&amp;diff=11393</id>
		<title>Setting up a router (Red Hat)</title>
		<link rel="alternate" type="text/html" href="https://wiki.linuxquestions.org/index.php?title=Setting_up_a_router_(Red_Hat)&amp;diff=11393"/>
		<updated>2004-08-31T21:28:28Z</updated>

		<summary type="html">&lt;p&gt;Bmfmyth: Setting up Router/Default Gateway with Redhat 9.0 Tutorial&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''Setting up Router/Default Gateway with Redhat 9.0 Tutorial'''&lt;br /&gt;
&lt;br /&gt;
By: Brant Freidank (darkmyth at [H]ardForum) ( myth + admin at http://darkmyth.proboards27.com) (bmfmyth at linuxquestions.org) &lt;br /&gt;
&lt;br /&gt;
First off you need to download these things &lt;br /&gt;
&lt;br /&gt;
Redhat 9.0 distro disks one two and three: http://linuxiso.org/distro.php?distro=7 &lt;br /&gt;
&lt;br /&gt;
You then need to burn these disks as an image. I use Nero 6.0 to do this. You can find a demo of Nero 6.0 at nero’s web-site. http://www.nero.com/us/nero6-ultraedition.php &lt;br /&gt;
&lt;br /&gt;
Nano- (editor program for text documents) http://www.nano-editor.org/dist/v1.....2.3-1.i386.rpm &lt;br /&gt;
&lt;br /&gt;
Firestarter- (Easy setup firewall and NAT setup.) http://prdownloads.sourceforge.net/...86.rpm?download &lt;br /&gt;
&lt;br /&gt;
Then select a mirror from that page that’s closest to you. &lt;br /&gt;
&lt;br /&gt;
Dhp-3.0pl2 this is the dhcp server that you will config to give out ip’s to your lan network. http://www.binarycode.org/isc/dhcp/dhcp-3.0pl2.tar.gz &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
During setup you’ll need to set eth0 as assign by dhcp and start at startup but eth1 you’ll just click start at startup. You then go down to the manual setting for the nic card setup as 10.0.0.1 netmask will be set when you hit enter to go down to the next line. Then put default the gateway as 10.0.0.1 and leave dns and everything below that blank. &lt;br /&gt;
&lt;br /&gt;
Once you are done installing redhat 9.0 on your machine you must install the various programs above and create some files. &lt;br /&gt;
&lt;br /&gt;
First you must install nano by doing this in a terminal &lt;br /&gt;
&lt;br /&gt;
rpm –i nano-1.2.3-1.i386.rpm &lt;br /&gt;
&lt;br /&gt;
Nano is then installed. &lt;br /&gt;
&lt;br /&gt;
Then you must untar dhcp by doing this in a terminal &lt;br /&gt;
&lt;br /&gt;
tar xzvf dhcp-3.0pl2.tar.gz &lt;br /&gt;
&lt;br /&gt;
then cd into dhcp-3.0pl2 directory that is created &lt;br /&gt;
&lt;br /&gt;
type in ./configure then make then make install you now need to get out of the dhcp-3.0pl2 directory by typing this &lt;br /&gt;
&lt;br /&gt;
cd .. &lt;br /&gt;
&lt;br /&gt;
now you should be in a prompt with &lt;br /&gt;
&lt;br /&gt;
root@localhost root# &lt;br /&gt;
&lt;br /&gt;
Now you need to make a few files. You do this by the touch command in your terminal. &lt;br /&gt;
&lt;br /&gt;
touch /etc/dhcpd.conf &lt;br /&gt;
&lt;br /&gt;
you then need to make a directory. You do this by using the mkdir command in your terminal &lt;br /&gt;
&lt;br /&gt;
mkdir /var/state/dhcp &lt;br /&gt;
&lt;br /&gt;
you then make a text file in this directory while still in root &lt;br /&gt;
&lt;br /&gt;
touch /var/state/dhcp/dhcpd.leases &lt;br /&gt;
&lt;br /&gt;
Now you must configure your /etc/dhcpd.conf file. You do this by using nano. &lt;br /&gt;
&lt;br /&gt;
nano /etc/dhcpd.conf &lt;br /&gt;
&lt;br /&gt;
when you are done editing the file press ctrl + x in order to exit and press y to save changes to the file &lt;br /&gt;
&lt;br /&gt;
An example of the my /etc/dhcpd.conf file would be this. (My network is a class A network.) &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
/etc/dhcpd.conf &lt;br /&gt;
ddns-update-style interim; &lt;br /&gt;
subnet 10.0.0.0 netmask 255.255.0.0 { default-lease-time 63000; max-lease-time 72000; option routers 10.0.0.1; option subnet-mask 255.255.0.0; option domain-name-servers this is provided by your isp if there are more than one dns server separate by a comma; range 10.0.0.2 10.0.0.253; } &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You now need to make the file /etc/sysconfig/iptables &lt;br /&gt;
&lt;br /&gt;
You again use the touch command to do this. &lt;br /&gt;
&lt;br /&gt;
touch /etc/sysconfig/iptables &lt;br /&gt;
&lt;br /&gt;
once you have created this file you need to go into it and place your iptables rules. &lt;br /&gt;
&lt;br /&gt;
Again nano into the file and enter the following data by using this command &lt;br /&gt;
&lt;br /&gt;
nano /etc/sysconfig/iptables &lt;br /&gt;
&lt;br /&gt;
when you are done editing the file press ctrl + x in order to exit and press y to save changes to the file &lt;br /&gt;
&lt;br /&gt;
An example of my file is: &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
iptables - configuration files for iptables in Red Hat Linux 8.0 &lt;br /&gt;
&lt;br /&gt;
This is appropriate for protecting a single workstation. &lt;br /&gt;
&lt;br /&gt;
The script could be a lot more rigorous, e.g., only allow &lt;br /&gt;
selected outbound ports, rather than allowing all outbound &lt;br /&gt;
traffic, use REJECT rather than DROP, etc. However, the &lt;br /&gt;
goal of this script was to provide some protection for ports &lt;br /&gt;
while minimizing the number of checks made on each packet. &lt;br /&gt;
&lt;br /&gt;
This file should be owned by user root, group root. &lt;br /&gt;
The permissions on this file should be set to 600. &lt;br /&gt;
&lt;br /&gt;
Edit lines as necessary, then uncomment (remove hash mark) the &lt;br /&gt;
lines you wish to use. &lt;br /&gt;
&lt;br /&gt;
Although every precaution has been taken in the preparation of this &lt;br /&gt;
file, the author assumes no responsibility for errors or omissions. &lt;br /&gt;
Neither is any liability assumed for damages resulting from the use of &lt;br /&gt;
the information contained herein. &lt;br /&gt;
&lt;br /&gt;
m-woo@uiuc.edu 9 Jan 2003 &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
filter &lt;br /&gt;
INPUT DROP [0:0] &lt;br /&gt;
FORWARD DROP [0:0] &lt;br /&gt;
OUTPUT DROP [0:0] &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Drop all incoming fragments &lt;br /&gt;
-A INPUT -i eth0 -f -j DROP &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Drop outside packets with localhost address - anti-spoofing measure &lt;br /&gt;
-A INPUT -s 10.0.0.1/255.0.0.0 -i ! lo -j DROP &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Pass all locally-originating packets &lt;br /&gt;
-A INPUT -i lo -j ACCEPT -A OUTPUT -o lo -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Accept ICMP ping echo request packets &lt;br /&gt;
(this allows other people to ping your machine, among other things), &lt;br /&gt;
-A INPUT -p icmp --icmp-type echo-request -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Accept all traffic from a specific machine with IP x.x.x.x &lt;br /&gt;
replace x.x.x.x with the desired IP, then uncomment the line. &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn -s 10.0.0.0 -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Accept traffic on port p from a specific machine with IP x.x.x.x &lt;br /&gt;
replace p with the desired port number, and replace x.x.x.x with &lt;br /&gt;
the desired IP, then uncomment the line. &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn -s 10.0.0.1 --dport 80 -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Accept all inbound ssh traffic &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 22 -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Accept all inbound identd &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 113 -j ACCEPT &lt;br /&gt;
or you can reject and send back a TCP RST packet instead &lt;br /&gt;
-A INPUT -p tcp -m tcp --dport 113 -j REJECT --reject-with tcp-reset &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Allow all sendmail SMTP traffic &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 25 -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Allow all sendmail MSA traffic &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 587 -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Allow all web server access (port 80) &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 80 -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Allow all secure web server access (port 443) &lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 443 -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Allow inbound established and related outside communication &lt;br /&gt;
-A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Drop outside initiated connections &lt;br /&gt;
-A INPUT -m state --state NEW -j REJECT &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Allow all outbound tcp, udp, icmp traffic with state &lt;br /&gt;
-A OUTPUT -p tcp -m state --state NEW,ESTABLISHED -j ACCEPT -A OUTPUT -p udp -m state --state NEW,ESTABLISHED -j ACCEPT -A OUTPUT -p icmp -m state --state NEW,ESTABLISHED,RELATED -j ACCEPT COMMIT &lt;br /&gt;
You also need to add the line &lt;br /&gt;
&lt;br /&gt;
echo 1 &amp;gt; /proc/sys/net/ipv4/ip_forward &lt;br /&gt;
&lt;br /&gt;
to your /etc/rc.d/rc.local file &lt;br /&gt;
&lt;br /&gt;
also hit enter twice after the above line and put &lt;br /&gt;
&lt;br /&gt;
dhcpd &lt;br /&gt;
&lt;br /&gt;
This will automatically start your dhcpd server for you on startup of your machine. &lt;br /&gt;
&lt;br /&gt;
Now you need to install firestarter. &lt;br /&gt;
&lt;br /&gt;
You do this using the rpm command &lt;br /&gt;
&lt;br /&gt;
rpm –i firestarter-0.9.2-3.i386.rpm &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Now go into your terminal and run the firestarter setup by typing firestarter and hitting enter. &lt;br /&gt;
&lt;br /&gt;
Setup Guide: 1. A gui setup should pop up. 2. Click Forward 3. There should be two nics detected eth0 and eth1 4. Unclick start at dial out 5. But put a check in IP address assigned via DHCP 6. Then click forward 7. On the next screen click Enable Network Address Translation 8. Then set your internal device as eth1 9. Then click Specify internal network IP range manually 10. Internal network address range 10.0.0.1/8 11. Now click forward 12. Click Enable Public access to the following services: 13. Put a check in www, dns, dhcp, ftp, SSL web, Xwindows, NTP, and POP 14. Now click forward 15. On the next screen click Enable ToS filtering related to the following packets 16. Check everything on the left and then check throughput on the right 17. Now click forward 18. On the next screen click Enable ICMP filtering related to the following packets: 19. Check Echo, Traceroute, MS Traceroute, address masking, and Redirection 20. Now click forward 21. And click save 22. Once you save it and firestarter starts up go into the tab that says Rules. 23. Go to Open ports and double click. Add the ports 80, and 53 24. You can add more ports as you need later on by doing the same thing. &lt;br /&gt;
&lt;br /&gt;
Now reboot your machine by going to your terminal and typing shutdown –r now &lt;br /&gt;
&lt;br /&gt;
Once it reboots log in as root and then go to the redhat toolbar and click the redhat icon go up till you have your mouse over run program. A box will pop up and you need to type in firestarter to run the firestarter program. &lt;br /&gt;
&lt;br /&gt;
Congratulations you have now setup a default gateway and router for your home network. The nic you setup as eth0 will have a strait through cat5 cable going from your cable modem to that nic card. You then Have a crossover cable going from your eth1 card to either your switch if you want to connect more than one computer or directly to the back of your computer if you want to just have one client for the time being, or for just testing purposes. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Comment: &lt;br /&gt;
&lt;br /&gt;
Brant Freidank – Use this and distribute this tutorial to anyone you see fit. You can modify this tutorial to your needs if you wish. But please give credit where it is due for the tutorial.&lt;/div&gt;</summary>
		<author><name>Bmfmyth</name></author>
	</entry>
	<entry>
		<id>https://wiki.linuxquestions.org/index.php?title=User:Bmfmyth&amp;diff=24781</id>
		<title>User:Bmfmyth</title>
		<link rel="alternate" type="text/html" href="https://wiki.linuxquestions.org/index.php?title=User:Bmfmyth&amp;diff=24781"/>
		<updated>2004-08-31T21:23:38Z</updated>

		<summary type="html">&lt;p&gt;Bmfmyth: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;[[Router Setup]]&lt;br /&gt;
'''Setting up Router/Default Gateway with Redhat 9.0 Tutorial'''&lt;br /&gt;
&lt;br /&gt;
By: Brant Freidank (darkmyth at [H]ardForum) ( myth + admin at http://darkmyth.proboards27.com) (bmfmyth at linuxquestions.org)&lt;br /&gt;
&lt;br /&gt;
First off you need to download these things&lt;br /&gt;
&lt;br /&gt;
Redhat 9.0 distro disks one two and three:&lt;br /&gt;
http://linuxiso.org/distro.php?distro=7&lt;br /&gt;
&lt;br /&gt;
You then need to burn these disks as an image. I use Nero 6.0 to do this. You can find a demo of Nero 6.0 at nero’s web-site. &lt;br /&gt;
http://www.nero.com/us/nero6-ultraedition.php&lt;br /&gt;
&lt;br /&gt;
Nano- (editor program for text documents)&lt;br /&gt;
http://www.nano-editor.org/dist/v1.....2.3-1.i386.rpm&lt;br /&gt;
&lt;br /&gt;
Firestarter- (Easy setup firewall and NAT setup.)&lt;br /&gt;
http://prdownloads.sourceforge.net/...86.rpm?download&lt;br /&gt;
&lt;br /&gt;
Then select a mirror from that page that’s closest to you.&lt;br /&gt;
&lt;br /&gt;
Dhp-3.0pl2 this is the dhcp server that you will config to give out ip’s to your lan network.&lt;br /&gt;
http://www.binarycode.org/isc/dhcp/dhcp-3.0pl2.tar.gz&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
During setup you’ll need to set eth0 as assign by dhcp and start at startup but eth1 you’ll just click start at startup. You then go down to the manual setting for the nic card setup as 10.0.0.1 netmask will be set when you hit enter to go down to the next line. Then put default the gateway as 10.0.0.1 and leave dns and everything below that blank.&lt;br /&gt;
&lt;br /&gt;
Once you are done installing redhat 9.0 on your machine you must install the various programs above and create some files.&lt;br /&gt;
&lt;br /&gt;
First you must install nano by doing this in a terminal&lt;br /&gt;
&lt;br /&gt;
rpm –i nano-1.2.3-1.i386.rpm&lt;br /&gt;
&lt;br /&gt;
Nano is then installed.&lt;br /&gt;
&lt;br /&gt;
Then you must untar dhcp by doing this in a terminal&lt;br /&gt;
&lt;br /&gt;
tar xzvf dhcp-3.0pl2.tar.gz&lt;br /&gt;
&lt;br /&gt;
then cd into dhcp-3.0pl2 directory that is created&lt;br /&gt;
&lt;br /&gt;
type in ./configure&lt;br /&gt;
then make&lt;br /&gt;
then make install&lt;br /&gt;
you now need to get out of the dhcp-3.0pl2 directory by typing this&lt;br /&gt;
&lt;br /&gt;
cd ..&lt;br /&gt;
&lt;br /&gt;
now you should be in a prompt with&lt;br /&gt;
&lt;br /&gt;
root@localhost root# &lt;br /&gt;
&lt;br /&gt;
Now you need to make a few files. You do this by the touch command in your terminal.&lt;br /&gt;
&lt;br /&gt;
touch /etc/dhcpd.conf&lt;br /&gt;
&lt;br /&gt;
you then need to make a directory. You do this by using the mkdir command in your terminal&lt;br /&gt;
&lt;br /&gt;
mkdir /var/state/dhcp&lt;br /&gt;
&lt;br /&gt;
you then make a text file in this directory while still in root&lt;br /&gt;
&lt;br /&gt;
touch /var/state/dhcp/dhcpd.leases&lt;br /&gt;
&lt;br /&gt;
Now you must configure your /etc/dhcpd.conf file.&lt;br /&gt;
You do this by using nano.&lt;br /&gt;
&lt;br /&gt;
nano /etc/dhcpd.conf&lt;br /&gt;
&lt;br /&gt;
when you are done editing the file press ctrl + x in order to exit and press y to save changes to the file&lt;br /&gt;
&lt;br /&gt;
An example of the my /etc/dhcpd.conf file would be this. (My network is a class A network.)&lt;br /&gt;
&lt;br /&gt;
#/etc/dhcpd.conf&lt;br /&gt;
ddns-update-style interim;&lt;br /&gt;
&lt;br /&gt;
subnet 10.0.0.0 netmask 255.255.0.0 {&lt;br /&gt;
default-lease-time 63000;&lt;br /&gt;
max-lease-time 72000;&lt;br /&gt;
option routers 10.0.0.1;&lt;br /&gt;
option subnet-mask 255.255.0.0;&lt;br /&gt;
option domain-name-servers this is provided by your isp if there are more than one dns server separate by a comma;&lt;br /&gt;
range 10.0.0.2 10.0.0.253;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You now need to make the file /etc/sysconfig/iptables&lt;br /&gt;
&lt;br /&gt;
You again use the touch command to do this.&lt;br /&gt;
&lt;br /&gt;
touch /etc/sysconfig/iptables&lt;br /&gt;
&lt;br /&gt;
once you have created this file you need to go into it and place your iptables rules. &lt;br /&gt;
&lt;br /&gt;
Again nano into the file and enter the following data by using this command&lt;br /&gt;
&lt;br /&gt;
nano /etc/sysconfig/iptables&lt;br /&gt;
&lt;br /&gt;
when you are done editing the file press ctrl + x in order to exit and press y to save changes to the file&lt;br /&gt;
&lt;br /&gt;
An example of my file is:&lt;br /&gt;
&lt;br /&gt;
# iptables - configuration files for iptables in Red Hat Linux 8.0&lt;br /&gt;
#&lt;br /&gt;
# This is appropriate for protecting a single workstation.&lt;br /&gt;
# &lt;br /&gt;
# The script could be a lot more rigorous, e.g., only allow&lt;br /&gt;
# selected outbound ports, rather than allowing all outbound&lt;br /&gt;
# traffic, use REJECT rather than DROP, etc. However, the &lt;br /&gt;
# goal of this script was to provide some protection for ports &lt;br /&gt;
# while minimizing the number of checks made on each packet.&lt;br /&gt;
#&lt;br /&gt;
# This file should be owned by user root, group root.&lt;br /&gt;
# The permissions on this file should be set to 600.&lt;br /&gt;
#&lt;br /&gt;
# Edit lines as necessary, then uncomment (remove hash mark) the &lt;br /&gt;
# lines you wish to use.&lt;br /&gt;
#&lt;br /&gt;
# Although every precaution has been taken in the preparation of this&lt;br /&gt;
# file, the author assumes no responsibility for errors or omissions.&lt;br /&gt;
# Neither is any liability assumed for damages resulting from the use of&lt;br /&gt;
# the information contained herein.&lt;br /&gt;
#&lt;br /&gt;
# m-woo@uiuc.edu 9 Jan 2003&lt;br /&gt;
#&lt;br /&gt;
*filter&lt;br /&gt;
:INPUT DROP [0:0]&lt;br /&gt;
:FORWARD DROP [0:0]&lt;br /&gt;
:OUTPUT DROP [0:0]&lt;br /&gt;
&lt;br /&gt;
## Drop all incoming fragments&lt;br /&gt;
-A INPUT -i eth0 -f -j DROP&lt;br /&gt;
&lt;br /&gt;
## Drop outside packets with localhost address - anti-spoofing measure&lt;br /&gt;
-A INPUT -s 10.0.0.1/255.0.0.0 -i ! lo -j DROP&lt;br /&gt;
&lt;br /&gt;
## Pass all locally-originating packets&lt;br /&gt;
-A INPUT -i lo -j ACCEPT&lt;br /&gt;
-A OUTPUT -o lo -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Accept ICMP ping echo request packets&lt;br /&gt;
## (this allows other people to ping your machine, among other things),&lt;br /&gt;
-A INPUT -p icmp --icmp-type echo-request -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Accept all traffic from a specific machine with IP x.x.x.x&lt;br /&gt;
## replace x.x.x.x with the desired IP, then uncomment the line.&lt;br /&gt;
-A INPUT -p tcp -m tcp --syn -s 10.0.0.0 -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Accept traffic on port p from a specific machine with IP x.x.x.x&lt;br /&gt;
## replace p with the desired port number, and replace x.x.x.x with &lt;br /&gt;
## the desired IP, then uncomment the line.&lt;br /&gt;
-A INPUT -p tcp -m tcp --syn -s 10.0.0.1 --dport 80 -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Accept all inbound ssh traffic&lt;br /&gt;
#-A INPUT -p tcp -m tcp --syn --dport 22 -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Accept all inbound identd&lt;br /&gt;
#-A INPUT -p tcp -m tcp --syn --dport 113 -j ACCEPT&lt;br /&gt;
## or you can reject and send back a TCP RST packet instead&lt;br /&gt;
#-A INPUT -p tcp -m tcp --dport 113 -j REJECT --reject-with tcp-reset&lt;br /&gt;
&lt;br /&gt;
## Allow all sendmail SMTP traffic&lt;br /&gt;
#-A INPUT -p tcp -m tcp --syn --dport 25 -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Allow all sendmail MSA traffic&lt;br /&gt;
#-A INPUT -p tcp -m tcp --syn --dport 587 -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Allow all web server access (port 80)&lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 80 -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Allow all secure web server access (port 443)&lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 443 -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Allow inbound established and related outside communication &lt;br /&gt;
-A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Drop outside initiated connections&lt;br /&gt;
-A INPUT -m state --state NEW -j REJECT&lt;br /&gt;
&lt;br /&gt;
## Allow all outbound tcp, udp, icmp traffic with state&lt;br /&gt;
-A OUTPUT -p tcp -m state --state NEW,ESTABLISHED -j ACCEPT&lt;br /&gt;
-A OUTPUT -p udp -m state --state NEW,ESTABLISHED -j ACCEPT&lt;br /&gt;
-A OUTPUT -p icmp -m state --state NEW,ESTABLISHED,RELATED -j ACCEPT&lt;br /&gt;
COMMIT&lt;br /&gt;
&lt;br /&gt;
You also need to add the line&lt;br /&gt;
&lt;br /&gt;
echo 1 &amp;gt; /proc/sys/net/ipv4/ip_forward &lt;br /&gt;
&lt;br /&gt;
to your /etc/rc.d/rc.local file&lt;br /&gt;
&lt;br /&gt;
also hit enter twice after the above line and put&lt;br /&gt;
&lt;br /&gt;
dhcpd&lt;br /&gt;
&lt;br /&gt;
This will automatically start your dhcpd server for you on startup of your machine.&lt;br /&gt;
&lt;br /&gt;
Now you need to install firestarter.&lt;br /&gt;
&lt;br /&gt;
You do this using the rpm command&lt;br /&gt;
&lt;br /&gt;
rpm –i firestarter-0.9.2-3.i386.rpm&lt;br /&gt;
&lt;br /&gt;
Now go into your terminal and run the firestarter setup by typing firestarter and hitting enter.&lt;br /&gt;
&lt;br /&gt;
Setup Guide:&lt;br /&gt;
1. A gui setup should pop up.&lt;br /&gt;
2. Click Forward&lt;br /&gt;
3. There should be two nics detected eth0 and eth1 &lt;br /&gt;
4. Unclick start at dial out&lt;br /&gt;
5. But put a check in IP address assigned via DHCP&lt;br /&gt;
6. Then click forward &lt;br /&gt;
7. On the next screen click Enable Network Address Translation &lt;br /&gt;
8. Then set your internal device as eth1&lt;br /&gt;
9. Then click Specify internal network IP range manually &lt;br /&gt;
10. Internal network address range 10.0.0.1/8&lt;br /&gt;
11. Now click forward&lt;br /&gt;
12. Click Enable Public access to the following services:&lt;br /&gt;
13. Put a check in www, dns, dhcp, ftp, SSL web, Xwindows, NTP, and POP &lt;br /&gt;
14. Now click forward&lt;br /&gt;
15. On the next screen click Enable ToS filtering related to the following packets&lt;br /&gt;
16. Check everything on the left and then check throughput on the right&lt;br /&gt;
17. Now click forward&lt;br /&gt;
18. On the next screen click Enable ICMP filtering related to the following packets:&lt;br /&gt;
19. Check Echo, Traceroute, MS Traceroute, address masking, and Redirection&lt;br /&gt;
20. Now click forward&lt;br /&gt;
21. And click save &lt;br /&gt;
22. Once you save it and firestarter starts up go into the tab that says Rules.&lt;br /&gt;
23. Go to Open ports and double click. Add the ports 80, and 53&lt;br /&gt;
24. You can add more ports as you need later on by doing the same thing.&lt;br /&gt;
&lt;br /&gt;
Now reboot your machine by going to your terminal and typing shutdown –r now&lt;br /&gt;
&lt;br /&gt;
Once it reboots log in as root and then go to the redhat toolbar and click the redhat icon go up till you have your mouse over run program. A box will pop up and you need to type in firestarter to run the firestarter program. &lt;br /&gt;
&lt;br /&gt;
Congratulations you have now setup a default gateway and router for your home network. The nic you setup as eth0 will have a strait through cat5 cable going from your cable modem to that nic card. You then Have a crossover cable going from your eth1 card to either your switch if you want to connect more than one computer or directly to the back of your computer if you want to just have one client for the time being, or for just testing purposes. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Comment:&lt;br /&gt;
&lt;br /&gt;
Brant Freidank – Use this and distribute this tutorial to anyone you see fit. You can modify this tutorial to your needs if you wish. But please give credit where it is due for the tutorial.&lt;/div&gt;</summary>
		<author><name>Bmfmyth</name></author>
	</entry>
	<entry>
		<id>https://wiki.linuxquestions.org/index.php?title=User:Bmfmyth&amp;diff=11379</id>
		<title>User:Bmfmyth</title>
		<link rel="alternate" type="text/html" href="https://wiki.linuxquestions.org/index.php?title=User:Bmfmyth&amp;diff=11379"/>
		<updated>2004-08-31T21:04:53Z</updated>

		<summary type="html">&lt;p&gt;Bmfmyth: Setting up Router/Default Gateway with Redhat 9.0 Tutorial&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;'''Setting up Router/Default Gateway with Redhat 9.0 Tutorial'''&lt;br /&gt;
&lt;br /&gt;
By: Brant Freidank (darkmyth at [H]ardForum) ( myth + admin at http://darkmyth.proboards27.com) (bmfmyth at linuxquestions.org)&lt;br /&gt;
&lt;br /&gt;
First off you need to download these things&lt;br /&gt;
&lt;br /&gt;
Redhat 9.0 distro disks one two and three:&lt;br /&gt;
http://linuxiso.org/distro.php?distro=7&lt;br /&gt;
&lt;br /&gt;
You then need to burn these disks as an image. I use Nero 6.0 to do this. You can find a demo of Nero 6.0 at nero’s web-site. &lt;br /&gt;
http://www.nero.com/us/nero6-ultraedition.php&lt;br /&gt;
&lt;br /&gt;
Nano- (editor program for text documents)&lt;br /&gt;
http://www.nano-editor.org/dist/v1.....2.3-1.i386.rpm&lt;br /&gt;
&lt;br /&gt;
Firestarter- (Easy setup firewall and NAT setup.)&lt;br /&gt;
http://prdownloads.sourceforge.net/...86.rpm?download&lt;br /&gt;
&lt;br /&gt;
Then select a mirror from that page that’s closest to you.&lt;br /&gt;
&lt;br /&gt;
Dhp-3.0pl2 this is the dhcp server that you will config to give out ip’s to your lan network.&lt;br /&gt;
http://www.binarycode.org/isc/dhcp/dhcp-3.0pl2.tar.gz&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
During setup you’ll need to set eth0 as assign by dhcp and start at startup but eth1 you’ll just click start at startup. You then go down to the manual setting for the nic card setup as 10.0.0.1 netmask will be set when you hit enter to go down to the next line. Then put default the gateway as 10.0.0.1 and leave dns and everything below that blank.&lt;br /&gt;
&lt;br /&gt;
Once you are done installing redhat 9.0 on your machine you must install the various programs above and create some files.&lt;br /&gt;
&lt;br /&gt;
First you must install nano by doing this in a terminal&lt;br /&gt;
&lt;br /&gt;
rpm –i nano-1.2.3-1.i386.rpm&lt;br /&gt;
&lt;br /&gt;
Nano is then installed.&lt;br /&gt;
&lt;br /&gt;
Then you must untar dhcp by doing this in a terminal&lt;br /&gt;
&lt;br /&gt;
tar xzvf dhcp-3.0pl2.tar.gz&lt;br /&gt;
&lt;br /&gt;
then cd into dhcp-3.0pl2 directory that is created&lt;br /&gt;
&lt;br /&gt;
type in ./configure&lt;br /&gt;
then make&lt;br /&gt;
then make install&lt;br /&gt;
you now need to get out of the dhcp-3.0pl2 directory by typing this&lt;br /&gt;
&lt;br /&gt;
cd ..&lt;br /&gt;
&lt;br /&gt;
now you should be in a prompt with&lt;br /&gt;
&lt;br /&gt;
root@localhost root# &lt;br /&gt;
&lt;br /&gt;
Now you need to make a few files. You do this by the touch command in your terminal.&lt;br /&gt;
&lt;br /&gt;
touch /etc/dhcpd.conf&lt;br /&gt;
&lt;br /&gt;
you then need to make a directory. You do this by using the mkdir command in your terminal&lt;br /&gt;
&lt;br /&gt;
mkdir /var/state/dhcp&lt;br /&gt;
&lt;br /&gt;
you then make a text file in this directory while still in root&lt;br /&gt;
&lt;br /&gt;
touch /var/state/dhcp/dhcpd.leases&lt;br /&gt;
&lt;br /&gt;
Now you must configure your /etc/dhcpd.conf file.&lt;br /&gt;
You do this by using nano.&lt;br /&gt;
&lt;br /&gt;
nano /etc/dhcpd.conf&lt;br /&gt;
&lt;br /&gt;
when you are done editing the file press ctrl + x in order to exit and press y to save changes to the file&lt;br /&gt;
&lt;br /&gt;
An example of the my /etc/dhcpd.conf file would be this. (My network is a class A network.)&lt;br /&gt;
&lt;br /&gt;
#/etc/dhcpd.conf&lt;br /&gt;
ddns-update-style interim;&lt;br /&gt;
&lt;br /&gt;
subnet 10.0.0.0 netmask 255.255.0.0 {&lt;br /&gt;
default-lease-time 63000;&lt;br /&gt;
max-lease-time 72000;&lt;br /&gt;
option routers 10.0.0.1;&lt;br /&gt;
option subnet-mask 255.255.0.0;&lt;br /&gt;
option domain-name-servers this is provided by your isp if there are more than one dns server separate by a comma;&lt;br /&gt;
range 10.0.0.2 10.0.0.253;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
You now need to make the file /etc/sysconfig/iptables&lt;br /&gt;
&lt;br /&gt;
You again use the touch command to do this.&lt;br /&gt;
&lt;br /&gt;
touch /etc/sysconfig/iptables&lt;br /&gt;
&lt;br /&gt;
once you have created this file you need to go into it and place your iptables rules. &lt;br /&gt;
&lt;br /&gt;
Again nano into the file and enter the following data by using this command&lt;br /&gt;
&lt;br /&gt;
nano /etc/sysconfig/iptables&lt;br /&gt;
&lt;br /&gt;
when you are done editing the file press ctrl + x in order to exit and press y to save changes to the file&lt;br /&gt;
&lt;br /&gt;
An example of my file is:&lt;br /&gt;
&lt;br /&gt;
# iptables - configuration files for iptables in Red Hat Linux 8.0&lt;br /&gt;
#&lt;br /&gt;
# This is appropriate for protecting a single workstation.&lt;br /&gt;
# &lt;br /&gt;
# The script could be a lot more rigorous, e.g., only allow&lt;br /&gt;
# selected outbound ports, rather than allowing all outbound&lt;br /&gt;
# traffic, use REJECT rather than DROP, etc. However, the &lt;br /&gt;
# goal of this script was to provide some protection for ports &lt;br /&gt;
# while minimizing the number of checks made on each packet.&lt;br /&gt;
#&lt;br /&gt;
# This file should be owned by user root, group root.&lt;br /&gt;
# The permissions on this file should be set to 600.&lt;br /&gt;
#&lt;br /&gt;
# Edit lines as necessary, then uncomment (remove hash mark) the &lt;br /&gt;
# lines you wish to use.&lt;br /&gt;
#&lt;br /&gt;
# Although every precaution has been taken in the preparation of this&lt;br /&gt;
# file, the author assumes no responsibility for errors or omissions.&lt;br /&gt;
# Neither is any liability assumed for damages resulting from the use of&lt;br /&gt;
# the information contained herein.&lt;br /&gt;
#&lt;br /&gt;
# m-woo@uiuc.edu 9 Jan 2003&lt;br /&gt;
#&lt;br /&gt;
*filter&lt;br /&gt;
:INPUT DROP [0:0]&lt;br /&gt;
:FORWARD DROP [0:0]&lt;br /&gt;
:OUTPUT DROP [0:0]&lt;br /&gt;
&lt;br /&gt;
## Drop all incoming fragments&lt;br /&gt;
-A INPUT -i eth0 -f -j DROP&lt;br /&gt;
&lt;br /&gt;
## Drop outside packets with localhost address - anti-spoofing measure&lt;br /&gt;
-A INPUT -s 10.0.0.1/255.0.0.0 -i ! lo -j DROP&lt;br /&gt;
&lt;br /&gt;
## Pass all locally-originating packets&lt;br /&gt;
-A INPUT -i lo -j ACCEPT&lt;br /&gt;
-A OUTPUT -o lo -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Accept ICMP ping echo request packets&lt;br /&gt;
## (this allows other people to ping your machine, among other things),&lt;br /&gt;
-A INPUT -p icmp --icmp-type echo-request -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Accept all traffic from a specific machine with IP x.x.x.x&lt;br /&gt;
## replace x.x.x.x with the desired IP, then uncomment the line.&lt;br /&gt;
-A INPUT -p tcp -m tcp --syn -s 10.0.0.0 -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Accept traffic on port p from a specific machine with IP x.x.x.x&lt;br /&gt;
## replace p with the desired port number, and replace x.x.x.x with &lt;br /&gt;
## the desired IP, then uncomment the line.&lt;br /&gt;
-A INPUT -p tcp -m tcp --syn -s 10.0.0.1 --dport 80 -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Accept all inbound ssh traffic&lt;br /&gt;
#-A INPUT -p tcp -m tcp --syn --dport 22 -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Accept all inbound identd&lt;br /&gt;
#-A INPUT -p tcp -m tcp --syn --dport 113 -j ACCEPT&lt;br /&gt;
## or you can reject and send back a TCP RST packet instead&lt;br /&gt;
#-A INPUT -p tcp -m tcp --dport 113 -j REJECT --reject-with tcp-reset&lt;br /&gt;
&lt;br /&gt;
## Allow all sendmail SMTP traffic&lt;br /&gt;
#-A INPUT -p tcp -m tcp --syn --dport 25 -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Allow all sendmail MSA traffic&lt;br /&gt;
#-A INPUT -p tcp -m tcp --syn --dport 587 -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Allow all web server access (port 80)&lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 80 -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Allow all secure web server access (port 443)&lt;br /&gt;
-A INPUT -p tcp -m tcp --syn --dport 443 -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Allow inbound established and related outside communication &lt;br /&gt;
-A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT&lt;br /&gt;
&lt;br /&gt;
## Drop outside initiated connections&lt;br /&gt;
-A INPUT -m state --state NEW -j REJECT&lt;br /&gt;
&lt;br /&gt;
## Allow all outbound tcp, udp, icmp traffic with state&lt;br /&gt;
-A OUTPUT -p tcp -m state --state NEW,ESTABLISHED -j ACCEPT&lt;br /&gt;
-A OUTPUT -p udp -m state --state NEW,ESTABLISHED -j ACCEPT&lt;br /&gt;
-A OUTPUT -p icmp -m state --state NEW,ESTABLISHED,RELATED -j ACCEPT&lt;br /&gt;
COMMIT&lt;br /&gt;
&lt;br /&gt;
You also need to add the line&lt;br /&gt;
&lt;br /&gt;
echo 1 &amp;gt; /proc/sys/net/ipv4/ip_forward &lt;br /&gt;
&lt;br /&gt;
to your /etc/rc.d/rc.local file&lt;br /&gt;
&lt;br /&gt;
also hit enter twice after the above line and put&lt;br /&gt;
&lt;br /&gt;
dhcpd&lt;br /&gt;
&lt;br /&gt;
This will automatically start your dhcpd server for you on startup of your machine.&lt;br /&gt;
&lt;br /&gt;
Now you need to install firestarter.&lt;br /&gt;
&lt;br /&gt;
You do this using the rpm command&lt;br /&gt;
&lt;br /&gt;
rpm –i firestarter-0.9.2-3.i386.rpm&lt;br /&gt;
&lt;br /&gt;
Now go into your terminal and run the firestarter setup by typing firestarter and hitting enter.&lt;br /&gt;
&lt;br /&gt;
Setup Guide:&lt;br /&gt;
1. A gui setup should pop up.&lt;br /&gt;
2. Click Forward&lt;br /&gt;
3. There should be two nics detected eth0 and eth1 &lt;br /&gt;
4. Unclick start at dial out&lt;br /&gt;
5. But put a check in IP address assigned via DHCP&lt;br /&gt;
6. Then click forward &lt;br /&gt;
7. On the next screen click Enable Network Address Translation &lt;br /&gt;
8. Then set your internal device as eth1&lt;br /&gt;
9. Then click Specify internal network IP range manually &lt;br /&gt;
10. Internal network address range 10.0.0.1/8&lt;br /&gt;
11. Now click forward&lt;br /&gt;
12. Click Enable Public access to the following services:&lt;br /&gt;
13. Put a check in www, dns, dhcp, ftp, SSL web, Xwindows, NTP, and POP &lt;br /&gt;
14. Now click forward&lt;br /&gt;
15. On the next screen click Enable ToS filtering related to the following packets&lt;br /&gt;
16. Check everything on the left and then check throughput on the right&lt;br /&gt;
17. Now click forward&lt;br /&gt;
18. On the next screen click Enable ICMP filtering related to the following packets:&lt;br /&gt;
19. Check Echo, Traceroute, MS Traceroute, address masking, and Redirection&lt;br /&gt;
20. Now click forward&lt;br /&gt;
21. And click save &lt;br /&gt;
22. Once you save it and firestarter starts up go into the tab that says Rules.&lt;br /&gt;
23. Go to Open ports and double click. Add the ports 80, and 53&lt;br /&gt;
24. You can add more ports as you need later on by doing the same thing.&lt;br /&gt;
&lt;br /&gt;
Now reboot your machine by going to your terminal and typing shutdown –r now&lt;br /&gt;
&lt;br /&gt;
Once it reboots log in as root and then go to the redhat toolbar and click the redhat icon go up till you have your mouse over run program. A box will pop up and you need to type in firestarter to run the firestarter program. &lt;br /&gt;
&lt;br /&gt;
Congratulations you have now setup a default gateway and router for your home network. The nic you setup as eth0 will have a strait through cat5 cable going from your cable modem to that nic card. You then Have a crossover cable going from your eth1 card to either your switch if you want to connect more than one computer or directly to the back of your computer if you want to just have one client for the time being, or for just testing purposes. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Comment:&lt;br /&gt;
&lt;br /&gt;
Brant Freidank – Use this and distribute this tutorial to anyone you see fit. You can modify this tutorial to your needs if you wish. But please give credit where it is due for the tutorial.&lt;/div&gt;</summary>
		<author><name>Bmfmyth</name></author>
	</entry>
</feed>