From nobody@FreeBSD.org  Sun Sep 17 15:32:44 2006
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id 351E016A403
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 17 Sep 2006 15:32:44 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [216.136.204.117])
	by mx1.FreeBSD.org (Postfix) with ESMTP id AC97D43D5E
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 17 Sep 2006 15:32:43 +0000 (GMT)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.13.1/8.13.1) with ESMTP id k8HFWhcJ063020
	for <freebsd-gnats-submit@FreeBSD.org>; Sun, 17 Sep 2006 15:32:43 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.13.1/8.13.1/Submit) id k8HFWhQN063019;
	Sun, 17 Sep 2006 15:32:43 GMT
	(envelope-from nobody)
Message-Id: <200609171532.k8HFWhQN063019@www.freebsd.org>
Date: Sun, 17 Sep 2006 15:32:43 GMT
From: Joo Rocha Braga Filho <goffredo@gmail.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: sugestions about ipfw table
X-Send-Pr-Version: www-2.3

>Number:         103328
>Category:       kern
>Synopsis:       [ipfw] [request] sugestions about ipfw table
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-ipfw
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Sun Sep 17 15:40:23 GMT 2006
>Closed-Date:    
>Last-Modified:  Sun Jan 27 10:39:27 UTC 2008
>Originator:     Joo Rocha Braga Filho
>Release:        6.1
>Organization:
Paratyinfo
>Environment:
>Description:
Why not a struct? Something like this:

tablearg
tablearg_2
tablearg_MAC_1
tablearg_MAC_2
tablearg_IP_2

It can be used like this:

ipfw pipe 110 config mask src-ip 0xffffffff bw  64Kbit/s queue 10Kbytes
ipfw pipe 112 config mask src-ip 0xffffffff bw 256Kbit/s queue 40Kbytes
ipfw pipe 210 config mask dst-ip 0xffffffff bw  64Kbit/s queue 10Kbytes
ipfw pipe 212 config mask dst-ip 0xffffffff bw 256Kbit/s queue 40Kbytes
           ...
ipfw table 1 add 192.168.2.2 110 210 00:01:02:03:04:05
ipfw table 1 add 192.168.0.2 112 212 00:03:04:05:06:07
           ...
ipfw add pipe tablearg ip from table(1) to any   MAC any tablearg_MAC_1
ipfw add pipe tablearg_2 ip from any to table(1) MAC tablearg_MAC_1 any
           ...
ipfw add deny ip from any to any

It can help against spoofing IPs and limiting traffic.

thanks,
    Joo Rocha.

>How-To-Repeat:

>Fix:

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->freebsd-ipfw 
Responsible-Changed-By: linimon 
Responsible-Changed-When: Thu Sep 21 11:37:46 UTC 2006 
Responsible-Changed-Why:  
Over to maintainer(s). 

http://www.freebsd.org/cgi/query-pr.cgi?pr=103328 
>Unformatted:
