<?xml version="1.0" encoding="US-ASCII"?>
  <?xml-stylesheet type="text/xsl" href="rfc2629.xslt" ?>

<!DOCTYPE rfc SYSTEM "rfc2629.dtd" [
]>

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

<rfc submissionType="IETF" ipr="trust200902" consensus="yes" number="8555" category="std">

  <front>
    <title abbrev="ACME">Automatic Certificate Management Environment (ACME)</title>

    <author initials="R." surname="Barnes" fullname="Richard Barnes">
      <organization>Cisco</organization>
      <address>
        <email>rlb@ipv.sx</email>
      </address>
    </author>
    <author initials="J." surname="Hoffman-Andrews" fullname="Jacob Hoffman-Andrews">
      <organization>EFF</organization>
      <address>
        <email>jsha@eff.org</email>
      </address>
    </author>
    <author initials="D." surname="McCarney" fullname="Daniel McCarney">
      <organization>Let's Encrypt</organization>
      <address>
        <email>cpu@letsencrypt.org</email>
      </address>
    </author>
    <author initials="J." surname="Kasten" fullname="James Kasten">
      <organization>University of Michigan</organization>
      <address>
        <email>jdkasten@umich.edu</email>
      </address>
    </author>

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


    <workgroup>ACME Working Group</workgroup>
    <keyword>certificate</keyword> <keyword>HTTPS</keyword> <keyword>PKI</keyword> <keyword>X.509</keyword>

    <abstract>


<t>Public Key Infrastructure using X.509 (PKIX) certificates are used for a number of purposes,
the most significant of which is the authentication of domain names.  Thus,
certification authorities (CAs) in the Web PKI are trusted to verify that an applicant
for a certificate legitimately represents the domain name(s) in the certificate.
As of this writing, this verification is done through a collection of ad hoc mechanisms.
This document describes a protocol that a CA and an
applicant can use to automate the process of verification and certificate
issuance.  The protocol also provides facilities for other certificate
management functions, such as certificate revocation.</t>



    </abstract>


  </front>

  <middle>


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

<t>Certificates <xref target="RFC5280"/> in the Web PKI are most commonly used to authenticate
domain names.  Thus, certification authorities (CAs) in the Web PKI are trusted to
verify that an applicant for a certificate legitimately represents the domain
name(s) in the certificate.</t>

<t>Different types of certificates reflect different kinds of CA verification of
information about the certificate subject.  "Domain Validation" (DV)
certificates are by far the most common type.  The only validation
the CA is required to perform in the DV issuance process is to
verify that the requester has effective control of the domain <xref target="CABFBR"></xref>.  The CA is not
required to attempt to verify the requester's
real-world identity.  (This is as opposed to "Organization Validation" (OV) and
"Extended Validation" (EV) certificates, where the process is intended to also
verify the real-world identity of the requester.)</t>

<t>Existing Web PKI certificate authorities tend to use a set of ad hoc
protocols for certificate issuance and identity verification.  In the case of DV
certificates, a typical user experience is something like:</t>

<t><list style="symbols">
  <t>Generate a PKCS#10 <xref target="RFC2986"/> Certificate Signing Request (CSR).</t>
  <t>Cut and paste the CSR into a CA's web page.</t>
  <t>Prove ownership of the domain(s) in the CSR by one of the following methods:
  <list style="symbols">
      <t>Put a CA-provided challenge at a specific place on the web server.</t>
      <t>Put a CA-provided challenge in a DNS record corresponding to the target
domain.</t>
      <t>Receive a CA-provided challenge at (hopefully) an administrator-controlled email
address corresponding to the domain, and then respond to it on the CA's web
page.</t>
    </list></t>
  <t>Download the issued certificate and install it on the user's Web Server.</t>
</list></t>

<t>With the exception of the CSR itself and the certificates that are issued, these
are all completely ad hoc procedures and are accomplished by getting the human
user to follow interactive natural-language instructions from the CA rather than
by machine-implemented published protocols.  In many cases, the instructions are
difficult to follow and cause significant frustration and confusion.  Informal usability tests
by the authors indicate that webmasters often need 1-3 hours to obtain and
install a certificate for a domain.  Even in the best case, the lack of
published, standardized mechanisms presents an obstacle to the wide deployment
of HTTPS and other PKIX-dependent systems because it inhibits mechanization of
tasks related to certificate issuance, deployment, and revocation.</t>

<t>This document describes an extensible framework for automating the issuance and
domain validation procedure, thereby allowing servers and infrastructure
software to obtain certificates without user interaction.  Use of this protocol
should radically simplify the deployment of HTTPS and the practicality of PKIX-based
authentication for other protocols based on Transport Layer Security (TLS)
<xref target="RFC5246"/>.</t>

<t>It should be noted that while the focus of this document is on validating
domain names for purposes of issuing certificates in the Web PKI, ACME supports
extensions for uses with other identifiers in other PKI contexts.  For example,
as of this writing, there is ongoing work to use ACME for issuance of Web PKI
certificates attesting to IP addresses <xref target="ACME-IP"/> and Secure Telephone Identity Revisited (STIR)
certificates attesting to telephone numbers <xref target="ACME-TELEPHONE"/>.</t>

<t>ACME can also be used to automate some aspects of certificate management even
where non-automated processes are still needed.  For example, the external
account binding feature (see <xref target="external-account-binding"/>) can allow an ACME
account to use authorizations that have been granted to an external, non-ACME
account.  This allows ACME to address issuance scenarios that cannot yet be
fully automated, such as the issuance of "Extended Validation" certificates.</t>

</section>
<section anchor="deployment-model-and-operator-experience" title="Deployment Model and Operator Experience">

<t>The guiding use case for ACME is obtaining certificates for websites
(HTTPS <xref target="RFC2818"/>).  In this case, a web server is intended to speak
for one or more domains, and the process of certificate issuance is intended to
verify that this web server actually speaks for the domain(s).</t>

<t>DV certificate validation commonly checks claims about properties related to
control of a domain name -- properties that can be observed by the certificate
issuer in an interactive process that can be conducted purely online.  That
means that under typical circumstances, all steps in the request, verification,
and issuance process can be represented and performed by Internet protocols with
no out-of-band human intervention.</t>

<t>Prior to ACME, when deploying an HTTPS server, a server operator typically gets a
prompt to generate a self-signed certificate.  If the operator were instead
deploying an HTTPS server using ACME, the experience would be something like this:</t>

<t><list style="symbols">
  <t>The operator's ACME client prompts the operator for the intended domain name(s) that the
web server is to stand for.</t>
  <t>The ACME client presents the operator with a list of CAs from which it could
get a certificate.  (This list will change over time based on the capabilities
of CAs and updates to ACME configuration.) The ACME client might prompt the
operator for payment information at this point.</t>
  <t>The operator selects a CA.</t>
  <t>In the background, the ACME client contacts the CA and requests that it
issue a certificate for the intended domain name(s).</t>
  <t>The CA verifies that the client controls the requested domain name(s) by
having the ACME client perform some action(s) that can only be done
with control of the domain name(s).
For example, the CA might require a client requesting example.com
to provision a DNS record under example.com or an HTTP resource
under http://example.com.</t>
  <t>Once the CA is satisfied, it issues the certificate and the ACME client
automatically downloads and installs it, potentially notifying the operator
via email, SMS, etc.</t>
  <t>The ACME client periodically contacts the CA to get updated certificates,
stapled Online Certificate Status Protocol (OCSP) responses <xref target="RFC6960"/>, or whatever else would be required to keep the web server functional and its credentials up to date.</t>
</list></t>

<t>In this way, it would be nearly as easy to deploy with a CA-issued certificate
as with a self-signed certificate. Furthermore, the maintenance of that
CA-issued certificate would require minimal manual intervention.  Such close
integration of ACME with HTTPS servers allows the immediate and automated
deployment of certificates as they are issued, sparing the human administrator
from much of the time-consuming work described in the previous section.</t>

</section>
<section anchor="terminology" title="Terminology">

<t>The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
"SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and
"OPTIONAL" 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>

<t>The two main roles in ACME are "client" and "server".  The ACME client uses the
protocol to request certificate management actions, such as issuance or
revocation.  An ACME client may run on a web server, mail server, or some other
server system that requires valid X.509 certificates.  Or, it may run on a separate
server that does not consume the certificate but is authorized to respond to a
CA-provided challenge.  The ACME server runs at a certification authority
and responds to client requests, performing the requested actions if the client is
authorized.</t>

<t>An ACME client authenticates to the server by means of an "account key pair".  The client uses the
private key of this key pair to sign all messages sent to the server.  The
server uses the public key to verify the authenticity and integrity of messages
from the client.</t>

</section>
<section anchor="protocol-overview" title="Protocol Overview">

<t>ACME allows a client to request certificate management actions using a set of
JavaScript Object Notation (JSON) messages <xref target="RFC8259"/> carried over HTTPS <xref target="RFC2818"/>.
Issuance using ACME resembles a traditional CA's issuance process, in which a user creates an account,
requests a certificate, and proves control of the domain(s) in that certificate in
order for the CA to issue the requested certificate.</t>

<t>The first phase of ACME is for the client to request an account with the
ACME server.  The client generates an asymmetric key pair and requests a
new account, optionally providing contact information, agreeing to terms
of service (ToS), and/or associating the account with an existing account
in another system. The creation request is signed with the generated
private key to prove that the client controls it.</t>

<figure title="Account Creation"><artwork><![CDATA[
      Client                                                   Server

      [Contact Information]
      [ToS Agreement]
      [Additional Data]
      Signature                     ------->
                                                          Account URL
                                    <-------           Account Object


                [] Information covered by request signatures
]]></artwork></figure>

<t>Once an account is registered, there are four major steps the client needs to take to
get a certificate:</t>

<t><list style="numbers">
  <t>Submit an order for a certificate to be issued</t>
  <t>Prove control of any identifiers requested in the certificate</t>
  <t>Finalize the order by submitting a CSR</t>
  <t>Await issuance and download the issued certificate</t>
</list></t>

<t>The client's order for a certificate describes the desired identifiers
plus a few additional fields that
capture semantics that are not supported in the CSR format.  If the server is
willing to consider issuing such a certificate, it responds with a list of
requirements that the client must satisfy before the certificate will be issued.</t>

<t>For example, in most cases, the server will require the client to demonstrate
that it controls the identifiers in the requested certificate.  Because there
are many different ways to validate possession of different types of
identifiers, the server will choose from an extensible set of challenges that
are appropriate for the identifier being claimed.  The client responds with a
set of responses that tell the server which challenges the client has completed.
The server then validates that the client has completed the challenges.</t>

<t>Once the validation process is complete and the server is satisfied that the
client has met its requirements, the client finalizes the order by submitting
a PKCS#10 Certificate Signing Request (CSR). The server will issue the requested
certificate and make it available to the client.</t>

<figure title="Certificate Issuance"><artwork><![CDATA[
      Client                                                   Server

      [Order]
      Signature                     ------->
                                    <-------  Required Authorizations

      [Responses]
      Signature                     ------->

                          <~~~~~~~~Validation~~~~~~~~>

      [CSR]
      Signature                     ------->
                                    <-------          Acknowledgement

                          <~~~~~~Await issuance~~~~~~>

      [POST-as-GET request]
      Signature                     ------->
                                    <-------              Certificate

                [] Information covered by request signatures
]]></artwork></figure>

<t>To revoke a certificate, the client sends a signed revocation request indicating
the certificate to be revoked:</t>

<figure title="Certificate Revocation"><artwork><![CDATA[
      Client                                                 Server

      [Revocation request]
      Signature                    -------->

                                   <--------                 Result

                [] Information covered by request signatures
]]></artwork></figure>

<t>Note that while ACME is defined with enough flexibility to handle different
types of identifiers in principle, the primary use case addressed by this
document is the case where domain names are used as identifiers.  For example,
all of the identifier validation challenges described in
<xref target="identifier-validation-challenges"/> address validation of domain names.
The use of ACME for other identifiers will require further specification in order
to describe how these identifiers are encoded in the protocol and what types of
validation challenges the server might require.</t>

</section>
<section anchor="character-encoding" title="Character Encoding">

<t>All requests and responses sent via HTTP by ACME clients, ACME servers, and
validation servers as well as any inputs for digest computations MUST be encoded
using the UTF-8 character set <xref target="RFC3629"/>. Note that identifiers that appear in
certificates may have their own encoding considerations (e.g., DNS names containing
non-ASCII characters are expressed as A-labels rather than U-labels). Any such
encoding considerations are to be applied prior to the aforementioned UTF-8
encoding.</t>

</section>
<section anchor="message-transport" title="Message Transport">

<t>Communications between an ACME client and an ACME server are done over HTTPS,
using JSON Web Signature (JWS) <xref target="RFC7515"/> to provide some additional security
properties for messages sent from
the client to the server.  HTTPS provides server authentication and
confidentiality.  With some ACME-specific extensions, JWS provides
authentication of the client's request payloads, anti-replay protection, and
integrity for the HTTPS request URL.</t>

<section anchor="https-requests" title="HTTPS Requests">

<t>Each ACME function is accomplished by the client sending a sequence of HTTPS
requests to the server <xref target="RFC2818"/>, carrying JSON messages <xref target="RFC8259"/>.  Use of
HTTPS is REQUIRED. Each subsection of
<xref target="certificate-management"/> below describes the message formats used by the
function and the order in which messages are sent.</t>

<t>In most HTTPS transactions used by ACME, the ACME client is the HTTPS client
and the ACME server is the HTTPS server. The ACME server acts as a
client when validating challenges: an HTTP client when
validating an 'http-01' challenge, a DNS client with 'dns-01', etc.</t>

<t>ACME servers SHOULD follow the recommendations of <xref target="RFC7525"/> when configuring
their TLS implementations.  ACME servers that support TLS 1.3 MAY allow clients
to send early data (0-RTT).  This is safe because the ACME protocol itself
includes anti-replay protections (see <xref target="replay-protection"/>) in all cases where
they are required.  For this reason, there are no restrictions on what ACME
data can be carried in 0-RTT.</t>

<t>ACME clients MUST send a User-Agent header field, in accordance with
<xref target="RFC7231"/>. This header field SHOULD include the name and version of the
ACME software in addition to the name and version of the underlying
HTTP client software.</t>

<t>ACME clients SHOULD send an Accept-Language header field in accordance with
<xref target="RFC7231"/> to enable localization of error messages.</t>

<t>ACME servers that are intended to be generally accessible need to use
Cross-Origin Resource Sharing (CORS) in order to be accessible from
browser-based clients <xref target="W3C.REC-cors-20140116"/>.  Such servers SHOULD set the
Access-Control-Allow-Origin header field to the value "*".</t>

<t>Binary fields in the JSON objects used by ACME are encoded using base64url
encoding described in Section 5 of <xref target="RFC4648"/> according to the profile specified
in JSON Web Signature in Section 2 of <xref target="RFC7515"/>. This encoding uses a URL safe
character set. Trailing '=' characters MUST be stripped. Encoded
values that include trailing '=' characters MUST be rejected as
improperly encoded.</t>

</section>
<section anchor="request-authentication" title="Request Authentication">

<t>All ACME requests with a non-empty body MUST encapsulate their payload
in a JSON Web Signature (JWS) <xref target="RFC7515"/> object, signed using the account's
private key unless otherwise specified.  The server MUST verify the JWS before
processing the request. Encapsulating request bodies in JWS provides
authentication of requests.</t>

<t>A JWS object sent as the body of an ACME request MUST meet the following additional criteria:</t>

<t><list style="symbols">
  <t>The JWS MUST be in the  Flattened JSON Serialization <xref target="RFC7515"/></t>
  <t>The JWS MUST NOT have multiple signatures</t>
  <t>The JWS Unencoded Payload Option <xref target="RFC7797"/> MUST NOT be used</t>
  <t>The JWS Unprotected Header <xref target="RFC7515"/> MUST NOT be used</t>
  <t>The JWS Payload MUST NOT be detached</t>
  <t>The JWS Protected Header MUST include the following fields:
  <list style="symbols">
      <t>"alg" (Algorithm)
      <list style="symbols">
          <t>This field MUST NOT contain "none" or a Message Authentication Code (MAC) algorithm (e.g. one in which the algorithm registry description mentions MAC/HMAC).</t>
        </list></t>
      <t>"nonce" (defined in <xref target="replay-protection"/>)</t>
      <t>"url" (defined in <xref target="request-url-integrity"/>)</t>
      <t>Either "jwk" (JSON Web Key) or "kid" (Key ID) as specified below</t>
    </list></t>
</list></t>

<t>An ACME server MUST implement the "ES256" signature algorithm <xref target="RFC7518"/> and SHOULD implement the "EdDSA" signature algorithm using the "Ed25519" variant (indicated by "crv") <xref target="RFC8037"/>.</t>

<t>The "jwk" and "kid" fields are mutually exclusive. Servers MUST reject requests
that contain both.</t>

<t>For newAccount requests, and for revokeCert requests authenticated by a certificate
key, there MUST be a "jwk" field. This field MUST contain the public key
corresponding to the private key used to sign the JWS.</t>

<t>For all other requests, the request is signed using an existing account, and
there MUST be a "kid" field. This field MUST contain the account URL received by
POSTing to the newAccount resource.</t>

<t>If the client sends a JWS signed with an algorithm that the server does not
support, then the server MUST return an error with status code 400 (Bad Request)
and type "urn:ietf:params:acme:error:badSignatureAlgorithm".  The problem
document returned with the error MUST include an "algorithms" field with an
array of supported "alg" values.  See <xref target="errors"/> for more details on
the structure of error responses.</t>

<t>If the server supports the signature algorithm "alg" but either does not support
or chooses to reject the public key "jwk", then the server MUST return an error
with status code 400 (Bad Request) and type
"urn:ietf:params:acme:error:badPublicKey".  The problem document detail SHOULD
describe the reason for rejecting the public key; some example reasons are:</t>

<t><list style="symbols">
  <t>"alg" is "RS256" but the modulus "n" is too small (e.g., 512-bit)</t>
  <t>"alg" is "ES256" but "jwk" does not contain a valid P-256 public key</t>
  <t>"alg" is "EdDSA" and "crv" is "Ed448", but the server only supports "EdDSA"
with "Ed25519"</t>
  <t>the corresponding private key is known to have been compromised</t>
</list></t>

<t>Because client requests in ACME carry JWS objects in the Flattened
JSON Serialization, they must have the Content-Type header field
set to "application/jose+json".  If a request does not meet this
requirement, then the server MUST return a response with status code
415 (Unsupported Media Type).</t>

</section>
<section anchor="post-as-get" title="GET and POST-as-GET Requests">

<t>Note that authentication via signed JWS request bodies implies that
requests without an entity body are not authenticated, in particular
GET requests.  Except for the cases described in this section, if
the server receives a GET request, it MUST return an error with
status code 405 (Method Not Allowed) and type "malformed".</t>

<t>If a client wishes to fetch a resource from the server (which would
otherwise be done with a GET), then it MUST send a POST request with
a JWS body as described above, where the payload of the JWS is a
zero-length octet string.  In other words, the "payload" field of the
JWS object MUST be present and set to the empty string ("").</t>

<t>We will refer to these as "POST-as-GET" requests. On receiving a
request with a zero-length (and thus non-JSON) payload, the server
MUST authenticate the sender and verify any access control rules.
Otherwise, the server MUST treat this request as having the same
semantics as a GET request for the same resource.</t>

<t>The server MUST allow GET requests for the directory and newNonce
resources (see <xref target="resources"/>), in addition to POST-as-GET requests
for these resources.  This enables clients to bootstrap into the
ACME authentication system.</t>

</section>
<section anchor="request-url-integrity" title="Request URL Integrity">

<t>It is common in deployment for the entity terminating TLS for HTTPS to be different
from the entity operating the logical HTTPS server, with a "request routing"
layer in the middle.  For example, an ACME CA might have a content delivery
network terminate TLS connections from clients so that it can inspect client
requests for denial-of-service (DoS) protection.</t>

<t>These intermediaries can also change values in the request that are not signed
in the HTTPS request, e.g., the request URL and header fields.  ACME uses JWS to
provide an integrity mechanism, which protects against an intermediary
changing the request URL to another ACME URL.</t>

<t>As noted in <xref target="request-authentication"/>, all ACME request objects carry a
"url" header parameter in their protected header.  This header parameter encodes
the URL to which the client is directing the request.  On receiving such an
object in an HTTP request, the server MUST compare the "url" header parameter to
the request URL.  If the two do not match, then the server MUST reject the
request as unauthorized.</t>

<t>Except for the directory resource, all ACME resources are addressed with URLs
provided to the client by the server.  In POST requests sent to these resources, the client MUST set
the "url" header parameter to the exact string provided by the server (rather
than performing any re-encoding on the URL).  The server SHOULD perform the
corresponding string equality check, configuring each resource with the URL
string provided to clients and having the resource check that requests have the
same string in their "url" header parameter. The server MUST reject the request
as unauthorized if the string equality check fails.</t>

<section anchor="url-url-jws-header-parameter" title="&quot;url&quot; (URL) JWS Header Parameter">

<t>The "url" header parameter specifies the URL <xref target="RFC3986"/> to which this JWS
object is directed.  The "url" header parameter MUST be carried in the protected
header of the JWS.  The value of the "url" header parameter MUST be a string
representing the target URL.</t>

</section>
</section>
<section anchor="replay-protection" title="Replay Protection">

<t>In order to protect ACME resources from any possible replay attacks, ACME
POST requests have a mandatory anti-replay mechanism.  This mechanism is based on the
server maintaining a list of nonces that it has issued, and requiring
any signed request from the client to carry such a nonce.</t>

<t>An ACME server provides nonces to clients using the HTTP Replay-Nonce header field,
as specified in <xref target="replay-nonce"/>.  The server MUST include a Replay-Nonce
header field in every successful response to a POST request and SHOULD provide
it in error responses as well.</t>

<t>Every JWS sent by an ACME client MUST include, in its protected header, the
"nonce" header parameter, with contents as defined in
<xref target="nonce-nonce-jws-header-parameter"/>.  As part of JWS verification, the
ACME server MUST verify that the value of the "nonce" header is a value that the
server previously provided in a Replay-Nonce header field.  Once a nonce value
has appeared in an ACME request, the server MUST consider it invalid, in the same
way as a value it had never issued.</t>

<t>When a server rejects a request because its nonce value was unacceptable (or not
present), it MUST provide HTTP status code 400 (Bad Request), and indicate the
ACME error type "urn:ietf:params:acme:error:badNonce".  An error response with
the "badNonce" error type MUST include a Replay-Nonce header field with a
fresh nonce that the server will accept in a retry of the original
query (and possibly in other requests, according to the server's
nonce scoping policy).
On receiving such a response, a client SHOULD retry the request using the new
nonce.</t>

<t>The precise method used to generate and track nonces is up to the server.  For
example, the server could generate a random 128-bit value for each response,
keep a list of issued nonces, and strike nonces from this list as they are used.</t>

<t>Other than the constraint above with regard to nonces issued in
"badNonce" responses, ACME does not constrain how servers
scope nonces. Clients MAY assume that nonces have broad scope,
e.g., by having a single pool of nonces used for all requests.
However, when retrying in response to a "badNonce" error, the client
MUST use the nonce provided in the error response. Servers should
scope nonces broadly enough that retries are not needed very often.</t>

<section anchor="replay-nonce" title="Replay-Nonce">

<t>The Replay-Nonce HTTP header field includes a server-generated value that the
server can use to detect unauthorized replay in future client requests.  The
server MUST generate the values provided in Replay-Nonce header fields in such a way that
they are unique to each message, with high probability, and unpredictable to anyone besides the server. For instance, it is
acceptable to generate Replay-Nonces randomly.</t>

<t>The value of the Replay-Nonce header field MUST be an octet string encoded according to
the base64url encoding described in Section 2 of <xref target="RFC7515"/>.  Clients MUST
ignore invalid Replay-Nonce values.  The ABNF <xref target="RFC5234"/> for the Replay-Nonce
header field follows:</t>

<figure><artwork><![CDATA[
  base64url = ALPHA / DIGIT / "-" / "_"

  Replay-Nonce = 1*base64url
]]></artwork></figure>

<t>The Replay-Nonce header field SHOULD NOT be included in HTTP request messages.</t>

</section>
<section anchor="nonce-nonce-jws-header-parameter" title="&quot;nonce&quot; (Nonce) JWS Header Parameter">

<t>The "nonce" header parameter provides a unique value that enables the verifier
of a JWS to recognize when replay has occurred. The "nonce" header parameter
MUST be carried in the protected header of the JWS.</t>

<t>The value of the "nonce" header parameter MUST be an octet string, encoded
according to the base64url encoding described in Section 2 of <xref target="RFC7515"/>.  If
the value of a "nonce" header parameter is not valid according to this encoding,
then the verifier MUST reject the JWS as malformed.</t>

</section>
</section>
<section anchor="rate-limits" title="Rate Limits">

<t>Creation of resources can be rate limited by ACME servers to ensure fair usage and
prevent abuse.  Once the rate limit is exceeded, the server MUST respond
with an error with the type "urn:ietf:params:acme:error:rateLimited".
Additionally, the server SHOULD send a Retry-After header field <xref target="RFC7231"/> indicating
when the current request may succeed again.  If multiple rate limits are
in place, that is the time where all rate limits allow access again for
the current request with exactly the same parameters.</t>

<t>In addition to the human-readable "detail" field of the error response, the
server MAY send one or multiple link relations in the Link header field <xref target="RFC8288"/> pointing to
documentation about the specific rate limit that was hit, using the "help" link relation type.</t>

</section>
<section anchor="errors" title="Errors">

<t>Errors can be reported in ACME both at the HTTP layer and within challenge
objects as defined in <xref target="identifier-validation-challenges"/>. ACME servers can
return responses with an HTTP error response code (4XX or 5XX). For example,
if the client submits a request using a method not allowed in this document,
then the server MAY return status code 405 (Method Not Allowed).</t>

<t>When the server responds with an error status, it SHOULD provide additional
information using a problem document <xref target="RFC7807"/>.  To facilitate automatic
response to errors, this document defines the following standard tokens for use
in the "type" field (within the ACME URN namespace "urn:ietf:params:acme:error:"):</t>

<?rfc compact="no"?>
<texttable>
      <ttcol align='left'>Type</ttcol>
      <ttcol align='left'>Description</ttcol>
      <c>accountDoesNotExist</c>
      <c>The request specified an account that does not exist</c>
      <c>alreadyRevoked</c>
      <c>The request specified a certificate to be revoked that has already been revoked</c>
      <c>badCSR</c>
      <c>The CSR is unacceptable (e.g., due to a short key)</c>
      <c>badNonce</c>
      <c>The client sent an unacceptable anti-replay nonce</c>
      <c>badPublicKey</c>
      <c>The JWS was signed by a public key the server does not support</c>
      <c>badRevocationReason</c>
      <c>The revocation reason provided is not allowed by the server</c>
      <c>badSignatureAlgorithm</c>
      <c>The JWS was signed with an algorithm the server does not support</c>
      <c>caa</c>
      <c>Certification Authority Authorization (CAA) records forbid the CA from issuing a certificate</c>
      <c>compound</c>
      <c>Specific error conditions are indicated in the "subproblems" array</c>
      <c>connection</c>
      <c>The server could not connect to validation target</c>
      <c>dns</c>
      <c>There was a problem with a DNS query during identifier validation</c>
      <c>externalAccountRequired</c>
      <c>The request must include a value for the "externalAccountBinding" field</c>
      <c>incorrectResponse</c>
      <c>Response received didn't match the challenge's requirements</c>
      <c>invalidContact</c>
      <c>A contact URL for an account was invalid</c>
      <c>malformed</c>
      <c>The request message was malformed</c>
      <c>orderNotReady</c>
      <c>The request attempted to finalize an order that is not ready to be finalized</c>
      <c>rateLimited</c>
      <c>The request exceeds a rate limit</c>
      <c>rejectedIdentifier</c>
      <c>The server will not issue certificates for the identifier</c>
      <c>serverInternal</c>
      <c>The server experienced an internal error</c>
      <c>tls</c>
      <c>The server received a TLS error during validation</c>
      <c>unauthorized</c>
      <c>The client lacks sufficient authorization</c>
      <c>unsupportedContact</c>
      <c>A contact URL for an account used an unsupported protocol scheme</c>
      <c>unsupportedIdentifier</c>
      <c>An identifier is of an unsupported type</c>
      <c>userActionRequired</c>
      <c>Visit the "instance" URL and take actions specified there</c>
</texttable>
<?rfc compact="yes"?>

<t>This list is not exhaustive. The server MAY return errors whose "type" field is
set to a URI other than those defined above.  Servers MUST NOT use the ACME URN
namespace for errors not listed in the appropriate IANA registry (see <xref target="acme-urn-space"/>).  Clients SHOULD display the
"detail" field of all errors.</t>

<t>In the remainder of this document, we use the tokens in the table above to refer
to error types, rather than the full URNs.  For example, an "error of type
'badCSR'" refers to an error document with "type" value
"urn:ietf:params:acme:error:badCSR".</t>

<section anchor="subproblems" title="Subproblems">

<t>Sometimes a CA may need to return multiple errors in response to a request.
Additionally, the CA may need to attribute errors to specific
identifiers.  For instance, a newOrder request may contain multiple
identifiers for which the CA cannot issue certificates. In this situation, an ACME
problem document MAY contain the "subproblems" field, containing a JSON
array of problem documents, each of which MAY contain an "identifier"
field. If present, the "identifier" field MUST contain an ACME identifier
(<xref target="iana-identifier"/>). The "identifier" field MUST NOT be present at
the top level in ACME problem documents. It can only be present in subproblems.
Subproblems need not all have the same type, and they do not need to match the top level type.</t>

<t>ACME clients may choose to use the "identifier" field of a subproblem
as a hint that an operation would succeed if that identifier were omitted. For
instance, if an order contains ten DNS identifiers, and the newOrder
request returns a problem document with two subproblems (referencing two
of those identifiers), the ACME client may choose to submit another order
containing only the eight identifiers not listed in the problem document.</t>

<figure><artwork><![CDATA[
HTTP/1.1 403 Forbidden
Content-Type: application/problem+json
Link: <https://example.com/acme/directory>;rel="index"

{
    "type": "urn:ietf:params:acme:error:malformed",
    "detail": "Some of the identifiers requested were rejected",
    "subproblems": [
        {
            "type": "urn:ietf:params:acme:error:malformed",
            "detail": "Invalid underscore in DNS name \"_example.org\"",
            "identifier": {
                "type": "dns",
                "value": "_example.org"
            }
        },
        {
            "type": "urn:ietf:params:acme:error:rejectedIdentifier",
            "detail": "This CA will not issue for \"example.net\"",
            "identifier": {
                "type": "dns",
                "value": "example.net"
            }
        }
    ]
}
]]></artwork></figure>

</section>
</section>
</section>
<section anchor="certificate-management" title="Certificate Management">

<t>In this section, we describe the certificate management functions that ACME
enables:</t>

<t><list style="symbols">
  <t>Account Creation</t>
  <t>Ordering a Certificate</t>
  <t>Identifier Authorization</t>
  <t>Certificate Issuance</t>
  <t>Certificate Revocation</t>
</list></t>

<section anchor="resources" title="Resources">

<t>ACME is structured as an HTTP-based application with the following types of resources:</t>

<t><list style="symbols">
  <t>Account resources, representing information about an account
(<xref target="account-objects"/>, <xref target="account-management"/>)</t>
  <t>Order resources, representing an account's requests to issue certificates
(<xref target="order-objects"/>)</t>
  <t>Authorization resources, representing an account's authorization to act for an
identifier (<xref target="authorization-objects"/>)</t>
  <t>Challenge resources, representing a challenge to prove control of an
identifier (<xref target="identifier-authorization"/>, <xref target="identifier-validation-challenges"/>)</t>
  <t>Certificate resources, representing issued certificates
(<xref target="downloading-the-certificate"/>)</t>
  <t>A "directory" resource (<xref target="directory"/>)</t>
  <t>A "newNonce" resource (<xref target="getting-a-nonce"/>)</t>
  <t>A "newAccount" resource (<xref target="account-management"/>)</t>
  <t>A "newOrder" resource (<xref target="applying-for-certificate-issuance"/>)</t>
  <t>A "revokeCert" resource (<xref target="certificate-revocation"/>)</t>
  <t>A "keyChange" resource (<xref target="account-key-roll-over"/>)</t>
</list></t>

<t>The server MUST provide "directory" and "newNonce" resources.</t>

<t>ACME uses different URLs for different management functions. Each function is
listed in a directory along with its corresponding URL, so clients only need to
be configured with the directory URL.  These URLs are connected by a few
different link relations <xref target="RFC5988"/>.</t>

<t>The "up" link relation is used with challenge resources to indicate the
authorization resource to which a challenge belongs.  It is also used, with some
media types, from certificate resources to indicate a resource from which the
client may fetch a chain of CA certificates that could be used to validate the
certificate in the original resource.</t>

<t>The "index" link relation is present on all resources other than the
directory and indicates the URL of the directory.</t>

<t>The following diagram illustrates the relations between resources on an ACME
server.  For the most part, these relations are expressed by URLs provided as
strings in the resources' JSON representations.  Lines with labels in quotes
indicate HTTP link relations.</t>

<figure title="ACME Resources and Relationships"><artwork><![CDATA[
                               directory
                                   |
                                   +--> newNonce
                                   |
       +----------+----------+-----+-----+------------+
       |          |          |           |            |
       |          |          |           |            |
       V          V          V           V            V
  newAccount   newAuthz   newOrder   revokeCert   keyChange
       |          |          |
       |          |          |
       V          |          V
    account       |        order --+--> finalize
                  |          |     |
                  |          |     +--> cert
                  |          V
                  +---> authorization
                            | ^
                            | | "up"
                            V |
                          challenge
]]></artwork></figure>

<t>The following table illustrates a typical sequence of requests required to
establish a new account with the server, prove control of an identifier, issue a
certificate, and fetch an updated certificate some time after issuance.  The
"-&gt;" is a mnemonic for a Location header field pointing to a created resource.</t>
<?rfc compact="no"?>
<texttable>
      <ttcol align='left'>Action</ttcol>
      <ttcol align='left'>Request</ttcol>
      <ttcol align='left'>Response</ttcol>
      <c>Get directory</c>
      <c>GET  directory</c>
      <c>200</c>
      <c>Get nonce</c>
      <c>HEAD newNonce</c>
      <c>200</c>
      <c>Create account</c>
      <c>POST newAccount</c>
      <c>201 -&gt; account</c>
      <c>Submit order</c>
      <c>POST newOrder</c>
      <c>201 -&gt; order</c>
      <c>Fetch challenges</c>
      <c>POST-as-GET order's authorization urls</c>
      <c>200</c>
      <c>Respond to challenges</c>
      <c>POST authorization challenge urls</c>
      <c>200</c>
      <c>Poll for status</c>
      <c>POST-as-GET order</c>
      <c>200</c>
      <c>Finalize order</c>
      <c>POST order's finalize url</c>
      <c>200</c>
      <c>Poll for status</c>
      <c>POST-as-GET order</c>
      <c>200</c>
      <c>Download certificate</c>
      <c>POST-as-GET order's certificate url</c>
      <c>200</c>
</texttable>
<?rfc compact="yes"?>
<t>The remainder of this section provides the details of how these resources are
structured and how the ACME protocol makes use of them.</t>

<section anchor="directory" title="Directory">

<t>In order to help clients configure themselves with the right URLs for each ACME
operation, ACME servers provide a directory object. This should be the only URL
needed to configure clients. It is a JSON object, whose field names are drawn from
the resource registry (<xref target="iana-resource"/>) and whose values are the corresponding
URLs.</t>
<?rfc compact="no"?>
<texttable>
      <ttcol align='left'>Field</ttcol>
      <ttcol align='left'>URL in Value</ttcol>
      <c>newNonce</c>
      <c>New nonce</c>
      <c>newAccount</c>
      <c>New account</c>
      <c>newOrder</c>
      <c>New order</c>
      <c>newAuthz</c>
      <c>New authorization</c>
      <c>revokeCert</c>
      <c>Revoke certificate</c>
      <c>keyChange</c>
      <c>Key change</c>
</texttable>
<?rfc compact="yes"?>
<t>There is no constraint on the URL of the directory except that it
should be different from the other ACME server resources' URLs, and that it
should not clash with other services. For instance:</t>

<t><list style="symbols">
  <t>a host that functions as both an ACME and a Web server may want to keep
the root path "/" for an HTML "front page" and place the ACME
directory under the path "/acme".</t>
  <t>a host that only functions as an ACME server could place the directory
under the path "/".</t>
</list></t>

<t>If the ACME server does not implement pre-authorization (<xref target="pre-authorization"/>), it
MUST omit the "newAuthz" field of the directory.</t>

<t>The object MAY additionally contain a "meta" field. If present, it MUST be a
JSON object; each field in the object is an item of metadata relating to
the service provided by the ACME server.</t>

<t>The following metadata items are defined (<xref target="iana-meta"/>), all of which are OPTIONAL:</t>

<t><list style="hanging">
  <t hangText='termsOfService (optional, string):'>
  A URL identifying the current terms of service.</t>
  <t hangText='website (optional, string):'>
  An HTTP or HTTPS URL locating a website providing more
information about the ACME server.</t>
  <t hangText='caaIdentities (optional, array of string):'>
  The hostnames that the ACME server recognizes as referring to
itself for the purposes of CAA record validation as defined in
<xref target="RFC6844"/>.  Each string MUST represent the same sequence of ASCII
code points that the server will expect to see as the "Issuer Domain
Name" in a CAA issue or issuewild property tag.  This allows clients
to determine the correct issuer domain name to use when configuring
CAA records.</t>
  <t hangText='externalAccountRequired (optional, boolean):'>
  If this field is present and set to "true", then the CA requires that all
newAccount requests include an "externalAccountBinding" field associating the
new account with an external account.</t>
</list></t>

<t>Clients access the directory by sending a GET request to the directory URL.</t>

<figure><artwork><![CDATA[
HTTP/1.1 200 OK
Content-Type: application/json

{
  "newNonce": "https://example.com/acme/new-nonce",
  "newAccount": "https://example.com/acme/new-account",
  "newOrder": "https://example.com/acme/new-order",
  "newAuthz": "https://example.com/acme/new-authz",
  "revokeCert": "https://example.com/acme/revoke-cert",
  "keyChange": "https://example.com/acme/key-change",
  "meta": {
    "termsOfService": "https://example.com/acme/terms/2017-5-30",
    "website": "https://www.example.com/",
    "caaIdentities": ["example.com"],
    "externalAccountRequired": false
  }
}
]]></artwork></figure>

</section>
<section anchor="account-objects" title="Account Objects">

<t>An ACME account resource represents a set of metadata associated with an account.
Account resources have the following structure:</t>

<t><list style="hanging">
  <t hangText='status (required, string):'>
  The status of this account. Possible values are "valid", "deactivated", and
"revoked".  The value "deactivated" should be used to indicate client-initiated
deactivation whereas "revoked" should be used to indicate server-initiated
deactivation. See <xref target="status-changes"/>.</t>
  <t hangText='contact (optional, array of string):'>
  An array of URLs that the server can use to contact the client for issues
related to this account. For example, the server may wish to notify the
client about server-initiated revocation or certificate expiration.
For information on supported URL schemes, see <xref target="account-management"/>.</t>
  <t hangText='termsOfServiceAgreed (optional, boolean):'>
  Including this field in a newAccount request, with a value of true, indicates
the client's agreement with the terms of service. This field cannot be updated
by the client.</t>
  <t hangText='externalAccountBinding (optional, object):'>
  Including this field in a newAccount request indicates approval by the holder
of an existing non-ACME account to bind that account to this ACME account. This
field is not updateable by the client (see <xref target="external-account-binding"/>).</t>
  <t hangText='orders (required, string):'>
  A URL from which a list of orders submitted by this account can be fetched via
a POST-as-GET request, as described in <xref target="orders-list"/>.</t>
</list></t>

<figure><artwork><![CDATA[
{
  "status": "valid",
  "contact": [
    "mailto:cert-admin@example.org",
    "mailto:admin@example.org"
  ],
  "termsOfServiceAgreed": true,
  "orders": "https://example.com/acme/orders/rzGoeA"
}
]]></artwork></figure>

<section anchor="orders-list" title="Orders List">

<t>Each account object includes an "orders" URL from which a list of orders created
by the account can be fetched via POST-as-GET request. The result of the request
MUST be a JSON object whose "orders" field is an array of URLs, each identifying
an order belonging to the account.  The server SHOULD include pending orders
and SHOULD NOT include orders that are invalid in the array of URLs. The server
MAY return an incomplete list, along with a Link header field with a "next" link
relation indicating where further entries can be acquired.</t>

<figure><artwork><![CDATA[
HTTP/1.1 200 OK
Content-Type: application/json
Link: <https://example.com/acme/directory>;rel="index"
Link: <https://example.com/acme/orders/rzGoeA?cursor=2>;rel="next"

{
  "orders": [
    "https://example.com/acme/order/TOlocE8rfgo",
    "https://example.com/acme/order/4E16bbL5iSw",
    /* more URLs not shown for example brevity */
    "https://example.com/acme/order/neBHYLfw0mg"
  ]
}
]]></artwork></figure>

</section>
</section>
<section anchor="order-objects" title="Order Objects">

<t>An ACME order object represents a client's request for a certificate and is
used to track the progress of that order through to issuance.  Thus, the object
contains information about the requested certificate, the authorizations that
the server requires the client to complete, and any certificates that have
resulted from this order.</t>

<t><list style="hanging">
  <t hangText='status (required, string):'>
  The status of this order.  Possible values are "pending",
"ready", "processing", "valid", and "invalid".  See
<xref target="status-changes"/>.</t>
  <t hangText='expires (optional, string):'>
  The timestamp after which the server will consider this order invalid, encoded
in the format specified in <xref target="RFC3339"/>.  This field is REQUIRED for
objects with "pending" or "valid" in the status field.</t>
  <t hangText='identifiers (required, array of object):'>
  An array of identifier objects that the order pertains to.

      <list style="hanging">
        <t hangText='type (required, string):'>
        The type of identifier.  This document defines the "dns"
identifier type.  See the registry defined in <xref target="iana-identifier"/>
for any others.</t>
        <t hangText='value (required, string):'>
        The identifier itself.</t>
      </list>
  </t>
  <t hangText='notBefore (optional, string):'>
  The requested value of the notBefore field in the certificate, in the date
format defined in <xref target="RFC3339"/>.</t>
  <t hangText='notAfter (optional, string):'>
  The requested value of the notAfter field in the certificate, in the date
format defined in <xref target="RFC3339"/>.</t>
  <t hangText='error (optional, object):'>
  The error that occurred while processing the order, if any.
This field is structured as a problem document <xref target="RFC7807"/>.</t>
  <t hangText='authorizations (required, array of string):'>
  For pending orders, the authorizations that the client needs to complete
before the requested certificate can be issued (see
<xref target="identifier-authorization"/>), including unexpired authorizations that the client has completed in the past for identifiers specified in the order. The authorizations required are dictated by server policy; there may not be a 1:1 relationship between the order identifiers and the authorizations required. For final orders (in the "valid" or "invalid" state), the authorizations that
were completed.  Each entry is a URL from which an authorization can be fetched
with a POST-as-GET request.</t>
  <t hangText='finalize (required, string):'>
  A URL that a CSR must be POSTed to once all of the order's authorizations are
satisfied to finalize the order. The result of a successful finalization will be
the population of the certificate URL for the order.</t>
  <t hangText='certificate (optional, string):'>
  A URL for the certificate that has been issued in response to this order.</t>
</list></t>

<figure><artwork><![CDATA[
{
  "status": "valid",
  "expires": "2016-01-20T14:09:07.99Z",

  "identifiers": [
    { "type": "dns", "value": "www.example.org" },
    { "type": "dns", "value": "example.org" }
  ],

  "notBefore": "2016-01-01T00:00:00Z",
  "notAfter": "2016-01-08T00:00:00Z",

  "authorizations": [
    "https://example.com/acme/authz/PAniVnsZcis",
    "https://example.com/acme/authz/r4HqLzrSrpI"
  ],

  "finalize": "https://example.com/acme/order/TOlocE8rfgo/finalize",

  "certificate": "https://example.com/acme/cert/mAt3xBGaobw"
}
]]></artwork></figure>

<t>Any identifier of type "dns" in a newOrder request MAY have a wildcard domain
name as its value. A wildcard domain name consists of a single asterisk
character followed by a single full stop character ("*.") followed by a domain
name as defined for use in the Subject Alternate Name Extension by
<xref target="RFC5280"/>. An authorization returned by the server for a wildcard domain name
identifier MUST NOT include the asterisk and full stop ("*.") prefix in the
authorization identifier value. The returned authorization MUST include the
optional "wildcard" field, with a value of true.</t>

<t>The elements of the "authorizations" and "identifiers" arrays are immutable once
set.  The server MUST NOT change the contents of either array after they are
created. If a client observes a change in the contents of either array, then it
SHOULD consider the order invalid.</t>

<t>The "authorizations" array of the order SHOULD reflect all authorizations
that the CA takes into account in deciding to issue, even if some authorizations
were fulfilled in earlier orders or in pre-authorization transactions.  For
example, if a CA allows multiple orders to be fulfilled based on a single
authorization transaction, then it SHOULD reflect that authorization in all of
the orders.</t>

<t>Note that just because an authorization URL is listed in the
"authorizations" array of an order object doesn't mean that the
client is required to take action.  There are several reasons that
the referenced authorizations may already be valid:</t>

<t><list style="symbols">
  <t>The client completed the authorization as part of a previous order</t>
  <t>The client previously pre-authorized the identifier (see <xref target="pre-authorization"/>)</t>
  <t>The server granted the client authorization based on an external account</t>
</list></t>

<t>Clients SHOULD check the "status" field of an order to determine
whether they need to take any action.</t>

</section>
<section anchor="authorization-objects" title="Authorization Objects">

<t>An ACME authorization object represents a server's authorization for an account
to represent an identifier.  In addition to the identifier, an authorization
includes several metadata fields, such as the status of the authorization (e.g.,
"pending", "valid", or "revoked") and which challenges were used to validate
possession of the identifier.</t>

<t>The structure of an ACME authorization resource is as follows:</t>

<t><list style="hanging">
  <t hangText='identifier (required, object):'>
  The identifier that the account is authorized to represent.

      <list style="hanging">
        <t hangText='type (required, string):'>
        The type of identifier (see below and <xref target="iana-identifier"/>).</t>
        <t hangText='value (required, string):'>
        The identifier itself.</t>
      </list>
  </t>
  <t hangText='status (required, string):'>
  The status of this authorization.  Possible values are "pending",
"valid", "invalid", "deactivated", "expired", and "revoked".  See
<xref target="status-changes"/>.</t>
  <t hangText='expires (optional, string):'>
  The timestamp after which the server will consider this authorization invalid,
encoded in the format specified in <xref target="RFC3339"/>.  This field is REQUIRED
for objects with "valid" in the "status" field.</t>
  <t hangText='challenges (required, array of objects):'>
  For pending authorizations, the challenges that the client can
fulfill in order to prove possession of the identifier.  For valid
authorizations, the challenge that was validated.  For invalid
authorizations, the challenge that was attempted and failed.  Each
array entry is an object with parameters required to validate the
challenge.  A client should attempt to fulfill one of these
challenges, and a server should consider any one of the challenges
sufficient to make the authorization valid.</t>
  <t hangText='wildcard (optional, boolean):'>
  This field MUST be present and true for authorizations created as
a result of a newOrder request containing a DNS identifier with a
value that was a wildcard domain name.  For other authorizations,
it MUST be absent.  Wildcard domain names are described in <xref target="order-objects"/>.</t>
</list></t>

<t>The only type of identifier defined by this specification is a fully qualified
domain name (type: "dns"). The domain name MUST be encoded in the
form in which it would appear in a certificate.  That is, it MUST be
encoded according to the rules in Section 7 of <xref target="RFC5280"/>.  Servers MUST verify
any identifier values that begin with the ASCII-Compatible Encoding prefix
"xn--" as defined in <xref target="RFC5890"/> are properly encoded. Wildcard domain names
(with "*" as the first label) MUST NOT be included in authorization objects. If
an authorization object conveys authorization for the base domain of a newOrder
DNS identifier containing a wildcard domain name, then the optional authorizations
"wildcard" field MUST be present with a value of true.</t>

<t><xref target="identifier-validation-challenges"/> describes a set of challenges for domain
name validation.</t>

<figure><artwork><![CDATA[
{
  "status": "valid",
  "expires": "2015-03-01T14:09:07.99Z",

  "identifier": {
    "type": "dns",
    "value": "www.example.org"
  },

  "challenges": [
    {
      "url": "https://example.com/acme/chall/prV_B7yEyA4",
      "type": "http-01",
      "status": "valid",
      "token": "DGyRejmCefe7v4NfDGDKfA",
      "validated": "2014-12-01T12:05:58.16Z"
    }
  ],

  "wildcard": false
}
]]></artwork></figure>

</section>
<section anchor="challenge-objects" title="Challenge Objects">

<t>An ACME challenge object represents a server's offer to validate a
client's possession of an identifier in a specific way.  Unlike the
other objects listed above, there is not a single standard structure
for a challenge object.  The contents of a challenge object depend
on the validation method being used.  The general structure of
challenge objects and an initial set of validation methods are
described in <xref target="identifier-validation-challenges"/>.</t>

</section>
<section anchor="status-changes" title="Status Changes">

<t>Each ACME object type goes through a simple state machine over its
lifetime.  The "status" field of the object indicates which state
the object is currently in.</t>

<t>Challenge objects are created in the "pending" state.  They
transition to the "processing" state when the client responds to the
challenge (see <xref target="responding-to-challenges"/>) and the server begins
attempting to validate that the client has completed the challenge.
Note that within the "processing" state, the server may attempt to
validate the challenge multiple times (see <xref target="retrying-challenges"/>).
Likewise, client requests for retries do not cause a state change.
If validation is successful, the challenge moves to the "valid"
state; if there is an error, the challenge moves to the "invalid"
state.</t>

<figure title="State Transitions for Challenge Objects"><artwork><![CDATA[
         pending
            |
            | Receive
            | response
            V
        processing <-+
            |   |    | Server retry or
            |   |    | client retry request
            |   +----+
            |
            |
Successful  |   Failed
validation  |   validation
  +---------+---------+
  |                   |
  V                   V
valid              invalid
]]></artwork></figure>

<t>Authorization objects are created in the "pending" state.  If one of
the challenges listed in the authorization transitions to the
"valid" state, then the authorization also changes to the "valid"
state.  If the client attempts to fulfill a challenge and fails, or
if there is an error while the authorization is still
pending, then the authorization transitions to the "invalid" state.
Once the authorization is in the "valid" state, it can expire
("expired"), be deactivated by the client ("deactivated", see
<xref target="deactivating-an-authorization"/>), or revoked by the server
("revoked").</t>

<figure title="State Transitions for Authorization Objects"><artwork><![CDATA[
                   pending --------------------+
                      |                        |
    Challenge failure |                        |
           or         |                        |
          Error       |  Challenge valid       |
            +---------+---------+              |
            |                   |              |
            V                   V              |
         invalid              valid            |
                                |              |
                                |              |
                                |              |
                 +--------------+--------------+
                 |              |              |
                 |              |              |
          Server |       Client |   Time after |
          revoke |   deactivate |    "expires" |
                 V              V              V
              revoked      deactivated      expired
]]></artwork></figure>

<t>Order objects are created in the "pending" state.  Once all of the
authorizations listed in the order object are in the "valid" state,
the order transitions to the "ready" state.  The order moves to the
"processing" state after the client submits a request to the order's
"finalize" URL and the CA begins the issuance process for the
certificate.  Once the certificate is issued, the order enters the
"valid" state.  If an error occurs at any of these stages, the
order moves to the "invalid" state.  The order also moves to the
"invalid" state if it expires or one of its authorizations enters a
final state other than "valid" ("expired", "revoked", or "deactivated").</t>

<figure title="State Transitions for Order Objects"><artwork><![CDATA[
 pending --------------+
    |                  |
    | All authz        |
    | "valid"          |
    V                  |
  ready ---------------+
    |                  |
    | Receive          |
    | finalize         |
    | request          |
    V                  |
processing ------------+
    |                  |
    | Certificate      | Error or
    | issued           | Authorization failure
    V                  V
  valid             invalid
]]></artwork></figure>

<t>Account objects are created in the "valid" state, since no further
action is required to create an account after a successful
newAccount request.  If the account is deactivated by the client  or
revoked by the server, it moves to the corresponding state.</t>

<figure title="State Transitions for Account Objects"><artwork><![CDATA[
                  valid
                    |
                    |
        +-----------+-----------+
 Client |                Server |
deactiv.|                revoke |
        V                       V
   deactivated               revoked
]]></artwork></figure>

<t>Note that some of these states may not ever appear in a "status"
field, depending on server behavior.  For example, a server that
issues synchronously will never show an order in the "processing"
state.  A server that deletes expired authorizations immediately
will never show an authorization in the "expired" state.</t>

</section>
</section>
<section anchor="getting-a-nonce" title="Getting a Nonce">

<t>Before sending a POST request to the server, an ACME client needs to have a
fresh anti-replay nonce to put in the "nonce" header of the JWS.  In most cases,
the client will have gotten a nonce from a previous request.  However, the
client might sometimes need to get a new nonce, e.g., on its first request to
the server or if an existing nonce is no longer valid.</t>

<t>To get a fresh nonce, the client sends a HEAD request to the newNonce resource
on the server.  The server's response MUST include a Replay-Nonce header field
containing a fresh nonce and SHOULD have status code 200 (OK).  The
server MUST also respond to GET requests for this resource, returning an empty
body (while still providing a Replay-Nonce header) with a status code of 204 (No Content).</t>

<figure><artwork><![CDATA[
HEAD /acme/new-nonce HTTP/1.1
Host: example.com

HTTP/1.1 200 OK
Replay-Nonce: oFvnlFP1wIhRlYS2jTaXbA
Cache-Control: no-store
Link: <https://example.com/acme/directory>;rel="index"
]]></artwork></figure>

<t>Proxy caching of responses from the newNonce resource can cause
clients to receive the same nonce repeatedly, leading to "badNonce" errors.
The server MUST include a Cache-Control header field with the "no-store"
directive in responses for the newNonce resource, in order to prevent
caching of this resource.</t>

</section>
<section anchor="account-management" title="Account Management">

<t>In this section, we describe how an ACME client can create an
account on an ACME server and perform some modifications to the
account after it has been created.</t>

<t>A client creates a new account with the server by sending a POST request to the
server's newAccount URL.  The body of the request is a stub account object
containing some subset of the following fields:</t>

<t><list style="hanging">
  <t hangText='contact (optional, array of string):'>
  Same meaning as the corresponding server field defined in <xref target="account-objects"/>.</t>
  <t hangText='termsOfServiceAgreed (optional, boolean):'>
  Same meaning as the corresponding server field defined in <xref target="account-objects"/>.</t>
  <t hangText='onlyReturnExisting (optional, boolean):'>
  If this field is present with the value "true", then the server MUST NOT
create a new account if one does not already exist.  This allows a client to
look up an account URL based on an account key (see
<xref target="finding-an-account-url-given-a-key"/>).</t>
  <t hangText='externalAccountBinding (optional, object):'>
  Same meaning as the corresponding server field defined in <xref target="account-objects"/></t>
</list></t>

<figure><artwork><![CDATA[
POST /acme/new-account HTTP/1.1
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "jwk": {...},
    "nonce": "6S8IqOGY7eL2lsGoTZYifg",
    "url": "https://example.com/acme/new-account"
  }),
  "payload": base64url({
    "termsOfServiceAgreed": true,
    "contact": [
      "mailto:cert-admin@example.org",
      "mailto:admin@example.org"
    ]
  }),
  "signature": "RZPOnYoPs1PhjszF...-nh6X1qtOFPB519I"
}
]]></artwork></figure>

<t>The server MUST ignore any values provided in the "orders" fields in account
objects sent by the client, as well as any other fields that it does not
recognize. If new fields are specified in the future, the specification of those
fields MUST describe whether they can be provided by the client. The server MUST
NOT reflect the "onlyReturnExisting" field or any unrecognized fields in the
resulting account object. This allows clients to detect when servers do not
support an extension field.</t>

<t>The server SHOULD validate that the contact URLs in the "contact" field are
valid and supported by the server. If the server validates contact URLs, it MUST
support the "mailto" scheme.  Clients MUST NOT provide a "mailto" URL in the
"contact" field that contains <spanx style="verb">hfields</spanx> <xref target="RFC6068"/> or more than one
<spanx style="verb">addr-spec</spanx> in the <spanx style="verb">to</spanx> component.  If a server encounters a "mailto" contact
URL that does not meet these criteria, then it SHOULD reject it as invalid.</t>

<t>If the server rejects a contact URL for using an
unsupported scheme, it MUST return an error of type "unsupportedContact", with
a description of the error and what types of contact URLs the server
considers acceptable. If the server rejects a contact URL for using a supported
scheme but an invalid value, then the server MUST return an error of type
"invalidContact".</t>

<t>If the server wishes to require the client to agree to terms under which the ACME
service is to be used, it MUST indicate the URL where such terms can be accessed
in the "termsOfService" subfield of the "meta" field in the directory object,
and the server MUST reject newAccount requests that do not have the
"termsOfServiceAgreed" field set to "true".  Clients SHOULD NOT automatically agree
to terms by default.  Rather, they SHOULD require some user interaction for
agreement to terms.</t>

<t>The server creates an account and stores the public key used to verify the
JWS (i.e., the "jwk" element of the JWS header) to authenticate future requests
from the account.  The server returns this account object in a 201 (Created)
response, with the account URL in a Location header field. The account URL is
used as the "kid" value in the JWS authenticating subsequent requests by this
account (see <xref target="request-authentication"/>).  The account URL is also used for
requests for management actions on this account, as described below.</t>

<figure><artwork><![CDATA[
HTTP/1.1 201 Created
Content-Type: application/json
Replay-Nonce: D8s4D2mLs8Vn-goWuPQeKA
Link: <https://example.com/acme/directory>;rel="index"
Location: https://example.com/acme/acct/evOfKhNU60wg

{
  "status": "valid",

  "contact": [
    "mailto:cert-admin@example.org",
    "mailto:admin@example.org"
  ],

  "orders": "https://example.com/acme/acct/evOfKhNU60wg/orders"
}
]]></artwork></figure>

<section anchor="finding-an-account-url-given-a-key" title="Finding an Account URL Given a Key">

<t>If the server receives a newAccount request signed with a key for which it already has an account registered with the provided account key,
then it MUST return a response with status code 200 (OK) and provide the URL of
that account in the Location header field.  The body of this response represents the account object as it existed on the server before this request; any fields in the request object MUST be ignored.  This allows a client that has
an account key but not the corresponding account URL to recover the account URL.</t>

<t>If a client wishes to find the URL for an existing account and does not want an
account to be created if one does not already exist, then it SHOULD do so by
sending a POST request to the newAccount URL with a JWS whose payload has an
"onlyReturnExisting" field set to "true" ({"onlyReturnExisting": true}).
If a client sends such a request and an account does not exist, then the server
MUST return an error response with status code 400 (Bad Request) and type
"urn:ietf:params:acme:error:accountDoesNotExist".</t>

</section>
<section anchor="account-update" title="Account Update">

<t>If the client wishes to update this information in the future, it sends a POST
request with updated information to the account URL.  The server MUST ignore any
updates to the "orders" field, "termsOfServiceAgreed" field (see <xref target="changes-of-terms-of-service"/>), the "status" field (except as allowed by <xref target="account-deactivation"/>), or any other fields it does not recognize. If the server
accepts the update, it MUST return a response with a 200 (OK) status code and the
resulting account object.</t>

<t>For example, to update the contact information in the above account, the client
could send the following request:</t>

<figure><artwork><![CDATA[
POST /acme/acct/evOfKhNU60wg HTTP/1.1
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "kid": "https://example.com/acme/acct/evOfKhNU60wg",
    "nonce": "ax5RnthDqp_Yf4_HZnFLmA",
    "url": "https://example.com/acme/acct/evOfKhNU60wg"
  }),
  "payload": base64url({
    "contact": [
      "mailto:certificates@example.org",
      "mailto:admin@example.org"
    ]
  }),
  "signature": "hDXzvcj8T6fbFbmn...rDzXzzvzpRy64N0o"
}
]]></artwork></figure>

</section>
<section anchor="changes-of-terms-of-service" title="Changes of Terms of Service">

<t>As described above, a client can indicate its agreement with the CA's terms of
service by setting the "termsOfServiceAgreed" field in its account object to
"true".</t>

<t>If the server has changed its terms of service since a client initially agreed,
and the server is unwilling to process a request without explicit agreement to
the new terms, then it MUST return an error response with status code 403
(Forbidden) and type "urn:ietf:params:acme:error:userActionRequired".  This
response MUST include a Link header field with link relation "terms-of-service" and
the latest terms-of-service URL.</t>

<t>The problem document returned with the error MUST also include an "instance"
field, indicating a URL that the client should direct a human user to visit in
order for instructions on how to agree to the terms.</t>

<figure><artwork><![CDATA[
HTTP/1.1 403 Forbidden
Replay-Nonce: T81bdZroZ2ITWSondpTmAw
Link: <https://example.com/acme/directory>;rel="index"
Link: <https://example.com/acme/terms/2017-6-02>;rel="terms-of-service"
Content-Type: application/problem+json
Content-Language: en

{
  "type": "urn:ietf:params:acme:error:userActionRequired",
  "detail": "Terms of service have changed",
  "instance": "https://example.com/acme/agreement/?token=W8Ih3PswD-8"
}
]]></artwork></figure>

</section>
<section anchor="external-account-binding" title="External Account Binding">

<t>The server MAY require a value for the "externalAccountBinding" field to be
present in "newAccount" requests.  This can be used to associate an ACME account with an
existing account in a non-ACME system, such as a CA customer database.</t>

<t>To enable ACME account binding, the CA operating the ACME server needs to provide the ACME client with a
MAC key and a key identifier, using some mechanism outside of ACME. The key
identifier MUST be an ASCII string. The MAC key SHOULD be provided in
base64url-encoded form, to maximize compatibility between non-ACME provisioning systems
and ACME clients.</t>

<t>The ACME client then computes a binding JWS to indicate the external account holder's
approval of the ACME account key.  The payload of this JWS is the ACME account key
being registered, in JWK form.  The protected header of the JWS MUST meet the
following criteria:</t>

<t><list style="symbols">
  <t>The "alg" field MUST indicate a MAC-based algorithm</t>
  <t>The "kid" field MUST contain the key identifier provided by the CA</t>
  <t>The "nonce" field MUST NOT be present</t>
  <t>The "url" field MUST be set to the same value as the outer JWS</t>
</list></t>

<t>The "signature" field of the JWS will contain the MAC value computed with the
MAC key provided by the CA.</t>

<figure><artwork><![CDATA[
POST /acme/new-account HTTP/1.1
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "jwk": /* account key */,
    "nonce": "K60BWPrMQG9SDxBDS_xtSw",
    "url": "https://example.com/acme/new-account"
  }),
  "payload": base64url({
    "contact": [
      "mailto:cert-admin@example.org",
      "mailto:admin@example.org"
    ],
    "termsOfServiceAgreed": true,

    "externalAccountBinding": {
      "protected": base64url({
        "alg": "HS256",
        "kid": /* key identifier from CA */,
        "url": "https://example.com/acme/new-account"
      }),
      "payload": base64url(/* same as in "jwk" above */),
      "signature": /* MAC using MAC key from CA */
    }
  }),
  "signature": "5TWiqIYQfIDfALQv...x9C2mg8JGPxl5bI4"
}
]]></artwork></figure>

<t>If such a CA requires that newAccount requests contain an "externalAccountBinding"
field, then it MUST provide the value "true" in the "externalAccountRequired" subfield
of the "meta" field in the directory object.  If the CA receives a
newAccount request without an "externalAccountBinding" field, then it SHOULD
reply with an error of type "externalAccountRequired".</t>

<t>When a CA receives a newAccount request containing an
"externalAccountBinding" field, it decides whether or not to verify the
binding.  If the CA does not verify the binding, then it MUST NOT reflect the
"externalAccountBinding" field in the resulting account object (if any).  To
verify the account binding, the CA MUST take the following steps:</t>

<t><list style="numbers">
  <t>Verify that the value of the field is a well-formed JWS</t>
  <t>Verify that the JWS protected field meets the above criteria</t>
  <t>Retrieve the MAC key corresponding to the key identifier in the "kid" field</t>
  <t>Verify that the MAC on the JWS verifies using that MAC key</t>
  <t>Verify that the payload of the JWS represents the same key as was used to
verify the outer JWS (i.e., the "jwk" field of the outer JWS)</t>
</list></t>

<t>If all of these checks pass and the CA creates a new account, then the CA may
consider the new account associated with the external account corresponding to
the MAC key.  The account object the CA returns MUST include an
"externalAccountBinding" field with the same value as the field in
the request.  If any of these checks fail, then the CA MUST
reject the newAccount request.</t>

</section>
<section anchor="account-key-roll-over" title="Account Key Rollover">

<t>A client may wish to change the public key that is associated with an account in
order to recover from a key compromise or proactively mitigate the impact of an
unnoticed key compromise.</t>

<t>To change the key associated with an account, the client sends a
request to the server containing signatures by both the old and new
keys.  The signature by the new key covers the account URL and the
old key, signifying a request by the new key holder to take over the
account from the old key holder.  The signature by the old key
covers this request and its signature, and indicates the old key
holder's assent to the rollover request.</t>

<t>To create this request object, the client first constructs a
keyChange object describing the account to be updated and its
account key:</t>

<t><list style="hanging">
  <t hangText='account (required, string):'>
  The URL for the account being modified.  The content of this field MUST be the
exact string provided in the Location header field in response to the
newAccount request that created the account.</t>
  <t hangText='oldKey (required, JWK):'>
  The JWK representation of the old key.</t>
</list></t>

<t>The client then encapsulates the keyChange object in an "inner" JWS, signed with the
requested new account key.
This "inner" JWS becomes the payload for the "outer" JWS that is the body of the ACME
request.</t>

<t>The outer JWS MUST meet the normal requirements for an ACME JWS request body (see
<xref target="request-authentication"/>).  The inner JWS MUST meet the normal requirements,
with the following differences:</t>

<t><list style="symbols">
  <t>The inner JWS MUST have a "jwk" header parameter, containing the public key of
the new key pair.</t>
  <t>The inner JWS MUST have the same "url" header parameter as the outer JWS.</t>
  <t>The inner JWS MUST omit the "nonce" header parameter.</t>
</list></t>

<t>This transaction has signatures from both the old and new keys so that the
server can verify that the holders of the two keys both agree to the change.
The signatures are nested to preserve the property that all signatures on POST
messages are signed by exactly one key.  The "inner" JWS effectively
represents a request by the holder of the new key to take over the
account form the holder of the old key.  The "outer" JWS represents
the current account holder's assent to this request.</t>

<figure><artwork><![CDATA[
POST /acme/key-change HTTP/1.1
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "kid": "https://example.com/acme/acct/evOfKhNU60wg",
    "nonce": "S9XaOcxP5McpnTcWPIhYuB",
    "url": "https://example.com/acme/key-change"
  }),
  "payload": base64url({
    "protected": base64url({
      "alg": "ES256",
      "jwk": /* new key */,
      "url": "https://example.com/acme/key-change"
    }),
    "payload": base64url({
      "account": "https://example.com/acme/acct/evOfKhNU60wg",
      "oldKey": /* old key */
    }),
    "signature": "Xe8B94RD30Azj2ea...8BmZIRtcSKPSd8gU"
  }),
  "signature": "5TWiqIYQfIDfALQv...x9C2mg8JGPxl5bI4"
}
]]></artwork></figure>

<t>On receiving a keyChange request, the server MUST perform the following steps in
addition to the typical JWS validation:</t>

<t><list style="numbers">
  <t>Validate the POST request belongs to a currently active account, as described
in <xref target="message-transport"/>.</t>
  <t>Check that the payload of the JWS is a well-formed JWS object (the "inner
JWS").</t>
  <t>Check that the JWS protected header of the inner JWS has a "jwk" field.</t>
  <t>Check that the inner JWS verifies using the key in its "jwk" field.</t>
  <t>Check that the payload of the inner JWS is a well-formed keyChange object
(as described above).</t>
  <t>Check that the "url" parameters of the inner and outer JWSs are the same.</t>
  <t>Check that the "account" field of the keyChange object contains the URL for
the account matching the old key (i.e., the "kid" field in the
outer JWS).</t>
  <t>Check that the "oldKey" field of the keyChange object is the
same as the account key for the account in question.</t>
  <t>Check that no account exists whose account key is the same as the key in the
"jwk" header parameter of the inner JWS.</t>
</list></t>

<t>If all of these checks pass, then the server updates the corresponding account
by replacing the old account key with the new public key and returns status
code 200 (OK). Otherwise, the server responds with an error status code and a
problem document describing the error.  If there is an existing account with
the new key provided, then the server SHOULD use status code 409 (Conflict) and
provide the URL of that account in the Location header field.</t>

<t>Note that changing the account key for an account SHOULD NOT have any other
impact on the account.  For example, the server MUST NOT invalidate pending
orders or authorization transactions based on a change of account key.</t>

</section>
<section anchor="account-deactivation" title="Account Deactivation">

<t>A client can deactivate an account by posting a signed update to the account URL with
a status field of "deactivated".  Clients may wish to do this when the account
key is compromised or decommissioned. A deactivated account can no longer request
certificate issuance or access resources related to the account, such as orders
or authorizations.  If a server receives a POST or POST-as-GET from
a deactivated account, it MUST return an error response with status
code 401 (Unauthorized) and type "urn:ietf:params:acme:error:unauthorized".</t>

<figure><artwork><![CDATA[
POST /acme/acct/evOfKhNU60wg HTTP/1.1
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "kid": "https://example.com/acme/acct/evOfKhNU60wg",
    "nonce": "ntuJWWSic4WVNSqeUmshgg",
    "url": "https://example.com/acme/acct/evOfKhNU60wg"
  }),
  "payload": base64url({
    "status": "deactivated"
  }),
  "signature": "earzVLd3m5M4xJzR...bVTqn7R08AKOVf3Y"
}
]]></artwork></figure>

<t>The server MUST verify that the request is signed by the account key. If the
server accepts the deactivation request, it replies with a 200 (OK) status code
and the current contents of the account object.</t>

<t>Once an account is deactivated, the server MUST NOT accept further requests
authorized by that account's key. The server SHOULD cancel any pending operations authorized
by the account's key, such as certificate orders. A server may take a variety of actions in
response to an account deactivation, e.g., deleting data related to that account
or sending mail to the account's contacts.  Servers SHOULD NOT revoke
certificates issued by the deactivated account, since this could cause
operational disruption for servers using these certificates. ACME does not
provide a way to reactivate a deactivated account.</t>

</section>
</section>
<section anchor="applying-for-certificate-issuance" title="Applying for Certificate Issuance">

<t>The client begins the certificate issuance process by sending a POST request to the server's
newOrder resource.  The body of the POST is a JWS object whose JSON payload is
a subset of the order object defined in <xref target="order-objects"/>, containing the fields
that describe the certificate to be issued:</t>

<t><list style="hanging">
  <t hangText='identifiers (required, array of object):'>
  An array of identifier objects that the client wishes to submit an order for.

      <list style="hanging">
        <t hangText='type (required, string):'>
        The type of identifier.</t>
        <t hangText='value (required, string):'>
        The identifier itself.</t>
      </list>
  </t>
  <t hangText='notBefore (optional, string):'>
  The requested value of the notBefore field in the certificate, in the date
format defined in <xref target="RFC3339"/>.</t>
  <t hangText='notAfter (optional, string):'>
  The requested value of the notAfter field in the certificate, in the date
format defined in <xref target="RFC3339"/>.</t>
</list></t>

<figure><artwork><![CDATA[
POST /acme/new-order HTTP/1.1
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "kid": "https://example.com/acme/acct/evOfKhNU60wg",
    "nonce": "5XJ1L3lEkMG7tR6pA00clA",
    "url": "https://example.com/acme/new-order"
  }),
  "payload": base64url({
    "identifiers": [
      { "type": "dns", "value": "www.example.org" },
      { "type": "dns", "value": "example.org" }
    ],
    "notBefore": "2016-01-01T00:04:00+04:00",
    "notAfter": "2016-01-08T00:04:00+04:00"
  }),
  "signature": "H6ZXtGjTZyUnPeKn...wEA4TklBdh3e454g"
}
]]></artwork></figure>

<t>The server MUST return an error if it cannot fulfill the request as specified,
and it MUST NOT issue a certificate with contents other than those requested.  If
the server requires the request to be modified in a certain way, it should
indicate the required changes using an appropriate error type and description.</t>

<t>If the server is willing to issue the requested certificate, it responds with a
201 (Created) response.  The body of this response is an order object reflecting
the client's request and any authorizations the client must complete before the
certificate will be issued.</t>

<figure><artwork><![CDATA[
HTTP/1.1 201 Created
Replay-Nonce: MYAuvOpaoIiywTezizk5vw
Link: <https://example.com/acme/directory>;rel="index"
Location: https://example.com/acme/order/TOlocE8rfgo

{
  "status": "pending",
  "expires": "2016-01-05T14:09:07.99Z",

  "notBefore": "2016-01-01T00:00:00Z",
  "notAfter": "2016-01-08T00:00:00Z",

  "identifiers": [
    { "type": "dns", "value": "www.example.org" },
    { "type": "dns", "value": "example.org" }
  ],

  "authorizations": [
    "https://example.com/acme/authz/PAniVnsZcis",
    "https://example.com/acme/authz/r4HqLzrSrpI"
  ],

  "finalize": "https://example.com/acme/order/TOlocE8rfgo/finalize"
}
]]></artwork></figure>

<t>The order object returned by the server represents a promise that if the
client fulfills the server's requirements before the "expires" time, then the
server will be willing to finalize the order upon request and issue the
requested certificate.  In the order object, any authorization referenced in the
"authorizations" array whose status is "pending" represents an authorization
transaction that the client must complete before the server will issue the
certificate (see <xref target="identifier-authorization"/>).  If the client fails to complete
the required actions before the "expires" time, then the server SHOULD change
the status of the order to "invalid" and MAY delete the order resource. Clients
MUST NOT make any assumptions about the sort order of "identifiers" or
"authorizations" elements in the returned order object.</t>

<t>Once the client believes it has fulfilled the server's requirements, it should
send a POST request to the order resource's finalize URL. The POST body MUST
include a CSR:</t>

<t><list style="hanging">
  <t hangText='csr (required, string):'>
  A CSR encoding the parameters for the certificate being requested <xref target="RFC2986"/>.
The CSR is sent in the base64url-encoded version of the DER format.  (Note:
Because this field uses base64url, and does not include headers, it is different
from PEM.)</t>
</list></t>

<figure><artwork><![CDATA[
POST /acme/order/TOlocE8rfgo/finalize HTTP/1.1
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "kid": "https://example.com/acme/acct/evOfKhNU60wg",
    "nonce": "MSF2j2nawWHPxxkE3ZJtKQ",
    "url": "https://example.com/acme/order/TOlocE8rfgo/finalize"
  }),
  "payload": base64url({
    "csr": "MIIBPTCBxAIBADBFMQ...FS6aKdZeGsysoCo4H9P",
  }),
  "signature": "uOrUfIIk5RyQ...nw62Ay1cl6AB"
}
]]></artwork></figure>

<t>The CSR encodes the client's requests with regard to the content of the
certificate to be issued.  The CSR MUST indicate the exact same set of requested
identifiers as the initial newOrder request.  Identifiers of type "dns" MUST appear either in the commonName portion
of the requested subject name or in an extensionRequest attribute <xref target="RFC2985"/>
requesting a subjectAltName extension, or both.  (These identifiers may appear
in any sort order.)  Specifications that define
new identifier types must specify where in the certificate signing
request these
identifiers can appear.</t>

<t>A request to finalize an order will result in an error if the CA is unwilling to issue a certificate corresponding to the submitted CSR.  For example:</t>

<t><list style="symbols">
  <t>If the CSR and order identifiers differ</t>
  <t>If the account is not authorized for the identifiers indicated in the CSR</t>
  <t>If the CSR requests extensions that the CA is not willing to include</t>
</list></t>

<t>In such cases, the problem document returned by the server SHOULD
use error code "badCSR" and describe specific reasons the CSR was
rejected in its "detail" field.  After returning such an error, the
server SHOULD leave the order in the "ready" state, to allow the
client to submit a new finalize request with an amended CSR.</t>

<t>A request to finalize an order will result in error if the order is not in the
"ready" state.  In such cases, the server MUST return a 403 (Forbidden) error
with a problem document of type "orderNotReady".  The client should then send a
POST-as-GET request to the order resource to obtain its current state.  The
status of the order will indicate what action the client should take (see
below).</t>

<t>If a request to finalize an order is successful, the server will return a 200
(OK) with an updated order object.  The status of the order will indicate what
action the client should take:</t>

<t><list style="symbols">
  <t>"invalid": The certificate will not be issued.  Consider this order process
abandoned.</t>
  <t>"pending": The server does not believe that the client has fulfilled the
requirements.  Check the "authorizations" array for entries that are still
pending.</t>
  <t>"ready": The server agrees that the requirements have been
fulfilled, and is awaiting finalization.  Submit a finalization
request.</t>
  <t>"processing": The certificate is being issued. Send a POST-as-GET request after the
time given in the Retry-After header field of the response, if
any.</t>
  <t>"valid": The server has issued the certificate and provisioned its URL to the
"certificate" field of the order.  Download the certificate.</t>
</list></t>

<figure><artwork><![CDATA[
HTTP/1.1 200 OK
Replay-Nonce: CGf81JWBsq8QyIgPCi9Q9X
Link: <https://example.com/acme/directory>;rel="index"
Location: https://example.com/acme/order/TOlocE8rfgo

{
  "status": "valid",
  "expires": "2016-01-20T14:09:07.99Z",

  "notBefore": "2016-01-01T00:00:00Z",
  "notAfter": "2016-01-08T00:00:00Z",

  "identifiers": [
    { "type": "dns", "value": "www.example.org" },
    { "type": "dns", "value": "example.org" }
  ],

  "authorizations": [
    "https://example.com/acme/authz/PAniVnsZcis",
    "https://example.com/acme/authz/r4HqLzrSrpI"
  ],

  "finalize": "https://example.com/acme/order/TOlocE8rfgo/finalize",

  "certificate": "https://example.com/acme/cert/mAt3xBGaobw"
}
]]></artwork></figure>

<section anchor="pre-authorization" title="Pre-authorization">

<t>The order process described above presumes that authorization objects are
created reactively, in response to a certificate order.  Some servers
may also wish to enable clients to obtain authorization for an identifier
proactively, outside of the context of a specific issuance.  For example, a
client hosting virtual servers for a collection of names might wish to obtain
authorization before any virtual servers are created and only create a certificate when
a virtual server starts up.</t>

<t>In some cases, a CA running an ACME server might have a completely external,
non-ACME process for authorizing a client to issue certificates for an identifier.  In these
cases, the CA should provision its ACME server with authorization objects
corresponding to these authorizations and reflect them as already valid in any
orders submitted by the client.</t>

<t>If a CA wishes to allow pre-authorization within ACME, it can offer a "new
authorization" resource in its directory by adding the field "newAuthz" with a
URL for the newAuthz resource.</t>

<t>To request authorization for an identifier, the client sends a POST request to
the newAuthz resource specifying the identifier for which authorization
is being requested.</t>

<t><list style="hanging">
  <t hangText='identifier (required, object):'>
  The identifier to appear in the resulting authorization object
(see <xref target="authorization-objects"/>).

      <list style="hanging">
        <t hangText='type (required, string):'>
        The type of identifier.</t>
        <t hangText='value (required, string):'>
        The identifier itself.</t>
      </list>
  </t>
</list></t>

<figure><artwork><![CDATA[
POST /acme/new-authz HTTP/1.1
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "kid": "https://example.com/acme/acct/evOfKhNU60wg",
    "nonce": "uQpSjlRb4vQVCjVYAyyUWg",
    "url": "https://example.com/acme/new-authz"
  }),
  "payload": base64url({
    "identifier": {
      "type": "dns",
      "value": "example.org"
    }
  }),
  "signature": "nuSDISbWG8mMgE7H...QyVUL68yzf3Zawps"
}
]]></artwork></figure>

<t>Note that because the identifier in a pre-authorization request is
the exact identifier to be included in the authorization object,
pre-authorization cannot be used to authorize issuance of certificates
containing wildcard domain names.</t>

<t>Before processing the authorization request, the server SHOULD determine whether
it is willing to issue certificates for the identifier.  For example, the server
should check that the identifier is of a supported type.  Servers might also
check names against a blacklist of known high-value identifiers.  If the server
is unwilling to issue for the identifier, it SHOULD return an error
with status code 403 (Forbidden), with a problem document describing
the reason for the rejection.</t>

<t>If the server is willing to proceed, it builds a pending authorization object
from the inputs submitted by the client:</t>

<t><list style="symbols">
  <t>"identifier" the identifier submitted by the client</t>
  <t>"status" MUST be "pending" unless the server has out-of-band information
about the client's authorization status</t>
  <t>"challenges" as selected by the server's policy for this identifier</t>
</list></t>

<t>The server allocates a new URL for this authorization and returns a 201
(Created) response with the authorization URL in the Location header field and
the JSON authorization object in the body.  The client then follows the process
described in <xref target="identifier-authorization"/> to complete the authorization process.</t>

</section>
<section anchor="downloading-the-certificate" title="Downloading the Certificate">

<t>To download the issued certificate, the client simply sends a POST-as-GET request to the
certificate URL.</t>

<t>The default format of the certificate is application/pem-certificate-chain (see <xref target="iana-considerations"/>).</t>

<t>The server MAY provide one or more link relation header fields <xref target="RFC5988"/> with
relation "alternate". Each such field SHOULD express an alternative certificate
chain starting with the same end-entity certificate. This can be used to express
paths to various trust anchors. Clients can fetch these alternates and use their
own heuristics to decide which is optimal.</t>

<figure><artwork><![CDATA[
POST /acme/cert/mAt3xBGaobw HTTP/1.1
Host: example.com
Content-Type: application/jose+json
Accept: application/pem-certificate-chain

{
  "protected": base64url({
    "alg": "ES256",
    "kid": "https://example.com/acme/acct/evOfKhNU60wg",
    "nonce": "uQpSjlRb4vQVCjVYAyyUWg",
    "url": "https://example.com/acme/cert/mAt3xBGaobw"
  }),
  "payload": "",
  "signature": "nuSDISbWG8mMgE7H...QyVUL68yzf3Zawps"
}

HTTP/1.1 200 OK
Content-Type: application/pem-certificate-chain
Link: <https://example.com/acme/directory>;rel="index"

-----BEGIN CERTIFICATE-----
[End-entity certificate contents]
-----END CERTIFICATE-----
-----BEGIN CERTIFICATE-----
[Issuer certificate contents]
-----END CERTIFICATE-----
-----BEGIN CERTIFICATE-----
[Other certificate contents]
-----END CERTIFICATE-----
]]></artwork></figure>

<t>A certificate resource represents a single, immutable certificate. If the client
wishes to obtain a renewed certificate, the client initiates a new order process
to request one.</t>

<t>Because certificate resources are immutable once issuance is complete, the
server MAY enable the caching of the resource by adding Expires and
Cache-Control header fields specifying a point in time in the distant future. These
header fields have no relation to the certificate's period of validity.</t>

<t>The ACME client MAY request other formats by including an Accept
header field <xref target="RFC7231"/> in its request.  For example, the client could use the media type
<spanx style="verb">application/pkix-cert</spanx> <xref target="RFC2585"/> or <spanx style="verb">application/pkcs7-mime</spanx> <xref target="RFC5751"/> to request the end-entity certificate
in DER format. Server support for alternate formats is OPTIONAL. For
formats that can only express a single certificate, the server SHOULD
provide one or more <spanx style="verb">Link: rel="up"</spanx> header fields pointing to an issuer or
issuers so that ACME clients can build a certificate chain as defined
in TLS (see Section 4.4.2 of <xref target="RFC8446"/>).</t>

</section>
</section>
<section anchor="identifier-authorization" title="Identifier Authorization">

<t>The identifier authorization process establishes the authorization of an account
to manage certificates for a given identifier.  This process assures the
server of two things:</t>

<t><list style="numbers">
  <t>That the client controls the private key of the account key pair, and</t>
  <t>That the client controls the identifier in question.</t>
</list></t>

<t>This process may be repeated to associate multiple identifiers with an account
(e.g., to request certificates with multiple identifiers) or to associate
multiple accounts with an identifier (e.g., to allow multiple entities to manage
certificates).</t>

<t>Authorization resources are created by the server in response to newOrder or
newAuthz requests submitted by an account key holder; their
URLs are provided to the client in the responses to these requests.  The
authorization object is implicitly tied to the account key used to sign the
request.</t>

<t>When a client receives an order from the server in reply to a newOrder request, it downloads the authorization
resources by sending POST-as-GET requests to the indicated URLs.  If the client
initiates authorization using a request to the newAuthz resource, it
will have already received the pending authorization object in the response
to that request.</t>

<figure><artwork><![CDATA[
POST /acme/authz/PAniVnsZcis HTTP/1.1
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "kid": "https://example.com/acme/acct/evOfKhNU60wg",
    "nonce": "uQpSjlRb4vQVCjVYAyyUWg",
    "url": "https://example.com/acme/authz/PAniVnsZcis"
  }),
  "payload": "",
  "signature": "nuSDISbWG8mMgE7H...QyVUL68yzf3Zawps"
}

HTTP/1.1 200 OK
Content-Type: application/json
Link: <https://example.com/acme/directory>;rel="index"

{
  "status": "pending",
  "expires": "2016-01-02T14:09:30Z",

  "identifier": {
    "type": "dns",
    "value": "www.example.org"
  },

  "challenges": [
    {
      "type": "http-01",
      "url": "https://example.com/acme/chall/prV_B7yEyA4",
      "token": "DGyRejmCefe7v4NfDGDKfA"
    },
    {
      "type": "dns-01",
      "url": "https://example.com/acme/chall/Rg5dV14Gh1Q",
      "token": "DGyRejmCefe7v4NfDGDKfA"
    }
  ]
}
]]></artwork></figure>

<section anchor="responding-to-challenges" title="Responding to Challenges">

<t>To prove control of the identifier and receive authorization, the client needs to
provision the required challenge response based on the challenge type and
indicate to the server that it is ready for the challenge validation to
be attempted.</t>

<t>The client indicates to the server that it is ready for the challenge validation by
sending an empty JSON body (<spanx style="verb">{}</spanx>) carried in a POST request to the challenge
URL (not the authorization URL).</t>

<t>For example, if the client were to respond to the "http-01" challenge in the
above authorization, it would send the following request:</t>

<figure><artwork><![CDATA[
POST /acme/chall/prV_B7yEyA4 HTTP/1.1
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "kid": "https://example.com/acme/acct/evOfKhNU60wg",
    "nonce": "Q_s3MWoqT05TrdkM2MTDcw",
    "url": "https://example.com/acme/chall/prV_B7yEyA4"
  }),
  "payload": base64url({}),
  "signature": "9cbg5JO1Gf5YLjjz...SpkUfcdPai9uVYYQ"
}
]]></artwork></figure>

<t>The server updates the authorization document by updating its representation of
the challenge with the response object provided by the client.  The server MUST
ignore any fields in the response object that are not specified as response
fields for this type of challenge.
Note that the challenges in this document do
not define any response fields, but future specifications might define them.
The server provides a 200 (OK) response
with the updated challenge object as its body.</t>

<t>If the client's response is invalid for any reason or does not provide the
server with appropriate information to validate the challenge, then the server
MUST return an HTTP error.  On receiving such an error, the client SHOULD undo
any actions that have been taken to fulfill the challenge, e.g., removing files
that have been provisioned to a web server.</t>

<t>The server is said to "finalize" the authorization when it has completed
one of the validations.  This is done by assigning the authorization a status of "valid"
or "invalid", corresponding to whether it considers the account authorized
for the identifier. If the final state is "valid", then the server MUST include
an "expires" field. When finalizing an authorization, the server MAY remove
challenges other than the one that was completed, and it may modify the "expires"
field. The server SHOULD NOT remove challenges with status "invalid".</t>

<t>Usually, the validation process will take some time, so the client will need to
poll the authorization resource to see when it is finalized.  For challenges
where the client can tell when the server has validated the challenge (e.g., by
seeing an HTTP or DNS request from the server), the client SHOULD NOT begin
polling until it has seen the validation request from the server.</t>

<t>To check on the status of an authorization, the client sends a POST-as-GET request to
the authorization URL, and the server responds with the current authorization
object. In responding to poll requests while the validation is still in
progress, the server MUST return a 200 (OK) response and MAY include a
Retry-After header field to suggest a polling interval to the client.</t>

<figure><artwork><![CDATA[
POST /acme/authz/PAniVnsZcis HTTP/1.1
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "kid": "https://example.com/acme/acct/evOfKhNU60wg",
    "nonce": "uQpSjlRb4vQVCjVYAyyUWg",
    "url": "https://example.com/acme/authz/PAniVnsZcis"
  }),
  "payload": "",
  "signature": "nuSDISbWG8mMgE7H...QyVUL68yzf3Zawps"
}

HTTP/1.1 200 OK
Content-Type: application/json
Link: <https://example.com/acme/directory>;rel="index"

{
  "status": "valid",
  "expires": "2018-09-09T14:09:01.13Z",

  "identifier": {
    "type": "dns",
    "value": "www.example.org"
  },

  "challenges": [
    {
      "type": "http-01",
      "url": "https://example.com/acme/chall/prV_B7yEyA4",
      "status": "valid",
      "validated": "2014-12-01T12:05:13.72Z",
      "token": "IlirfxKKXAsHtmzK29Pj8A"
    }
  ]
}
]]></artwork></figure>

</section>
<section anchor="deactivating-an-authorization" title="Deactivating an Authorization">

<t>If a client wishes to relinquish its authorization to issue certificates for an
identifier, then it may request that the server deactivate each authorization
associated with it by sending POST requests with the static object
{"status": "deactivated"} to each authorization URL.</t>

<figure><artwork><![CDATA[
POST /acme/authz/PAniVnsZcis HTTP/1.1
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "kid": "https://example.com/acme/acct/evOfKhNU60wg",
    "nonce": "xWCM9lGbIyCgue8di6ueWQ",
    "url": "https://example.com/acme/authz/PAniVnsZcis"
  }),
  "payload": base64url({
    "status": "deactivated"
  }),
  "signature": "srX9Ji7Le9bjszhu...WTFdtujObzMtZcx4"
}
]]></artwork></figure>

<t>The server MUST verify that the request is signed by the account key
corresponding to the account that owns the authorization. If the server accepts
the deactivation, it should reply with a 200 (OK) status code and the updated
contents of the authorization object.</t>

<t>The server MUST NOT treat deactivated authorization objects as sufficient for
issuing certificates.</t>

</section>
</section>
<section anchor="certificate-revocation" title="Certificate Revocation">

<t>To request that a certificate be revoked, the client sends a POST request to
the ACME server's revokeCert URL.  The body of the POST is a JWS object whose
JSON payload contains the certificate to be revoked:</t>

<t><list style="hanging">
  <t hangText='certificate (required, string):'>
  The certificate to be revoked, in the base64url-encoded version of the DER
format.  (Note: Because this field uses base64url, and does not include headers,
it is different from PEM.)</t>
  <t hangText='reason (optional, int):'>
  One of the revocation reasonCodes defined in Section 5.3.1 of <xref target="RFC5280"/>
to be used when generating OCSP responses and CRLs. If this field is not set,
the server SHOULD omit the reasonCode CRL entry extension when generating OCSP
responses and CRLs. The server MAY disallow a subset of reasonCodes from being
used by the user. If a request contains a disallowed reasonCode, then the server MUST
reject it with the error type "urn:ietf:params:acme:error:badRevocationReason".
The problem document detail SHOULD indicate which reasonCodes are allowed.</t>
</list></t>

<t>Revocation requests are different from other ACME requests in that they can be
signed with either an account key pair or the key pair in the certificate.</t>

<t>Example using an account key pair for the signature:</t>

<figure><artwork><![CDATA[
POST /acme/revoke-cert HTTP/1.1
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "kid": "https://example.com/acme/acct/evOfKhNU60wg",
    "nonce": "JHb54aT_KTXBWQOzGYkt9A",
    "url": "https://example.com/acme/revoke-cert"
  }),
  "payload": base64url({
    "certificate": "MIIEDTCCAvegAwIBAgIRAP8...",
    "reason": 4
  }),
  "signature": "Q1bURgJoEslbD1c5...3pYdSMLio57mQNN4"
}
]]></artwork></figure>

<t>Example using the certificate key pair for the signature:</t>

<figure><artwork><![CDATA[
POST /acme/revoke-cert HTTP/1.1
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "RS256",
    "jwk": /* certificate's public key */,
    "nonce": "JHb54aT_KTXBWQOzGYkt9A",
    "url": "https://example.com/acme/revoke-cert"
  }),
  "payload": base64url({
    "certificate": "MIIEDTCCAvegAwIBAgIRAP8...",
    "reason": 1
  }),
  "signature": "Q1bURgJoEslbD1c5...3pYdSMLio57mQNN4"
}
]]></artwork></figure>

<t>Before revoking a certificate, the server MUST verify that the key used to sign
the request is authorized to revoke the certificate.  The server MUST consider
at least the following accounts authorized for a given certificate:</t>

<t><list style="symbols">
  <t>the account that issued the certificate.</t>
  <t>an account that holds authorizations for all of the identifiers in the
certificate.</t>
</list></t>

<t>The server MUST also consider a revocation request valid if it is signed with
the private key corresponding to the public key in the certificate.</t>

<t>If the revocation succeeds, the server responds with status code 200 (OK).  If
the revocation fails, the server returns an error.  For example, if the certificate
has already been revoked, the server returns an error response with status code 400
(Bad Request) and type "urn:ietf:params:acme:error:alreadyRevoked".</t>

<figure><artwork><![CDATA[
HTTP/1.1 200 OK
Replay-Nonce: IXVHDyxIRGcTE0VSblhPzw
Content-Length: 0
Link: <https://example.com/acme/directory>;rel="index"

--- or ---

HTTP/1.1 403 Forbidden
Replay-Nonce: lXfyFzi6238tfPQRwgfmPU
Content-Type: application/problem+json
Content-Language: en
Link: <https://example.com/acme/directory>;rel="index"

{
  "type": "urn:ietf:params:acme:error:unauthorized",
  "detail": "No authorization provided for name example.org"
}
]]></artwork></figure>

</section>
</section>
<section anchor="identifier-validation-challenges" title="Identifier Validation Challenges">

<t>There are few types of identifiers in the world for which there is a standardized
mechanism to prove possession of a given identifier.  In all practical cases,
CAs rely on a variety of means to test whether an entity applying for a
certificate with a given identifier actually controls that identifier.</t>

<t>Challenges provide the server with assurance that an account holder is also
the entity that controls an identifier.  For each type of challenge, it must be
the case that, in order for an entity to successfully complete the challenge, the
entity must both:</t>

<t><list style="symbols">
  <t>Hold the private key of the account key pair used to respond to the challenge, and</t>
  <t>Control the identifier in question.</t>
</list></t>

<t><xref target="security-considerations"/> documents how the challenges defined in this
document meet these requirements.  New challenges will need to document how they
do.</t>

<t>ACME uses an extensible challenge/response framework for identifier validation.
The server presents a set of challenges in the authorization object it sends to a
client (as objects in the "challenges" array), and the client responds by
sending a response object in a POST request to a challenge URL.</t>

<t>This section describes an initial set of challenge types.  The definition of a
challenge type includes:</t>

<t><list style="numbers">
  <t>Content of challenge objects</t>
  <t>Content of response objects</t>
  <t>How the server uses the challenge and response to verify control of an
identifier</t>
</list></t>

<t>Challenge objects all contain the following basic fields:</t>

<t><list style="hanging">
  <t hangText='type (required, string):'>
  The type of challenge encoded in the object.</t>
  <t hangText='url (required, string):'>
  The URL to which a response can be posted.</t>
  <t hangText='status (required, string):'>
  The status of this challenge.  Possible values are "pending",
"processing", "valid", and "invalid" (see <xref target="status-changes"/>).</t>
  <t hangText='validated (optional, string):'>
  The time at which the server validated this challenge, encoded in the
format specified in <xref target="RFC3339"/>.  This field is REQUIRED if the
"status" field is "valid".</t>
  <t hangText='error (optional, object):'>
  Error that occurred while the server was validating the challenge, if any,
structured as a problem document <xref target="RFC7807"/>. Multiple errors can be indicated
by using subproblems <xref target="subproblems"/>. A challenge object with an error MUST have
status equal to "invalid".</t>
</list></t>

<t>All additional fields are specified by the challenge type.  If the server sets a
challenge's "status" to "invalid", it SHOULD also include the "error" field to
help the client diagnose why the challenge failed.</t>

<t>Different challenges allow the server to obtain proof of different aspects of
control over an identifier.  In some challenges, like HTTP and DNS, the
client directly proves its ability to do certain things related to the
identifier.  The choice of which challenges to offer to a client under which
circumstances is a matter of server policy.</t>

<t>The identifier validation challenges described in this section all relate to
validation of domain names.  If ACME is extended in the future to support other
types of identifiers, there will need to be new challenge types, and they will
need to specify which types of identifier they apply to.</t>

<section anchor="key-authorizations" title="Key Authorizations">

<t>All challenges defined in this document make use of a key authorization
string.  A key authorization is a string that concatenates the token for the
challenge with a key fingerprint, separated by a "." character:</t>

<figure><artwork><![CDATA[
keyAuthorization = token || '.' || base64url(Thumbprint(accountKey))
]]></artwork></figure>

<t>The "Thumbprint" step indicates the computation specified in <xref target="RFC7638"/>,
using the SHA-256 digest <xref target="FIPS180-4"></xref>.  As noted in <xref target="RFC7518"/> any prepended
zero octets in the fields of a JWK object MUST be stripped before doing the computation.</t>

<t>As specified in the individual challenges below, the token for a challenge is a
string comprised entirely of characters in the URL-safe base64 alphabet.
The "||" operator indicates concatenation of strings.</t>

</section>
<section anchor="retrying-challenges" title="Retrying Challenges">

<t>ACME challenges typically require the client to set up some network-accessible
resource that the server can query in order to validate that the client
controls an identifier.  In practice, it is not uncommon for the server's
queries to fail while a resource is being set up, e.g., due to information
propagating across a cluster or firewall rules not being in place.</t>

<t>Clients SHOULD NOT respond to challenges until they believe that the server's
queries will succeed. If a server's initial validation query fails, the server
SHOULD retry the query after some time, in order to account for delay in setting
up responses such as DNS records or HTTP resources. The precise retry schedule
is up to the server, but server operators should keep in mind the operational
scenarios that the schedule is trying to accommodate.  Given that retries are
intended to address things like propagation delays in HTTP or DNS provisioning,
there should not usually be any reason to retry more often than every 5 or 10
seconds. While the server is still trying, the
status of the challenge remains "processing"; it is only marked "invalid" once the
server has given up.</t>

<t>The server MUST provide information about its retry state to the client via the
"error" field in the challenge and the Retry-After HTTP header field in
response to requests to the challenge resource. The server MUST add an entry to
the "error" field in the challenge after each failed validation query. The
server SHOULD set the Retry-After header field to a time after the server's
next validation query, since the status of the challenge will not change until
that time.</t>

<t>Clients can explicitly request a retry by re-sending their response to a
challenge in a new POST request (with a new nonce, etc.). This allows clients
to request a retry when the state has changed (e.g., after firewall rules have been
updated). Servers SHOULD retry a request immediately on receiving such a POST
request. In order to avoid denial-of-service attacks via client-initiated
retries, servers SHOULD rate-limit such requests.</t>

</section>
<section anchor="http-challenge" title="HTTP Challenge">

<t>With HTTP validation, the client in an ACME transaction proves its control over
a domain name by proving that it can provision HTTP resources on a server
accessible under that domain name.
The ACME server challenges the client to
provision a file at a specific path, with a specific string as its content.</t>

<t>As a domain may resolve to multiple IPv4 and IPv6 addresses, the server will
connect to at least one of the hosts found in the DNS A and AAAA records, at its
discretion.  Because many web servers allocate a default HTTPS virtual host to a
particular low-privilege tenant user in a subtle and non-intuitive manner, the
challenge must be completed over HTTP, not HTTPS.</t>

<t><list style="hanging">
  <t hangText='type (required, string):'>
  The string "http-01".</t>
  <t hangText='token (required, string):'>
  A random value that uniquely identifies the challenge.  This value MUST have
at least 128 bits of entropy.
It MUST NOT contain any characters outside the base64url alphabet and MUST NOT
include base64 padding characters ("=").  See <xref target="RFC4086"/> for additional information
on randomness requirements.</t>
</list></t>

<figure><artwork><![CDATA[
{
  "type": "http-01",
  "url": "https://example.com/acme/chall/prV_B7yEyA4",
  "status": "pending",
  "token": "LoqXcYV8q5ONbJQxbmR7SCTNo3tiAXDfowyjxAjEuX0"
}
]]></artwork></figure>

<t>A client fulfills this challenge by constructing a key authorization from
the "token" value provided in the challenge and the client's account key.  The
client then provisions the key authorization as a resource on the HTTP server
for the domain in question.</t>

<t>The path at which the resource is provisioned is comprised of the fixed prefix
"/.well-known/acme-challenge/", followed by the "token" value in the challenge.
The value of the resource MUST be the ASCII representation of the key
authorization.</t>

<figure><artwork><![CDATA[
GET /.well-known/acme-challenge/LoqXcYV8...jxAjEuX0
Host: example.org

HTTP/1.1 200 OK
Content-Type: application/octet-stream

LoqXcYV8...jxAjEuX0.9jg46WB3...fm21mqTI
]]></artwork></figure>

<t>(In the above, "..." indicates that the token and the JWK
thumbprint in the key authorization have been truncated to fit on
the page.)</t>

<t>A client responds with an empty object ({}) to acknowledge that the challenge
can be validated by the server.</t>

<figure><artwork><![CDATA[
POST /acme/chall/prV_B7yEyA4
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "kid": "https://example.com/acme/acct/evOfKhNU60wg",
    "nonce": "UQI1PoRi5OuXzxuX7V7wL0",
    "url": "https://example.com/acme/chall/prV_B7yEyA4"
  }),
  "payload": base64url({}),
  "signature": "Q1bURgJoEslbD1c5...3pYdSMLio57mQNN4"
}
]]></artwork></figure>

<t>On receiving a response, the server constructs and stores the key authorization
from the challenge "token" value and the current client account key.</t>

<t>Given a challenge/response pair, the server verifies the client's control of the
domain by verifying that the resource was provisioned as expected.</t>

<t><list style="numbers">
  <t>Construct a URL by populating the URL template <xref target="RFC6570"/>
"http://{domain}/.well-known/acme-challenge/{token}", where:
  <list style="symbols">
      <t>the domain field is set to the domain name being verified; and</t>
      <t>the token field is set to the token in the challenge.</t>
    </list></t>
  <t>Verify that the resulting URL is well-formed.</t>
  <t>Dereference the URL using an HTTP GET request.  This request MUST be sent to
TCP port 80 on the HTTP server.</t>
  <t>Verify that the body of the response is a well-formed key authorization.  The
server SHOULD ignore whitespace characters at the end of the body.</t>
  <t>Verify that key authorization provided by the HTTP server matches the key
authorization stored by the server.</t>
</list></t>

<t>The server SHOULD follow redirects when dereferencing the URL.
Clients might use redirects, for example, so that the response can
be provided by a centralized certificate management server.  See
<xref target="integrity-of-authorizations"/> for security considerations related
to redirects.</t>

<t>If all of the above verifications succeed, then the validation is successful.
If the request fails, or the body does not pass these checks, then it has
failed.</t>

<t>The client SHOULD de-provision the resource provisioned for this
challenge once the challenge is complete, i.e., once the "status"
field of the challenge has the value "valid" or "invalid".</t>

<t>Note that because the token appears both in the request sent by the
ACME server and in the key authorization in the response, it is
possible to build clients that copy the token from request to
response.  Clients should avoid this behavior because it can lead
to cross-site scripting vulnerabilities; instead, clients should be
explicitly configured on a per-challenge basis. A client that does
copy tokens from requests to responses MUST validate that the token
in the request matches the token syntax above (e.g., that it
includes only characters from the base64url alphabet).</t>

</section>
<section anchor="dns-challenge" title="DNS Challenge">

<t>When the identifier being validated is a domain name, the client can prove
control of that domain by provisioning a TXT resource record containing a designated
value for a specific validation domain name.</t>

<t><list style="hanging">
  <t hangText='type (required, string):'>
  The string "dns-01".</t>
  <t hangText='token (required, string):'>
  A random value that uniquely identifies the challenge.  This value MUST have
at least 128 bits of entropy. It MUST NOT contain any characters outside the
base64url alphabet, including padding characters ("="). See <xref target="RFC4086"/> for
additional information on randomness requirements.</t>
</list></t>

<figure><artwork><![CDATA[
{
  "type": "dns-01",
  "url": "https://example.com/acme/chall/Rg5dV14Gh1Q",
  "status": "pending",
  "token": "evaGxfADs6pSRb2LAv9IZf17Dt3juxGJ-PCt92wr-oA"
}
]]></artwork></figure>

<t>A client fulfills this challenge by constructing a key authorization from the
"token" value provided in the challenge and the client's account key.  The
client then computes the SHA-256 digest <xref target="FIPS180-4"></xref> of the key authorization.</t>

<t>The record provisioned to the DNS contains the base64url encoding of this digest.  The
client constructs the validation domain name by prepending the label
"_acme-challenge" to the domain name being validated, then provisions a TXT
record with the digest value under that name. For example, if the domain name
being validated is "www.example.org", then the client would provision the following
DNS record:</t>

<figure><artwork><![CDATA[
_acme-challenge.www.example.org. 300 IN TXT "gfj9Xq...Rg85nM"
]]></artwork></figure>

<t>A client responds with an empty object ({}) to acknowledge that the challenge
can be validated by the server.</t>

<figure><artwork><![CDATA[
POST /acme/chall/Rg5dV14Gh1Q
Host: example.com
Content-Type: application/jose+json

{
  "protected": base64url({
    "alg": "ES256",
    "kid": "https://example.com/acme/acct/evOfKhNU60wg",
    "nonce": "SS2sSl1PtspvFZ08kNtzKd",
    "url": "https://example.com/acme/chall/Rg5dV14Gh1Q"
  }),
  "payload": base64url({}),
  "signature": "Q1bURgJoEslbD1c5...3pYdSMLio57mQNN4"
}
]]></artwork></figure>

<t>On receiving a response, the server constructs and stores the key authorization
from the challenge "token" value and the current client account key.</t>

<t>To validate a DNS challenge, the server performs the following steps:</t>

<t><list style="numbers">
  <t>Compute the SHA-256 digest <xref target="FIPS180-4"></xref> of the stored key authorization</t>
  <t>Query for TXT records for the validation domain name</t>
  <t>Verify that the contents of one of the TXT records match the digest value</t>
</list></t>

<t>If all of the above verifications succeed, then the validation is successful.
If no DNS record is found, or DNS record and response payload do not pass these
checks, then the validation fails.</t>

<t>The client SHOULD de-provision the resource record(s) provisioned for this
challenge once the challenge is complete, i.e., once the "status"
field of the challenge has the value "valid" or "invalid".</t>

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

<section anchor="media-type-applicationpem-certificate-chain" title="Media Type: application/pem-certificate-chain">

<t>A file of this type contains one or more certificates encoded with
the PEM textual encoding, according to <xref target="RFC7468"/>.  The
textual encoding of certificates in this file MUST use the strict
encoding and MUST NOT include explanatory text.  The ABNF for this
format is as follows, where <spanx style="verb">stricttextualmsg</spanx> and <spanx style="verb">eol</spanx> are as
defined in Section 3 of RFC 7468:</t>

<figure><artwork><![CDATA[
certchain = stricttextualmsg *(eol stricttextualmsg)
]]></artwork></figure>

<t>In order to provide easy interoperation with TLS, the first
certificate MUST be an end-entity certificate. Each following certificate
SHOULD directly certify the one preceding it. Because certificate validation
requires that trust anchors be distributed independently, a certificate
that represents a trust anchor MAY be omitted from the chain, provided
that supported peers are known to possess any omitted certificates.</t>

<t>The following has been registered in the "Media Types" registry:</t>

<t>Type name: application</t>

<t>Subtype name: pem-certificate-chain</t>

<t>Required parameters: None</t>

<t>Optional parameters: None</t>

<t>Encoding considerations: 7bit</t>

<t>Security considerations: Carries a cryptographic certificate and its associated certificate chain.  This media type carries no active content.</t>

<t>Interoperability considerations: None</t>

<t>Published specification: RFC 8555</t>

<t>Applications that use this media type: ACME clients and servers, HTTP servers, other applications that need to be configured with a certificate chain</t>

<t>Additional information:</t>

<t>Deprecated alias names for this type: n/a
  Magic number(s): n/a
  File extension(s): .pem
  Macintosh file type code(s): n/a</t>

<t>Person &amp; email address to contact for further information: See Authors' Addresses section.</t>

<t>Intended usage: COMMON</t>

<t>Restrictions on usage: n/a</t>

<t>Author: See Authors' Addresses section.</t>

<t>Change controller: IETF &lt;iesg@ietf.org&gt;</t>

</section>
<section anchor="well-known-uri-for-the-http-challenge" title="Well-Known URI for the HTTP Challenge">

<t>The following value has been registered in the "Well-Known URIs" registry
(using the template from <xref target="RFC5785"/>):</t>

<t>URI suffix: acme-challenge</t>

<t>Change controller: IETF</t>

<t>Specification document(s): RFC 8555, <xref target="http-challenge"/></t>

<t>Related information: N/A</t>

</section>
<section anchor="replay-nonce-http-header" title="Replay-Nonce HTTP Header">

<t>The following value has been registered in the "Message Headers"
registry:</t>

<texttable>
      <ttcol align='left'>Header Field Name</ttcol>
      <ttcol align='left'>Protocol</ttcol>
      <ttcol align='left'>Status</ttcol>
      <ttcol align='left'>Reference</ttcol>
      <c>Replay-Nonce</c>
      <c>http</c>
      <c>standard</c>
      <c>RFC 8555, <xref target="replay-nonce"/></c>
</texttable>

</section>
<section anchor="url-jws-header-parameter" title="&quot;url&quot; JWS Header Parameter">

<t>The following value has been registered in the "JSON Web Signature and
Encryption Header Parameters" registry:</t>

<t><list style="symbols">
  <t>Header Parameter Name: "url"</t>
  <t>Header Parameter Description: URL</t>
  <t>Header Parameter Usage Location(s): JWE, JWS</t>
  <t>Change Controller: IESG</t>
  <t>Specification Document(s): RFC 8555, <xref target="url-url-jws-header-parameter"/></t>
</list></t>

</section>
<section anchor="nonce-jws-header-parameter" title="&quot;nonce&quot; JWS Header Parameter">

<t>The following value has been registered in the "JSON Web Signature and
Encryption Header Parameters" registry:</t>

<t><list style="symbols">
  <t>Header Parameter Name: "nonce"</t>
  <t>Header Parameter Description: Nonce</t>
  <t>Header Parameter Usage Location(s): JWE, JWS</t>
  <t>Change Controller: IESG</t>
  <t>Specification Document(s): RFC 8555, <xref target="nonce-nonce-jws-header-parameter"/></t>
</list></t>

</section>
<section anchor="acme-urn-space" title="URN Sub-namespace for ACME (urn:ietf:params:acme)">

<t>The following value has been registered in the "IETF URN Sub-namespace for
Registered Protocol Parameter Identifiers" registry, following the
template in <xref target="RFC3553"/>:</t>

<t><list style="hanging">
  <t hangText='Registry name:'>
  acme</t>
  <t hangText='Specification:'>
  RFC 8555</t>
  <t hangText='Repository:'>
  http://www.iana.org/assignments/acme</t>
  <t hangText='Index value:'>
  No transformation needed.</t>
</list></t>

</section>
<section anchor="new-registries" title="New Registries">

<t>IANA has created the following registries:</t>

<t><list style="numbers">
  <t>ACME Account Object Fields (<xref target="iana-account"/>)</t>
  <t>ACME Order Object Fields (<xref target="iana-order"/>)</t>
  <t>ACME Authorization Object Fields (<xref target="iana-authz"/>)</t>
  <t>ACME Error Types (<xref target="iana-error"/>)</t>
  <t>ACME Resource Types (<xref target="iana-resource"/>)</t>
  <t>ACME Directory Metadata Fields (<xref target="iana-meta"/>)</t>
  <t>ACME Identifier Types (<xref target="iana-identifier"/>)</t>
  <t>ACME Validation Methods (<xref target="iana-validation"/>)</t>
</list></t>

<t>All of these registries are under a heading of "Automated Certificate Management
Environment (ACME) Protocol" and are administered under a Specification
Required policy <xref target="RFC8126"/>.</t>

<section anchor="iana-account" title="Fields in Account Objects">

<t>The "ACME Account Object Fields" registry lists field names that are defined
for use in ACME account objects.  Fields marked as "configurable" may be included in a
newAccount request.</t>

<t>Template:</t>

<t><list style="symbols">
  <t>Field name: The string to be used as a field name in the JSON object</t>
  <t>Field type: The type of value to be provided, e.g., string, boolean, array of
string</t>
  <t>Requests: Either the value "none" or a list of types of requests
where the field is allowed in a request object, taken from the
following values:
  <list style="symbols">
      <t>"new" - Requests to the "newAccount" URL</t>
      <t>"account" - Requests to an account URL</t>
    </list></t>
  <t>Reference: Where this field is defined</t>
</list></t>

<t>Initial contents: The fields and descriptions defined in <xref target="account-objects"/>.</t>

<?rfc compact="no"?>
<texttable>
      <ttcol align='left'>Field Name</ttcol>
      <ttcol align='left'>Field Type</ttcol>
      <ttcol align='left'>Requests</ttcol>
      <ttcol align='left'>Reference</ttcol>
      <c>status</c>
      <c>string</c>
      <c>new, account</c>
      <c>RFC 8555</c>
      <c>contact</c>
      <c>array of string</c>
      <c>new, account</c>
      <c>RFC 8555</c>
      <c>externalAccountBinding</c>
      <c>object</c>
      <c>new</c>
      <c>RFC 8555</c>
      <c>termsOfServiceAgreed</c>
      <c>boolean</c>
      <c>new</c>
      <c>RFC 8555</c>
      <c>onlyReturnExisting</c>
      <c>boolean</c>
      <c>new</c>
      <c>RFC 8555</c>
      <c>orders</c>
      <c>string</c>
      <c>none</c>
      <c>RFC 8555</c>
</texttable>
<?rfc compact="yes"?>

</section>
<section anchor="iana-order" title="Fields in Order Objects">

<t>The "ACME Order Object Fields" registry lists field names that are defined
for use in ACME order objects.  Fields marked as "configurable" may be included in a
newOrder request.</t>

<t>Template:</t>

<t><list style="symbols">
  <t>Field name: The string to be used as a field name in the JSON object</t>
  <t>Field type: The type of value to be provided, e.g., string, boolean, array of
string</t>
  <t>Configurable: Boolean indicating whether the server should accept
values provided by the client</t>
  <t>Reference: Where this field is defined</t>
</list></t>

<t>Initial contents: The fields and descriptions defined in <xref target="order-objects"/>.</t>

<?rfc compact="no"?>
<texttable>
      <ttcol align='left'>Field Name</ttcol>
      <ttcol align='left'>Field Type</ttcol>
      <ttcol align='left'>Configurable</ttcol>
      <ttcol align='left'>Reference</ttcol>
      <c>status</c>
      <c>string</c>
      <c>false</c>
      <c>RFC 8555</c>
      <c>expires</c>
      <c>string</c>
      <c>false</c>
      <c>RFC 8555</c>
      <c>identifiers</c>
      <c>array of object</c>
      <c>true</c>
      <c>RFC 8555</c>
      <c>notBefore</c>
      <c>string</c>
      <c>true</c>
      <c>RFC 8555</c>
      <c>notAfter</c>
      <c>string</c>
      <c>true</c>
      <c>RFC 8555</c>
      <c>error</c>
      <c>string</c>
      <c>false</c>
      <c>RFC 8555</c>
      <c>authorizations</c>
      <c>array of string</c>
      <c>false</c>
      <c>RFC 8555</c>
      <c>finalize</c>
      <c>string</c>
      <c>false</c>
      <c>RFC 8555</c>
      <c>certificate</c>
      <c>string</c>
      <c>false</c>
      <c>RFC 8555</c>
</texttable>
<?rfc compact="yes"?>
</section>
<section anchor="iana-authz" title="Fields in Authorization Objects">

<t>The "ACME Authorization Object Fields" registry lists field names that are
defined for use in ACME authorization objects.  Fields marked as
"configurable" may be included in a newAuthz request.</t>

<t>Template:</t>

<t><list style="symbols">
  <t>Field name: The string to be used as a field name in the JSON object</t>
  <t>Field type: The type of value to be provided, e.g., string, boolean, array of
string</t>
  <t>Configurable: Boolean indicating whether the server should accept
values provided by the client</t>
  <t>Reference: Where this field is defined</t>
</list></t>

<t>Initial contents: The fields and descriptions defined in <xref target="authorization-objects"/>.</t>

<?rfc compact="no"?>
<texttable>
      <ttcol align='left'>Field Name</ttcol>
      <ttcol align='left'>Field Type</ttcol>
      <ttcol align='left'>Configurable</ttcol>
      <ttcol align='left'>Reference</ttcol>
      <c>identifier</c>
      <c>object</c>
      <c>true</c>
      <c>RFC 8555</c>
      <c>status</c>
      <c>string</c>
      <c>false</c>
      <c>RFC 8555</c>
      <c>expires</c>
      <c>string</c>
      <c>false</c>
      <c>RFC 8555</c>
      <c>challenges</c>
      <c>array of object</c>
      <c>false</c>
      <c>RFC 8555</c>
      <c>wildcard</c>
      <c>boolean</c>
      <c>false</c>
      <c>RFC 8555</c>
</texttable>
<?rfc compact="yes"?>

</section>
<section anchor="iana-error" title="Error Types">

<t>The "ACME Error Types" registry lists values that are used within URN
values that are provided in the "type" field of problem documents in ACME.</t>

<t>Template:</t>

<t><list style="symbols">
  <t>Type: The label to be included in the URN for this error, following
"urn:ietf:params:acme:error:"</t>
  <t>Description: A human-readable description of the error</t>
  <t>Reference: Where the error is defined</t>
</list></t>

<t>Initial contents: The types and descriptions in the table in <xref target="errors"/> above,
with the Reference field set to point to this specification.</t>

</section>
<section anchor="iana-resource" title="Resource Types">

<t>The "ACME Resource Types" registry lists the types of resources that ACME
servers may list in their directory objects.</t>

<t>Template:</t>

<t><list style="symbols">
  <t>Field name: The value to be used as a field name in the directory object</t>
  <t>Resource type: The type of resource labeled by the field</t>
  <t>Reference: Where the resource type is defined</t>
</list></t>

<t>Initial contents:</t>
<?rfc compact="no"?>
<texttable>
      <ttcol align='left'>Field Name</ttcol>
      <ttcol align='left'>Resource Type</ttcol>
      <ttcol align='left'>Reference</ttcol>
      <c>newNonce</c>
      <c>New nonce</c>
      <c>RFC 8555</c>
      <c>newAccount</c>
      <c>New account</c>
      <c>RFC 8555</c>
      <c>newOrder</c>
      <c>New order</c>
      <c>RFC 8555</c>
      <c>newAuthz</c>
      <c>New authorization</c>
      <c>RFC 8555</c>
      <c>revokeCert</c>
      <c>Revoke certificate</c>
      <c>RFC 8555</c>
      <c>keyChange</c>
      <c>Key change</c>
      <c>RFC 8555</c>
      <c>meta</c>
      <c>Metadata object</c>
      <c>RFC 8555</c>
</texttable>
<?rfc compact="yes"?>

</section>
<section anchor="iana-meta" title="Fields in the &quot;meta&quot; Object within a Directory Object">

<t>The "ACME Directory Metadata Fields" registry lists field names that are
defined for use in the JSON object included in the "meta" field of an ACME
directory object.</t>

<t>Template:</t>

<t><list style="symbols">
  <t>Field name: The string to be used as a field name in the JSON object</t>
  <t>Field type: The type of value to be provided, e.g., string, boolean, array of
string</t>
  <t>Reference: Where this field is defined</t>
</list></t>

<t>Initial contents: The fields and descriptions defined in <xref target="directory"/>.</t>

<?rfc compact="no"?>
<texttable>
      <ttcol align='left'>Field Name</ttcol>
      <ttcol align='left'>Field Type</ttcol>
      <ttcol align='left'>Reference</ttcol>
      <c>termsOfService</c>
      <c>string</c>
      <c>RFC 8555</c>
      <c>website</c>
      <c>string</c>
      <c>RFC 8555</c>
      <c>caaIdentities</c>
      <c>array of string</c>
      <c>RFC 8555</c>
      <c>externalAccountRequired</c>
      <c>boolean</c>
      <c>RFC 8555</c>
</texttable>
<?rfc compact="yes"?>

</section>
<section anchor="iana-identifier" title="Identifier Types">

<t>The "ACME Identifier Types" registry lists the types of identifiers that
can be present in ACME authorization objects.</t>

<t>Template:</t>

<t><list style="symbols">
  <t>Label: The value to be put in the "type" field of the identifier object</t>
  <t>Reference: Where the identifier type is defined</t>
</list></t>

<t>Initial contents:</t>

<texttable>
      <ttcol align='left'>Label</ttcol>
      <ttcol align='left'>Reference</ttcol>
      <c>dns</c>
      <c>RFC 8555</c>
</texttable>

</section>
<section anchor="iana-validation" title="Validation Methods">

<t>The "ACME Validation Methods" registry lists identifiers for the ways that
CAs can validate control of identifiers.  Each method's entry must specify
whether it corresponds to an ACME challenge type.  The "Identifier Type" field
must be contained in the Label column of the "ACME Identifier Types" registry.</t>

<t>Template:</t>

<t><list style="symbols">
  <t>Label: The identifier for this validation method</t>
  <t>Identifier Type: The type of identifier that this method applies to</t>
  <t>ACME: "Y" if the validation method corresponds to an ACME challenge type;
"N" otherwise</t>
  <t>Reference: Where the validation method is defined</t>
</list></t>

<t>This registry may also contain reserved entries (e.g., to avoid
collisions).  Such entries should have the "ACME" field set to "N"
and the "Identifier Type" set to "RESERVED".</t>

<t>Initial Contents</t>

<?rfc compact="no"?>
<texttable>
      <ttcol align='left'>Label</ttcol>
      <ttcol align='left'>Identifier Type</ttcol>
      <ttcol align='left'>ACME</ttcol>
      <ttcol align='left'>Reference</ttcol>
      <c>http-01</c>
      <c>dns</c>
      <c>Y</c>
      <c>RFC 8555</c>
      <c>dns-01</c>
      <c>dns</c>
      <c>Y</c>
      <c>RFC 8555</c>
      <c>tls-sni-01</c>
      <c>RESERVED</c>
      <c>N</c>
      <c>RFC 8555</c>
      <c>tls-sni-02</c>
      <c>RESERVED</c>
      <c>N</c>
      <c>RFC 8555</c>
</texttable>

<?rfc compact="yes"?>
<t>When evaluating a request for an assignment in this registry, the designated
expert should ensure that the method being registered has a clear,
interoperable definition and does not overlap with existing validation methods.
That is, it should not be possible for a client and server to follow the
same set of actions to fulfill two different validation methods.</t>

<t>The values "tls-sni-01" and "tls-sni-02" are reserved because they
were used in pre-RFC versions of this specification to denote
validation methods that were removed because they were found not to be secure in some cases.</t>

<t>Validation methods do not have to be compatible with ACME in order to be
registered.  For example, a CA might wish to register a validation method
to support its use with the ACME extensions to CAA
<xref target="ACME-CAA"/>.</t>

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

<t>ACME is a protocol for managing certificates that attest to identifier/key
bindings.  Thus, the foremost security goal of ACME is to ensure the integrity of
this process, i.e., to ensure that the bindings attested by certificates are
correct and that only authorized entities can manage certificates.  ACME
identifies clients by their account keys, so this overall goal breaks down into
two more precise goals:</t>

<t><list style="numbers">
  <t>Only an entity that controls an identifier can get an authorization for that
identifier</t>
  <t>Once authorized, an account key's authorizations cannot be improperly
used by another account</t>
</list></t>

<t>In this section, we discuss the threat model that underlies ACME and the ways
that ACME achieves these security goals within that threat model.  We also
discuss the denial-of-service risks that ACME servers face, and a few other
miscellaneous considerations.</t>

<section anchor="threat-model" title="Threat Model">

<t>As a service on the Internet, ACME broadly exists within the Internet threat
model <xref target="RFC3552"/>.  In analyzing ACME, it is useful to think of an ACME server
interacting with other Internet hosts along two "channels":</t>

<t><list style="symbols">
  <t>An ACME channel, over which the ACME HTTPS requests are exchanged</t>
  <t>A validation channel, over which the ACME server performs additional requests
to validate a client's control of an identifier</t>
</list></t>

<figure title="Communications Channels Used by ACME"><artwork><![CDATA[
+------------+
|    ACME    |     ACME Channel
|   Client   |--------------------+
+------------+                    |
                                  V
                            +------------+
                            |    ACME    |
                            |   Server   |
                            +------------+
+------------+                    |
| Validation |<-------------------+
|   Server   |  Validation Channel
+------------+
]]></artwork></figure>

<t>In practice, the risks to these channels are not entirely separate, but they are
different in most cases.  Each channel, for example, uses a
different communications pattern: the ACME channel will comprise inbound HTTPS
connections to the ACME server and the validation channel outbound HTTP or DNS
requests.</t>

<t>Broadly speaking, ACME aims to be secure against active and passive attackers on
any individual channel.  Some vulnerabilities arise (noted below) when an
attacker can exploit both the ACME channel and one of the others.</t>

<t>On the ACME channel, in addition to network-layer attackers, we also need to
account for man-in-the-middle (MitM) attacks at the application layer and for
abusive use of the protocol itself.  Protection against application-layer MitM
addresses potential attackers such as Content Distribution Networks (CDNs) and
middleboxes with a TLS MitM function.  Preventing abusive use of ACME means
ensuring that an attacker with access to the validation channel can't obtain
illegitimate authorization by acting as an ACME client (legitimately, in terms
of the protocol).</t>

<t>ACME does not protect against other types of abuse by a MitM on the ACME channel.
For example, such an attacker could send a bogus "badSignatureAlgorithm"
error response to downgrade a client to the lowest-quality signature algorithm that
the server supports.  A MitM that is present on all connections (such as a
CDN) can cause denial-of-service conditions in a variety of ways.</t>

</section>
<section anchor="integrity-of-authorizations" title="Integrity of Authorizations">

<t>ACME allows anyone to request challenges for an identifier by registering an
account key and sending a newOrder request using that account key.  The
integrity of the authorization process thus depends on the identifier validation
challenges to ensure that the challenge can only be completed by someone who
both (1) holds the private key of the account key pair and (2) controls the
identifier in question.</t>

<t>Validation responses need to be bound to an account key pair in order to avoid
situations where a MitM on ACME HTTPS requests can switch out a legitimate domain holder's
account key for one of his choosing.  Such MitMs can arise, for
example, if a CA uses a CDN or third-party reverse proxy in front of
its ACME interface.  An attack by such an MitM could have the
following form:</t>

<t><list style="numbers">
  <t>Legitimate domain holder registers account key pair A</t>
  <t>MitM registers account key pair B</t>
  <t>Legitimate domain holder sends a newOrder request signed using account key A</t>
  <t>MitM suppresses the legitimate request but sends the same request signed
using account key B</t>
  <t>ACME server issues challenges and MitM forwards them to the legitimate domain
holder</t>
  <t>Legitimate domain holder provisions the validation response</t>
  <t>ACME server performs validation query and sees the response provisioned by the
legitimate domain holder</t>
  <t>Because the challenges were issued in response to a message signed with account key
B, the ACME server grants authorization to account key B (the MitM) instead of
account key A (the legitimate domain holder)</t>
</list></t>

<figure title="Man-in-the-Middle Attack Exploiting a Validation Method without
Account Key Binding"><artwork><![CDATA[
Domain                                         ACME
Holder                  MitM                  Server
  |                      |                      |
  | newAccount(A)        |                      |
  |--------------------->|--------------------->|
  |                      |                      |
  |                      | newAccount(B)        |
  |                      |--------------------->|
  | newOrder(domain, A)  |                      |
  |--------------------->|                      |
  |                      | newOrder(domain, B)  |
  |                      |--------------------->|
  |                      |                      |
  |   authz, challenges  |   authz, challenges  |
  |<---------------------|<---------------------|
  |                      |                      |
  | response(chall, A)   | response(chall, B)   |
  |--------------------->|--------------------->|
  |                      |                      |
  |  validation request  |                      |
  |<--------------------------------------------|
  |                      |                      |
  | validation response  |                      |
  |-------------------------------------------->|
  |                      |                      |
  |                      |                      | Considers challenge
  |                      |                      | fulfilled by B
  |                      |                      |
]]></artwork></figure>

<t>All of the challenges defined in this document have a binding between the account private key and
the validation query made by the server, via the key authorization. The key
authorization reflects the account public key and is provided to the server in
the validation response over the validation channel.</t>

<t>The association of challenges to identifiers is typically done by requiring the
client to perform some action that only someone who effectively controls the
identifier can perform.  For the challenges in this document, the actions are as follows:</t>

<t><list style="symbols">
  <t>HTTP: Provision files under .well-known on a web server for the domain</t>
  <t>DNS: Provision DNS resource records for the domain</t>
</list></t>

<t>There are several ways that these assumptions can be violated, both by
misconfiguration and by attacks.  For example, on a web server that allows
non-administrative users to write to .well-known, any user can claim to own the
web server's hostname by responding to an HTTP challenge.  Similarly, if
a server that can be used for ACME
validation is compromised by a malicious actor, then that malicious actor can
use that access to obtain certificates via ACME.</t>

<t>The use of hosting providers is a particular risk for ACME validation.  If the
owner of the domain has outsourced operation of DNS or web services to a hosting
provider, there is nothing that can be done against tampering by the hosting
provider.  As far as the outside world is concerned, the zone or website
provided by the hosting provider is the real thing.</t>

<t>More limited forms of delegation can also lead to an unintended party gaining
the ability to successfully complete a validation transaction.  For example,
suppose an ACME server follows HTTP redirects in HTTP validation and a
website operator provisions a catch-all redirect rule that redirects requests
for unknown resources to a different domain.  Then the target of the redirect
could use that to get a certificate through HTTP validation since the
validation path will not be known to the primary server.</t>

<t>The DNS is a common point of vulnerability for all of these challenges.  An
entity that can provision false DNS records for a domain can attack the DNS
challenge directly and can provision false A/AAAA records to direct the ACME
server to send its HTTP validation query to a remote server of the attacker's
choosing.  There are a few different mitigations that ACME servers
can apply:</t>

<t><list style="symbols">
  <t>Always querying the DNS using a DNSSEC-validating resolver (enhancing
security for zones that are DNSSEC-enabled)</t>
  <t>Querying the DNS from multiple vantage points to address local attackers</t>
  <t>Applying mitigations against DNS off-path attackers, e.g., adding entropy to
requests <xref target="DNS0x20"/> or only using TCP</t>
</list></t>

<t>Given these considerations, the ACME validation process makes it impossible for
any attacker on the ACME channel or a passive attacker on the validation
channel to hijack the authorization process to authorize a key of the attacker's
choice.</t>

<t>An attacker that can only see the ACME channel would need to convince the
validation server to provide a response that would authorize the attacker's
account key, but this is prevented by binding the validation response to the
account key used to request challenges.  A passive attacker on the validation
channel can observe the correct validation response and even replay it, but that
response can only be used with the account key for which it was generated.</t>

<t>An active attacker on the validation channel can subvert the ACME process, by
performing normal ACME transactions and providing a validation response for his
own account key.  The risks due to hosting providers noted above are a
particular case.</t>

<t>Attackers can also exploit vulnerabilities in Internet routing
protocols to gain access to the validation channel (see, e.g.,
<xref target="RFC7132"/>).  In order to make such attacks more difficult, it is
RECOMMENDED that the server perform DNS queries and make HTTP
connections from multiple points in the network.  Since routing
attacks are often localized or dependent on the position of the
attacker, forcing the attacker to attack multiple points (the
server's validation vantage points) or a specific point (the DNS / HTTP server) makes it more difficult to subvert ACME validation
using attacks on routing.</t>

</section>
<section anchor="denial-of-service-considerations" title="Denial-of-Service Considerations">

<t>As a protocol run over HTTPS, standard considerations for TCP-based and
HTTP-based DoS mitigation also apply to ACME.</t>

<t>At the application layer, ACME requires the server to perform a few potentially
expensive operations.  Identifier validation transactions require the ACME
server to make outbound connections to potentially attacker-controlled servers,
and certificate issuance can require interactions with cryptographic hardware.</t>

<t>In addition, an attacker can also cause the ACME server to send validation
requests to a domain of its choosing by submitting authorization requests for
the victim domain.</t>

<t>All of these attacks can be mitigated by the application of appropriate rate
limits.  Issues closer to the front end, like POST body validation, can be
addressed using HTTP request limiting.  For validation and certificate requests,
there are other identifiers on which rate limits can be keyed.  For example, the
server might limit the rate at which any individual account key can issue
certificates or the rate at which validation can be requested within a given
subtree of the DNS.  And in order to prevent attackers from circumventing these
limits simply by minting new accounts, servers would need to limit the rate at
which accounts can be registered.</t>

</section>
<section anchor="server-side-request-forgery" title="Server-Side Request Forgery">

<t>Server-Side Request Forgery (SSRF) attacks can arise when an attacker can cause
a server to perform HTTP requests to an attacker-chosen URL.  In the ACME HTTP
challenge validation process, the ACME server performs an HTTP GET request to a
URL in which the attacker can choose the domain.  This request is made before
the server has verified that the client controls the domain, so any client can
cause a query to any domain.</t>

<t>Some ACME server implementations include information from the validation server's
response (in order to facilitate debugging).  Such implementations enable an
attacker to extract this information from any web server that is accessible to
the ACME server, even if it is not accessible to the ACME client.
For example, the ACME server might be able to access servers behind
a firewall that would prevent access by the ACME client.</t>

<t>It might seem that the risk of SSRF through this channel is limited by the fact
that the attacker can only control the domain of the URL, not the path.
However, if the attacker first sets the domain to one they control, then they
can send the server an HTTP redirect (e.g., a 302 response) which will cause the
server to query an arbitrary URL.</t>

<t>In order to further limit the SSRF risk, ACME server operators should ensure
that validation queries can only be sent to servers on the public Internet, and
not, say, web services within the server operator's internal network.  Since the
attacker could make requests to these public servers himself, he can't gain
anything extra through an SSRF attack on ACME aside from a layer of
anonymization.</t>

</section>
<section anchor="ca-policy-considerations" title="CA Policy Considerations">

<t>The controls on issuance enabled by ACME are focused on validating that a
certificate applicant controls the identifier he claims.  Before issuing a
certificate, however, there are many other checks that a CA might need to
perform, for example:</t>

<t><list style="symbols">
  <t>Has the client agreed to a subscriber agreement?</t>
  <t>Is the claimed identifier syntactically valid?</t>
  <t>For domain names:
  <list style="symbols">
      <t>If the leftmost label is a '*', then have the appropriate checks been
applied?</t>
      <t>Is the name on the Public Suffix List?</t>
      <t>Is the name a high-value name?</t>
      <t>Is the name a known phishing domain?</t>
    </list></t>
  <t>Is the key in the CSR sufficiently strong?</t>
  <t>Is the CSR signed with an acceptable algorithm?</t>
  <t>Has issuance been authorized or forbidden by a Certificate Authority
Authorization (CAA) record (<xref target="RFC6844"/>)?</t>
</list></t>

<t>CAs that use ACME to automate issuance will need to ensure that their servers
perform all necessary checks before issuing.</t>

<t>CAs using ACME to allow clients to agree to terms of service should keep in mind
that ACME clients can automate this agreement, possibly not involving a human
user.</t>

<t>ACME does not specify how the server constructs the URLs that it
uses to address resources.  If the server operator uses URLs that
are predictable to third parties, this can leak information about
what URLs exist on the server, since an attacker can probe for
whether a POST-as-GET request to the URL returns 404 (Not Found) or
401 (Unauthorized).</t>

<t>For example, suppose that the CA uses highly structured URLs with
guessable fields:</t>

<t><list style="symbols">
  <t>Accounts: https://example.com/:accountID</t>
  <t>Orders: https://example.com/:accountID/:domainName</t>
  <t>Authorizations: https://example.com/:accountID/:domainName</t>
  <t>Certificates: https://example.com/:accountID/:domainName</t>
</list></t>

<t>Under that scheme, an attacker could probe for which domain names are
associated with which accounts, which may allow correlation of ownership
between domain names, if the CA does not otherwise permit it.</t>

<t>To avoid leaking these correlations, CAs SHOULD assign URLs with an
unpredictable component.
For example, a CA might assign URLs for each resource type from an
independent namespace, using unpredictable IDs for each resource:</t>

<t><list style="symbols">
  <t>Accounts: https://example.com/acct/:accountID</t>
  <t>Orders: https://example.com/order/:orderID</t>
  <t>Authorizations: https://example.com/authz/:authorizationID</t>
  <t>Certificates: https://example.com/cert/:certID</t>
</list></t>

<t>Such a scheme would leak only the type of resource, hiding the
additional correlations revealed in the example above.</t>

</section>
</section>
<section anchor="operational-considerations" title="Operational Considerations">

<t>There are certain factors that arise in operational reality that operators of
ACME-based CAs will need to keep in mind when configuring their services.
See the subsections below for examples.</t>

<section anchor="key-selection" title="Key Selection">

<t>ACME relies on two different classes of key pair:</t>

<t><list style="symbols">
  <t>Account key pairs, which are used to authenticate account holders</t>
  <t>Certificate key pairs, which are used to sign and verify CSRs (and whose
public keys are included in certificates)</t>
</list></t>

<t>Compromise of the private key of an account key pair has more serious consequences than
compromise of a private key corresponding to a certificate.  While
the compromise of a certificate key pair allows the attacker to impersonate the
entities named in the certificate for the lifetime of the certificate, the
compromise of an account key pair allows the attacker to take full control of
the victim's ACME account and take any action that the legitimate
account holder could take within the scope of ACME:</t>

<t><list style="numbers">
  <t>Issuing certificates using existing authorizations</t>
  <t>Revoking existing certificates</t>
  <t>Accessing and changing account information (e.g., contacts)</t>
  <t>Changing the account key pair for the account, locking out the
legitimate account holder</t>
</list></t>

<t>For this reason, it is RECOMMENDED that each account key pair be
used only for authentication of a single ACME account.  For example,
the public key of an account key pair MUST NOT be included in a
certificate.  If an ACME client receives a request from a user for
account creation or key rollover using an account key that the
client knows to be used elsewhere, then the client MUST return an
error.  Clients MUST generate a fresh account key for every account
creation or rollover operation.  Note that given the requirements of
<xref target="finding-an-account-url-given-a-key"/>, servers will not create
accounts with reused keys anyway.</t>

<t>ACME clients and servers MUST verify that a CSR submitted in a finalize request does not contain a
public key for any known account key pair.  In particular, when a server
receives a finalize request, it MUST verify that the public key in a CSR is not
the same as the public key of the account key pair used to authenticate that
request.  This assures that vulnerabilities in the protocols with which the
certificate is used (e.g., signing oracles in TLS <xref target="JSS15"></xref>) do not result in
compromise of the ACME account. Because ACME accounts are uniquely identified by
their account key pair (see <xref target="finding-an-account-url-given-a-key"/>), the server
MUST not allow account key pair reuse across multiple accounts.</t>

</section>
<section anchor="dns-security" title="DNS Security">

<t>As noted above, DNS forgery attacks against the ACME server can result in the
server making incorrect decisions about domain control and thus mis-issuing
certificates. Servers SHOULD perform DNS queries over TCP, which provides better
resistance to some forgery attacks than DNS over UDP.</t>

<t>An ACME-based CA will often need to make DNS queries, e.g., to validate control
of DNS names.  Because the security of such validations ultimately depends on
the authenticity of DNS data, every possible precaution should be taken to
secure DNS queries done by the CA. Therefore, it is RECOMMENDED that ACME-based
CAs make all DNS queries via DNSSEC-validating stub or recursive resolvers. This
provides additional protection to domains that choose to make use of DNSSEC.</t>

<t>An ACME-based CA must only use a resolver if it trusts the resolver and every
component of the network route by which it is accessed. Therefore, it is
RECOMMENDED that ACME-based CAs operate their own DNSSEC-validating resolvers
within their trusted network and use these resolvers both for CAA record
lookups and all record lookups in furtherance of a challenge scheme (A, AAAA,
TXT, etc.).</t>

</section>
<section anchor="token-entropy" title="Token Entropy">

<t>The http-01 and dns-01 validation methods mandate the use of
a random token value to uniquely identify the challenge. The value of the token
is required to contain at least 128 bits of entropy for the following security
properties. First, the ACME client should not be able to influence the ACME
server's choice of token as this may allow an attacker to reuse a domain owner's
previous challenge responses for a new validation request. Second, the entropy
requirement makes it more difficult for ACME clients to implement a "naive"
validation server that automatically replies to challenges without being
configured per challenge.</t>

</section>
<section anchor="malformed-certificate-chains" title="Malformed Certificate Chains">

<t>ACME provides certificate chains in the widely used format known colloquially
as PEM (though it may diverge from the actual Privacy Enhanced Mail
specification <xref target="RFC1421"/>, as noted in <xref target="RFC7468"/>). Some current software
will allow the configuration of a private key and a certificate in one PEM
file by concatenating the textual encodings of the two objects. In the context
of ACME, such software might be vulnerable to key replacement attacks. A
malicious ACME server could cause a client to use a private key of its choosing
by including the key in the PEM file returned in response to a query for a
certificate URL.</t>

<t>When processing a file of type "application/pem-certificate-chain", a client
SHOULD verify that the file contains only encoded certificates.  If anything
other than a certificate is found (i.e., if the string "-----BEGIN" is ever
followed by anything other than "CERTIFICATE"), then the client MUST reject the
file as invalid.</t>

</section>
</section>



  </middle>

  <back>

    <references title='Normative References'>

<reference anchor="FIPS180-4" target="http://csrc.nist.gov/publications/fips/fips180-4/fips-180-4.pdf">
  <front>
    <title>Secure Hash Standard (SHS)</title>
    <author >
      <organization>National Institute of Standards and Technology (NIST)</organization>
    </author>
    <date year="2015" month="August"/>
  </front>
  <seriesInfo name="FIPS PUB" value="180-4"/>
<seriesInfo name='DOI' value='10.6028/NIST.FIPS.180-4' />
</reference>
      

<reference anchor="JSS15" target="https://dl.acm.org/citation.cfm?id=2813657">
  <front>
    <title>On the Security of TLS 1.3 and QUIC Against Weaknesses in PKCS#1 v1.5 Encryption</title>
    <author initials="J." surname="Somorovsky" fullname="Juraj Somorovsky">
      <organization></organization>
    </author>
    <author initials="J." surname="Schwenk" fullname="Jorg Schwenk"><organization></organization></author>
    <author initials="J." surname="Somorovsky" fullname="Juraj Somorovsky"><organization></organization></author>
    <date/>
  </front>
  <seriesInfo name="CSS '15 Proceedings of the 22nd ACM SIGSAC Conference on Computer and Communications Security" value="Pages 1185-1196"/>
  <seriesInfo name="DOI" value="10.1145/2810103.2813657"/>
</reference>



<?rfc include="reference.RFC.5280"?>
<?rfc include="reference.RFC.2986"?>
<?rfc include="reference.RFC.5246"?>
<?rfc include="reference.RFC.2818"?>
<?rfc include="reference.RFC.2119"?>
<?rfc include="reference.RFC.8174"?>
<?rfc include="reference.RFC.8259"?>
<?rfc include="reference.RFC.3629"?>
<?rfc include="reference.RFC.7515"?>
<?rfc include="reference.RFC.7231"?>
<?rfc include="reference.RFC.4648"?>
<?rfc include="reference.RFC.7797"?>
<?rfc include="reference.RFC.7518"?>
<?rfc include="reference.RFC.8037"?>
<?rfc include="reference.RFC.3986"?>
<?rfc include="reference.RFC.5234"?>
<?rfc include="reference.RFC.8288"?>
<?rfc include="reference.RFC.7807"?>
  <?rfc include="reference.RFC.5988"?>
  <?rfc include="reference.RFC.6844"?>
  <?rfc include="reference.RFC.3339"?>
  <?rfc include="reference.RFC.5890"?>
  <?rfc include="reference.RFC.6068"?>
  <?rfc include="reference.RFC.2985"?>
  <?rfc include="reference.RFC.2585"?>
  <?rfc include="reference.RFC.5751"?>
  <?rfc include="reference.RFC.8446"?>
  <?rfc include="reference.RFC.7638"?>
  <?rfc include="reference.RFC.4086"?>
  <?rfc include="reference.RFC.6570"?>
  <?rfc include="reference.RFC.7468"?>
  <?rfc include="reference.RFC.8126"?>

    </references>

    <references title='Informative References'>

<reference anchor="CABFBR" target="https://cabforum.org/baseline-requirements-documents/">
  <front>
    <title>CA/Browser Forum Baseline Requirements</title>
    <author>
      <organization>CA/Browser Forum</organization>
    </author>
    <date year="2018" month="September"/>
  </front>
</reference>

<!--draft-ietf-acme-ip; Active AD Eval -->


<reference anchor="ACME-IP">
<front>
<title>ACME IP Identifier Validation Extension</title>

<author initials='R' surname='Shoemaker' fullname='Roland Shoemaker'>
    <organization />
</author>

<date month='February' year='2019' />

<abstract><t>This document specifies identifiers and challenges required to enable the Automated Certificate Management Environment (ACME) to issue certificates for IP addresses.</t></abstract>

</front>

<seriesInfo name='Work in Progress,' value='draft-ietf-acme-ip-05' />

</reference>

<!--draft-ietf-acme-telephone; Expired -->

<reference anchor="ACME-TELEPHONE">
<front>
<title>ACME Identifiers and Challenges for Telephone Numbers</title>

<author initials='J' surname='Peterson' fullname='Jon Peterson'>
    <organization />
</author>

<author initials='R' surname='Barnes' fullname='Richard Barnes'>
    <organization />
</author>

<date month='October' day='30' year='2017' />

<abstract><t>This document specifies identifiers and challenges required to enable the Automated Certificate Management Environment (ACME) to issue certificate for telephonoe numbers.</t></abstract>

</front>

<seriesInfo name='Work in Progress,' value='draft-ietf-acme-telephone-01' />

</reference>

  <?rfc include="reference.RFC.6960"?>
  <?rfc include="reference.RFC.7525"?>




<reference anchor="W3C.REC-cors-20140116"
           target='http://www.w3.org/TR/2014/REC-cors-20140116'>
<front>
<title>Cross-Origin Resource Sharing</title>

<author initials='A.' surname='Kesteren' fullname='Anne van Kesteren' role="editor">
    <organization />
</author>

<date month='January' day='16' year='2014' />
</front>

<seriesInfo name='W3C Recommendation' value='REC-cors-20140116' />
<format type='HTML' target='http://www.w3.org/TR/2014/REC-cors-20140116' />
</reference>


  <?rfc include="reference.RFC.5785"?>
  <?rfc include="reference.RFC.3553"?>


<!--draft-ietf-acme-caa-06; Active AD Eval-->
<reference anchor="ACME-CAA">
<front>
<title>CAA Record Extensions for Account URI and ACME Method Binding</title>

<author initials='H' surname='Landau' fullname='Hugo Landau'>
    <organization />
</author>

<date month='January' day='15' year='2019' />

<abstract><t>  The CAA DNS record allows a domain to communicate issuance policy to
   CAs, but only allows a domain to define policy with CA-level
   granularity.  However, the CAA specification also provides facilities
   for extension to admit more granular, CA-specific policy.  This
   specification defines two such parameters, one allowing specific
   accounts of a CA to be identified by URI and one allowing specific
   methods of domain control validation as defined by the ACME protocol
   to be required.</t></abstract>

</front>

<seriesInfo name='Work in Progress,' value='draft-ietf-acme-caa-06' />

</reference>

  <?rfc include="reference.RFC.3552"?>


<!--draft-vixie-dnsext-dns0x20-00; Expired -->
<reference anchor="DNS0x20">
<front>
<title>Use of Bit 0x20 in DNS Labels to Improve Transaction Identity</title>

<author initials='P' surname='Vixie' fullname='Paul Vixie'>
    <organization />
</author>

<author initials='D' surname='Dagon' fullname='David Dagon'>
    <organization />
</author>

<date month='March' day='18' year='2008' />

<abstract><t>The small (16-bit) size of the DNS transaction ID has made it a frequent target for forgery, with the unhappy result of many cache pollution vulnerabilities demonstrated throughout Internet history. Even with perfectly and unpredictably random transaction ID's, random and birthday attacks are still theoretically feasible.  This document describes a method by which an initiator can improve transaction identity using the 0x20 bit in DNS labels.</t></abstract>

</front>

<seriesInfo name='Work in Progress,' value='draft-vixie-dnsext-dns0x20-00' />

</reference>

  <?rfc include="reference.RFC.7132"?>
  <?rfc include="reference.RFC.1421"?>

    </references>

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

<t>In addition to the editors listed on the front page, this document has benefited
from contributions from a broad set of contributors, all the way back to its
inception.</t>

<t><list style="symbols">
  <t>Andrew Ayer, SSLMate</t>
  <t>Karthik Bhargavan, INRIA</t>
  <t>Peter Eckersley, EFF</t>
  <t>Alex Halderman, University of Michigan</t>
  <t>Sophie Herold, Hemio</t>
  <t>Tim Hollebeek, DigiCert</t>
  <t>Eric Rescorla, Mozilla</t>
  <t>Seth Schoen, EFF</t>
  <t>Roland Shoemaker, Let's Encrypt</t>
  <t>Rob Stradling, Sectigo</t>
  <t>Martin Thomson, Mozilla</t>
  <t>Jakub Warmuz, University of Oxford</t>
</list></t>

<t>This document draws on many concepts established by Eric Rescorla's "Automated
Certificate Issuance Protocol" draft.  Martin Thomson provided helpful guidance
in the use of HTTP.</t>

</section>
  </back>
</rfc>
