Re: [DNSOP] Status of "let localhost be localhost"?

Mike West <> Thu, 03 August 2017 10:52 UTC

Return-Path: <>
Received: from localhost (localhost []) by (Postfix) with ESMTP id 28EE9131D27 for <>; Thu, 3 Aug 2017 03:52:15 -0700 (PDT)
X-Virus-Scanned: amavisd-new at
X-Spam-Flag: NO
X-Spam-Score: -2.001
X-Spam-Status: No, score=-2.001 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, HTML_MESSAGE=0.001, RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001] autolearn=ham autolearn_force=no
Authentication-Results: (amavisd-new); dkim=pass (2048-bit key)
Received: from ([]) by localhost ( []) (amavisd-new, port 10024) with ESMTP id BDf80-w4xsMH for <>; Thu, 3 Aug 2017 03:52:12 -0700 (PDT)
Received: from ( [IPv6:2607:f8b0:4003:c06::229]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by (Postfix) with ESMTPS id 9BDFB131D6B for <>; Thu, 3 Aug 2017 03:52:12 -0700 (PDT)
Received: by with SMTP id d71so9106228oih.0 for <>; Thu, 03 Aug 2017 03:52:12 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=bQNA7FHyw+MCv7aSIXI9rwuVGNsief6xzAmdh3jTJJY=; b=vY3KUjaXBP6oIFAwk1qRLG96xdpJzpBEo89V1pP01YfLHPaIAAJP0YEV3K6g2Nrbb8 rX3wu0FH9PQobK4I6QoG3e3vLPU1tNhnTCI2K04d1uvpMApJKVXO8bao2g6iDBkBYIVm BVK3Kuz6Vupr6BQqK3VWgvtrc7Is/MtqOnCBhJkltkCQU82Q4DN3hwV3lYLYx9QNC/vf hGWht/XB0woMrloec6Z1Z790nAit9bIUO4d53AKOTKZsx3lRy+nhyp5Dt1L5I/PV2vuS icpbN3rRYXdHRUE378Sec4X0l0yj5lx7qnGGs0iv2+VUh469FQuIppuTAppJQTKGLX++ 8zIA==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=bQNA7FHyw+MCv7aSIXI9rwuVGNsief6xzAmdh3jTJJY=; b=FQkOZGwF6ESG3POLK+/om+juUixV+BGagAhFbhUXxqld/EQJ96TXepyYSrIkepwdG5 /aVoJSBZE512+JN5Ke7LagVx9b4T05BPCytEQUJcrTN64gb/4IVyw6l94tvRe2Y73YuF JvFOAoPTup6Cm8jXR3cwRXoMOLjid4Zin0PLKCiqJKgNpIHpaFRVg65+THjboiMURVCP ESz7qGIVD7QVTuxfhqzyUo5DiR0mkulwaCtZouw4jIBysTD6X3lof98Crjvwa7EOPX4s PFywkcpNulbErjOiD00fFVfQoORNVz7bDTnZEYmYgDcP3jv8dU9D7oRIHvnALgbQ4zQl fXOw==
X-Gm-Message-State: AIVw1117z1tXVgn2o0Pv07iXYfiHkulFvWYc3sJcvPEOvNhSc1RDSEHl +fSIBVqNOxtnaU2QWBYJaP3wvmT24GeJ
X-Received: by with SMTP id x132mr1065287oif.52.1501757531339; Thu, 03 Aug 2017 03:52:11 -0700 (PDT)
MIME-Version: 1.0
Received: by with HTTP; Thu, 3 Aug 2017 03:51:50 -0700 (PDT)
In-Reply-To: <>
References: <> <> <> <> <> <> <> <> <> <> <> <>
From: Mike West <>
Date: Thu, 3 Aug 2017 12:51:50 +0200
Message-ID: <>
To: Richard Barnes <>
Cc: Ted Lemon <>, Robert Edmonds <>, dnsop <>, Jacob Hoffman-Andrews <>, william manning <>, Erik Nygren <>
Content-Type: multipart/alternative; boundary="001a11c180443375e60555d72c16"
Archived-At: <>
Subject: Re: [DNSOP] Status of "let localhost be localhost"?
X-Mailman-Version: 2.1.22
Precedence: list
List-Id: IETF DNSOP WG mailing list <>
List-Unsubscribe: <>, <>
List-Archive: <>
List-Post: <>
List-Help: <>
List-Subscribe: <>, <>
X-List-Received-Date: Thu, 03 Aug 2017 10:52:15 -0000

It seems like there's clear agreement that `localhost` "should" map to
loopback addresses. That's what the RFC already says, after all, and it
matches my anecdata from conversations with developers (I haven't talked to
anyone (outside this group) who expected `localhost` to ever resolve
anywhere else). So, that's a good place to start.

Some folks in this thread (including me) think that "should" is too weak,
and that it would be helpful to make a stronger guarantee that `localhost`
matches its colloquial meaning. I think there are some pretty reasonable
arguments for this position:

1.  RFC6761 says <> that
users "may assume that IPv4 and IPv6 address queries for localhost names
will always resolve to the respective IP loopback address". It violates the
principle of least astonishment to allow the underlying platform to behave
at odds with that assumption. I'd suggest that we should either harden the
requirements below, or stop inviting users to make incorrect assumptions.
Given the widespread acceptance of those assumptions, the former seems like
the right course of action to me. :)

2.  Various bits of software behave in various (and inconsistent) ways when
presented with a DNS query for `localhost`. "Should" has not been as
effective as I'd like in creating an environment in which user expectations
are met. Chrome is the client I'm most familiar with, and it takes
advantage of the "should"'s and "may"'s in some circumstances to hard-code
resolution of `localhost`. That behavior isn't consistent across platforms,
however, and, as Richard notes, it would be helpful in our decision-making
if we clarified the guarantees the platform ought to provide.

3.  Groups like SUNSET4 are actively opposed to hard-coding IP addresses
like ``, but if that's the only way that developers can really
ensure users' expectations are met, that's what they'll end up doing. As
Richard has noted a few times in this thread: that would be a worse outcome
than making stronger guarantees about the meaning of an mapped label.

If y'all decide that this is really just something that browsers need to
care about, then it's of course possible to address Chrome's use case by
overriding RFC 6761 in a W3C spec. If that's the course of action y'all
would prefer, I can do that. It seems like taking browsers' handling of
`localhost` out of the hands of DNSOP/IETF would be a bad outcome for this
group, but it's certainly an option.

With regard to DNSSEC delegations, my intuition is that Jacob's assessment
is reasonable, but I recognize that I don't know nearly enough about DNSSEC
to have a meaningful opinion. I'm happy to accept the group's assessment on
this point.

Thanks for continuing the conversation!


On Thu, Aug 3, 2017 at 1:27 AM, Richard Barnes <> wrote:

> On Wed, Aug 2, 2017 at 4:27 PM, Ted Lemon <> wrote:
>> On Aug 2, 2017, at 2:02 PM, Robert Edmonds <> wrote:
>> draft-west-let-localhost-be-localhost-03 upgrades the requirements in
>> RFC 6761 §6.3 to make them much stricter, for all applications,
>> converting SHOULDs to MUSTs, etc. So we're not arguing about whether
>> localhost "should" be treated specially, but whether it MUST be treated
>> specially, by all applications. Can the W3C not impose stricter
>> requirements on browser developers even if 6761 doesn't impose mandatory
>> treatment for "localhost"?
>> It should be MUST in both cases.   But writing that in an RFC doesn't
>> make it so.   Bear in mind when you look at the W3C document that it is
>> talking about what would be ideal, not what is actually present in browsers.
>> As an app developer worried about security footprint, I would be wiser to
>> be cautious and use ::1 or, rather than using localhost and
>> relying on the name resolution infrastructure.   But the use case that I
>> would be most skeptical about is using localhost in a URL.   I think that
>> should be MUST NOT.   Apparently there is not wholehearted agreement on
>> this topic, however... :)
> You have this backwards.  Browser today do take the more cautious,
> IP-based approach.  It sucks for developers.  They want to be able to use
> "localhost", but in order to do it safely, they will need to hard-wire it
> internally (since as you say, writing an RFC doesn't make resolvers
> change).  And they don't want to hard-wire unless that's the clear semantic
> because standards are what make the web work.
> --Richard