Thread (20 messages) 20 messages, 2 authors, 2024-10-22

Re: [PATCH net-next v3 02/10] net: ip: make fib_validate_source() return drop reason

From: Paolo Abeni <pabeni@redhat.com>
Date: 2024-10-21 10:36:54
Also in: bpf, bridge, lkml, netfilter-devel

On 10/21/24 12:20, Paolo Abeni wrote:
On 10/15/24 16:07, Menglong Dong wrote:
quoted
@@ -1785,9 +1785,10 @@ static int __mkroute_input(struct sk_buff *skb, const struct fib_result *res,
 		return -EINVAL;
 	}
 
-	err = fib_validate_source(skb, saddr, daddr, dscp, FIB_RES_OIF(*res),
-				  in_dev->dev, in_dev, &itag);
+	err = __fib_validate_source(skb, saddr, daddr, dscp, FIB_RES_OIF(*res),
+				    in_dev->dev, in_dev, &itag);
 	if (err < 0) {
+		err = -EINVAL;
 		ip_handle_martian_source(in_dev->dev, in_dev, skb, daddr,
 					 saddr);
I'm sorry for not noticing this issue before, but must preserve (at
least) the -EXDEV error code from the unpatched version or RP Filter MIB
accounting in ip_rcv_finish_core() will be fooled.
Please, ignore this comment. ENOCOFFEE here, sorry.

/P
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help