Files
twx-linux/include/net
David Ahern b8fb1ab461 net ipv6: Prevent neighbor add if protocol is disabled on device
Disabling IPv6 on an interface removes existing entries but nothing prevents
new entries from being manually added. To that end, add a new neigh_table
operation, allow_add, that is called on RTM_NEWNEIGH to see if neighbor
entries are allowed on a given device. If IPv6 is disabled on the device,
allow_add returns false and passes a message back to the user via extack.

  $ echo 1 > /proc/sys/net/ipv6/conf/eth1/disable_ipv6
  $ ip -6 neigh add fe80::4c88:bff:fe21:2704 dev eth1 lladdr de:ad:be:ef:01:01
  Error: IPv6 is disabled on this device.

Signed-off-by: David Ahern <dsahern@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2019-04-17 23:19:07 -07:00
..
2018-09-08 01:39:47 +09:00
…
2019-02-21 16:23:56 -08:00
…
…
…
…
2019-01-23 11:18:00 -08:00
…
2018-09-26 20:22:19 -07:00
…
…
…
…
…
…
…
…
…
…
2019-03-21 13:39:25 -07:00
…
…
…
2019-02-13 21:07:47 -08:00
…
…
…
…
…
…
…
2019-02-25 14:32:35 -08:00
…
…
…
…
…
…
…
…
…
…
2018-09-13 09:04:58 -07:00
…
…
…
…
…
…
…
…
…
2018-09-25 20:17:35 -07:00
…
…
…
…
…
…
…
…
2018-12-20 16:56:04 -08:00
…
…
…
…
…
…
…
…
…
…
2018-08-29 12:25:53 -07:00