From owner-freebsd-pf@FreeBSD.ORG Sun May 7 21:38:54 2006 Return-Path: X-Original-To: freebsd-pf@freebsd.org Delivered-To: freebsd-pf@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id DCDAF16A401 for ; Sun, 7 May 2006 21:38:54 +0000 (UTC) (envelope-from solinym@gmail.com) Received: from py-out-1112.google.com (py-out-1112.google.com [64.233.166.182]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6ED0C43D45 for ; Sun, 7 May 2006 21:38:54 +0000 (GMT) (envelope-from solinym@gmail.com) Received: by py-out-1112.google.com with SMTP id e30so1228154pya for ; Sun, 07 May 2006 14:38:53 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=UcwOawR+5xMa4SgWvgZMUgmdIzeHBJr4QEAFFQEt9/px0qKM/wOCfdzaEZjaFych3tjdK6PlMNw15M/Pxmtf15CcHeQG49foSBD1vQZjOde4iq4/VHtqd/E9l21dnfNYiippiF6K8uroCVpqfl6BA3ZaK2cuz2PwjcWcL6gjvAQ= Received: by 10.35.15.11 with SMTP id s11mr179299pyi; Sun, 07 May 2006 14:38:53 -0700 (PDT) Received: by 10.35.30.16 with HTTP; Sun, 7 May 2006 14:38:53 -0700 (PDT) Message-ID: Date: Sun, 7 May 2006 16:38:53 -0500 From: "Travis H." To: "Aguiar Magalhaes" In-Reply-To: <20060507003840.46676.qmail@web31608.mail.mud.yahoo.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Content-Disposition: inline References: <20060507003840.46676.qmail@web31608.mail.mud.yahoo.com> Cc: freebsd-pf@freebsd.org Subject: Re: logging pass rules X-BeenThere: freebsd-pf@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Technical discussion and general questions about packet filter \(pf\)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 07 May 2006 21:38:54 -0000 On 5/6/06, Aguiar Magalhaes wrote: > I'd like to make the same with the pass rules and then > to know the matched pass rule: > > block log all > pass in on $int_if inet proto tcp from $internal_net > to any port 80 keep state > pass in on $int_if proto udp from $internal_net to any > port 53 keep state > ... etc > > Do I have to add the word "log" for each pass rule ? > Is there another way ? pfctl -s rules -v -v (check "Evaluations" and "Packets" fields) > How can i do it ? p=3D"pass log" $p in on $int_if inet proto tcp from $interna_net... See? I've saved you two whole bytes per rule! -- "Curiousity killed the cat, but for a while I was a suspect" -- Steven Wrig= ht Security Guru for Hire http://www.lightconsulting.com/~travis/ -><- GPG fingerprint: 9D3F 395A DAC5 5CCC 9066 151D 0A6B 4098 0C55 1484