iptables: are DROP and LOG order sensitive

This is a discussion on iptables: are DROP and LOG order sensitive within the Linux Security forums, part of the System Security and Security Related category; Hi All, Are these two comand order sensitive? iptables -A dsl-in -j DROP iptables -A dsl-in -j LOG --...


Go Back   Usenet Forums > System Security and Security Related > Linux Security

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 07-03-2003
Anthony Ewell
 
Posts: n/a
Default iptables: are DROP and LOG order sensitive

Hi All,

Are these two comand order sensitive?

iptables -A dsl-in -j DROP
iptables -A dsl-in -j LOG --log-level debug --log-prefix "yada ... "

Many thanks,
--Tony
aewell@gbis.com


--
-------------------------
I Fish. Therefore, I am.
-------------------------

Reply With Quote
  #2 (permalink)  
Old 07-04-2003
Hal Burgiss
 
Posts: n/a
Default Re: iptables: are DROP and LOG order sensitive

On Thu, 03 Jul 2003 15:46:27 -0700, Anthony Ewell <aewell@gbis.com> wrote:
>
> Are these two comand order sensitive?
>
> iptables -A dsl-in -j DROP
> iptables -A dsl-in -j LOG --log-level debug --log-prefix "yada ... "


DROP terminates the chain. So you need to flip-flop these, assuming you
are trying to log the DROPs.

--
Hal Burgiss

Reply With Quote
  #3 (permalink)  
Old 07-04-2003
Ken
 
Posts: n/a
Default Re: iptables: are DROP and LOG order sensitive

Hi Tony -

On Thu, 03 Jul 2003 15:46:27 -0700, Anthony Ewell <aewell@gbis.com>
wrote:

>iptables -A dsl-in -j DROP
>iptables -A dsl-in -j LOG --log-level debug --log-prefix "yada ... "


Yes. DROP terminates, LOG continues. So in this order no logging
will occur. You must LOG *before* you DROP (or ACCEPT).

Ken
http://www.ke9nr.net/
Reply With Quote
  #4 (permalink)  
Old 07-04-2003
Allen Kistler
 
Posts: n/a
Default Re: iptables: are DROP and LOG order sensitive

Anthony Ewell wrote:
> Hi All,
>
> Are these two comand order sensitive?
>
> iptables -A dsl-in -j DROP
> iptables -A dsl-in -j LOG --log-level debug --log-prefix "yada ... "


Once you DROP a packet, it's dead and gone. It'll never make it to the
LOG rule.

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 03:20 PM.


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