From owner-freebsd-bugs@FreeBSD.ORG Tue Sep 22 12:30:02 2009 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5522B106568B for ; Tue, 22 Sep 2009 12:30:02 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 198558FC14 for ; Tue, 22 Sep 2009 12:30:02 +0000 (UTC) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id n8MCU12f011321 for ; Tue, 22 Sep 2009 12:30:01 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id n8MCU1OJ011317; Tue, 22 Sep 2009 12:30:01 GMT (envelope-from gnats) Resent-Date: Tue, 22 Sep 2009 12:30:01 GMT Resent-Message-Id: <200909221230.n8MCU1OJ011317@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Jens Kassel Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id ED2771065672 for ; Tue, 22 Sep 2009 12:19:57 +0000 (UTC) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21]) by mx1.freebsd.org (Postfix) with ESMTP id DCB108FC16 for ; Tue, 22 Sep 2009 12:19:57 +0000 (UTC) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.14.3/8.14.3) with ESMTP id n8MCJvma054209 for ; Tue, 22 Sep 2009 12:19:57 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.14.3/8.14.3/Submit) id n8MCJv9X054208; Tue, 22 Sep 2009 12:19:57 GMT (envelope-from nobody) Message-Id: <200909221219.n8MCJv9X054208@www.freebsd.org> Date: Tue, 22 Sep 2009 12:19:57 GMT From: Jens Kassel To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-3.1 Cc: Subject: misc/139058: mbuf cluster leak in ipfilter on FreeBSD 7.2 X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 22 Sep 2009 12:30:02 -0000 >Number: 139058 >Category: misc >Synopsis: mbuf cluster leak in ipfilter on FreeBSD 7.2 >Confidential: no >Severity: critical >Priority: high >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Tue Sep 22 12:30:01 UTC 2009 >Closed-Date: >Last-Modified: >Originator: Jens Kassel >Release: FreeBSD 7.2 release >Organization: Birdstep >Environment: uname -a FreeBSD h167.servicefactory.com 7.2-RELEASE FreeBSD 7.2-RELEASE #0: Fri May 1 08:49:13 UTC 2009 root@walker.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC i386 >Description: ipfilter/ipnat mbuf cluster leak ipf 1.4.28 A fix for this was already implemented on FreeBSD 6.4 but lost in the FreeBSD 7.2. I.e. version 1.4.28 on FreeBSD 6.4 differs from 1.4.28 on FreeBSD 7.2 >How-To-Repeat: Force many bad nats ipnat -s mapped in 25367 out 1563123 added 186173 expired 159616 no memory 0 bad nat 2142640 inuse 26253 orphans 0 rules 154 wilds 0 hash efficiency 49.56% bucket usage 39.71% minimal length 0 maximal length 9 average length 2.018 TCP Entries per state 0 1 2 3 4 5 6 7 8 9 10 11 0 22636 0 0 22 3404 108 0 0 0 1 60 mbuf cluster will leak .... >Fix: Apply the following patch --- ip_fil_freebsd.c 26 Oct 2006 11:22:04 -0000 1.1.1.1.2.2 +++ ip_fil_freebsd.c 21 Feb 2007 13:39:55 -0000 @@ -1016,7 +1016,7 @@ break; case -1 : error = -1; - goto done; + goto bad; break; } >Release-Note: >Audit-Trail: >Unformatted: