when i add a nat rule to pf like this
nat on re0 inet from 192.168.2.0/24 to any -> re0
this is destination out interface
the pf nat forward the packet to the ip of re0 ,not interface re0
pfctl -s nat i can see the rule change to this
nat on re0 inet from 192.168.2.0/24 to any -> 192.168.2.3 (re0 ip)
it means that when i change the re0 ip address other the nat will not work, because the nat rule do not bind the interface but bind to the ip of re0 interface,
i wish the pf nat could bind the interface rather then interface's ip.
You should use rule like this:
nat on re0 inet from 192.168.2.0/24 to any -> (re0)
(In reply to Raffeale from comment #0)
Please do not be too fast to open bugs.
You could read the documentation more carefully, search for solutions and ask questions on forums.
sorry ,it's my fault!
thanks a lot!