From mboxrd@z Thu Jan 1 00:00:00 1970 From: Pablo Neira Subject: Re: [PATCH] for some issues in tcp window tracking patch Date: Fri, 21 May 2004 11:33:36 +0200 Sender: netfilter-devel-admin@lists.netfilter.org Message-ID: <40ADCCF0.9040505@eurodev.net> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Return-path: To: Henrik Nordstrom , Netfilter Development Mailinglist In-Reply-To: Errors-To: netfilter-devel-admin@lists.netfilter.org List-Help: List-Post: List-Subscribe: , List-Unsubscribe: , List-Archive: List-Id: netfilter-devel.vger.kernel.org Hi Henrik, Henrik Nordstrom wrote: >>e) I'm not sure if it's worthy optimizing this case. In tcp_new, we are >>checking if a packet is clean as well as size of tcp header, then in >>tcp_packet we will do the same, so we are doing twice the same checking. >>If we consider that general case is that packets are clean, will be this >>double check worthy? >> >> > >But there is one obvious way to optimize this.. move the check for a valid >TCP header to the pkt_to_tuple function. > We can't do that because we are not only checking the tcp header but also using the information for window scaling. regards, Pablo