Linux Netfilter discussions
 help / color / mirror / Atom feed
From: Ralf Spenneberg <lists@spenneberg.org>
To: Atsushi Nakagawa <atnak@chejz.com>
Cc: Netfilter <netfilter@lists.netfilter.org>
Subject: Re: Dropping RST of SYN
Date: 04 Sep 2003 11:13:20 +0200	[thread overview]
Message-ID: <1062666800.1615.23.camel@kermit> (raw)
In-Reply-To: <20030904183027.9CC5.ATNAK@chejz.com>

Am Don, 2003-09-04 um 10.50 schrieb Atsushi Nakagawa:
> What iptables table/rule can I use to drop RST (TCP) packets that're in
> reply to SYN?
> This is what I want it to do:
> 
> -SYN->    [NEW]        -SYN->
>           [CLOSED]     <-RST-
>             ^
>           IF TCP & [NEW]: DROP '<-RST-' & SET [CLOSED]
Using the current state implementation, AFAIK this is not possible.
The RST is already an established packet. There is no way to
differentiate between this RST and a later valid and needed RST packet.
You can only drop all RST packets
-m state --state ESTABLISHED -p tcp --tcp-flags RST,ACK RST,ACK -j DROP

Cheers,

Ralf
-- 
Ralf Spenneberg
RHCE, RHCX

Book: Intrusion Detection für Linux Server   http://www.spenneberg.com
IPsec-Howto				     http://www.ipsec-howto.org
Honeynet Project Mirror:                     http://honeynet.spenneberg.org


  reply	other threads:[~2003-09-04  9:13 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-09-04  8:50 Dropping RST of SYN Atsushi Nakagawa
2003-09-04  9:13 ` Ralf Spenneberg [this message]
2003-09-08  5:51   ` Dharmendra.T
2003-09-08 10:02     ` Chris Brenton
2003-09-08 10:58       ` Atsushi Nakagawa
2003-09-08 11:29         ` Chris Brenton
2003-09-08 11:53         ` Stephen Satchell

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=1062666800.1615.23.camel@kermit \
    --to=lists@spenneberg.org \
    --cc=atnak@chejz.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