Thread (11 messages) 11 messages, 3 authors, 2012-02-04

RE: [PATCH] tcp: RST: binding oif to iif for tcp v4

flat view

From: Eric Dumazet <hidden>
Date: 2012-02-04 08:07:01

Le vendredi 03 février 2012 à 16:43 -0500, Shawn Lu a écrit :
[shawn Lu] ok.  Tcp socket is bind to device using SO_BINDTODEVICE  to
Limit traffic to specifc interface.  Sometime, it may not have a valid
Source address to get through ip_route_output_key. 
Define "Sometime" ?

We have to force the oif only if requested by the socket in this case.

arg.bound_dev_if = sk ? sk->sk_bound_dev_if : 0;

Thats what we do in tcp_v4_send_ack() :
	if (oif)
		arg.bound_dev_if = oif;
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help