NetBSD-Bugs archive

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

Re: kern/52074: -current npf map directive broken



On May 7,  8:50pm, roy%marples.name@localhost (Roy Marples) wrote:
-- Subject: Re: kern/52074: -current npf map directive broken

| I  think xtos already comitted a fix, but I'm unsure his fix is correct.
| I think the workflow should be this:
| 
| if (ia != NULL)
| 	error = ip_ifaddrvalid(ia);
| else
| 	error = flags & IP_FORWARDING ? 0 : -1;
| if (error != 0) { ...
| 
| The idea is that if we claim to send from an address it has to be valid, 
| but allow the NULL address if forwarded from the filter.
| 
| Does this make sense?
| The same path probably needs adjustment in inet6.

Sure, go for it. Why not put all the logic in ip_ifaddrvalid then?

christos


Home | Main Index | Thread Index | Old Index