From mboxrd@z Thu Jan 1 00:00:00 1970 From: Patrick McHardy Subject: Re: [resend] Passive OS fingerprint xtables match. Date: Thu, 04 Jun 2009 13:53:05 +0200 Message-ID: <4A27B5A1.9050300@trash.net> References: <20090511095343.GA30778@ioremap.net> <4A1D6A20.8050404@trash.net> <20090604113723.GA13018@ioremap.net> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit Cc: netdev@vger.kernel.org, David Miller , "Paul E. McKenney" , Netfilter Development Mailinglist , Jan Engelhardt To: Evgeniy Polyakov Return-path: Received: from stinky.trash.net ([213.144.137.162]:62583 "EHLO stinky.trash.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751512AbZFDLxG (ORCPT ); Thu, 4 Jun 2009 07:53:06 -0400 In-Reply-To: <20090604113723.GA13018@ioremap.net> Sender: netfilter-devel-owner@vger.kernel.org List-ID: Evgeniy Polyakov wrote: > Hi. > > On Wed, May 27, 2009 at 06:28:16PM +0200, Patrick McHardy (kaber@trash.net) wrote: >>> You will find something like this in the syslog: >>> Windows [2000:SP3:Windows XP Pro SP1, 2000 SP3]: 11.22.33.55:4024 -> >>> 11.22.33.44:139 hops=4 >>> Linux [2.5:]: 1.2.3.4:44448 -> 11.22.33.44:22 hops=4 >> Please convert this to use nf_log_packet(). > > That's hard - there is no hook number in the match function, so we do > not really know if it is forward, input or prerouting. This is really needed, spamming the ring buffer is not a good option. I'd say just add the hook number to xt_match_param. Its a bit inconsistent anyways that we're handing it to checkentry for validation, but not to the match function.