Skip to contentSkip to conversation

tproxy: check for transparent flag in ip_route_newports

PATCH Applied Ulrich Weber 2 participants 2 messages Sep 27, 2010

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 tproxy: check for transparent flag in ip_route_newports

as done in ip_route_connect()

---
 include/net/route.h |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
include/net/route.h +2 -0
index bd732d6..7e5e73b 100644
@@ -199,6 +199,8 @@ static inline int ip_route_newports(struct rtable **rp, u8 protocol,
 		fl.fl_ip_sport = sport;
 		fl.fl_ip_dport = dport;
 		fl.proto = protocol;
+		if (inet_sk(sk)->transparent)
+			fl.flags |= FLOWI_FLAG_ANYSRC;
 		ip_rt_put(*rp);
 		*rp = NULL;
 		security_sk_classify_flow(sk, &fl);
Signature · 1 line
1.7.1