Re: [PATCH net-next v2] ipv6: sysctl to restrict candidate source addresses

2015-07-09 Thread YOSHIFUJI Hideaki
David Miller wrote: > So we should look at a way at making the new behavior the default, and > in fact that makes sense and we can even optimize this piece of saddr > selection code to not do an iteration over all devices in the system > for no reason at all. It can just do a quick dev_get_by_ind

Re: [PATCH net-next v2] ipv6: sysctl to restrict candidate source addresses

2015-07-08 Thread David Miller
From: Erik Kline Date: Wed, 8 Jul 2015 21:41:58 +0900 >> I really would like to come up with a sane works-always behavior for >> this, but besides doing a retry on the complete source address selection >> algorithm I currently cannot come up with an idea. >> >> Maybe we can tweak saddr_eval a bit

Re: [PATCH net-next v2] ipv6: sysctl to restrict candidate source addresses

2015-07-08 Thread Erik Kline
> I really would like to come up with a sane works-always behavior for > this, but besides doing a retry on the complete source address selection > algorithm I currently cannot come up with an idea. > > Maybe we can tweak saddr_eval a bit. I think it all comes down to this: source address selectio

Re: [PATCH net-next v2] ipv6: sysctl to restrict candidate source addresses

2015-07-08 Thread Lorenzo Colitti
On Wed, Jul 8, 2015 at 5:43 PM, Hannes Frederic Sowa wrote: >> For example, consider the case where you have an IPv6 default route >> but not an IPv6 address on one interface (e.g., wifi), and a working >> configuration (IPv6 default route and IPv6 address) on another >> interface (e.g., cellular

Re: [PATCH net-next v2] ipv6: sysctl to restrict candidate source addresses

2015-07-08 Thread Hannes Frederic Sowa
On Wed, 2015-07-08 at 17:19 +0900, Lorenzo Colitti wrote: > On Wed, Jul 8, 2015 at 5:09 PM, Hannes Frederic Sowa > wrote: > > I wonder a little bit, because addresses which match the outgoing > > interface should get a higher score in saddr_eval, thus be > > automatically > > preferred. Is this c

Re: [PATCH net-next v2] ipv6: sysctl to restrict candidate source addresses

2015-07-08 Thread Lorenzo Colitti
On Wed, Jul 8, 2015 at 5:09 PM, Hannes Frederic Sowa wrote: > I wonder a little bit, because addresses which match the outgoing > interface should get a higher score in saddr_eval, thus be automatically > preferred. Is this check not strong enough? It isn't strong enough because the "prefer outgo

Re: [PATCH net-next v2] ipv6: sysctl to restrict candidate source addresses

2015-07-08 Thread Hannes Frederic Sowa
On Wed, 2015-07-08 at 10:29 +0900, Lorenzo Colitti wrote: > On Mon, Jul 6, 2015 at 12:05 PM, Erik Kline wrote: > > 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 inter

Re: [PATCH net-next v2] ipv6: sysctl to restrict candidate source addresses

2015-07-07 Thread Lorenzo Colitti
On Mon, Jul 6, 2015 at 12:05 PM, Erik Kline wrote: > 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 "outgoin

[PATCH net-next v2] ipv6: sysctl to restrict candidate source addresses

2015-07-05 Thread Erik Kline
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. Signe