Re: Policy-based routing with ipf

[email protected] (Michael van Elst)
Newsgroups gmane.os.netbsd.devel.network
Organization Serpens User Group
Message-ID <[email protected]>
[email protected] (Stephen Borrill) writes:

>   10.3.0.1 <-> NetBSD <-> 192.168.102.1
>10.3.0.254 <-> filter <-> 192.168.102.254

>My plan is to use policy-based routing to direct matched traffic back to 
>192.168.102.x via 10.3.0.254 (e.g. http or smb). I cannot work out how to 
>achieve this from the man page though.


Assuming the following interface names:

             wm0        wm1
>   10.3.0.1 <-> NetBSD <-> 192.168.102.1

this should be:

pass out quick on wm1 to wm0:10.3.0.254 from 10.3.0.1 to 192.168.102.0/24

pass out quick on wm1               packets sent by wm1
to wm0:10.3.0.254                   redirect to wm0 with next hop 10.3.0.254
from 10.3.0.1                       if src is the NetBSD box
to 192.168.102.0/24                 and dst is on the other net
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.