IPv6 ok on router, not routed for LAN

Hi,

I installed OpenWRT on a Netgear R6120 and configuring IPv6 behind a Freebox server ("4K" type) acting as a router (WiFi disabled). In a SSH console on the R6120, "ping6 ipv6.google.com" is successful. However on Windows clients connected via WiFi, I have IPv4 but no IPv6 connectivity.

At first I had no IPv6 default route from LAN, until I had set the following in Luci:

  • IPv6 ULA-prefix fd69:cdc6:cb9d::/48
  • Option "Always announce default router" checked

Now from Windows console, "route print -6" gives:

Active Routes:
If Metric Network Destination Gateway
12 266 ::/0 fe80::1659:c0ff:fecf:95ab
1 306 ::1/128 On-link
12 18 fd69:cdc6:cb9d::/64 On-link
12 266 fd69:cdc6:cb9d::a6b/128 On-link
12 266 fd69:cdc6:cb9d:0:9c6d:d336:f90d:533f/128
On-link
12 266 fd69:cdc6:cb9d:0:bcac:ce5b:6ae4:4caf/128
On-link
12 266 fe80::/64 On-link
12 266 fe80::bcac:ce5b:6ae4:4caf/128
On-link
1 306 ff00::/8 On-link
12 266 ff00::/8 On-link
Persistent Routes:
None

"ping -6 ipv6.google.com" from Windows still fails but now, name resolution is successful.
Pinging ipv6.l.google.com [2a00:1450:4007:812::200e] with 32 bytes of data:
Destination net unreachable.

Seems like OpenWrt does not route packets from LAN to the default route provided by the Freebox, while if pinging from OpenWrt itself is fine (e.g. when no forwarding is implied). I suspect either RA configuration (I'm still a newbie regarding IPv6), firewall blocking traffic or IPv6 forwarding disabled?

I tried various IPv6 settings but nothing worked; my current settings are:

  • Router Advertisement-Service: server
  • DHCPv6-Service: server
  • NDP-Proxy: hybrid
  • DHCPv6-Mode: stateless + stateful

What could be wrong? Which settings could I check to target the issue?

Additional information: if I activate DHCPv6 server on Freebox then I also lose pings from OpenWrt, so I let it deactivated.

From OpenWrt SSH, extract from "tcpdump -n ip6":

18:41:13.693379 IP6 fd69:cdc6:cb9d:0:9c6d:d336:f90d:533f > 2a00:1450:4007:808::200e: ICMP6, echo request, seq 41, length 40
18:41:13.693673 IP6 fd69:cdc6:cb9d::1 > fd69:cdc6:cb9d:0:9c6d:d336:f90d:533f: ICMP6, destination unreachable, unknown unreach code (5)
0x0000: 0105 7a92 0000 0000 6000 0000 0028 3a80
0x0010: fd69 cdc6 cb9d 0000 9c6d d336 f90d 533f
0x0020: 2a00 1450 4007 0808 0000 0000 0000 200e
0x0030: 8000 dba1 0001 0029 6162 6364 6566 6768
0x0040: 696a 6b6c 6d6e 6f70 7172 7374 7576 7761
0x0050: 6263 6465 6667 6869

Let's see the configs. Could you run the following commands and post them here using the "Preformatted text </> " button:
grafik
Remember to redact passwords, MAC addresses and any public IP addresses you may have

uci export network; uci export wireless; \
uci export dhcp; uci export firewall; \
head -n -0 /etc/firewall.user; \
iptables-save -c; ip6tables-save -c; \
ip -4 addr ; ip -4 ro li tab all ; ip -4 ru; \
ip -6 addr ; ip -6 ro li tab all ; ip -6 ru; \
ls -l  /etc/resolv.* /tmp/resolv.*; head -n -0 /etc/resolv.* /tmp/resolv.*

Your R6120 needs at least a free /64 prefix assigned to hand out to its clients. It seems it couldn't request a delegated prefix upstream. That's why the option "Always announce default router" needs to be checked in order for IPv6 router advertisements to work. Check if your ISP supports DHCPv6 prefix delegation, or some other way to get a prefix for your R6120. If you only get a single /64 prefix, it already in use by your upstream router. In that case you might want to take a look at the NDP proxy.

1 Like

My configs as you kindly requested:

package network

config interface 'loopback'
        option ifname 'lo'
        option proto 'static'
        option ipaddr '127.0.0.1'
        option netmask '255.0.0.0'

config globals 'globals'
        option ula_prefix 'fd69:cdc6:cb9d::/48'

config interface 'lan'
        option type 'bridge'
        option ifname 'eth0.1'
        option proto 'static'
        option ipaddr '192.168.1.1'
        option netmask '255.255.255.0'
        option ip6assign '60'
        option ip6ifaceid '::1'

config device 'lan_eth0_1_dev'
        option name 'eth0.1'
        option macaddr 'xx:xx:xx:xx:xx:ab'

config interface 'wan'
        option ifname 'eth0.2'
        option proto 'dhcp'

config device 'wan_eth0_2_dev'
        option name 'eth0.2'
        option macaddr 'xx:xx:xx:xx:xx:ac'

config interface 'wan6'
        option ifname 'eth0.2'
        option proto 'dhcpv6'

config switch
        option name 'switch0'
        option reset '1'
        option enable_vlan '1'

config switch_vlan
        option device 'switch0'
        option vlan '1'
        option ports '0 1 2 3 6t'

config switch_vlan
        option device 'switch0'
        option vlan '2'
        option ports '4 6t'

package wireless

config wifi-device 'radio0'
        option type 'mac80211'
        option hwmode '11g'
        option path 'platform/10300000.wmac'
        option htmode 'HT20'
        option country 'FR'
        option channel 'auto'

config wifi-iface 'default_radio0'
        option device 'radio0'
        option network 'lan'
        option mode 'ap'
        option key 'xxxx'
        option ssid 'xxxx'
        option encryption 'psk2'

config wifi-device 'radio1'
        option type 'mac80211'
        option hwmode '11a'
        option path 'pci0000:00/0000:00:00.0/0000:01:00.0'
        option htmode 'VHT80'
        option country 'FR'
        option channel 'auto'

config wifi-iface 'default_radio1'
        option device 'radio1'
        option network 'lan'
        option mode 'ap'
        option key 'xxxx'
        option ssid 'xxxx'
        option encryption 'psk2'

package dhcp

config dnsmasq
        option domainneeded '1'
        option boguspriv '1'
        option filterwin2k '0'
        option localise_queries '1'
        option rebind_protection '1'
        option rebind_localhost '1'
        option local '/lan/'
        option domain 'lan'
        option expandhosts '1'
        option nonegcache '0'
        option authoritative '1'
        option readethers '1'
        option leasefile '/tmp/dhcp.leases'
        option resolvfile '/tmp/resolv.conf.auto'
        option nonwildcard '1'
        option localservice '1'

config dhcp 'lan'
        option interface 'lan'
        option start '100'
        option limit '150'
        option leasetime '12h'
        option ra 'server'
        option ra_management '1'
        option dhcpv6 'server'
        option ra_default '1'

config dhcp 'wan'
        option interface 'wan'
        option ignore '1'

config odhcpd 'odhcpd'
        option maindhcp '0'
        option leasefile '/tmp/hosts/odhcpd'
        option leasetrigger '/usr/sbin/odhcpd-update'
        option loglevel '4'

package firewall

config defaults
        option syn_flood '1'
        option input 'ACCEPT'
        option output 'ACCEPT'
        option forward 'REJECT'

config zone
        option name 'lan'
        list network 'lan'
        option input 'ACCEPT'
        option output 'ACCEPT'
        option forward 'ACCEPT'

config zone
        option name 'wan'
        list network 'wan'
        list network 'wan6'
        option input 'REJECT'
        option output 'ACCEPT'
        option forward 'REJECT'
        option masq '1'
        option mtu_fix '1'

config forwarding
        option src 'lan'
        option dest 'wan'

config rule
        option name 'Allow-DHCP-Renew'
        option src 'wan'
        option proto 'udp'
        option dest_port '68'
        option target 'ACCEPT'
        option family 'ipv4'

config rule
        option name 'Allow-Ping'
        option src 'wan'
        option proto 'icmp'
        option icmp_type 'echo-request'
        option family 'ipv4'
        option target 'ACCEPT'

config rule
        option name 'Allow-IGMP'
        option src 'wan'
        option proto 'igmp'
        option family 'ipv4'
        option target 'ACCEPT'

config rule
        option name 'Allow-DHCPv6'
        option src 'wan'
        option proto 'udp'
        option src_ip 'fc00::/6'
        option dest_ip 'fc00::/6'
        option dest_port '546'
        option family 'ipv6'
        option target 'ACCEPT'

config rule
        option name 'Allow-MLD'
        option src 'wan'
        option proto 'icmp'
        option src_ip 'fe80::/10'
        list icmp_type '130/0'
        list icmp_type '131/0'
        list icmp_type '132/0'
        list icmp_type '143/0'
        option family 'ipv6'
        option target 'ACCEPT'

config rule
        option name 'Allow-ICMPv6-Input'
        option src 'wan'
        option proto 'icmp'
        list icmp_type 'echo-request'
        list icmp_type 'echo-reply'
        list icmp_type 'destination-unreachable'
        list icmp_type 'packet-too-big'
        list icmp_type 'time-exceeded'
        list icmp_type 'bad-header'
        list icmp_type 'unknown-header-type'
        list icmp_type 'router-solicitation'
        list icmp_type 'neighbour-solicitation'
        list icmp_type 'router-advertisement'
        list icmp_type 'neighbour-advertisement'
        option limit '1000/sec'
        option family 'ipv6'
        option target 'ACCEPT'

config rule
        option name 'Allow-ICMPv6-Forward'
        option src 'wan'
        option dest '*'
        option proto 'icmp'
        list icmp_type 'echo-request'
        list icmp_type 'echo-reply'
        list icmp_type 'destination-unreachable'
        list icmp_type 'packet-too-big'
        list icmp_type 'time-exceeded'
        list icmp_type 'bad-header'
        list icmp_type 'unknown-header-type'
        option limit '1000/sec'
        option family 'ipv6'
        option target 'ACCEPT'

config rule
        option name 'Allow-IPSec-ESP'
        option src 'wan'
        option dest 'lan'
        option proto 'esp'
        option target 'ACCEPT'

config rule
        option name 'Allow-ISAKMP'
        option src 'wan'
        option dest 'lan'
        option dest_port '500'
        option proto 'udp'
        option target 'ACCEPT'

config include
        option path '/etc/firewall.user'

# This file is interpreted as shell script.
# Put your custom iptables rules here, they will
# be executed with each firewall (re-)start.

# Internal uci firewall chains are flushed and recreated on reload, so
# put custom rules into the root chains e.g. INPUT or FORWARD or into the
# special user chains, e.g. input_wan_rule or postrouting_lan_rule.
# Generated by iptables-save v1.8.3 on Wed May  6 09:53:07 2020
*nat
:PREROUTING ACCEPT [64877:7906871]
:INPUT ACCEPT [23261:1544197]
:OUTPUT ACCEPT [13617:960752]
:POSTROUTING ACCEPT [464:59954]
:postrouting_lan_rule - [0:0]
:postrouting_rule - [0:0]
:postrouting_wan_rule - [0:0]
:prerouting_lan_rule - [0:0]
:prerouting_rule - [0:0]
:prerouting_wan_rule - [0:0]
:zone_lan_postrouting - [0:0]
:zone_lan_prerouting - [0:0]
:zone_wan_postrouting - [0:0]
:zone_wan_prerouting - [0:0]
[64877:7906871] -A PREROUTING -m comment --comment "!fw3: Custom prerouting rule chain" -j prerouting_rule
[61848:7137838] -A PREROUTING -i br-lan -m comment --comment "!fw3" -j zone_lan_prerouting
[3029:769033] -A PREROUTING -i eth0.2 -m comment --comment "!fw3" -j zone_wan_prerouting
[34963:2797453] -A POSTROUTING -m comment --comment "!fw3: Custom postrouting rule chain" -j postrouting_rule
[110:34808] -A POSTROUTING -o br-lan -m comment --comment "!fw3" -j zone_lan_postrouting
[34499:2737499] -A POSTROUTING -o eth0.2 -m comment --comment "!fw3" -j zone_wan_postrouting
[110:34808] -A zone_lan_postrouting -m comment --comment "!fw3: Custom lan postrouting rule chain" -j postrouting_lan_rule
[61848:7137838] -A zone_lan_prerouting -m comment --comment "!fw3: Custom lan prerouting rule chain" -j prerouting_lan_rule
[34499:2737499] -A zone_wan_postrouting -m comment --comment "!fw3: Custom wan postrouting rule chain" -j postrouting_wan_rule
[34499:2737499] -A zone_wan_postrouting -m comment --comment "!fw3" -j MASQUERADE
[3029:769033] -A zone_wan_prerouting -m comment --comment "!fw3: Custom wan prerouting rule chain" -j prerouting_wan_rule
COMMIT
# Completed on Wed May  6 09:53:07 2020
# Generated by iptables-save v1.8.3 on Wed May  6 09:53:07 2020
*raw
:PREROUTING ACCEPT [7628469:11954001380]
:OUTPUT ACCEPT [74456:46558843]
:zone_lan_helper - [0:0]
[4863085:345437697] -A PREROUTING -i br-lan -m comment --comment "!fw3: lan CT helper assignment" -j zone_lan_helper
COMMIT
# Completed on Wed May  6 09:53:07 2020
# Generated by iptables-save v1.8.3 on Wed May  6 09:53:07 2020
*mangle
:PREROUTING ACCEPT [7628469:11954001380]
:INPUT ACCEPT [82007:7473976]
:FORWARD ACCEPT [7526345:11942046303]
:OUTPUT ACCEPT [74456:46558843]
:POSTROUTING ACCEPT [7597288:11988399688]
:qos_Default - [0:0]
:qos_Default_ct - [0:0]
[13054:807714] -A FORWARD -o eth0.2 -p tcp -m tcp --tcp-flags SYN,RST SYN -m comment --comment "!fw3: Zone wan MTU fixing" -j TCPMSS --clamp-mss-to-pmtu
[0:0] -A qos_Default -j CONNMARK --restore-mark --nfmask 0xf --ctmask 0xf
[0:0] -A qos_Default -m mark --mark 0x0/0xf -j qos_Default_ct
[0:0] -A qos_Default -p udp -m mark --mark 0x0/0xf0 -m length --length 0:500 -j MARK --set-xmark 0x22/0xff
[0:0] -A qos_Default -p icmp -j MARK --set-xmark 0x11/0xff
[0:0] -A qos_Default -p tcp -m mark --mark 0x0/0xf0 -m tcp --sport 1024:65535 --dport 1024:65535 -j MARK --set-xmark 0x44/0xff
[0:0] -A qos_Default -p udp -m mark --mark 0x0/0xf0 -m udp --sport 1024:65535 --dport 1024:65535 -j MARK --set-xmark 0x44/0xff
[0:0] -A qos_Default -j CONNMARK --save-mark --nfmask 0xff --ctmask 0xff
[0:0] -A qos_Default_ct -p tcp -m mark --mark 0x0/0xf -m tcp -m multiport --ports 22,53 -m comment --comment "ssh, dns" -j MARK --set-xmark 0x11/0xff
[0:0] -A qos_Default_ct -p udp -m mark --mark 0x0/0xf -m udp -m multiport --ports 22,53 -m comment --comment "ssh, dns" -j MARK --set-xmark 0x11/0xff
[0:0] -A qos_Default_ct -p tcp -m mark --mark 0x0/0xf -m tcp -m multiport --ports 20,21,25,80,110,443,993,995 -m comment --comment "ftp, smtp, http(s), imap" -j MARK --set-xmark 0x33/0xff
[0:0] -A qos_Default_ct -p tcp -m mark --mark 0x0/0xf -m tcp -m multiport --ports 5190 -m comment --comment "AOL, iChat, ICQ" -j MARK --set-xmark 0x22/0xff
[0:0] -A qos_Default_ct -p udp -m mark --mark 0x0/0xf -m udp -m multiport --ports 5190 -m comment --comment "AOL, iChat, ICQ" -j MARK --set-xmark 0x22/0xff
[0:0] -A qos_Default_ct -j CONNMARK --save-mark --nfmask 0xff --ctmask 0xff
COMMIT
# Completed on Wed May  6 09:53:07 2020
# Generated by iptables-save v1.8.3 on Wed May  6 09:53:07 2020
*filter
:INPUT ACCEPT [0:0]
:FORWARD DROP [0:0]
:OUTPUT ACCEPT [0:0]
:forwarding_lan_rule - [0:0]
:forwarding_rule - [0:0]
:forwarding_wan_rule - [0:0]
:input_lan_rule - [0:0]
:input_rule - [0:0]
:input_wan_rule - [0:0]
:output_lan_rule - [0:0]
:output_rule - [0:0]
:output_wan_rule - [0:0]
:reject - [0:0]
:syn_flood - [0:0]
:zone_lan_dest_ACCEPT - [0:0]
:zone_lan_forward - [0:0]
:zone_lan_input - [0:0]
:zone_lan_output - [0:0]
:zone_lan_src_ACCEPT - [0:0]
:zone_wan_dest_ACCEPT - [0:0]
:zone_wan_dest_REJECT - [0:0]
:zone_wan_forward - [0:0]
:zone_wan_input - [0:0]
:zone_wan_output - [0:0]
:zone_wan_src_REJECT - [0:0]
[11966:1169499] -A INPUT -i lo -m comment --comment "!fw3" -j ACCEPT
[70041:6304477] -A INPUT -m comment --comment "!fw3: Custom input rule chain" -j input_rule
[42230:4261867] -A INPUT -m conntrack --ctstate RELATED,ESTABLISHED -m comment --comment "!fw3" -j ACCEPT
[3037:156828] -A INPUT -p tcp -m tcp --tcp-flags FIN,SYN,RST,ACK SYN -m comment --comment "!fw3" -j syn_flood
[27563:1993103] -A INPUT -i br-lan -m comment --comment "!fw3" -j zone_lan_input
[248:49507] -A INPUT -i eth0.2 -m comment --comment "!fw3" -j zone_wan_input
[7526345:11942046303] -A FORWARD -m comment --comment "!fw3: Custom forwarding rule chain" -j forwarding_rule
[7498649:11939719757] -A FORWARD -m conntrack --ctstate RELATED,ESTABLISHED -m comment --comment "!fw3" -j ACCEPT
[27696:2326546] -A FORWARD -i br-lan -m comment --comment "!fw3" -j zone_lan_forward
[0:0] -A FORWARD -i eth0.2 -m comment --comment "!fw3" -j zone_wan_forward
[0:0] -A FORWARD -m comment --comment "!fw3" -j reject
[12944:1289870] -A OUTPUT -o lo -m comment --comment "!fw3" -j ACCEPT
[61512:45268973] -A OUTPUT -m comment --comment "!fw3: Custom output rule chain" -j output_rule
[47487:44182938] -A OUTPUT -m conntrack --ctstate RELATED,ESTABLISHED -m comment --comment "!fw3" -j ACCEPT
[489:159148] -A OUTPUT -o br-lan -m comment --comment "!fw3" -j zone_lan_output
[13536:926887] -A OUTPUT -o eth0.2 -m comment --comment "!fw3" -j zone_wan_output
[95:12963] -A reject -p tcp -m comment --comment "!fw3" -j REJECT --reject-with tcp-reset
[153:36544] -A reject -m comment --comment "!fw3" -j REJECT --reject-with icmp-port-unreachable
[3037:156828] -A syn_flood -p tcp -m tcp --tcp-flags FIN,SYN,RST,ACK SYN -m limit --limit 25/sec --limit-burst 50 -m comment --comment "!fw3" -j RETURN
[0:0] -A syn_flood -m comment --comment "!fw3" -j DROP
[489:159148] -A zone_lan_dest_ACCEPT -o br-lan -m comment --comment "!fw3" -j ACCEPT
[27696:2326546] -A zone_lan_forward -m comment --comment "!fw3: Custom lan forwarding rule chain" -j forwarding_lan_rule
[27696:2326546] -A zone_lan_forward -m comment --comment "!fw3: Zone lan to wan forwarding policy" -j zone_wan_dest_ACCEPT
[0:0] -A zone_lan_forward -m conntrack --ctstate DNAT -m comment --comment "!fw3: Accept port forwards" -j ACCEPT
[0:0] -A zone_lan_forward -m comment --comment "!fw3" -j zone_lan_dest_ACCEPT
[27563:1993103] -A zone_lan_input -m comment --comment "!fw3: Custom lan input rule chain" -j input_lan_rule
[0:0] -A zone_lan_input -m conntrack --ctstate DNAT -m comment --comment "!fw3: Accept port redirections" -j ACCEPT
[27563:1993103] -A zone_lan_input -m comment --comment "!fw3" -j zone_lan_src_ACCEPT
[489:159148] -A zone_lan_output -m comment --comment "!fw3: Custom lan output rule chain" -j output_lan_rule
[489:159148] -A zone_lan_output -m comment --comment "!fw3" -j zone_lan_dest_ACCEPT
[27563:1993103] -A zone_lan_src_ACCEPT -i br-lan -m conntrack --ctstate NEW,UNTRACKED -m comment --comment "!fw3" -j ACCEPT
[3513:205458] -A zone_wan_dest_ACCEPT -o eth0.2 -m conntrack --ctstate INVALID -m comment --comment "!fw3: Prevent NAT leakage" -j DROP
[37719:3047975] -A zone_wan_dest_ACCEPT -o eth0.2 -m comment --comment "!fw3" -j ACCEPT
[0:0] -A zone_wan_dest_REJECT -o eth0.2 -m comment --comment "!fw3" -j reject
[0:0] -A zone_wan_forward -m comment --comment "!fw3: Custom wan forwarding rule chain" -j forwarding_wan_rule
[0:0] -A zone_wan_forward -p esp -m comment --comment "!fw3: Allow-IPSec-ESP" -j zone_lan_dest_ACCEPT
[0:0] -A zone_wan_forward -p udp -m udp --dport 500 -m comment --comment "!fw3: Allow-ISAKMP" -j zone_lan_dest_ACCEPT
[0:0] -A zone_wan_forward -m conntrack --ctstate DNAT -m comment --comment "!fw3: Accept port forwards" -j ACCEPT
[0:0] -A zone_wan_forward -m comment --comment "!fw3" -j zone_wan_dest_REJECT
[248:49507] -A zone_wan_input -m comment --comment "!fw3: Custom wan input rule chain" -j input_wan_rule
[0:0] -A zone_wan_input -p udp -m udp --dport 68 -m comment --comment "!fw3: Allow-DHCP-Renew" -j ACCEPT
[0:0] -A zone_wan_input -p icmp -m icmp --icmp-type 8 -m comment --comment "!fw3: Allow-Ping" -j ACCEPT
[0:0] -A zone_wan_input -p igmp -m comment --comment "!fw3: Allow-IGMP" -j ACCEPT
[0:0] -A zone_wan_input -m conntrack --ctstate DNAT -m comment --comment "!fw3: Accept port redirections" -j ACCEPT
[248:49507] -A zone_wan_input -m comment --comment "!fw3" -j zone_wan_src_REJECT
[13536:926887] -A zone_wan_output -m comment --comment "!fw3: Custom wan output rule chain" -j output_wan_rule
[13536:926887] -A zone_wan_output -m comment --comment "!fw3" -j zone_wan_dest_ACCEPT
[248:49507] -A zone_wan_src_REJECT -i eth0.2 -m comment --comment "!fw3" -j reject
COMMIT
# Completed on Wed May  6 09:53:07 2020
# Generated by ip6tables-save v1.8.3 on Wed May  6 09:53:07 2020
*mangle
:PREROUTING ACCEPT [24537:5117795]
:INPUT ACCEPT [13422:3236927]
:FORWARD ACCEPT [0:0]
:OUTPUT ACCEPT [14929:1748133]
:POSTROUTING ACCEPT [14929:1748133]
:qos_Default - [0:0]
:qos_Default_ct - [0:0]
[0:0] -A FORWARD -o eth0.2 -p tcp -m tcp --tcp-flags SYN,RST SYN -m comment --comment "!fw3: Zone wan MTU fixing" -j TCPMSS --clamp-mss-to-pmtu
[0:0] -A qos_Default -j CONNMARK --restore-mark --nfmask 0xf --ctmask 0xf
[0:0] -A qos_Default -m mark --mark 0x0/0xf -j qos_Default_ct
[0:0] -A qos_Default -p udp -m mark --mark 0x0/0xf0 -m length --length 0:500 -j MARK --set-xmark 0x22/0xff
[0:0] -A qos_Default -p icmp -j MARK --set-xmark 0x11/0xff
[0:0] -A qos_Default -p tcp -m mark --mark 0x0/0xf0 -m tcp --sport 1024:65535 --dport 1024:65535 -j MARK --set-xmark 0x44/0xff
[0:0] -A qos_Default -p udp -m mark --mark 0x0/0xf0 -m udp --sport 1024:65535 --dport 1024:65535 -j MARK --set-xmark 0x44/0xff
[0:0] -A qos_Default -j CONNMARK --save-mark --nfmask 0xff --ctmask 0xff
[0:0] -A qos_Default_ct -p tcp -m mark --mark 0x0/0xf -m tcp -m multiport --ports 22,53 -m comment --comment "ssh, dns" -j MARK --set-xmark 0x11/0xff
[0:0] -A qos_Default_ct -p udp -m mark --mark 0x0/0xf -m udp -m multiport --ports 22,53 -m comment --comment "ssh, dns" -j MARK --set-xmark 0x11/0xff
[0:0] -A qos_Default_ct -p tcp -m mark --mark 0x0/0xf -m tcp -m multiport --ports 20,21,25,80,110,443,993,995 -m comment --comment "ftp, smtp, http(s), imap" -j MARK --set-xmark 0x33/0xff
[0:0] -A qos_Default_ct -p tcp -m mark --mark 0x0/0xf -m tcp -m multiport --ports 5190 -m comment --comment "AOL, iChat, ICQ" -j MARK --set-xmark 0x22/0xff
[0:0] -A qos_Default_ct -p udp -m mark --mark 0x0/0xf -m udp -m multiport --ports 5190 -m comment --comment "AOL, iChat, ICQ" -j MARK --set-xmark 0x22/0xff
[0:0] -A qos_Default_ct -j CONNMARK --save-mark --nfmask 0xff --ctmask 0xff
COMMIT
# Completed on Wed May  6 09:53:07 2020
# Generated by ip6tables-save v1.8.3 on Wed May  6 09:53:07 2020
*filter
:INPUT ACCEPT [0:0]
:FORWARD DROP [0:0]
:OUTPUT ACCEPT [0:0]
:forwarding_lan_rule - [0:0]
:forwarding_rule - [0:0]
:forwarding_wan_rule - [0:0]
:input_lan_rule - [0:0]
:input_rule - [0:0]
:input_wan_rule - [0:0]
:output_lan_rule - [0:0]
:output_rule - [0:0]
:output_wan_rule - [0:0]
:reject - [0:0]
:syn_flood - [0:0]
:zone_lan_dest_ACCEPT - [0:0]
:zone_lan_forward - [0:0]
:zone_lan_input - [0:0]
:zone_lan_output - [0:0]
:zone_lan_src_ACCEPT - [0:0]
:zone_wan_dest_ACCEPT - [0:0]
:zone_wan_dest_REJECT - [0:0]
:zone_wan_forward - [0:0]
:zone_wan_input - [0:0]
:zone_wan_output - [0:0]
:zone_wan_src_REJECT - [0:0]
[0:0] -A INPUT -i lo -m comment --comment "!fw3" -j ACCEPT
[13422:3236927] -A INPUT -m comment --comment "!fw3: Custom input rule chain" -j input_rule
[1782:2303202] -A INPUT -m conntrack --ctstate RELATED,ESTABLISHED -m comment --comment "!fw3" -j ACCEPT
[0:0] -A INPUT -p tcp -m tcp --tcp-flags FIN,SYN,RST,ACK SYN -m comment --comment "!fw3" -j syn_flood
[10580:853317] -A INPUT -i br-lan -m comment --comment "!fw3" -j zone_lan_input
[1060:80408] -A INPUT -i eth0.2 -m comment --comment "!fw3" -j zone_wan_input
[0:0] -A FORWARD -p ipv6-icmp -j ACCEPT
[0:0] -A FORWARD -m comment --comment "!fw3: Custom forwarding rule chain" -j forwarding_rule
[0:0] -A FORWARD -m conntrack --ctstate RELATED,ESTABLISHED -m comment --comment "!fw3" -j ACCEPT
[0:0] -A FORWARD -i br-lan -m comment --comment "!fw3" -j zone_lan_forward
[0:0] -A FORWARD -i eth0.2 -m comment --comment "!fw3" -j zone_wan_forward
[0:0] -A FORWARD -m comment --comment "!fw3" -j reject
[0:0] -A OUTPUT -o lo -m comment --comment "!fw3" -j ACCEPT
[14929:1748133] -A OUTPUT -m comment --comment "!fw3: Custom output rule chain" -j output_rule
[9156:1277596] -A OUTPUT -m conntrack --ctstate RELATED,ESTABLISHED -m comment --comment "!fw3" -j ACCEPT
[4362:331522] -A OUTPUT -o br-lan -m comment --comment "!fw3" -j zone_lan_output
[1395:137607] -A OUTPUT -o eth0.2 -m comment --comment "!fw3" -j zone_wan_output
[0:0] -A reject -p tcp -m comment --comment "!fw3" -j REJECT --reject-with tcp-reset
[0:0] -A reject -m comment --comment "!fw3" -j REJECT --reject-with icmp6-port-unreachable
[0:0] -A syn_flood -p tcp -m tcp --tcp-flags FIN,SYN,RST,ACK SYN -m limit --limit 25/sec --limit-burst 50 -m comment --comment "!fw3" -j RETURN
[0:0] -A syn_flood -m comment --comment "!fw3" -j DROP
[4362:331522] -A zone_lan_dest_ACCEPT -o br-lan -m comment --comment "!fw3" -j ACCEPT
[0:0] -A zone_lan_forward -m comment --comment "!fw3: Custom lan forwarding rule chain" -j forwarding_lan_rule
[0:0] -A zone_lan_forward -m comment --comment "!fw3: Zone lan to wan forwarding policy" -j zone_wan_dest_ACCEPT
[0:0] -A zone_lan_forward -m comment --comment "!fw3" -j zone_lan_dest_ACCEPT
[10580:853317] -A zone_lan_input -m comment --comment "!fw3: Custom lan input rule chain" -j input_lan_rule
[10580:853317] -A zone_lan_input -m comment --comment "!fw3" -j zone_lan_src_ACCEPT
[4362:331522] -A zone_lan_output -m comment --comment "!fw3: Custom lan output rule chain" -j output_lan_rule
[4362:331522] -A zone_lan_output -m comment --comment "!fw3" -j zone_lan_dest_ACCEPT
[10580:853317] -A zone_lan_src_ACCEPT -i br-lan -m conntrack --ctstate NEW,UNTRACKED -m comment --comment "!fw3" -j ACCEPT
[0:0] -A zone_wan_dest_ACCEPT -o eth0.2 -m conntrack --ctstate INVALID -m comment --comment "!fw3: Prevent NAT leakage" -j DROP
[1395:137607] -A zone_wan_dest_ACCEPT -o eth0.2 -m comment --comment "!fw3" -j ACCEPT
[0:0] -A zone_wan_dest_REJECT -o eth0.2 -m comment --comment "!fw3" -j reject
[0:0] -A zone_wan_forward -m comment --comment "!fw3: Custom wan forwarding rule chain" -j forwarding_wan_rule
[0:0] -A zone_wan_forward -p ipv6-icmp -m icmp6 --icmpv6-type 128 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Forward" -j ACCEPT
[0:0] -A zone_wan_forward -p ipv6-icmp -m icmp6 --icmpv6-type 129 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Forward" -j ACCEPT
[0:0] -A zone_wan_forward -p ipv6-icmp -m icmp6 --icmpv6-type 1 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Forward" -j ACCEPT
[0:0] -A zone_wan_forward -p ipv6-icmp -m icmp6 --icmpv6-type 2 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Forward" -j ACCEPT
[0:0] -A zone_wan_forward -p ipv6-icmp -m icmp6 --icmpv6-type 3 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Forward" -j ACCEPT
[0:0] -A zone_wan_forward -p ipv6-icmp -m icmp6 --icmpv6-type 4/0 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Forward" -j ACCEPT
[0:0] -A zone_wan_forward -p ipv6-icmp -m icmp6 --icmpv6-type 4/1 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Forward" -j ACCEPT
[0:0] -A zone_wan_forward -p esp -m comment --comment "!fw3: Allow-IPSec-ESP" -j zone_lan_dest_ACCEPT
[0:0] -A zone_wan_forward -p udp -m udp --dport 500 -m comment --comment "!fw3: Allow-ISAKMP" -j zone_lan_dest_ACCEPT
[0:0] -A zone_wan_forward -m comment --comment "!fw3" -j zone_wan_dest_REJECT
[1060:80408] -A zone_wan_input -m comment --comment "!fw3: Custom wan input rule chain" -j input_wan_rule
[0:0] -A zone_wan_input -s fc00::/6 -d fc00::/6 -p udp -m udp --dport 546 -m comment --comment "!fw3: Allow-DHCPv6" -j ACCEPT
[0:0] -A zone_wan_input -s fe80::/10 -p ipv6-icmp -m icmp6 --icmpv6-type 130/0 -m comment --comment "!fw3: Allow-MLD" -j ACCEPT
[0:0] -A zone_wan_input -s fe80::/10 -p ipv6-icmp -m icmp6 --icmpv6-type 131/0 -m comment --comment "!fw3: Allow-MLD" -j ACCEPT
[0:0] -A zone_wan_input -s fe80::/10 -p ipv6-icmp -m icmp6 --icmpv6-type 132/0 -m comment --comment "!fw3: Allow-MLD" -j ACCEPT
[0:0] -A zone_wan_input -s fe80::/10 -p ipv6-icmp -m icmp6 --icmpv6-type 143/0 -m comment --comment "!fw3: Allow-MLD" -j ACCEPT
[0:0] -A zone_wan_input -p ipv6-icmp -m icmp6 --icmpv6-type 128 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Input" -j ACCEPT
[0:0] -A zone_wan_input -p ipv6-icmp -m icmp6 --icmpv6-type 129 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Input" -j ACCEPT
[0:0] -A zone_wan_input -p ipv6-icmp -m icmp6 --icmpv6-type 1 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Input" -j ACCEPT
[0:0] -A zone_wan_input -p ipv6-icmp -m icmp6 --icmpv6-type 2 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Input" -j ACCEPT
[0:0] -A zone_wan_input -p ipv6-icmp -m icmp6 --icmpv6-type 3 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Input" -j ACCEPT
[0:0] -A zone_wan_input -p ipv6-icmp -m icmp6 --icmpv6-type 4/0 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Input" -j ACCEPT
[0:0] -A zone_wan_input -p ipv6-icmp -m icmp6 --icmpv6-type 4/1 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Input" -j ACCEPT
[0:0] -A zone_wan_input -p ipv6-icmp -m icmp6 --icmpv6-type 133 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Input" -j ACCEPT
[467:33624] -A zone_wan_input -p ipv6-icmp -m icmp6 --icmpv6-type 135 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Input" -j ACCEPT
[138:17664] -A zone_wan_input -p ipv6-icmp -m icmp6 --icmpv6-type 134 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Input" -j ACCEPT
[455:29120] -A zone_wan_input -p ipv6-icmp -m icmp6 --icmpv6-type 136 -m limit --limit 1000/sec -m comment --comment "!fw3: Allow-ICMPv6-Input" -j ACCEPT
[0:0] -A zone_wan_input -m comment --comment "!fw3" -j zone_wan_src_REJECT
[1395:137607] -A zone_wan_output -m comment --comment "!fw3: Custom wan output rule chain" -j output_wan_rule
[1395:137607] -A zone_wan_output -m comment --comment "!fw3" -j zone_wan_dest_ACCEPT
[0:0] -A zone_wan_src_REJECT -i eth0.2 -m comment --comment "!fw3" -j reject
COMMIT
# Completed on Wed May  6 09:53:07 2020
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN qlen 1000
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
7: br-lan: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP qlen 1000
    inet 192.168.1.1/24 brd 192.168.1.255 scope global br-lan
       valid_lft forever preferred_lft forever
9: eth0.2@eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP qlen 1000
    inet 192.168.0.3/24 brd 192.168.0.255 scope global eth0.2
       valid_lft forever preferred_lft forever
default via 192.168.0.254 dev eth0.2  src 192.168.0.3
192.168.0.0/24 dev eth0.2 scope link  src 192.168.0.3
192.168.1.0/24 dev br-lan scope link  src 192.168.1.1
broadcast 127.0.0.0 dev lo table local scope link  src 127.0.0.1
local 127.0.0.0/8 dev lo table local scope host  src 127.0.0.1
local 127.0.0.1 dev lo table local scope host  src 127.0.0.1
broadcast 127.255.255.255 dev lo table local scope link  src 127.0.0.1
broadcast 192.168.0.0 dev eth0.2 table local scope link  src 192.168.0.3
local 192.168.0.3 dev eth0.2 table local scope host  src 192.168.0.3
broadcast 192.168.0.255 dev eth0.2 table local scope link  src 192.168.0.3
broadcast 192.168.1.0 dev br-lan table local scope link  src 192.168.1.1
local 192.168.1.1 dev br-lan table local scope host  src 192.168.1.1
broadcast 192.168.1.255 dev br-lan table local scope link  src 192.168.1.1
0:      from all lookup local
32766:  from all lookup main
32767:  from all lookup default
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 state UNKNOWN qlen 1000
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 state UNKNOWN qlen 1000
    inet6 fe80::xxxx:xxxx:xxxx:xxab/64 scope link
       valid_lft forever preferred_lft forever
7: br-lan: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 state UP qlen 1000
    inet6 fd69:cdc6:cb9d::1/60 scope global
       valid_lft forever preferred_lft forever
    inet6 fe80::xxxx:xxxx:xxxx:xxab/64 scope link
       valid_lft forever preferred_lft forever
9: eth0.2@eth0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 state UP qlen 1000
    inet6 2a01:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxac/64 scope global dynamic
       valid_lft 86284sec preferred_lft 86284sec
    inet6 fe80::xxxx:xxxx:xxxx:xxac/64 scope link
       valid_lft forever preferred_lft forever
10: wlan0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 state UP qlen 1000
    inet6 fe80::xxxx:xxxx:xxxx:xxab/64 scope link
       valid_lft forever preferred_lft forever
11: wlan1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 state UP qlen 1000
    inet6 fe80::xxxx:xxxx:xxxx:xxad/64 scope link
       valid_lft forever preferred_lft forever
default from 2a01:xxxx:xxxx:xxxx::/64 via fe80::xxxx:xxxx:xxxx:xx94 dev eth0.2  metric 512
2a01:xxxx:xxxx:xxxx::/64 dev eth0.2  metric 256
fd69:cdc6:cb9d::xxxx dev br-lan  metric 1024
fd69:cdc6:cb9d::xxxx dev br-lan  metric 1024
fd69:cdc6:cb9d:0:xxxx:xxxx:xxxx:xxxx dev br-lan  metric 1024
fd69:cdc6:cb9d:0:xxxx:xxxx:xxxx:xxxx dev br-lan  metric 1024
fd69:cdc6:cb9d:0:xxxx:xxxx:xxxx:xxxx dev br-lan  metric 1024
fd69:cdc6:cb9d:0:xxxx:xxxx:xxxx:xxxx dev br-lan  metric 1024
fd69:cdc6:cb9d:0:xxxx:xxxx:xxxx:xxxx dev br-lan  metric 1024
fd69:cdc6:cb9d:0:xxxx:xxxx:xxxx:xxxx dev br-lan  metric 1024
fd69:cdc6:cb9d:0:xxxx:xxxx:xxxx:xxxx dev br-lan  metric 1024
fd69:cdc6:cb9d:0:xxxx:xxxx:xxxx:xxxx dev br-lan  metric 1024
fd69:cdc6:cb9d:0:xxxx:xxxx:xxxx:xxxx dev br-lan  metric 1024
fd69:cdc6:cb9d::/64 dev br-lan  metric 1024
unreachable fd69:cdc6:cb9d::/48 dev lo  metric 2147483647  error -148
fe80::/64 dev eth0  metric 256
fe80::/64 dev eth0.2  metric 256
fe80::/64 dev br-lan  metric 256
fe80::/64 dev wlan0  metric 256
fe80::/64 dev wlan1  metric 256
local ::1 dev lo table local  metric 0
anycast 2a01:xxxx:xxxx:xxxx:: dev eth0.2 table local  metric 0
local 2a01:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx:xxxx dev eth0.2 table local  metric 0
anycast fd69:cdc6:cb9d:: dev br-lan table local  metric 0
local fd69:cdc6:cb9d::1 dev br-lan table local  metric 0
anycast fe80:: dev eth0 table local  metric 0
anycast fe80:: dev eth0.2 table local  metric 0
anycast fe80:: dev br-lan table local  metric 0
anycast fe80:: dev wlan0 table local  metric 0
anycast fe80:: dev wlan1 table local  metric 0
local fe80::xxxx:xxxx:xxxx:xxab dev eth0 table local  metric 0
local fe80::xxxx:xxxx:xxxx:xxab dev br-lan table local  metric 0
local fe80::xxxx:xxxx:xxxx:xxab dev wlan0 table local  metric 0
local fe80::xxxx:xxxx:xxxx:xxac dev eth0.2 table local  metric 0
local fe80::xxxx:xxxx:xxxx:xxad dev wlan1 table local  metric 0
ff00::/8 dev eth0 table local  metric 256
ff00::/8 dev br-lan table local  metric 256
ff00::/8 dev eth0.2 table local  metric 256
ff00::/8 dev wlan0 table local  metric 256
ff00::/8 dev wlan1 table local  metric 256
0:      from all lookup local
32766:  from all lookup main
4200000001:     from all iif lo lookup unspec 12
4200000007:     from all iif br-lan lookup unspec 12
4200000009:     from all iif eth0.2 lookup unspec 12
4200000009:     from all iif eth0.2 lookup unspec 12
lrwxrwxrwx    1 root     root            16 Feb 27 22:05 /etc/resolv.conf -> /tmp/resolv.conf
-rw-r--r--    1 root     root            32 May  5 20:00 /tmp/resolv.conf
-rw-r--r--    1 root     root            83 May  5 18:52 /tmp/resolv.conf.auto
==> /etc/resolv.conf <==
search lan
nameserver 127.0.0.1

==> /tmp/resolv.conf <==
search lan
nameserver 127.0.0.1

==> /tmp/resolv.conf.auto <==
# Interface wan
nameserver 192.168.0.254
# Interface wan6
nameserver fd0f:ee:b0::1

Does this router delegate prefix to your R6120 by DHCPv6? Is it configured?

Hi trendy and vuhuy,
Yes the prefix delegation seems to be a range 2a01:xxxx:xxxx:xxx0::/64 to 2a01:xxxx:xxxx:xxx7::/64, as vuhuy supposed. I have the possibility to configure a next-hop on that router for each of these 8 prefixes.

If /64 mask is imposed by my ISP, can't we take a smaller subnet of that on OpenWrt ?

I think these are the prefixes available on your Freebox? Is OpenWRT able to request its own prefix? I suspect your ISP doesn't allow prefix delegation.

It seems to me you're French and I don't if the same situation applies to you. I once set up IPv6 with OpenWRT behind a Freebox for a friend of mine when I was visiting him. His provider didn't allow downstream routers like the OpenWRT request its own prefix by DHCPv6 Prefix Delegation. You mentioning the next-hop option reminded me of this.

So what I did was setting the second nexthop (xxx1) to the WAN6 local link address of your downstream OpenWRT router on the Freebox. The first nexthop (xxx0) was empty or something, I left it there because that prefix was used by the LAN side of the Freebox. In OpenWRT, I had to adjust some values on the WAN6 and LAN interface. I recall leaving everything default except setting a custom prefix. So lets loop through all IPv6 related options in LuCI:

So from your WAN6 general settings tabs:

Protocol: leave it on DHCPv6 client
Request IPv6-address: disabled i think? (try the "try" option if it doesn't work)
Request IPv6-prefix of length: automatic

From the WAN6 advanced tab:
Use builtin IPv6-management: check
Custom delegated IPv6-prefix: your second nexthop prefix (2001:xxxx:xxx1::/64)

From the LAN general settings tab:
IPv6 assignment length: 64
IPv6 assignment hint: leave empty
IPv6 suffix: leave empty (should pick ::1 by default)

From the LAN DHCP server IPv6 settings tab:
Router Advertisement-Service: server mode
DHCPv6-Service: default is server mode
NDP-Proxy: default is disabled
DHCPv6-Mode: default is stateless + statefull
Announced DNS servers: default is empty

So the last tab is set to your own preferences. Note that Router Advertisement-Service must be in server mode. All recent devices and OS should work with that mode. Android doesn't do stateless or stateful DHCPv6. Enable the DHCPv6 server for maximum compatibility. Windows 10 Anniversery or older doesn't do SLAAC. Also set the Announced DNS servers to your local DNS server if you want to resolve local hostnames for devices using SLAAC. DHCPv6 should also advertise a DNS server, but since Android only does SLAAC we need to set the Announced DNS server option. Oh yeah, and different Android devices, different behavior. Some Android devices ignore DNS server set with ULA-addresses, so you might want to use global IPv6 addresses.

So in my case, I use the following settings, as all Windows clients are updated the most recent version in my network.

Router Advertisement-Service: server mode
DHCPv6-Service: disabled
NDP-Proxy: disabled
Announced DNS servers: global ipv6 address of my OpenWRT router

Restart interfaces or device (openwrt and clients) and it should work. Oh yeah and I had to set some static routes. Please post the routes on your OpenWRT box and a client if you're done. I can't remember this part. Must be the routes for the clients to access the public internet I think.

1 Like

That's just exactly the solution I just tried and it seems to be successful, inspired by https://utux.fr/index.php?article13/free-bridge-ipv6

I thus had to set up a static config for upstream interface.

config interface 'wan6'
        option ifname 'eth0.2'
        #option proto 'dhcpv6'
        option proto 'static'
        option ip6addr 2a01:xxxx:xxxx:xxx0::2/64
        option ip6gw 2a01:xxxx:xxxx:xxx0::1
        option ip6prefix 2a01:xxxx:xxxx:xxx1::/64
        option dns 2a01:xxxx:xxxx:xxx0::1

I'll check the rest of your detailed answer, thanks!

1 Like

Yeah maybe it's the last part that I can't remember. I also needed to set up two static routes in the end.

I have a fair idea, must be a target ::/0 with the gateway global IPv6 address of your freebox on the wan6 interface 2a01:xxx:xxxx:xxx0::1 , and target 2a01:xxx:xxxx:xxx1::/64 on your lan interface.

Anyway if you don't succeed try to reset your configs. I remember I was in a hurry because we needed to leave, and I did everything in the LuCI web interface, so it wasn't that complicated (at least not for my friend's setup)

Using DHCPv6 client was not successful, I really needed static address for WAN6.

Summary (for future readers)

On OpenWrt (do you have a better way to read it using LuCI?):

  1. Open SSH console to OpenWrt device (using IPv4 address or symbolic name) and enter:
ifconfig | grep inet
  1. Under IPv4 upstream address (192.168.0.x), retrieve link-local address fe80::xxxx:xxxx:xxxx:xxxx

On Freebox:

  1. Login and open tab "Configuration IPv6".
  2. Retrieve link-local address fe80::xxxx:xxxx:xxxx:xxxx (this is IPv6 gateway)
  3. Retrieve global address prefix 2a01:xxxx:xxxx:xxx0::/64
  4. Set next-hop for prefixes xxx0::/64 and xxx1::/64 to link-local fe80::xxxx:xxxx:xxxx:xxxx (got from SSH)

In LuCI, Network, WAN6:

  • Protocol: static address
  • All IPv4 stuff let empty
  • Custom DNS server 2a01:xxxx:xxxx:xxx0::1
  • IPv6 assignment length: disabled
  • IPv6 address: 2a01:xxxx:xxxx:xxx0::2
  • IPv6 gateway: fe80::xxxx:xxxx:xxxx:xxxx (link-local to Freebox)
  • Routed prefix: 2a01:xxxx:xxxx:xxx1::/64 (does it mean stuff for LAN?)
  • IPv6 suffix: (empty)
  • Advanced tab: Use builtin IPv6 management: check

LAN config: as vuhuy specified

No static route appears to be necessary.

Test (Windows):

ping -6 ipv6.google.com

Test (Linux):

ping6 ipv6.google.com
2 Likes

Thank you :blush:

Nice I see you got it working, good to hear!

The routed prefix is the prefix that's pushed to clients, so in your configuration the static routes aren't needed.

The difference between the configurations is that you're using a static assignment + setting the routed prefix, and my friend uses the DHCPv6 client + a custom delegated prefix (so static routes are needed) . In his OpenWRT configuration, the DHCPv6 client wasn't actually used because the WAN6 side of the OpenWRT got configured via SLAAC. I don't know why this wouldn't work in your configuration but I'm glad you figured it out! Different routes with the same goal. Maybe there's a difference in Freebox configuration, or OpenWRT changed something in the newer releases.

1 Like