ipv6: Update Neighbor Cache when IPv6 RA is received on a router
commit31ce8c71a3bdab12debb5899b1f6dac13e54c71d
authorDavid Ward <david.ward@ll.mit.edu>
Sat, 29 Aug 2009 07:04:09 +0000 (29 00:04 -0700)
committerDavid S. Miller <davem@davemloft.net>
Sat, 29 Aug 2009 07:04:09 +0000 (29 00:04 -0700)
tree1c1e02ec7b5953669b58c79c1f7d7d5b962f5c07
parent078b0735881c7969aaf21469f3577831cddd9f8c
ipv6: Update Neighbor Cache when IPv6 RA is received on a router

When processing a received IPv6 Router Advertisement, the kernel
creates or updates an IPv6 Neighbor Cache entry for the sender --
but presently this does not occur if IPv6 forwarding is enabled
(net.ipv6.conf.*.forwarding = 1), or if IPv6 Router Advertisements
are not accepted (net.ipv6.conf.*.accept_ra = 0), because in these
cases processing of the Router Advertisement has already halted.

This patch allows the Neighbor Cache to be updated in these cases,
while still avoiding any modification to routes or link parameters.

This continues to satisfy RFC 4861, since any entry created in the
Neighbor Cache as the result of a received Router Advertisement is
still placed in the STALE state.

Signed-off-by: David Ward <david.ward@ll.mit.edu>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/ndisc.c