ipv6: sysctl to restrict candidate source addresses
authorErik Kline <ek@google.com>
Wed, 22 Jul 2015 07:38:25 +0000 (16:38 +0900)
committerHuang, Tao <huangtao@rock-chips.com>
Tue, 27 Oct 2015 08:28:21 +0000 (16:28 +0800)
commit4375ac61a03e2d7f88ca770d289afbe08d1af3c6
treed521f5c18ad4ee62284949a5d66231ec0472ef5f
parent69923ebd717da521b30bec6cca2333de6f52ab7e
ipv6: sysctl to restrict candidate source addresses

Per RFC 6724, section 4, "Candidate Source Addresses":

    It is RECOMMENDED that the candidate source addresses be the set
    of unicast addresses assigned to the interface that will be used
    to send to the destination (the "outgoing" interface).

Add a sysctl to enable this behaviour.

Signed-off-by: Erik Kline <ek@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
[Simplified back-port of net-next 3985e8a3611a93bb36789f65db862e5700aab65e]

Bug: 19470192
Bug: 21832279
Bug: 22464419
Change-Id: Ib74ef945dcabe64215064f15ee1660b6524d65ce
(cherry picked from commit 0633924e7776754ccb473d649e5fa9ee45617a46)
Documentation/networking/ip-sysctl.txt
include/linux/ipv6.h
include/uapi/linux/ipv6.h
net/ipv6/addrconf.c