[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [ezjail] Help with jail routing

skridsko grafstrom wrote:
> Hi,
> I need some advice on how to get a jail setup as decribed below:
> 1) single ethernet interface lnc0
> netmask
> 2) pptp netgraph interface ng0
> -> (point to point)
> 3) default gateway is via lnc0
> I wish to create a jail which uses ng0 as the gateway, ie. all traffic
> in and out of the jail is routed via pptp. The default gateway cannot
> be changed in my setup (part of the challenge here, since you cannot
> change the default gateway within a jail). How should I go about doing
> this? Thanks a lot!

I think you can do that with the pf packetfilter, something like:

pass out on lnc0 route-to (ng0, from <jailip-addr> to any