LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 09-05-2005, 02:46 PM   #16
metallica1973
Senior Member
 
Registered: Feb 2003
Location: Washington D.C
Posts: 2,190

Original Poster
Rep: Reputation: 60

You have inspired me to write my own firewall script for you have made my script look very, to put in nicely stupid. I have view your script and I did have one question?

1 - I have looked at several different types of advanced firewall scripts andl most of them use certain variables that I wasnt quite sure if these were built in variables or were they declared variables that the author specified ?

2nd - have you made the updates to you script available on your site?
 
Old 09-05-2005, 05:50 PM   #17
fotoguy
Senior Member
 
Registered: Mar 2003
Location: Brisbane Queensland Australia
Distribution: Custom Debian Live ISO's
Posts: 1,291

Rep: Reputation: 62
Yes the update is available on my site, the only this is I haven't change the version number on it. Most global variables are usually user defined, but that being said, because of the complexity and versatility of iptables, you can start writing lots of programming code into it as well.

No doubt you would have come across some extremely complex scripts with lots of code but you will notice some iptables rules in amongst them. The error I had with some of the rules was I have just started to learn ipchains and was using the same theory for iptables.

With ipchains all local and routed data packets comes in on the INPUT chain, after that it must check whether it's destined for a local process (eg. say a web server running on the firewall) if no local process is it's destination in then goes to a routing decision. If it has passed in the opposite direction there will be an entry in the nat table so it will then by-pass the FORWARD chain and go directly to the OUTPUT chain.

But for iptables routing data packets by-pass the INPUT and OUTPUT chains and only use the FORWARD chain. Only local processes use the INPUT and OUTPUT chains. So I had to re-write some of the rules and put the logging chains on my FORWARD rules as well.

Also to forward packets to a server on the inside of your network you need to use the prerouting chain, so I manage to set that up to forward remote desktop to a host on the inside. So that should help you out if you run any services behind your firewall.
 
Old 09-05-2005, 07:02 PM   #18
metallica1973
Senior Member
 
Registered: Feb 2003
Location: Washington D.C
Posts: 2,190

Original Poster
Rep: Reputation: 60
I am in the process as we speak of doing a complete overhaul to my iptables script. Once I perfect it I will display it!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
iptables ssh ruleman Linux - Security 3 05-07-2005 03:46 PM
iptables and ssh iomari Linux - Networking 6 10-01-2004 07:44 PM
ssh / iptables bruj3w Linux - Networking 17 08-05-2004 12:00 PM
iptables ssh priority? Emanon Linux - Networking 2 04-15-2004 02:22 AM
Ipchains/iptables/ssh RockerSWE Linux - Networking 6 03-18-2003 03:19 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 08:35 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration