[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: getaddrinfo address ordering [Re: IPv6 transition architecturediscussion]
On Wed, 27 Nov 2002, Stig Venaas wrote:
> > Programs should _never_ have a preference, if they do they
> > should ask for an AF_INET or AF_INET6 that's enough preference already
> > :)
> > I am against having the AI_PREFER4/6 as this would be too program
> > specific and one needs to recompile to get it out.
>
> I agree, we really should avoid this. I think adding even more
> complexity to getaddrinfo() is a bad idea. And not only does it
> take time to deploy, but it might also be hard to change the
> applications later. This is really something the sysadmin should
> be able to choose, there is no default that fits all.
There are more layers than that, e.g.
- "if I have an app and install it anywhere at all, I have no way of
knowing whether the system has implemented A,AAA preferation method -- so
I'll just ship it with AF_UNSPEC + AI_PREFERV4, so people can run it with
'app v6host', 'app -6 v46host' or 'app v46host' without problems, it'll
always fall back to v4 if it doesn't know better"
- "my app is special and is really only usable in v6 context; I'd prefer
it to use v6 even though whatever's configured in A,AAAA preferation
method. AF_UNSPEC + AI_PREFERV6 could handle that"
Ie. I'd like the app writers to be able to write "v6-safe" code. Code
that, when run or compiled on nearly any system, would produce code that's
safe to be used in v4-preferring environments _regardless of_ whether the
app user's box even has any A,AAAA preferation method.
But I can very well like with stuff like AI_PREFER* -- we just need the
toggle to change the ordering of A,AAAA records when using AF_UNSPEC ASAP,
if not yesterday. If we could manage to get that deployed fast enough,
and v4 preferred widely enough, perhaps in 1-2 years people could start
shipping v6-enabled apps, waiting for the site admins decision to prefer
v6 instead when they're confident enough to do so.
--
Pekka Savola "Tell me of difficulties surmounted,
Netcore Oy not those you stumble over and fall"
Systems. Networks. Security. -- Robert Jordan: A Crown of Swords