From owner-svn-src-all@FreeBSD.ORG Wed Oct 13 22:07:58 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 39B78106566B; Wed, 13 Oct 2010 22:07:58 +0000 (UTC) (envelope-from luigi@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 28A3D8FC08; Wed, 13 Oct 2010 22:07:58 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o9DM7wXr002368; Wed, 13 Oct 2010 22:07:58 GMT (envelope-from luigi@svn.freebsd.org) Received: (from luigi@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o9DM7wcH002366; Wed, 13 Oct 2010 22:07:58 GMT (envelope-from luigi@svn.freebsd.org) Message-Id: <201010132207.o9DM7wcH002366@svn.freebsd.org> From: Luigi Rizzo Date: Wed, 13 Oct 2010 22:07:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r213810 - head/sbin/ipfw X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 13 Oct 2010 22:07:58 -0000 Author: luigi Date: Wed Oct 13 22:07:57 2010 New Revision: 213810 URL: http://svn.freebsd.org/changeset/base/213810 Log: document logging through bpf Modified: head/sbin/ipfw/ipfw.8 Modified: head/sbin/ipfw/ipfw.8 ============================================================================== --- head/sbin/ipfw/ipfw.8 Wed Oct 13 22:04:55 2010 (r213809) +++ head/sbin/ipfw/ipfw.8 Wed Oct 13 22:07:57 2010 (r213810) @@ -557,28 +557,33 @@ packet delivery. Note: this condition is checked before any other condition, including ones such as keep-state or check-state which might have side effects. .It Cm log Op Cm logamount Ar number -When a packet matches a rule with the +Packets matching a rule with the .Cm log -keyword, a message will be -logged to +keyword will be made available for logging in two ways: +if the sysctl variable +.Va net.inet.ip.fw.verbose +is set to 0 (default), one can use +.Xr bpf 4 +attached to the +.Xr ipfw0 +pseudo interface. There is no overhead if no +.Xr bpf +is attached to the pseudo interface. +.Pp +If +.Va net.inet.ip.fw.verbose +is set to 1, packets will be logged to .Xr syslogd 8 with a .Dv LOG_SECURITY -facility. -The logging only occurs if the sysctl variable -.Va net.inet.ip.fw.verbose -is set to 1 -(which is the default when the kernel is compiled with -.Dv IPFIREWALL_VERBOSE ) -and the number of packets logged so far for that -particular rule does not exceed the +facility up to a maximum of .Cm logamount -parameter. +packets. If no .Cm logamount is specified, the limit is taken from the sysctl variable .Va net.inet.ip.fw.verbose_limit . -In both cases, a value of 0 removes the logging limit. +In both cases, a value of 0 means unlimited logging. .Pp Once the limit is reached, logging can be re-enabled by clearing the logging counter or the packet counter for that entry, see the