Re: iptables question

This is a discussion on Re: iptables question within the Linux Networking forums, part of the Linux Forums category; Lars von Wedel wrote: > Hello, > > in the iptables tutorial (v 1.1.19 under I.4) I ...


Go Back   Usenet Forums > Linux Forums > Linux Networking

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 08-01-2003
jack
 
Posts: n/a
Default Re: iptables question

Lars von Wedel wrote:
> Hello,
>
> in the iptables tutorial (v 1.1.19 under I.4) I find two lines,
> the first one being
>
> $IPTABLES -A INPUT -p ALL -i $INET_IFACE -m state \
> --state ESTABLISHED,RELATED -j ACCEPT
>
> and the other one
>
> $IPTABLES -A allowed -p TCP -m state \
> --state ESTABLISHED,RELATED -j ACCEPT
>
> To my understanding, the latter one is more specific than the former and
> since it should be evaluated further down the chains, it seems to be
> unnecessary!?


Well, in that second rule, there's no interface defined. So TCP packets
that come in via any other than $INET_IFACE will match this rule.

And, this is an user-created chain ("allowed"), so You should expect
a rule in the INPUT chain that redirects the handling of those packets
here.

But You are correct, if $INET_IFACE was defined in that second rule
above, no packet will ever match that rule because they are already
caught by the first one, thus making the second one redundant.


Cheers, Jack.

--
----------------------------------------------------------------------
My personal reading of the string "MicroSoft" expands to "NanoWeak"...

Reply With Quote
Reply


Thread Tools
Display Modes

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

vB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



All times are GMT +1. The time now is 01:11 PM.


Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO 3.0.0