diff options
author | Darren 'Tadgy' Austin <darren@afterdark.org.uk> | 2021-03-08 21:38:15 +0000 |
---|---|---|
committer | Darren 'Tadgy' Austin <darren@afterdark.org.uk> | 2021-03-08 21:38:15 +0000 |
commit | 908f03bd53526adb20a56b91f2b343dc57ec6d02 (patch) | |
tree | 5f099448f97fddc7e6e6c2cf3e79586238d2c4b9 /rc.inet1 | |
parent | aeb252e2a4307a294d8483e4af52b747d7225535 (diff) | |
download | slacknetsetup-908f03bd53526adb20a56b91f2b343dc57ec6d02.tar.xz |
Move enabling RA before SLAAC security section. Thanks to davjohn on LQ.
Diffstat (limited to 'rc.inet1')
-rw-r--r-- | rc.inet1 | 16 |
1 files changed, 8 insertions, 8 deletions
@@ -329,6 +329,14 @@ if_up() { IF_UP=0 if [ -e /proc/sys/net/ipv6 ] && [ "${USE_DHCP6[$i]}" != "yes" ] && [ "${USE_SLAAC[$i]}" = "yes" ]; then # configure via SLAAC info_log "${1}: enabling SLAAC" + # Enable accepting of RA packets, unless explicitly configured not to: + if [ "${USE_RA[$i]}" = "no" ]; then + debug_log "${1}: ignoring IPv6 RA" + echo "0" >/proc/sys/net/ipv6/conf/${1}/accept_ra + else + debug_log "${1}: accepting IPv6 RA" + echo "1" >/proc/sys/net/ipv6/conf/${1}/accept_ra + fi # Set up SLAAC privacy enhancements if configured. if [ "${SLAAC_PRIVIPGEN[$i]}" = "yes" ]; then if [ -n "${SLAAC_SECRET[$i]}" ]; then @@ -345,14 +353,6 @@ if_up() { debug_log "${1}: enabling SLAAC tempaddr" echo "2" >/proc/sys/net/ipv6/conf/${1}/use_tempaddr fi - # Enable accepting of RA packets, unless explicitly configured not to: - if [ "${USE_RA[$i]}" = "no" ]; then - debug_log "${1}: ignoring IPv6 RA" - echo "0" >/proc/sys/net/ipv6/conf/${1}/accept_ra - else - debug_log "${1}: accepting IPv6 RA" - echo "1" >/proc/sys/net/ipv6/conf/${1}/accept_ra - fi # Enable auto configuration of interfaces: echo "1" >/proc/sys/net/ipv6/conf/${1}/autoconf # Bring the interface up: |