<?xml version="1.0" encoding="US-ASCII"?>
<!DOCTYPE rfc SYSTEM "rfc2629.dtd" [
<!ENTITY RFC1034 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.1034.xml">
<!ENTITY RFC1035 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.1035.xml">
<!ENTITY RFC1928 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.1928.xml">
<!ENTITY RFC2119 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.2119.xml">
<!ENTITY RFC2308 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.2308.xml">
<!ENTITY RFC2629 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.2629.xml">
<!ENTITY RFC3552 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.3552.xml">
<!ENTITY RFC4648 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.4648.xml">
<!ENTITY RFC6761 SYSTEM "http://xml.resource.org/public/rfc/bibxml/reference.RFC.6761.xml">
<!ENTITY I-D.narten-iana-considerations-rfc2434bis SYSTEM "http://xml.resource.org/public/rfc/bibxml3/reference.I-D.narten-iana-considerations-rfc2434bis.xml">
]>
<?xml-stylesheet type='text/xsl' href='rfc2629.xslt' ?>

<?rfc strict="yes" ?>
<?rfc toc="yes" ?>
<?rfc symrefs="yes"?>
<?rfc sortrefs="yes" ?>
<?rfc compact="yes" ?>
<?rfc subcompact="no" ?>

<rfc category="info"
     docName="draft-grothoff-iesg-special-use-p2p-gns-00"
     ipr="trust200902">

  <front>
    <title abbrev="Special-Use GNU Namesystem">
      Special-Use Domain Names of the GNU Name System
    </title>

    <author fullname="Christian Grothoff" initials="C.G." surname="Grothoff">
      <organization>INRIA</organization>
      <address>
        <postal>
          <street>&Eacute;quipe D&eacute;centralis&eacute;e</street>
          <street>INRIA Rennes Bretagne Atlantique</street>
          <street>263 avenue du G&eacute;n&eacute;ral Leclerc</street>
          <street>Campus Universitaire de Beaulieu</street>
          <city>Rennes</city>
          <region>Bretagne</region>
	  <code>F-35042</code>
          <country>FR</country>
        </postal>
        <email>christian@grothoff.org</email>
      </address>
    </author>

    <author fullname="Matthias Wachs" initials="M.W." surname="Wachs">
      <organization>Technische Universit&auml;t M&uuml;nchen</organization>
      <address>
        <postal>
          <street>Free Secure Network Systems Group</street>
          <street>Lehrstuhl fuer Netzarchitekturen und Netzdienste</street>
          <street>Boltzmannstrasse 3</street>
          <street>Technische Universitaet Muenchen</street>
          <code>D-85748</code>
          <city>Garching bei Muenchen</city>
          <region>Bayern</region>
          <country>DE</country>
        </postal>
        <email>wachs@net.in.tum.de</email>
      </address>
    </author>

    <author fullname="Hellekin O. Wolf" initials="H.O.W." role="editor"
            surname="Wolf">
      <organization>GNU consensus</organization>
      <address>
        <email>hellekin@gnu.org</email>
      </address>
    </author>

    <author fullname="Jacob Appelbaum" initials="J.A." surname="Appelbaum">
      <organization>Tor Project Inc.</organization>
      <address>
        <email>jacob@appelbaum.net</email>
      </address>
    </author>

    <author fullname="Leif Ryge" initials="L.R." surname="Ryge">
      <organization>Tor Project Inc.</organization>
      <address>
        <email>leif@synthesize.us</email>
      </address>
    </author>

    <date day="30" month="June" year="2015" />

    <!-- Meta-data Declarations -->
    <area>General</area>
    <workgroup>Internet Engineering Task Force</workgroup>

    <keyword>special-use</keyword>
    <keyword>peer-to-peer</keyword>
    <keyword>domain names</keyword>
    <keyword>DNS</keyword>
    <keyword>GNS</keyword>

    <abstract>

      <t>This document registers a set of Special-Use Domain Names for
      use with Peer-to-Peer (P2P) systems, as per RFC6761.</t>

    </abstract>

  </front>

  <middle>

    <section anchor="introduction"
	     title="Introduction">

      <t>The GNU Name System (GNS) uses &quot;GNU&quot; and
      &quot;ZKEY&quot; to realize privacy-enhanced,
      fully-decentralized and censorship-resistant naming.</t>

      <t>In order to avoid interoperability issues with DNS as well as
      to address security and privacy concerns, this document
      registers a set of Special-Use Domain Names for use with P2P
      systems (pTLDs), as per <xref target="RFC6761"/>,:
      &quot;GNU&quot; and &quot;ZKEY&quot;.</t>

    </section>

    <section anchor="applicability"
	     title="Applicability">

      <t><xref target="RFC6761"/> Section 3 states:</t>

      <t><list style="empty"><t>&quot;[I]f a domain name has special
      properties that affect the way hardware and software
      implementations handle the name, that apply universally
      regardless of what network the implementation may be connected
      to, then that domain name may be a candidate for having the IETF
      declare it to be a Special-Use Domain Name and specify what
      special treatment implementations should give to that name. On
      the other hand, if declaring a given name to be special would
      result in no change to any implementations, then that suggests
      that the name may not be special in any material way, and it may
      be more appropriate to use the existing DNS mechanisms <xref
      target="RFC1034"/> to provide the desired delegation, data, or
      lack-of-data, for the name in question. Where the desired
      behaviour can be achieved via the existing domain name
      registration processes, that process should be used. Reservation
      of a Special-Use Domain Name is not a mechanism for
      circumventing normal domain name registration
      processes.&quot;</t></list></t>

      <t>The set of Special-Use Domain Names for the GNU Name System
      (pTLDs) reserved by this document meet this requirement, as they
      share the following specificities:</t>

      <t><list style="symbols">
	<t>pTLDs are not manageable by some designated administration.
	Instead, they are managed according to various alternate
	strategies or combinations thereof, introduced in this
	document, and their respective protocol specifications:
	automated cryptographic assignment (&quot;.zkey&quot;),
        or user-controled assignment in a private
	scope (&quot;.gnu&quot;).</t>

	<t>The pTLDs do not depend on the DNS context for their
	resolution: GNS resolution MAY involve the DNS server
	infrastructure, as it returns DNS-compatible results; however,
	a specific P2P protocol is used for regular name resolution,
	covered by its respective protocol specification.</t>

	<t>GNS name resolution is typically integrated with
	existing software libraries and APIs to extend regular DNS
	operation and enable more secure name resolution.
        GNS implementations MUST intercept queries for the
        respective pTLDs to ensure GNS names cannot leak into
        the DNS from properly configured systems.
        Nevertheless, in case GNS names do leak into the DNS, the default
	hierarchical DNS response to any request to any pTLD MUST be
	NXDOMAIN.</t>

	<t>Finally, in order to facilitate the GNU Name System's vision of a
	censorship-resistant, fully-decentralized name system, and
	provide security and privacy features matching user
	expectations, this document specifies desirable changes in
	existing DNS software and DNS operations.</t>
      </list></t>

    </section>

    <section anchor="terminology-and-conventions"
	     title="Terminology and Conventions Used in This Document">

      <t>The key words &quot;MUST&quot;, &quot;MUST NOT&quot;,
      &quot;REQUIRED&quot;, &quot;SHALL&quot;, &quot;SHALL NOT&quot;,
      &quot;SHOULD&quot;, &quot;SHOULD NOT&quot;,
      &quot;RECOMMENDED&quot;, &quot;MAY&quot;, and
      &quot;OPTIONAL&quot; in this document are to be interpreted as
      described in <xref target="RFC2119"/>.</t>

      <t>The word &quot;peer&quot; is used in the meaning of a
      individual system on the network.</t>

      <t>The abbreviation &quot;pTLD&quot; is used in this document to
      mean a pseudo Top-Level Domain, i.e., a Special-Use Domain Name
      per <xref target="RFC6761"/> reserved to the GNU Name System in this
      document.  A pTLD is mentioned in capitals, and within double
      quotes to mark the difference with a regular DNS gTLD.</t>

      <t>In this document, &quot;.tld&quot; (lowercase, with quotes)
      means: any domain or hostname within the scope of a given pTLD,
      while .tld (lowercase, without quotes) refers to an adjective
      form.  For example, a collection of &quot;.gnu&quot; peers in
      &quot;GNU&quot;, but an .gnu URL. [TO REMOVE: in the IANA
      Considerations section, we use the simple .tld format to request
      TLD reservation for consistency with previous RFCs].</t>

      <t>The word &quot;NXDOMAIN&quot; refers to an alternate
      expression for the &quot;Name Error&quot; RCODE as described in
      section 4.1.1 of <xref target="RFC1035"/>.  When referring to
      &quot;NXDOMAIN&quot; and negative caching <xref
      target="RFC2308"/> response, this document means an
      authoritative (AA=1) name error (RCODE=3) response
      exclusively.</t>

    </section>

    <section anchor="description-of-special-use-domains-in-p2p-networks"
	     title="Description of Special-Use Domains in P2P Networks">

      <section anchor="dot-gnu"
               title="The &quot;GNU&quot; Relative pTLD">

        <t>&quot;GNU&quot; is used to specify that a domain name
        should be resolved using GNS.  The GNS resolution process is
        documented in <xref target="Wachs2014"/>.</t>

	<t>The &quot;GNU&quot; domain is special in the following
	ways:</t>

	<t><list style="numbers">
	  <!-- 1. Users Considerations -->
	  <t>Users can use these names as they would other domain
	  names, entering them anywhere that they would otherwise
	  enter a conventional DNS domain name.
	  <vspace blankLines="1"/>
	  Since there is no central authority responsible for
	  assigning .gnu names, and that specific domain is local to
	  the local peer, users need to be aware of that specificity.
	  <vspace blankLines="1"/>
	  Legacy applications MAY expect the DNS-to-GNS proxy to
	  return DNS compatible results for the resolution of .gnu
	  domains.
	  <vspace blankLines="1" />
	  </t>

	  <!-- 2. Application Software Considerations -->
	  <t>Legacy application software does not need to recognize
	  .gnu domains as special, and may continue to use these names
	  as they would other domain names.
	  <vspace blankLines="1"/>
	  GNS-aware applications MAY also use GNS resolvers directly
	  to resolve .gnu domains (in particular, if they want access
	  to GNS-specific record types).
	  <vspace blankLines="1" />
	  </t>

	  <!-- 3. Name Resolution APIs and Libraries Considerations -->
	  <t>Name resolution APIs and libraries SHOULD either respond
	  to requests for .gnu names by resolving them via the GNS
	  protocol, or respond with NXDOMAIN.
	  <vspace blankLines="1" />
	  </t>

	  <!-- 4. Caching DNS Servers Considerations -->
	  <!-- TODO: specify negative responses -->
	  <t>Caching DNS servers SHOULD recognize .gnu names as
	  special and SHOULD NOT attempt to look up NS records for
	  them, or otherwise query authoritative DNS servers in an
	  attempt to resolve .gnu names.  Instead, caching DNS servers
	  SHOULD generate immediate negative responses for all such
	  queries.
	  <vspace blankLines="1" />
	  </t>

	  <!-- 5. Authoritative DNS Servers Considerations -->
	  <t>Authoritative DNS servers are not expected to treat .gnu
	  domain requests specially.  In practice, they MUST answer
	  with NXDOMAIN, as &quot;GNU&quot; is not available via
	  global DNS resolution, and not doing so can put users'
	  privacy at risk (see item 6).
	  <vspace blankLines="1" />
	  </t>

	  <!-- 6. DNS Server Operators Considerations -->
	  <t>DNS server operators SHOULD be aware that .gnu names are
	  reserved for use with GNS, and MUST NOT override their
	  resolution (e.g., to redirect users to another service or
	  error information).
	  <vspace blankLines="1" />
	  </t>

	  <!-- 7. DNS Registries/Registrars Considerations -->
	  <t>DNS registries/registrars MUST NOT grant any request to
	  register .gnu names.  This helps avoid conflicts <xref
	  target="SAC45"/>. These names are defined by the GNS
	  protocol specification, and they fall outside the set of
	  names available for allocation by registries/registrars.
	  <vspace blankLines="1" />
	  </t>
	</list></t>

      </section>

      <section anchor="dot-zkey"
               title="The &quot;ZKEY&quot; Compressed Public Key pTLD">

        <t>The &quot;ZKEY&quot; pTLD is used to signify that
        resolution of the given name MUST be performed using a record
        signed by an authority that is in possession of a particular
        public key.  Names in &quot;ZKEY&quot; MUST end with a domain
        which is the compressed point representation from <xref
        target="EdDSA"/> on <xref target="Curve25519"/> of the public
        key of the authority, encoded using Crockford's variant of
        base32hex <xref target="RFC4648"/> (with additionally 'U'
        being considered equal to 'V') for easier optical character
        recognition.  A GNS resolver uses the key to locate a record
        signed by the respective authority.</t>

        <t>&quot;ZKEY&quot; provides a (reverse) mapping from globally
        unique hashes to public key, therefore .zkey names are
        non-memorable, and are expected to be hidden from the user
        <xref target="Wachs2014"/>.</t>

	<t>The &quot;ZKEY&quot; domain is special in the following
	ways:</t>

	<t><list style="numbers">
	  <!-- 1. Users Considerations -->
	  <t>Users can use these names as they would other domain
	  names, entering them anywhere that they would otherwise
	  enter a conventional DNS domain name.
	  <vspace blankLines="1"/>
	  Since there is no central authority necessary or possible
	  for assigning .zkey names, and those names match
	  cryptographic keys, users need to be aware that they do not
	  belong to regular DNS, but are still global in their scope.
	  <vspace blankLines="1"/>
	  Legacy applications MAY expect the DNS-to-GNS proxy to
	  return DNS-compatible results for the resolution of .zkey
	  domains.
	  <vspace blankLines="1"/>
	  </t>

	  <!-- 2. Application Software Considerations -->
	  <t>Application software does not need to recognize .zkey
	  domains as special, and may continue to use these names as
	  they would other domain names.
	  <vspace blankLines="1"/>
	  GNS-aware applications MAY also use GNS resolvers directly
	  to resolve .zkey domains
	  <vspace blankLines="1"/>
	  </t>

	  <!-- 3. Name Resolution APIs and Libraries Considerations -->
	  <t>Name resolution APIs and libraries SHOULD either respond
	  to requests for .zkey names by resolving them via the GNS
	  protocol, or respond with NXDOMAIN.
	  <vspace blankLines="1"/>
	  </t>

	  <!-- 4. Caching DNS Servers Considerations -->
	  <!-- TODO: specify negative responses -->
	  <t>Caching DNS servers SHOULD recognize .zkey names as
	  special and SHOULD NOT attempt to look up NS records for
	  them, or otherwise query authoritative DNS servers in an
	  attempt to resolve .zkey names.  Instead, caching DNS
	  servers SHOULD generate immediate negative responses for all
	  such queries.
	  <vspace blankLines="1"/>
	  </t>

	  <!-- 5. Authoritative DNS Servers Considerations -->
	  <t>Authoritative DNS Servers are not expected to treat .zkey
	  domain requests specially.  In practice, they MUST answer
	  with NXDOMAIN, as &quot;ZKEY&quot; is not available via
	  global DNS resolution, and not doing so MAY put users'
	  privacy at risk (see item 6).
	  <vspace blankLines="1"/>
	  </t>

	  <!-- 6. DNS Server Operators Considerations -->
	  <t>DNS server operators SHOULD be aware that .zkey names are
	  reserved for use with GNS, and MUST NOT override their
	  resolution (e.g., to redirect users to another service or
	  error information).
	  <vspace blankLines="1"/>
	  </t>

	  <!-- 7. DNS Registries/Registrars Considerations -->
	  <t>DNS registries/registrars MUST NOT grant any request to
	  register .zkey names.  This helps avoid conflicts <xref
	  target="SAC45"/>. These names are defined as described
	  above, and they fall outside the set of names available for
	  allocation by registries/registrars.
	  <vspace blankLines="1"/>
	  </t>
	</list></t>

      </section>

    </section>

    <section anchor="security-considerations"
	     title="Security Considerations">

      <t>Specific software performs the resolution of names in
      the GNU Name System; this
      resolution process happens outside of the scope of DNS.  Leakage
      of requests to such domains to the global operational DNS can
      cause interception of traffic that might be misused to monitor,
      censor, or abuse the user's trust, and lead to privacy issues
      with potentially tragic consequences for the user.</t>

      <t>This document reserves these Top-Level Domain names to
      minimize the possibility of confusion, conflict, and especially
      privacy risks for users.</t>

      <t>In the introduction of this document, there's a requirement
      that DNS operators do not override resolution of the GNS names.
      This is a regulatory measure and cannot prevent such malicious
      abuse in practice.  Its purpose is to limit any information leak
      that would result from incorrectly configured systems, and to
      avoid that resolvers make unnecessary contact to the DNS Root
      Zone for such domains.  Verisign, Inc., as well as several
      Internet service providers (ISPs) have notoriously abused their
      position to override NXDOMAIN responses to their customers in
      the past <xref target="SSAC-NXDOMAIN-Abuse"/>.  For example, if
      a DNS operator would decide to override NXDOMAIN and send
      advertising to leaked .zkey sites, the information leak to the
      DNS would extend to the advertising server, with unpredictable
      consequences. Thus, implementors should be aware that any
      positive response coming from DNS must be considered with extra
      care, as it suggests a leak to DNS has been made, contrary to
      user's privacy expectations.</t>

      <t>The reality of X.509 Certificate Authorities (CAs) creating
      misleading certificates for these pTLDs due to ignorance
      stresses the need to document their special use.  X.509
      Certificate Authorities MAY create certificates for
      &quot;ZKEY&quot; given
      CSRs signed with the respective private keys corresponding to
      the respective names.  Certificate Authorities MUST NOT create
      certificates for &quot;GNU&quot; Top-Level domains.
      Nevertheless, clients SHOULD
      accept certificates for &quot;GNU&quot; Top-Level domains as they may be
      created legitimately by local proxies on the fly.</t>

      <t>Finally, legacy applications that do not explicitly support
      the pTLDs significantly increase the risk of pTLD queries
      escaping to DNS, as they are entirely dependent on the correct
      configuration on the operating system.</t>

    </section>

    <section anchor="iana-considerations"
	     title="IANA Considerations">

      <t>The Internet Assigned Numbers Authority (IANA) reserved the
      following entries in the Special-Use Domain Names registry <xref
      target="RFC6761"/>:</t>

      <t><list>
        <t> .gnu</t>
        <t>.zkey</t>
      </list></t>

      <t>[TO REMOVE: the assignement URL is
      https://www.iana.org/assignments/special-use-domain-names/ ]</t>

    </section>

    <section anchor="acknowledgements"
	     title="Acknowledgements">

      <t>The authors thank the I2P and Namecoin developers for their
      constructive feedback, as well as Mark Nottingham for his
      proof-reading and valuable feedback.  The authors also thank the
      members of DNSOP WG for their critiques and suggestions.</t>

    </section>

  </middle>

  <back>

    <references title="Normative References">

      &RFC1034;

      &RFC1035;

      &RFC2119;

      &RFC2308;

      &RFC6761;

    </references>

    <references title="Informative References">

      <reference anchor="Curve25519"
                 target="http://cr.yp.to/ecdh/curve25519-20060209.pdf">
        <front>
          <title>Curve25519: new Diffie-Hellman speed record</title>
          <author initials="D.J.B." fullname="Daniel J. Bernstein" surname="Bernstein">
            <organization></organization>
          </author>
          <date year="2006" month="February" />
        </front>
      </reference>

      <reference anchor="EdDSA"
                 target="http://ed25519.cr.yp.to/ed25519-20110926.pdf">
        <front>
          <title>High-speed, high-security signatures</title>
          <author initials="D.J.B." fullname="Daniel J. Bernstein" surname="Bernstein" />
          <author initials="N.D." fullname="Niels Duif" surname="Duif" />
          <author initials="T.L." fullname="Tanja Lange" surname="Lange" />
          <author initials="P.S." fullname="Peter Schwabe" surname="Schwabe" />
          <author initials="Y.B." fullname="Bo-Yin Yang" surname="Yang" />
          <date year="2011" month="September" />
        </front>
      </reference>

      <reference anchor="SSAC-NXDOMAIN-Abuse"
		 target="http://www.icann.org/committees/security/ssac-report-09jul04.pdf">
	<front>
	  <title>Redirection in the COM and NET Domains</title>
	  <author>
            <organization>ICANN Security and Stability Advisory
            Committee</organization>
          </author>
          <date month="July" year="2004"/>
        </front>
      </reference>

      &RFC4648;

      <reference anchor="SAC45"
                   target="http://www.icann.org/en/groups/ssac/documents/sac-045-en.pdf">
        <front>
          <title>Invalid Top Level Domain Queries at the Root
          Level of the Domain Name System</title>
          <author>
            <organization>ICANN Security and Stability Advisory
            Committee</organization>
          </author>
          <date month="November" year="2010"/>
        </front>
      </reference>

      <reference anchor="Wachs2014"
		 target="https://gnunet.org/gns-paper">
        <front>
	  <title>A Censorship-Resistant, Privacy-Enhancing and
	  Fully Decentralized Name System</title>
	  <author initials="M.W." fullname="Matthias Wachs" surname="Wachs">
	    <organization>Technische Universit&auml;t M&uuml;nchen</organization>
	  </author>
	  <author initials="M.S." fullname="Martin Schanzenbach" surname="Schanzenbach">
	    <organization>Technische Universit&auml;t M&uuml;nchen</organization>
	  </author>
	  <author initials="C.G." fullname="Christian Grothoff" surname="Grothoff">
	    <organization>Technische Universit&auml;t M&uuml;nchen</organization>
	  </author>
	  <date year="2014" month="October"/>
	</front>
      </reference>

    </references>
    <!-- Change Log

v00 2013-11-13  HOW   Initial version

v01 2013-12-05  HOW   First XML version
                      - Fix conformance issues
                      - Shorten abstract
                      - Remove appendix on Tor reference
                      - Add .bit
                      - Reorder references
                      - Integrate community feedback

v02 2014-02-15  HOW   Second XML version
                      - Split Reservation Considerations for each pTLD
                      - Revise abstract
                      - Explain .exit exceeded length unpredictability
                      - Integrate community feedback

v03 2014-12-21  HOW   Third XML version
                      - Shorten abstract and focus scope
		      - Expand security considerations:
		        - Add reference to SSL certificates for non-DNS domains
		        - Add reference to SSAC recommendations on name collisions
		      - Update GNUnet references
		      - Update I2P reference
		      - Update Namecoin reference
		      - Update Tor references
		      - Remove alternate use of dot-tld notation
		      - Added Leif as author
		      - Integrate community feedback

v04 2015-01-24  HOW   Fourth XML version
                      - Move I2P under geographic anonymity section
                      - Integrate I2P developers comments
                      - Integrate Namecoin developers comments
                      - Add security considerations
                      - Integrate community feedback

v05 2015-06-22  CG    First split version
                      - split into separate drafts for each name system
                      - Removed .onion as that's already a separate draft
    -->
  </back>
</rfc>
