Hi all,
I would like to create ipip6 tunnel interface with "peeraddr=::" to accept ipip6 packets from anonymous IPv6 addresses.
Here are my ipip6 configurations, and firewall service is stopped now.
uci set network.tun0=interface
uci set network.tun0.proto=ipip6
uci set network.tun0.peeraddr=::
uci set network.tun0.ip4ifaddr=192.0.0.1
uci set network.tun0.auto=1
uci set network.tun0.tunlink=wan6
uci set network.tun0.encaplimit=ignore
Then as follows I am able to see reply packets on the tun0 inteface, but somehow I am not able to see them on the wan6 interface (net0).
root@rt:/# tcpdump -eni net0
ba:7e:45:3e:9a:f7 > fe:15:64:4c:43:bd, ethertype IPv6 (0x86dd), length 138: 2001:db8:1::a01:100:0 > 2001:db8:23::1: 10.1.1.0 > 2.2.2.1: ICMP echo request, id 23, seq 4, length 64
ba:7e:45:3e:9a:f7 > fe:15:64:4c:43:bd, ethertype IPv6 (0x86dd), length 138: 2001:db8:1::a01:100:0 > 2001:db8:23::1: 10.1.1.0 > 2.2.2.1: ICMP echo request, id 23, seq 5, length 64
ba:7e:45:3e:9a:f7 > fe:15:64:4c:43:bd, ethertype IPv6 (0x86dd), length 138: 2001:db8:1::a01:100:0 > 2001:db8:23::1: 10.1.1.0 > 2.2.2.1: ICMP echo request, id 23, seq 6, length 64
root@rt:/# tcpdump -eni ipip6-tun0
In ethertype IPv4 (0x0800), length 100: 10.1.1.0 > 2.2.2.1: ICMP echo request, id 23, seq 54, length 64
Out ethertype IPv4 (0x0800), length 100: 2.2.2.1 > 10.1.1.0: ICMP echo reply, id 23, seq 54, length 64
In ethertype IPv4 (0x0800), length 100: 10.1.1.0 > 2.2.2.1: ICMP echo request, id 23, seq 55, length 64
Out ethertype IPv4 (0x0800), length 100: 2.2.2.1 > 10.1.1.0: ICMP echo reply, id 23, seq 55, length 64
root@rt:/# ip route
default dev ipip6-tun0 proto static scope link
2.2.2.0/24 dev net1 proto kernel scope link src 2.2.2.254
root@rt:/# ip -6 route
2001:db8:23::/64 dev net0 proto kernel metric 256 pref medium
fe80::/64 dev net0 proto kernel metric 256 pref medium
fe80::/64 dev net1 proto kernel metric 256 pref medium
fe80::/64 dev ipip6-tun0 proto kernel metric 256 pref medium
default via 2001:db8:23::ffff dev net0 proto static metric 1024 pref medium
How do I pass a reply packet to net0 and encapsulate it again with IPv6??
Do I need to add any routes?
Thank you in advance.