Skip to content
Snippets Groups Projects
Commit 615ea841 authored by Ken Zhu's avatar Ken Zhu Committed by Gerrit - the friendly Code Review server
Browse files

openswan: Fix nat traversal not working


before using udp encap, need call udp_encap_enable
otherwise, the udp encap packets will go to the socket creator.

Change-Id: I267179c71c646a8d11984990cabe99e198e32322
Signed-off-by: default avatarKen Zhu <guigenz@codeaurora.org>
parent 2ea3f6d2
No related branches found
No related tags found
No related merge requests found
diff -Nur a/linux/net/ipsec/ipsec_tunnel.c openswan-2.6.41/linux/net/ipsec/ipsec_tunnel.c
--- a/linux/net/ipsec/ipsec_tunnel.c 2019-04-03 16:15:42.236848820 -0700
+++ openswan-2.6.41/linux/net/ipsec/ipsec_tunnel.c 2019-04-03 16:17:57.724844808 -0700
@@ -1731,6 +1731,9 @@
sk->sk_destruct = ipsec_tunnel_udp_encap_destruct;
udp_sk(sk)->encap_type = encap_type;
udp_sk(sk)->encap_rcv = klips26_udp_encap_rcv;
+#ifdef NEED_UDP_ENCAP_ENABLE
+ udp_encap_enable();
+#endif
/* add the tunnel to our list so we can check on it later */
list_add(&ctx->link, &ipsec_tunnel_udp_encap_list);
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment