NetBSD-Users archive

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

Re: NPF port forward

So I've managed to achieve what I was trying to do with the following ipfilter configuration:

pass out from any to any
pass in from any to any

rdr pcn0 from to port = 389 -> port 3890

But if anyone knows if its possible with NPF please do post (or if you think my original NPF config should work let me know if you think I should post it in a devel mailing list as a possible bug).


On 17 January 2013 16:21, William Ross <> wrote:
I'm trying to get all packets sent by one specific machine (with IP to port 389 on my NetBSD box to be redirected to port 3890 (also on my NetBSD box).
My /etc/npf.conf is below and it looks like it should work, but has no effect. When I access port 389 from I still get the service running on port 389, rather than the one on port 3890. Can anyone suggest changes I can make to the config, or am I misusing NAT?

map pcn0 dynamic port 3890 <- pcn0 pass from port 389
group (name "internal", interface pcn0) {
        pass all
group (default) {
        pass final on lo0 all
        block all



Home | Main Index | Thread Index | Old Index