Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 30 May 2009 16:12:50 +0400
From:      Gema niskazhu <gemochka@gmail.com>
To:        freebsd-hackers@freebsd.org
Subject:   pf nat+bridge
Message-ID:  <84133fac0905300512ja548f95v756eb4e006f06ac8@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
Hi all!
First of all sorry for my bad english again =)
I've got some problems with nat gw with pf.
My situation is pretty simple:
I've got 2 networks:
external - 10.7.240.0/20
and a internal qemu network with a tap networking
192.168.0/24

External and internal ifaces are bridged

cloned_interfaces="tap0 bridge0"
autobridge_interfaces="bridge0"
autobridge_bridge0="tap0 nfe0"

I've dhcpd on nfe0 and it could be accesed through bridge.
I've such a simple rule in pf.conf:

qemu_if = "tap0"
ext_if = "nfe0"
nat on $ext_if from $qemu_if:network to any -> ($ext_if)
pass from {lo0,$qemu_if:network } to any keep state


But none packet forwarded if we try to acces external host from internal
network.
Is there any specificity of nat'ing bridged networks?
Or i mistaken some where else?
Sorry for dumb question.
Thanks a lot in advance!



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