<?xml version="1.0" encoding="utf-8"?>
<!-- This template is for creating an Internet Draft using xml2rfc,
     which is available here: http://xml.resource.org. -->
<!DOCTYPE rfc SYSTEM "rfc2629-xhtml.ent">

<rfc xmlns:xi="http://www.w3.org/2001/XInclude" category="info"
     docName="draft-ietf-sidrops-rp-06" ipr="trust200902" obsoletes=""
     updates="" submissionType="IETF" xml:lang="en" tocInclude="true"
     tocDepth="3" symRefs="true" sortRefs="true" version="3" number="0000"
     consensus="true"> 
  <!-- xml2rfc v2v3 conversion 2.44.0 -->
  <front>
    <title abbrev="RPKI RP Requirements">Requirements for Resource Public Key
    Infrastructure (RPKI) Relying Parties</title> 
    <seriesInfo name="RFC" value="0000"/>
    <author fullname="Di Ma" initials="D." surname="Ma">
      <organization>ZDNS</organization>
      <address>
        <postal>
          <street>4 South 4th St. Zhongguancun</street>
          <city>Haidian</city>
          <code>100190</code>
          <region>Beijing</region>
          <country>China</country>
        </postal>
        <email>madi@zdns.cn</email>
      </address>
    </author>
    <author fullname="Stephen Kent" initials="S." surname="Kent">
      <organization>Independent</organization>
      <address>
        <email>kent@alum.mit.edu</email>
      </address>
    </author>
    <date month="May" year="2020"/>
    <!-- Meta-data Declarations -->

    <area>Routing Area</area>
    <workgroup>SIDROPS</workgroup>
    <!-- <keyword>dns</keyword> -->

    <abstract>
      <t> This document provides a single reference point for requirements for
            Relying Party (RP) software for use in the Resource Public Key
            Infrastructure (RPKI).
            It cites requirements that appear in several RPKI RFCs, making it
            easier for implementers to become aware of these requirements.
            This document will be updated to reflect changes in the RFCs that
            it cites as normative. </t>
    </abstract>
  </front>
  <middle>
    <section numbered="true" toc="default">
      <name>Introduction</name>
      <t>RPKI Relying Party (RP) software is used by network operators and
   others to acquire and verify Internet Number Resource (INR) data
   stored in the RPKI repository system.  RPKI data, when verified,
   allows an RP to verify assertions about which Autonomous Systems
   (ASes) are authorized to originate routes for IP address prefixes.
   RPKI data also establishes a binding between public keys and BGP
   routers, and indicates the AS numbers that each router is authorized
   to represent.</t>
      <t> The essential requirements imposed on RP software to
   support securing Internet routing (<xref target="RFC6480" format="default"/>) are scattered
   throughout numerous RFC documents that are protocol-specific or
   provide best practices. The following RFCs define these requirements
   (or best practices):</t>
      <ul spacing="normal">
       <li>RFC 6481 (Repository Structure)</li>        
       <li>RFC 6482 (ROA format)</li>        
       <li>RFC 6486 (Manifests)</li>
       <li>RFC 6487 (Certificate and CRL profile)</li>
       <li>RFC 6488 (RPKI Signed Objects)</li>
       <li>RFC 6489 (Key Rollover)</li>
       <li>RFC 6810 (RPKI to Router Protocol)</li>
       <li>RFC 6916 (Algorithm Agility)</li>
       <li>RFC 7935 (Algorithms)</li>
       <li>RFC 8209 (Router Certificates)</li>
       <li>RFC 8210 (RPKI to Router Protocol,Version 1)</li>
       <li>RFC 8360 (Certificate Validation Procedure)</li>
       <li>RFC 8630  (Trust Anchor Locator)</li>
      </ul>
      <t>The distribution of RPKI RP requirements across these 13 documents
     makes it hard for an implementer to be confident that he/she has
   addressed all of these requirements.  Additionaly, good software
   engineering practice may call for segmenting the RP system into components
   with orthogonal functionalities, so that those components may be
   distributed.  A taxonomy of the collected RP software requirements can
   help clarify the role of the RP.</t>
      <t>To consolidate RP software requirements in one document, with
   pointers to all the relevant RFCs, this document outlines a set of
   baseline requirements imposed on RPs and provides a single reference
   point for requirements for RP software for use in the RPKI. The requirements
   are organized into four groups:</t>
      <ul spacing="normal">
       <li>Fetching and Caching RPKI Repository Objects</li>
       <li>Processing Certificates and CRLs</li>
       <li>Processing RPKI Repository Signed Objects</li>
       <li>Distributing Validated Cache of the RPKI Data</li>
      </ul>
      <t>This document will be updated to reflect new or changed requirements
   as these RFCs are updated, or additional RFCs are written.</t>
    </section>
    <section numbered="true" toc="default">
      <name>Fetching and Caching RPKI Repository Objects</name>
      <t>RP software uses synchronization mechanisms supported by targeted
   repositories (e.g., <xref target="rsync" format="default"/> or RRDP  <xref
   target="RFC8182" format="default"/>) 
   to download RPKI signed objects from the repository system, in order to
   update a local cache. These mechanisms download only those objects that
   have been added, or replaced with new versions, since the time when the
   RP most recently checked the repository.
   RP software validates the RPKI data and uses it to
   generate authenticated data identifying which ASes are authorized to
   originate routes for address prefixes, and which routers are
   authorized to sign BGP updates on behalf of specified ASes.</t>
      <section numbered="true" toc="default">
        <name>TAL Configuration and Processing</name>
        <t>In the RPKI, each RP chooses a set of trust anchors (TAs).
   Consistent with the extant INR allocation hierarchy, the IANA and/or
   the five RIRs are obvious candidates to be default TAs for the RP.</t>
        <t>An RP does not retrieve TAs directly.  A set of Trust Anchor Locators
   (TALs) is used by RP software to retrieve and verify the authenticity of
   each TA.</t>
        <t>TAL configuration and processing are specified in <xref
	target="RFC8630" sectionFormat="of" section="3"/>.</t> 
      </section>
      <section numbered="true" toc="default">
        <name>Locating RPKI Objects Using Authority and Subject Information Extensions</name>
        <t>TThe RPKI repository system is a distributed one, consisting of
   multiple repository instances.  Each repository instance contains one
   or more repository publication points.  RP software discovers publication
   points using the Subject Information Access (SIA) and the Authority
   Information Access (AIA) extensions from (validated) certificates.</t>
        <t><xref target="RFC6481" sectionFormat="of" section="5"/>  specifies how RP software
        locates all RPKI objectsby using the SIA and AIA extensions.
        Detailed specifications of SIA and AIA extensions in a resource
        certificate are described in Sections <xref target="RFC6481"
	sectionFormat="bare" section="4.8.8"/> and <xref target="RFC6481"
	sectionFormat="bare" section="4.8.7"/> of <xref target="RFC6481"
	format="default"/> respectively.</t> 
      </section>
      <section numbered="true" toc="default">
        <name>Dealing with Key Rollover</name>
        <t>RP software takes the key rollover period into account with regard to its
   frequency of synchronization with the RPKI repository system.</t>
        <t>RP software requirements for dealing with key rollover are
	described in <xref target="RFC6489" sectionFormat="of" section="3"/>
	and <xref target="RFC8634" sectionFormat="of" section="3"/>.</t>
      </section>
      <section numbered="true" toc="default">
        <name>Dealing with Algorithm Transition</name>
        <t>The set of cryptographic algorithms used with the RPKI is expected to
   change over time.  Each RP is expected to be aware of the milestones
   established for the algorithm transition and what actions are
   required at every juncture.</t>
        <t>RP software requirements for dealing with algorithm transition are
   specified in <xref target="RFC6916" sectionFormat="of" section="4"/>.</t>
      </section>
      <section numbered="true" toc="default">
        <name>Strategies for Efficient Cache Maintenance</name>
        <t>Each RP is expected to maintain a local cache of RPKI objects.  The
   cache needs to be as up to date and consistent with repository
   publication point data as the RP's frequency of checking permits.</t>
        <t>The last paragraph of <xref target="RFC6481"
	sectionFormat="of" section="5"/> provides
    guidance for maintenance of a local cache.</t>
      </section>
    </section>
    <section numbered="true" toc="default">
      <name>Certificate and CRL Processing</name>
      <t>The RPKI makes use of X.509 certificates and CRLs, but it profiles
   these standard formats <xref target="RFC6487" format="default"/>.  The major change to the profile
   established in <xref target="RFC5280" format="default"/> is the mandatory use of a new extension in
   RPKI certificates, defined in <xref target="RFC3779" format="default"/>.</t>
      <section numbered="true" toc="default">
        <name>Verifying Resource Certificate and Syntax</name>
        <t>Certificates in the RPKI are called resource certificates, and they
	are required to conform to the profile <xref target="RFC6487"
	format="default"/>.  An RP is required to verify that a resource
	certificate adheres to the profile established by <xref
	target="RFC6487" sectionFormat="of" section="4"/>.  This means that
	all extensions mandated by <xref target="RFC6487"
	sectionFormat="of" section="4.8"/> must be present and  the value of each extension
	must be within the range specified by <xref target="RFC6487"
	format="default"/>.  Moreover, any extension excluded by
	of <xref target="RFC6487" sectionFormat="of" section="4.8"/> must be omitted.</t> 
        <t><xref target="RFC6487" sectionFormat="of" section="7.1"/> specifies
	the procedure that RP software follows when verifying <xref
	target="RFC3779" format="default"/> extensions.</t> 
      </section>
      <section numbered="true" toc="default">
        <name>Certificate Path Validation</name>
        <t>Initially, the INRs in issuer's certificate are required to encompass the INRs
   in the subject's certificate.  This is one of the necessary
   principles of certificate path validation in addition to
   cryptographic verification i.e., verification of the signature on
   each certificate using the public key of the parent certificate).</t>
        <t><xref target="RFC6487" sectionFormat="of" section="7.2"/> specifies
	the procedure that RP software should follow to perform certificate
	path validation.</t> 
        <t>Certification Authorities that want to reduce aspects of
	operational fragility will migrate to the new OIDs <xref
	target="RFC8360" format="default"/>, informing RP software to use an
	alternative RPKI validation algorithm.  An RP is expected to support
	the amended procedure to handle accidental overclaiming, which is
	described in <xref target="RFC8360" sectionFormat="of" section="4"/>.</t> 
      </section>
      <section numbered="true" toc="default">
        <name>CRL Processing</name>
        <t>The CRL processing requirements imposed on CAs and RP are described
	in <xref target="RFC6487" sectionFormat="of" section="5"/>.  CRLs in
	the RPKI are tightly constrained; only the AuthorityKeyIndentifier
	([<xref target="RFC6487" sectionFormat="of" section="4.8.3"/>) and
	CRLNumber(<xref target="RFC5280" sectionFormat="of" section="5.2.3"/>)
	extensions are allowed, and they are required to be present.  No other
	CRL extensions are allowed, and no CRLEntry extensions are permitted.
	RP software is required to verify that these constraints have been
	met.  Each CRL in the RPKI must be verified using the public key from
	the certificate of the CA that issued the CRL.</t> 
        <t>In the RPKI, RPs are expected to pay extra attention when dealing
   with a CRL that is not consistent with the Manifest associated with
   the publication point associated with the CRL.</t>
        <t>Processing of a CRL that is not consistent with a manifest is a
	matter of local policy, as described in the fifth paragraph of <xref
	target="RFC6486" sectionFormat="of" section="6.6"/>.</t> 
      </section>
    </section>
    <section numbered="true" toc="default">
      <name>Processing RPKI Repository Signed Objects</name>
      <section numbered="true" toc="default">
        <name>Basic Signed Object Syntax Checks</name>
        <t>Before an RP can use a signed object from the RPKI repository, RP software
   is required to check the signed object syntax.</t>
        <t><xref target="RFC6488" sectionFormat="of" section="3"/> lists all
	the steps that RP software is required to execute in order to validate
	the top level syntax of a repository signed object.</t> 
        <t>Note that these checks are necessary, but not sufficient.  Additional
   validation checks must be performed based on the specific type of
   signed object as described in <xref target="syntax" format="default"/>.</t>
      </section>
      <section anchor="syntax" numbered="true" toc="default">
        <name>Syntax and Validation for Each Type of Signed Object</name>
        <section numbered="true" toc="default">
          <name>Manifest</name>
          <t>To determine whether a manifest is valid, RP software is required to
   perform manifest-specific checks in addition to the generic signed
   object checks specified in <xref target="RFC6488" format="default"/>.</t>
          <t>Specific checks for a Manifest are described in <xref
	  target="RFC6486" sectionFormat="of" section="4"/>.  If any of these
	  checks fails, indicating that the manifest is invalid, then the
	  manifest will be discarded and RP software will act as though no
	  manifest were present.</t> 
        </section>
        <section numbered="true" toc="default">
          <name>ROA</name>
          <t>To validate a ROA, RP software is required to perform all the checks
   specified in <xref target="RFC6488" format="default"/> as well as additional, ROA-specific
   validation steps.  The IP address delegation extension <xref target="RFC3779" format="default"/>
   present in the end-entity (EE) certificate (contained within the
   ROA), must encompass each of the IP address prefix(es) in the ROA.</t>
          <t>More details for ROA validation are specified in <xref
	  target="RFC6482" sectionFormat="of" section="4"/>.</t> 
        </section>
        <section numbered="true" toc="default">
          <name>Ghostbusters</name>
          <t>The Ghostbusters Record is optional; a publication point in the RPKI
   can have zero or more associated Ghostbuster Records.  If a CA has at
   least one Ghostbuster Record, RP software is required to verify that this
   Ghostbusters Record conforms to the syntax of signed object defined
   in <xref target="RFC6488" format="default"/>.</t>
          <t>The payload of this signed object is a (severely) profiled vCard.
   RP software is required to verify that the payload of Ghostbusters conforms to
   format as profiled in <xref target="RFC6493" format="default"/>.</t>
        </section>
        <section numbered="true" toc="default">
          <name>Verifying BGPsec Router Certificate</name>
          <t>A BGPsec Router Certificate is a resource certificate, so it is
	  required to comply with <xref target="RFC6487" format="default"/>.
	  Additionally, the certificate must contain an AS Identifier
	  Delegation extension (<xref target="RFC6487" sectionFormat="of"
	  section="4.8.11"/>), and must not contain an IP Address Delegation
	  extension (<xref target="RFC6487" sectionFormat="of"
	  section="4.8.10"/>).  The validation procedure used for BGPsec
	  Router Certificates is analogous to the validation procedure
	  described in <xref target="RFC6487" sectionFormat="of"
	  section="7"/>, but it uses the constraints defined in <xref
	  target="RFC8209" sectionFormat="of" section="3"/>.</t> 
          <t>Note that the cryptographic algorithms used by BGPsec routers are
	  found in <xref target="RFC8208" format="default"/>.  Currently, the
	  algorithms specified in <xref target="RFC8208" format="default"/>
	  and <xref target="RFC7935" format="default"/> are different.  BGPsec
	  RP software will need to support algorithms that are used to
	  validate BGPsec signatures as well as the algorithms that are needed
	  to validate signatures on BGPsec certificates, RPKI CA certificates,
	  and RPKI CRLs.</t> 
        </section>
      </section>
      <section numbered="true" toc="default">
        <name>How to Make Use of Manifest Data</name>
        <t>For a given publication point, RP software ought to perform tests,
	as specified in <xref target="RFC6486" sectionFormat="of"
	section="6.1"/>, to determine the state of the Manifest at the
	publication point.  A Manifest can be classified as either valid or
	invalid, and a valid Manifest is either current or stale.  An RP
	decides how to make use of a Manifest based on its state, according to
	local (RP) policy.</t> 
        <t>If there are valid objects in a publication point that are not
   present on a Manifest, <xref target="RFC6486" format="default"/> does not mandate specific RP
   behavior with respect to such objects.</t>
        <t>In the absence of a Manifest, an RP is expected to accept all valid
	signed objects present in the publication point (see <xref
	target="RFC6486" sectionFormat="of" section="6.2"/>). If a Manifest is
	stale or invalid and an RP has no way to acquire a more recent valid
	Manifest, the RP is expected to contact the repository manager via
	Ghostbusters record and thereafter make decisions according to local
	(RP) policy (see Sections <xref target="RFC6486"
	sectionFormat="bare" section="6.3"/> and <xref target="RFC6486"
	sectionFormat="bare" section="6.4"/> of <xref target="RFC6486" format="default"/>).</t> 
      </section>
      <section numbered="true" toc="default">
        <name>What to Do with Ghostbusters Information</name>
        <t>RP software may encounter a stale Manifest or CRL, or an expired
   CA certificate or ROA at a publication point.  An RP is expected to
   use the information from the Ghostbusters record to contact the
   maintainer of the publication point where any stale/expired objects
   were encountered.  The intent here is to encourage the relevant CA
   and/or repository manager to update the stale or expired objects.</t>
      </section>
    </section>
    <section numbered="true" toc="default">
      <name>Distributing Validated Cache</name>
      <t>On a periodic basis, BGP speakers within an AS request updated
   validated origin AS data and router/ASN data from the (local) validated cache of RPKI data.
   The RP may either transfer the validated data to the BGP speakers directly,
   or it may transfer the validated data to a cache server that is responsible
   for provisioning such data to BGP speakers.  The specifications of the
   protocol designed to deliver validated cache data to a BGP Speaker is provided
   in <xref target="RFC6810" format="default"/> and <xref target="RFC8210" format="default"/>.</t>
    </section>
    <section numbered="true" toc="default">
      <name>Local Control</name>
      <t>ISPs may want to establish a local view of exceptions to the RPKI
   data in the form of local filters and additions.  For instance, a
   network operator might wish to make use of a local override
   capability to protect routes from adverse actions <xref target="RFC8211" format="default"/>. The
   mechanisms developed to provide this capability to network operators
   are called "Simplified Local Internet Number Resource Management with the
   RPKI (SLURM).  If an ISP wants to implement SLURM, its RP system
   can follow the instruction specified in <xref target="RFC8416" format="default"/>.</t>
    </section>
    <section numbered="true" toc="default">
      <name>Security Considerations</name>
      <t>This document doesn't introduce any new security considerations; it
   is a resource for implementers.  The RP links the RPKI provisioning
   side and the routing system, establishing a verified, local view of global
   RPKI data to BGP speakers.  The security of the RP is critical to BGP
   messages exchanges.  Each RP implementation is expected to offer
   cache backup management to facilitate recovery from outages.
   RP software also should support application of secure
   transport (e.g., IPsec <xref target="RFC4301" format="default"/>) that is able to protect validated
   cache delivery in a unsafe environment.  This document highlights
   many validation actions applied to RPKI signed objects, an essential
   element of secure operation of RPKI security.</t>
    </section>
    <section numbered="true" toc="default">
      <name>IANA Considerations</name>
      <t>This document has no actions for IANA.</t>
    </section>
    <section numbered="true" toc="default">
      <name>Acknowledgements</name>
      <t>The authors thank <contact fullname="David Mandelberg"/>, <contact
      fullname="Wei Wang"/>, <contact fullname="Tim Bruijnzeels"/>, <contact
      fullname="George Michaelson"/> and <contact fullname="Oleg Muravskiy"/>
      for their review, feedback and editorial assistance in preparing this
      document.</t> 
    </section>
  </middle>
  <back>
    <references>
      <name>References</name>
      <references>
        <name>Normative References</name>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.3779.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.5280.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.6481.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.6482.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.6486.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.6487.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.6488.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.6489.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.6493.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.6810.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.6916.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.7935.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8208.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8209.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8210.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8360.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8630.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8634.xml"/>
      </references>
      <references>
        <name>Informative References</name>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.4301.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.6480.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8182.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8211.xml"/>
        <xi:include href="https://xml2rfc.tools.ietf.org/public/rfc/bibxml/reference.RFC.8416.xml"/>
        <reference anchor="rsync" target="http://rsync.samba.org/">
          <front>
            <title>rsync web page</title>
            <author/>
            <date/>
          </front>
        </reference>
      </references>
    </references>
  </back>
</rfc>
