Linux Netfilter discussions
 help / color / mirror / Atom feed
From: Jason Opperisano <opie@817west.com>
To: netfilter@lists.netfilter.org
Subject: Re: Question; what is this netfilter logfile entry ?
Date: Sun, 14 Nov 2004 12:02:02 -0500	[thread overview]
Message-ID: <41978F8A.4070000@817west.com> (raw)
In-Reply-To: <000c01c4c9f0$4807a0d0$de0aa8c0@comp>

Bo Jacobsen wrote:
> Nov 14 02:24:48 WF1-HOME kernel: DENY-OUT:.IN= OUT=eth0 SRC=192.168.1.2 DST=198.41.0.4 LEN=560 TOS=0x00 PREC=0xC0 TTL=64 ID=3123 PROTO=ICMP TYPE=3 CODE=3 [SRC=198.41.0.4 DST=192.168.1.2 LEN=532 TOS=0x00 PREC=0x00 TTL=49 ID=41159 PROTO=UDP SPT=53 DPT=51981 LEN=512 ]
> 
> It looks like ICMP with an embedded DNS call  ?.
> What is it exactly, and how would a rule to allow this look like ?

ICMP Type 3 Code 3:  Destination Unreachable, Port Unreachable

your gateway is telling 198.41.0.4 that it's packet with a src port of 
53 destined for 192.168.1.2:51981 was unreachable (i.e. host not 
listening on that port).

refer to:  http://www.iana.org/assignments/icmp-parameters

for the official list.

most of the time, these packets will fall under "-m state --state 
RELATED" however, from a "good Internet citizen" point of view, it's not 
a bad idea to allow ICMP errors codes to/from your gateway (PMTU 
discovery comes to mind).

   # unreachables
   iptables -A INPUT -p icmp --icmp-type 3 -j ACCEPT
   iptables -A OUTPUT -p icmp --icmp-type 3 -j ACCEPT

   # time exceeded
   iptables -A INPUT -p icmp --icmp-type 11 -j ACCEPT
   iptables -A OUTPUT -p icmp --icmp-type 11 -j ACCEPT

   # parameter problem
   iptables -A INPUT -p icmp --icmp-type 12 -j ACCEPT
   iptables -A OUTPUT -p icmp --icmp-type 12 -j ACCEPT

-j

--
Jason Opperisano <opie@817west.com>



  parent reply	other threads:[~2004-11-14 17:02 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-11-14  0:42 newbie question - what is the iptables equivalent of a Linksys "DMZ" ? David Williamson
2004-11-14  0:57 ` Chris Brenton
2004-11-14  2:18 ` Question; what is this netfilter logfile entry ? Bo Jacobsen
2004-11-14  7:42   ` Marc Haber
2004-11-14 10:51   ` Chris Brenton
2004-11-14 21:41     ` Bo Jacobsen
2004-11-14 17:02   ` Jason Opperisano [this message]
2004-11-14 13:35 ` newbie question - what is the iptables equivalent of a Linksys "DMZ" ? Tobias DiPasquale
2004-11-14 16:44 ` Jason Opperisano
2004-11-14 21:05   ` David Williamson

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=41978F8A.4070000@817west.com \
    --to=opie@817west.com \
    --cc=netfilter@lists.netfilter.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox