Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 21 Feb 2002 19:29:54 +0100
From:      Florian Nigsch <flo@nigsch.com>
To:        freebsd-questions@freebsd.org
Subject:   IPFW rules
Message-ID:  <20020221192954.A50541@nigsch.com>

next in thread | raw e-mail | index | archive | help
Hi all,

On a dualhomed host, FreeBSD 4.5-STABLE, consider the following:

ed0 = 1.2.3.4 (official IP)
ed1 = 192.168.1.0 (unoffical IP)

the box runs NATd.

-> Traffic accounting:

If I only want to count the actual traffic coming from / going to the Internet,
is the rule
	count ip from any to any via ed0
sufficient? To count the traffic from the inside hosts (192.168.1.0/24) to and
from the Internet, the rules
	count ip from 192.168.1.0/24 to any
	count ip from any to 192.168.1.0/24
should work. But that includes the internal traffic as well. Do I get this
internal traffic with
	count ip from any to any via ed1
? 

To what this all boils down: When a packet from an inside host (192.168.1.0/24)
goes out to the internet, when does NATd change the adress and hence which
counters are updatedb?

thanks,

flo

-- 

---
Florian Nigsch <flo@nigsch.com>
http://flo.nigsch.com/
PGP key: http://flo.nigsch.com/fnigsch.asc

-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GE d- s: a-- C++ UB++++ P+ L- E--- W N+ o+ K- w-- 
O-- M- V- PS+ PE Y+ PGP++ 5 X+ R* tv-- b+ DI+++++ D++ 
G- e* h r* y+++++ 
------END GEEK CODE BLOCK------

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020221192954.A50541>