Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 02 Mar 2004 13:52:13 -0500
From:      "Shaun T. Erickson" <ste@ste-land.com>
To:        danny@ricin.com
Cc:        freebsd-questions@freebsd.org
Subject:   Re: How do I test for NO tcp flags being set, in ipfilter? (repost)
Message-ID:  <4044D7DD.9090400@ste-land.com>
In-Reply-To: <200403021933.14816.danny@ricin.com>
References:  <4044C412.1070207@ste-land.com> <200403021933.14816.danny@ricin.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Danny Pansters wrote:

> On Tuesday 02 March 2004 18:27, Shaun T. Erickson wrote:
> 
>>How do I test for NO tcp flags being set, in ipfilter?
> 
> 
> You can filter on TCP flags but seems to me what you really mean is how to 
> check for no TCP options ("nop") rather than no flags:
> 
> 'with opt nop' is a syntax that should work.
> 
> WRT flags, it's my understanding that every TCP packet has at least the A or S 
> flag set. 

Actually, I do mean no flags set. Nmap's null scan uses packets with all 
tcp flags turned off.

On linux, with iptables, I would say "-tcp-flags ALL NONE" to test for 
this (the bits to test and the mask are in reverse order to how we 
specify them in ipfilter). The closest ipfilter statement would be 
"flags /FSRPAU", specifying no flags to be set, out of all flags. I 
don't believe this is legal syntax though.

	-ste



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4044D7DD.9090400>