Skip to content

Commit

Permalink
ipv6: Ignore route option with ROUTER_PREF_INVALID
Browse files Browse the repository at this point in the history
RFC4191 says that "If the Reserved (10) value is received, the Route
Information Option MUST be ignored.", so this patch makes us conform
to the RFC. This is different to the usage of the Default Router
Preference, where an invalid value must indeed be treated as
PREF_MEDIUM.

Signed-off-by: Jens Rosenboom <me@jayr.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Jens Rosenboom authored and David S. Miller committed Sep 17, 2009
1 parent b9f6025 commit 3933fc9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion net/ipv6/route.c
Original file line number Diff line number Diff line change
Expand Up @@ -481,7 +481,7 @@ int rt6_route_rcv(struct net_device *dev, u8 *opt, int len,

pref = rinfo->route_pref;
if (pref == ICMPV6_ROUTER_PREF_INVALID)
pref = ICMPV6_ROUTER_PREF_MEDIUM;
return -EINVAL;

lifetime = addrconf_timeout_fixup(ntohl(rinfo->lifetime), HZ);

Expand Down

0 comments on commit 3933fc9

Please sign in to comment.