<?xml version="1.0" encoding="US-ASCII"?>
<!DOCTYPE rfc SYSTEM 'rfc2629.dtd' []>

<rfc ipr="trust200902" submissionType="IETF" category="std" consensus="yes" number="8630" obsoletes="7730">

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

<front>
<title abbrev="HTTPS TAL">Resource Public Key Infrastructure (RPKI) Trust Anchor Locator</title>

<author initials="G." surname="Huston" fullname="Geoff Huston">
<organization>APNIC</organization>
<address>
<postal>
<street></street>
<city></city>
<code></code>
<country></country>
<region></region>
</postal>
<email>gih@apnic.net</email>
<uri>https://www.apnic.net</uri>
</address>
</author>

<author initials="S." surname="Weiler" fullname="Samuel Weiler">
<organization>W3C/MIT</organization>
<address>
<postal>
<street></street>
<city></city>
<code></code>
<country></country>
<region></region>
</postal>
<email>weiler@csail.mit.edu</email>
<uri></uri>
</address>
</author>

<author initials="G." surname="Michaelson" fullname="George Michaelson">
<organization>APNIC</organization>
<address>
<postal>
<street></street>
<city></city>
<code></code>
<country></country>
<region></region>
</postal>
<email>ggm@apnic.net</email>
<uri>https://www.apnic.net</uri>
</address>
</author>

<author initials="S." surname="Kent" fullname="Stephen Kent">
<organization>Unaffiliated</organization>
<address>
<postal>
<street></street>
<city></city>
<code></code>
<country></country>
<region></region>
</postal>
<email>kent@alum.mit.edu</email>
<uri></uri>
</address>
</author>

<author initials="T." surname="Bruijnzeels" fullname="Tim Bruijnzeels">
<organization>NLnet Labs</organization>
<address>
<postal>
<street></street>
<city></city>
<code></code>
<country></country>
<region></region>
</postal>
<phone></phone>
<email>tim@nlnetlabs.nl</email>
<uri>https://www.nlnetlabs.nl</uri>
</address>
</author>

<date year="2019" month="August" />

<abstract>
<t>This document defines a Trust Anchor Locator (TAL) for the Resource
Public Key Infrastructure (RPKI). The TAL allows Relying Parties in the
RPKI to download the current Trust Anchor (TA) Certification Authority
(CA) certificate from one or more locations and verify that the key of
this self-signed certificate matches the key on the TAL. Thus,
Relying Parties can be configured with TA keys but can allow these
TAs to change the content of their CA certificate. In particular, it
allows TAs to change the set of IP Address Delegations and/or
Autonomous System Identifier Delegations included in the extension(s) (RFC 3779)
of their certificate.
</t>
<t>This document obsoletes the previous definition of the TAL
as provided in RFC 7730 by adding support for Uniform Resource Identifiers
(URIs) (RFC 3986) that use HTTP over TLS (HTTPS) (RFC 7230) as the scheme.
</t>
</abstract>

</front>

<middle>

<section anchor="introduction" title="Introduction">
<t>This document defines a Trust Anchor Locator (TAL) for the Resource
Public Key Infrastructure (RPKI) <xref target="RFC6480"/>.  This format may be
used to distribute Trust Anchor (TA) material using a mix of out-of-band and
online means.  Procedures used by Relying Parties (RPs) to verify
RPKI signed objects SHOULD support this format to facilitate
interoperability between creators of TA material and RPs.
This document obsoletes <xref target="RFC7730"/> by adding support for
Uniform Resource Identifiers (URIs) <xref target="RFC3986"/> that use 
HTTP over TLS (HTTPS) <xref target="RFC7230"/> as the scheme.
</t>

<section anchor="terminology" title="Terminology">
    <t>The key words &quot;MUST&quot;, &quot;MUST NOT&quot;,
    &quot;REQUIRED&quot;, &quot;SHALL&quot;, &quot;SHALL&nbsp;NOT&quot;,
    &quot;SHOULD&quot;, &quot;SHOULD&nbsp;NOT&quot;, &quot;RECOMMENDED&quot;,
    &quot;NOT&nbsp;RECOMMENDED&quot;, &quot;MAY&quot;, and
    &quot;OPTIONAL&quot; in this document are to be interpreted as described
    in BCP&nbsp;14 <xref target="RFC2119"/> <xref target="RFC8174"/> when,
    and only when, they appear in all capitals, as shown here.</t>
</section>

<section anchor="changes-from-rfc7730" title="Changes from RFC 7730">
<t>The TAL format defined in this document differs from the definition
in <xref target="RFC7730"/> in that:
</t>
<t>
<list style="symbols">
<t>it allows for the use of the HTTPS scheme in URIs <xref target="RFC7230"/>, and</t>
<t>it allows for the inclusion of an optional comment section.</t>
</list>
</t>
<t>Note that current RPs may not support this new format yet.
Therefore, it is RECOMMENDED that a TA operator maintain
a TAL file as defined in <xref target="RFC7730"/> for a time as well, until
they are satisfied that RP tooling has been updated.
</t>
</section>
</section>

<section anchor="trust-anchor-locator" title="Trust Anchor Locator">

<section anchor="trust-anchor-locator-motivation" title="Trust Anchor Locator Motivation">
<t>This document does not propose a new format for TA material.
A TA in the RPKI is represented by a self&nbhy;signed
X.509 Certification Authority (CA) certificate, a format commonly
used in PKIs and widely supported by RP software.  This document
specifies a format for data used to retrieve and verify the
authenticity of a TA in a very simple fashion.  That data
is referred to as the TAL.
</t>
<t>The motivation for defining the TAL is to enable selected data in the
TA to change, without needing to redistribute
the TA per se.
</t>
<t>In the RPKI, certificates contain one or more extensions <xref target="RFC3779"/>
that can contain a set of IP Address Delegations and/or Autonomous System
Identifier Delegations. In this document, we refer to these delegations
as the Internet Number Resources (INRs) contained in an RPKI
certificate.
</t>
<t>The set of INRs associated with an entity acting as a TA is
likely to change over time.  Thus, if one were to use the common PKI
convention of distributing a TA to RPs in a secure fashion,
then this procedure would need to be repeated whenever the INR set
for the entity acting as a TA changed.  By distributing the
TAL (in a secure fashion) instead of distributing the TA,
this problem is avoided, i.e., the TAL is constant so long as the
TA's public key and its location do not change.
</t>
<t>The TAL is analogous to the TrustAnchorInfo data structure specified
in <xref target="RFC5914"/>, which is on the Standards Track.  That specification
could be used to represent the TAL, if one defined an rsync or HTTPS
URI extension for that data structure.  However, the TAL format was
adopted by RPKI implementors prior to the PKIX TA work, and
the RPKI implementor community has elected to utilize the TAL format
rather than define the requisite extension.  The community also
prefers the simplicity of the ASCII encoding of the TAL, versus the
binary (ASN.1) encoding for TrustAnchorInfo.
</t>
</section>

<section anchor="trust-anchor-locator-file-format" title="Trust Anchor Locator File Format">
<t>In this document, we define a TA URI as a URI that can be
used to retrieve a current TA certificate. This URI MUST
be either an rsync URI <xref target="RFC5781"/> or an HTTPS URI <xref
target="RFC7230"/>.
</t>
<t>The TAL is an ordered sequence of:
</t>
<t>
<list style="numbers">
<t>an optional comment section consisting of one or more lines
each starting with the "#" character, followed by human-readable
informational UTF-8 text, conforming to the restrictions defined
in Section&nbsp;2 of <xref target="RFC5198"/>, and ending with a line
break,</t>
<t>a URI section that is comprised of one or more ordered lines,
each containing a TA URI, and ending with a line break,</t>
<t>a line break, and</t>
<t>a subjectPublicKeyInfo <xref target="RFC5280"/> in DER format <xref
target="X.509"/>, encoded in base64 (see Section&nbsp;4 of <xref
target="RFC4648"/>).  To avoid long lines, line breaks MAY be inserted into
the base64-encoded string.</t>
</list>
</t>
<t>Note that line breaks in this file can use either &quot;&lt;CRLF&gt;&quot;
or &quot;&lt;LF&gt;&quot;.</t>
</section>

<section anchor="tal-and-trust-anchor-certificate-considerations" title="TAL and TA Certificate Considerations">
<t>Each TA URI in the TAL MUST reference a single object. It
MUST NOT reference a directory or any other form of collection of
objects. The referenced object MUST be a self-signed CA certificate that
conforms to the RPKI certificate profile <xref target="RFC6487"/>.  This certificate
is the TA in certification path discovery <xref target="RFC4158"/> and
validation <xref target="RFC5280"/> <xref target="RFC3779"/>.
</t>
<t>The validity interval of this TA is chosen such that (1) the
&quot;notBefore&quot; time predates the moment that this certificate is
published and (2) the &quot;notAfter&quot; time is after the planned time of
reissuance of this certificate.
</t>
<t>The INR extension(s) of this TA MUST contain a non-empty
set of number resources.  It MUST NOT use the &quot;inherit&quot; form of the
INR extension(s).  The INR set described in this certificate is the
set of number resources for which the issuing entity is offering
itself as a putative TA in the RPKI <xref target="RFC6480"/>.
</t>
<t>The public key used to verify the TA MUST be the same as
the subjectPublicKeyInfo in the CA certificate and in the TAL.
</t>
<t>The TA MUST contain a stable key that does not change when
the certificate is reissued due to changes in the INR extension(s),
when the certificate is renewed prior to expiration.
</t>
<t>Because the public key in the TAL and the TA MUST be stable,
this motivates operation of that CA in an offline mode. In that case, a
subordinate CA certificate containing the same INRs, or, in theory, any
subset of INRs, can be issued  for online operations. This allows the
entity that issues the TA to keep the corresponding private
key of this certificate offline, while issuing all relevant child
certificates under the immediate subordinate CA.  This measure also
allows the Certificate Revocation List (CRL) issued by that entity to
be used to revoke the subordinate CA certificate in the event of
suspected key compromise of this online operational key pair that is
potentially more vulnerable.
</t>
<t>The TA MUST be published at a stable URI.  When the TA is reissued for any
reason, the replacement CA certificate MUST be accessible using the same URI.
</t>
<t>Because the TA is a self-signed certificate, there is no
corresponding CRL that can be used to revoke it, nor is there a
manifest <xref target="RFC6486"/> that lists this certificate.
</t>
<t>If an entity wishes to withdraw a self-signed CA certificate as a
putative TA, for any reason, including key rollover, the
entity MUST remove the object from the location referenced in
the&nbsp;TAL.
</t>
<t>Where the TAL contains two or more TA URIs, the same
self-signed CA certificate MUST be found at each referenced location.
In order to increase operational resilience, it is RECOMMENDED that
(1)&nbsp;the domain name parts of each of these URIs resolve to distinct IP
addresses that are used by a diverse set of repository publication
points and (2)&nbsp;these IP addresses be included in distinct Route Origin
Authorization (ROA) objects signed by different CAs.
</t>
</section>

<section anchor="example" title="Example">

<figure align="center"><artwork align="center" type="ascii-art">
# This TAL is intended for documentation purposes only.
# Do not attempt to use this in a production setting.
rsync://rpki.example.org/rpki/hedgehog/root.cer
https://rpki.example.org/rpki/hedgehog/root.cer

MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAovWQL2lh6knDx
GUG5hbtCXvvh4AOzjhDkSHlj22gn/1oiM9IeDATIwP44vhQ6L/xvuk7W6
Kfa5ygmqQ+xOZOwTWPcrUbqaQyPNxokuivzyvqVZVDecOEqs78q58mSp9
nbtxmLRW7B67SJCBSzfa5XpVyXYEgYAjkk3fpmefU+AcxtxvvHB5OVPIa
BfPcs80ICMgHQX+fphvute9XLxjfJKJWkhZqZ0v7pZm2uhkcPx1PMGcrG
ee0WSDC3fr3erLueagpiLsFjwwpX6F+Ms8vqz45H+DKmYKvPSstZjCCq9
aJ0qANT9OtnfSDOS+aLRPjZryCNyvvBHxZXqj5YCGKtwIDAQAB
</artwork></figure>
</section>
</section>

<section anchor="RP_USE" title="Relying Party Use">
<t>In order to use the TAL to retrieve and validate a (putative) TA,
an RP SHOULD:
</t>
<t>
<list style="numbers">
<t>Retrieve the object referenced by (one of) the TA URI(s)
contained in the TAL.</t>
<t>Confirm that the retrieved object is a current, self-signed RPKI
CA certificate that conforms to the profile as specified in
<xref target="RFC6487"/>.</t>
<t>Confirm that the public key in the TAL matches the public key in
the retrieved object.</t>
<t>Perform other checks, as deemed appropriate (locally), to ensure
that the RP is willing to accept the entity publishing this
self&nbhy;signed CA certificate to be a TA.  These tests apply to
the validity of attestations made in the context of the RPKI
relating to all resources described in the INR extension(s) of this
certificate.
</t>
</list>
</t>
<t>An RP SHOULD perform these functions for each instance of a TAL that it
is holding for this purpose every time the RP performs a
resynchronization across the local repository cache.  In any case, an
RP also SHOULD perform these functions prior to the expiration of the
locally cached copy of the retrieved TA referenced by
the&nbsp;TAL.
</t>
<t>In the case where a TAL contains multiple TA URIs, an RP MAY
use a locally defined preference rule to select the URI to retrieve
the self-signed RPKI CA certificate that is to be used as a TA.
Some examples are:
</t>
<t>
<list style="symbols">
<t>Using the order provided in the TAL</t>
<t>Selecting the TA URI randomly from the available list</t>
<t>Creating a prioritized list of URIs based on RP-specific
parameters, such as connection establishment delay</t>
</list>
</t>
<t>If the connection to the preferred URI fails or the retrieved CA
certificate public key does not match the TAL public key, the RP
SHOULD retrieve the CA certificate from the next URI, according to
the local preference ranking of URIs.
</t>
</section>

<section anchor="uri-scheme-considerations" title="URI Scheme Considerations">
<t>Please note that the RSYNC protocol provides neither transport security
nor any means by which the RP can validate that they are
connected to the proper host. Therefore, it is RECOMMENDED that HTTPS be
used as the preferred scheme.
</t>
<t>Note that, although a Man in the Middle (MITM) cannot produce a CA
certificate that would be considered valid according to the process
described in <xref target="RP_USE"/>, this type of attack can prevent the RP
from learning about an updated CA certificate.
</t>
<t>RPs MUST do TLS certificate and host name validation when
they fetch a CA certificate using an HTTPS URI on a TAL. RPs SHOULD
log any TLS certificate or host name validation issues found so that
an operator can investigate the cause.
</t>
<t>It is RECOMMENDED that RPs and Repository Servers follow
the Best Current Practices outlined in <xref target="RFC7525"/> on the use of
HTTPS <xref target="RFC7230"/>.  RPs SHOULD do TLS
certificate and host name validation using subjectAltName dNSName
identities as described in <xref target="RFC6125"/>.  The rules and guidelines
defined in <xref target="RFC6125"/> apply here, with the following considerations:
</t>
<t>
<list style="symbols">
<t>RPs and Repository Servers SHOULD support the DNS-ID
  identifier type.  The DNS-ID identifier type SHOULD be present in
  Repository Server certificates.</t>
<t>DNS names in Repository Server certificates SHOULD NOT contain the
  wildcard character &quot;*&quot;.</t>
<t>This protocol does not require the use of SRV-IDs.</t>
<t>This protocol does not require the use of URI-IDs.</t>
</list>
</t>
</section>

<section anchor="security-considerations" title="Security Considerations">
<t>Compromise of a TA private key permits unauthorized parties
to masquerade as a TA, with potentially severe consequences.
Reliance on an inappropriate or incorrect TA has similar
potentially severe consequences.
</t>
<t>This TAL does not directly provide a list of resources covered by the
referenced self-signed CA certificate.  Instead, the RP is referred
to the TA itself and the INR extension(s) within this
certificate.  This provides necessary operational flexibility, but it
also allows the certificate issuer to claim to be authoritative for
any resource.  RPs should either (1)&nbsp;have great confidence in
the issuers of such certificates that they are configuring as TAs or
(2)&nbsp;issue their own self-signed certificate as a TA and,
in doing so, impose constraints on the subordinate certificates.</t>
</section>

<section anchor="iana-considerations" title="IANA Considerations">
<t>This document has no IANA actions.</t>
</section>

</middle>
<back>
<references title="Normative References">

<?rfc include="reference.RFC.2119"?>
<?rfc include="reference.RFC.3779"?>
<?rfc include="reference.RFC.3986"?>
<?rfc include="reference.RFC.4648"?>
<?rfc include="reference.RFC.5198"?>
<?rfc include="reference.RFC.5280"?>
<?rfc include="reference.RFC.5781"?>
<?rfc include="reference.RFC.6125"?>
<?rfc include="reference.RFC.6480"?>
<?rfc include="reference.RFC.6487"?>
<?rfc include="reference.RFC.7230"?>
<?rfc include="reference.RFC.7525"?>
<?rfc include="reference.RFC.7730"?>
<?rfc include="reference.RFC.8174"?>

<reference anchor='X.509' target="https://www.itu.int/rec/T-REC-X.509">
    <front>
        <title>Information technology - Open Systems Interconnection - The
 Directory: Public-key and attribute certificate frameworks</title>
        <author>
            <organization>ITU-T</organization>
        </author>
        <date month='October' year='2016'/>
    </front>
  <seriesInfo name="ITU-T Recommendation" value="X.509"/>
</reference>

</references>

<references title="Informative References">
<?rfc include="reference.RFC.4158"?>
<?rfc include="reference.RFC.5914"?>
<?rfc include="reference.RFC.6486"?>
</references>

<section anchor="acknowledgements" title="Acknowledgements" numbered="no">
<t>This approach to TA material was originally described by
Robert Kisteleki.
</t>
<t>The authors acknowledge the contributions of Rob Austein and Randy
Bush, who assisted with drafting this document and with helpful
review comments.
</t>
<t>The authors acknowledge the work of Roque Gagliano, Terry Manderson,
and Carlos Martinez-Cagnazzo in developing the ideas behind the
inclusion of multiple URIs in the TAL.
</t>
<t>The authors acknowledge Job Snijders for suggesting the inclusion
of comments at the start of the TAL.
</t>
</section>

</back>

</rfc>
