draft-ietf-acme-acme-03.txt   draft-ietf-acme-acme-04.txt 
Network Working Group R. Barnes Network Working Group R. Barnes
Internet-Draft Mozilla Internet-Draft Mozilla
Intended status: Standards Track J. Hoffman-Andrews Intended status: Standards Track J. Hoffman-Andrews
Expires: January 9, 2017 EFF Expires: May 4, 2017 EFF
J. Kasten J. Kasten
University of Michigan University of Michigan
July 08, 2016 October 31, 2016
Automatic Certificate Management Environment (ACME) Automatic Certificate Management Environment (ACME)
draft-ietf-acme-acme-03 draft-ietf-acme-acme-04
Abstract Abstract
Certificates in the Web's X.509 PKI (PKIX) are used for a number of Certificates in the Web's X.509 PKI (PKIX) are used for a number of
purposes, the most significant of which is the authentication of purposes, the most significant of which is the authentication of
domain names. Thus, certificate authorities in the Web PKI are domain names. Thus, certificate authorities in the Web PKI are
trusted to verify that an applicant for a certificate legitimately trusted to verify that an applicant for a certificate legitimately
represents the domain name(s) in the certificate. Today, this represents the domain name(s) in the certificate. Today, this
verification is done through a collection of ad hoc mechanisms. This verification is done through a collection of ad hoc mechanisms. This
document describes a protocol that a certificate authority (CA) and document describes a protocol that a certificate authority (CA) and
skipping to change at page 2, line 7 skipping to change at page 2, line 7
Internet-Drafts are working documents of the Internet Engineering Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF). Note that other groups may also distribute Task Force (IETF). Note that other groups may also distribute
working documents as Internet-Drafts. The list of current Internet- working documents as Internet-Drafts. The list of current Internet-
Drafts is at http://datatracker.ietf.org/drafts/current/. Drafts is at http://datatracker.ietf.org/drafts/current/.
Internet-Drafts are draft documents valid for a maximum of six months Internet-Drafts are draft documents valid for a maximum of six months
and may be updated, replaced, or obsoleted by other documents at any and may be updated, replaced, or obsoleted by other documents at any
time. It is inappropriate to use Internet-Drafts as reference time. It is inappropriate to use Internet-Drafts as reference
material or to cite them other than as "work in progress." material or to cite them other than as "work in progress."
This Internet-Draft will expire on January 9, 2017. This Internet-Draft will expire on May 4, 2017.
Copyright Notice Copyright Notice
Copyright (c) 2016 IETF Trust and the persons identified as the Copyright (c) 2016 IETF Trust and the persons identified as the
document authors. All rights reserved. document authors. All rights reserved.
This document is subject to BCP 78 and the IETF Trust's Legal This document is subject to BCP 78 and the IETF Trust's Legal
Provisions Relating to IETF Documents Provisions Relating to IETF Documents
(http://trustee.ietf.org/license-info) in effect on the date of (http://trustee.ietf.org/license-info) in effect on the date of
publication of this document. Please review these documents publication of this document. Please review these documents
skipping to change at page 2, line 31 skipping to change at page 2, line 31
the Trust Legal Provisions and are provided without warranty as the Trust Legal Provisions and are provided without warranty as
described in the Simplified BSD License. described in the Simplified BSD License.
Table of Contents Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3
2. Deployment Model and Operator Experience . . . . . . . . . . 4 2. Deployment Model and Operator Experience . . . . . . . . . . 4
3. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 6 3. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 6
4. Protocol Overview . . . . . . . . . . . . . . . . . . . . . . 6 4. Protocol Overview . . . . . . . . . . . . . . . . . . . . . . 6
5. Message Transport . . . . . . . . . . . . . . . . . . . . . . 8 5. Message Transport . . . . . . . . . . . . . . . . . . . . . . 8
5.1. HTTPS Requests . . . . . . . . . . . . . . . . . . . . . 9 5.1. HTTPS Requests . . . . . . . . . . . . . . . . . . . . . 8
5.2. Request Authentication . . . . . . . . . . . . . . . . . 9 5.2. Request Authentication . . . . . . . . . . . . . . . . . 9
5.3. Request URI Integrity . . . . . . . . . . . . . . . . . . 10 5.3. Equivalence of JWKs . . . . . . . . . . . . . . . . . . . 10
5.3.1. "url" (URL) JWS header parameter . . . . . . . . . . 10 5.4. Request URI Integrity . . . . . . . . . . . . . . . . . . 10
5.4. Replay protection . . . . . . . . . . . . . . . . . . . . 11 5.4.1. "url" (URL) JWS header parameter . . . . . . . . . . 11
5.4.1. Replay-Nonce . . . . . . . . . . . . . . . . . . . . 11 5.5. Replay protection . . . . . . . . . . . . . . . . . . . . 11
5.4.2. "nonce" (Nonce) JWS header parameter . . . . . . . . 12 5.5.1. Replay-Nonce . . . . . . . . . . . . . . . . . . . . 12
5.5. Rate limits . . . . . . . . . . . . . . . . . . . . . . . 12 5.5.2. "nonce" (Nonce) JWS header parameter . . . . . . . . 12
5.6. Errors . . . . . . . . . . . . . . . . . . . . . . . . . 12 5.6. Rate limits . . . . . . . . . . . . . . . . . . . . . . . 13
6. Certificate Management . . . . . . . . . . . . . . . . . . . 14 5.7. Errors . . . . . . . . . . . . . . . . . . . . . . . . . 13
6.1. Resources . . . . . . . . . . . . . . . . . . . . . . . . 14 6. Certificate Management . . . . . . . . . . . . . . . . . . . 15
6.1.1. Directory . . . . . . . . . . . . . . . . . . . . . . 16 6.1. Resources . . . . . . . . . . . . . . . . . . . . . . . . 15
6.1.2. Registration Objects . . . . . . . . . . . . . . . . 17 6.1.1. Directory . . . . . . . . . . . . . . . . . . . . . . 17
6.1.3. Application Objects . . . . . . . . . . . . . . . . . 19 6.1.2. Registration Objects . . . . . . . . . . . . . . . . 19
6.1.4. Authorization Objects . . . . . . . . . . . . . . . . 21 6.1.3. Application Objects . . . . . . . . . . . . . . . . . 20
6.2. Registration . . . . . . . . . . . . . . . . . . . . . . 23 6.1.4. Authorization Objects . . . . . . . . . . . . . . . . 23
6.2.1. Account Key Roll-over . . . . . . . . . . . . . . . . 25 6.2. Getting a Nonce . . . . . . . . . . . . . . . . . . . . . 25
6.2.2. Account deactivation . . . . . . . . . . . . . . . . 27 6.3. Registration . . . . . . . . . . . . . . . . . . . . . . 25
6.3. Applying for Certificate Issuance . . . . . . . . . . . . 28 6.3.1. Changes of Terms of Service . . . . . . . . . . . . . 28
6.3.1. Downloading the Certificate . . . . . . . . . . . . . 30 6.3.2. Account Key Roll-over . . . . . . . . . . . . . . . . 29
6.4. Identifier Authorization . . . . . . . . . . . . . . . . 31 6.3.3. Account deactivation . . . . . . . . . . . . . . . . 31
6.4.1. Responding to Challenges . . . . . . . . . . . . . . 33
6.4.2. Deactivating an Authorization . . . . . . . . . . . . 35 6.4. Applying for Certificate Issuance . . . . . . . . . . . . 32
6.5. Certificate Revocation . . . . . . . . . . . . . . . . . 36 6.4.1. Pre-Authorization . . . . . . . . . . . . . . . . . . 34
7. Identifier Validation Challenges . . . . . . . . . . . . . . 38 6.4.2. Downloading the Certificate . . . . . . . . . . . . . 36
7.1. Key Authorizations . . . . . . . . . . . . . . . . . . . 39 6.5. Identifier Authorization . . . . . . . . . . . . . . . . 38
7.2. HTTP . . . . . . . . . . . . . . . . . . . . . . . . . . 40 6.5.1. Responding to Challenges . . . . . . . . . . . . . . 39
7.3. TLS with Server Name Indication (TLS SNI) . . . . . . . . 42 6.5.2. Deactivating an Authorization . . . . . . . . . . . . 41
7.4. DNS . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 6.6. Certificate Revocation . . . . . . . . . . . . . . . . . 42
7.5. Out-of-Band . . . . . . . . . . . . . . . . . . . . . . . 45 7. Identifier Validation Challenges . . . . . . . . . . . . . . 44
8. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 46 7.1. Key Authorizations . . . . . . . . . . . . . . . . . . . 46
8.1. Well-Known URI for the HTTP Challenge . . . . . . . . . . 46 7.2. HTTP . . . . . . . . . . . . . . . . . . . . . . . . . . 46
8.2. Replay-Nonce HTTP Header . . . . . . . . . . . . . . . . 47 7.3. TLS with Server Name Indication (TLS SNI) . . . . . . . . 48
8.3. "url" JWS Header Parameter . . . . . . . . . . . . . . . 47 7.4. DNS . . . . . . . . . . . . . . . . . . . . . . . . . . . 50
8.4. "nonce" JWS Header Parameter . . . . . . . . . . . . . . 47 7.5. Out-of-Band . . . . . . . . . . . . . . . . . . . . . . . 52
8.5. URN Sub-namespace for ACME (urn:ietf:params:acme) . . . . 48 8. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 52
8.6. New Registries . . . . . . . . . . . . . . . . . . . . . 48 8.1. Well-Known URI for the HTTP Challenge . . . . . . . . . . 53
8.6.1. Error Codes . . . . . . . . . . . . . . . . . . . . . 48 8.2. Replay-Nonce HTTP Header . . . . . . . . . . . . . . . . 53
8.6.2. Resource Types . . . . . . . . . . . . . . . . . . . 49 8.3. "url" JWS Header Parameter . . . . . . . . . . . . . . . 53
8.6.3. Identifier Types . . . . . . . . . . . . . . . . . . 49 8.4. "nonce" JWS Header Parameter . . . . . . . . . . . . . . 53
8.6.4. Challenge Types . . . . . . . . . . . . . . . . . . . 50 8.5. URN Sub-namespace for ACME (urn:ietf:params:acme) . . . . 54
9. Security Considerations . . . . . . . . . . . . . . . . . . . 50 8.6. New Registries . . . . . . . . . . . . . . . . . . . . . 54
9.1. Threat model . . . . . . . . . . . . . . . . . . . . . . 51 8.6.1. Error Codes . . . . . . . . . . . . . . . . . . . . . 54
9.2. Integrity of Authorizations . . . . . . . . . . . . . . . 52 8.6.2. Resource Types . . . . . . . . . . . . . . . . . . . 55
9.3. Denial-of-Service Considerations . . . . . . . . . . . . 54 8.6.3. Identifier Types . . . . . . . . . . . . . . . . . . 55
9.4. Server-Side Request Forgery . . . . . . . . . . . . . . . 55 8.6.4. Challenge Types . . . . . . . . . . . . . . . . . . . 56
9.5. CA Policy Considerations . . . . . . . . . . . . . . . . 55 9. Security Considerations . . . . . . . . . . . . . . . . . . . 57
10. Operational Considerations . . . . . . . . . . . . . . . . . 56 9.1. Threat model . . . . . . . . . . . . . . . . . . . . . . 57
10.1. DNS over TCP . . . . . . . . . . . . . . . . . . . . . . 56 9.2. Integrity of Authorizations . . . . . . . . . . . . . . . 58
10.2. Default Virtual Hosts . . . . . . . . . . . . . . . . . 56 9.3. Denial-of-Service Considerations . . . . . . . . . . . . 60
10.3. Use of DNSSEC Resolvers . . . . . . . . . . . . . . . . 57 9.4. Server-Side Request Forgery . . . . . . . . . . . . . . . 61
11. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 57 9.5. CA Policy Considerations . . . . . . . . . . . . . . . . 62
12. References . . . . . . . . . . . . . . . . . . . . . . . . . 58 10. Operational Considerations . . . . . . . . . . . . . . . . . 62
12.1. Normative References . . . . . . . . . . . . . . . . . . 58 10.1. DNS over TCP . . . . . . . . . . . . . . . . . . . . . . 62
12.2. Informative References . . . . . . . . . . . . . . . . . 60 10.2. Default Virtual Hosts . . . . . . . . . . . . . . . . . 63
Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 61 10.3. Use of DNSSEC Resolvers . . . . . . . . . . . . . . . . 63
11. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 64
12. References . . . . . . . . . . . . . . . . . . . . . . . . . 64
12.1. Normative References . . . . . . . . . . . . . . . . . . 64
12.2. Informative References . . . . . . . . . . . . . . . . . 66
Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 67
1. Introduction 1. Introduction
Certificates in the Web PKI [RFC5280] are most commonly used to Certificates in the Web PKI [RFC5280] are most commonly used to
authenticate domain names. Thus, certificate authorities in the Web authenticate domain names. Thus, certificate authorities in the Web
PKI are trusted to verify that an applicant for a certificate PKI are trusted to verify that an applicant for a certificate
legitimately represents the domain name(s) in the certificate. legitimately represents the domain name(s) in the certificate.
Existing Web PKI certificate authorities tend to run on a set of ad Existing Web PKI certificate authorities tend to run on a set of ad
hoc protocols for certificate issuance and identity verification. A hoc protocols for certificate issuance and identity verification. A
skipping to change at page 6, line 44 skipping to change at page 6, line 50
In ACME, the account is represented by an account key pair. The "add In ACME, the account is represented by an account key pair. The "add
a domain" function is accomplished by authorizing the key pair for a a domain" function is accomplished by authorizing the key pair for a
given domain. Certificate issuance and revocation are authorized by given domain. Certificate issuance and revocation are authorized by
a signature with the key pair. a signature with the key pair.
The first phase of ACME is for the client to register with the ACME The first phase of ACME is for the client to register with the ACME
server. The client generates an asymmetric key pair and associates server. The client generates an asymmetric key pair and associates
this key pair with a set of contact information by signing the this key pair with a set of contact information by signing the
contact information. The server acknowledges the registration by contact information. The server acknowledges the registration by
replying with a registration object echoing the client's input. The replying with a registration object echoing the client's input.
server can also provide terms of service at this stage, which the
client can present to a human user.
Client Server Client Server
Contact Information Contact Information
Signature -------> Signature ------->
<------- Registration <------- Registration
Terms of Service
Once the client is registered, there are three major steps it needs Once the client is registered, there are three major steps it needs
to take to get a certificate: to take to get a certificate:
1. Apply for a certificate to be issued 1. Apply for a certificate to be issued
2. Fulfill the server's requirements for issuance 2. Fulfill the server's requirements for issuance
3. Finalize the application and request issuance 3. Await issuance and download the issued certificate
The client's application for a certificate describes the desired The client's application for a certificate describes the desired
certificate using a PKCS#10 Certificate Signing Request (CSR) plus a certificate using a PKCS#10 Certificate Signing Request (CSR) plus a
few additional fields that capture semantics that are not supported few additional fields that capture semantics that are not supported
in the CSR format. If the server is willing to consider issuing such in the CSR format. If the server is willing to consider issuing such
a certificate, it responds with a list of requirements that the a certificate, it responds with a list of requirements that the
client must satisfy before the certificate will be issued. client must satisfy before the certificate will be issued.
For example, in most cases, the server will require the client to For example, in most cases, the server will require the client to
demonstrate that it controls the identifiers in the requested demonstrate that it controls the identifiers in the requested
certificate. Because there are many different ways to validate certificate. Because there are many different ways to validate
possession of different types of identifiers, the server will choose possession of different types of identifiers, the server will choose
from an extensible set of challenges that are appropriate for the from an extensible set of challenges that are appropriate for the
identifier being claimed. The client responds with a set of identifier being claimed. The client responds with a set of
responses that tell the server which challenges the client has responses that tell the server which challenges the client has
completed. The server then validates the challenges to check that completed. The server then validates the challenges to check that
the client has accomplished the challenge. the client has accomplished the challenge.
Once the validation process is complete and the server is satisfied Once the validation process is complete and the server is satisfied
that the client has met its requirements, the server can either that the client has met its requirements, the server will issue the
proactively issue the requested certificate or wait for the client to requested certificate and make it available to the client.
request that the application be "finalized", at which point the
certificate will be issued and provided to the client.
Application Application
Signature -------> Signature ------->
<------- Requirements <------- Requirements
(e.g., Challenges) (e.g., Challenges)
Responses Responses
Signature -------> Signature ------->
<~~~~~~~~Validation~~~~~~~~> <~~~~~~~~Validation~~~~~~~~>
Finalize application
Signature ------->
<------- Certificate <------- Certificate
To revoke a certificate, the client simply sends a revocation request To revoke a certificate, the client simply sends a revocation request
indicating the certificate to be revoked, signed with an authorized indicating the certificate to be revoked, signed with an authorized
key pair. The server indicates whether the request has succeeded. key pair. The server indicates whether the request has succeeded.
Client Server Client Server
Revocation request Revocation request
Signature --------> Signature -------->
skipping to change at page 8, line 43 skipping to change at page 8, line 29
identifiers. For example, all of the identifier validation identifiers. For example, all of the identifier validation
challenges described in Section 7 below address validation of domain challenges described in Section 7 below address validation of domain
names. The use of ACME for other protocols will require further names. The use of ACME for other protocols will require further
specification, in order to describe how these identifiers are encoded specification, in order to describe how these identifiers are encoded
in the protocol, and what types of validation challenges the server in the protocol, and what types of validation challenges the server
might require. might require.
5. Message Transport 5. Message Transport
Communications between an ACME client and an ACME server are done Communications between an ACME client and an ACME server are done
over HTTPS, using JWS to provide some additional security properties over HTTPS, using JSON Web Signature (JWS) [RFC7515] to provide some
for messages sent from the client to the server. HTTPS provides additional security properties for messages sent from the client to
server authentication and confidentiality. With some ACME-specific the server. HTTPS provides server authentication and
extensions, JWS provides authentication of the client's request confidentiality. With some ACME-specific extensions, JWS provides
payloads, anti-replay protection, and integrity for the HTTPS request authentication of the client's request payloads, anti-replay
URI. protection, and integrity for the HTTPS request URI.
5.1. HTTPS Requests 5.1. HTTPS Requests
Each ACME function is accomplished by the client sending a sequence Each ACME function is accomplished by the client sending a sequence
of HTTPS requests to the server, carrying JSON messages of HTTPS requests to the server, carrying JSON messages
[RFC2818][RFC7159]. Use of HTTPS is REQUIRED. Clients SHOULD [RFC2818][RFC7159]. Use of HTTPS is REQUIRED. Clients SHOULD
support HTTP public key pinning [RFC7469], and servers SHOULD emit support HTTP public key pinning [RFC7469], and servers SHOULD emit
pinning headers. Each subsection of Section 6 below describes the pinning headers. Each subsection of Section 6 below describes the
message formats used by the function, and the order in which messages message formats used by the function, and the order in which messages
are sent. are sent.
In all HTTPS transactions used by ACME, the ACME client is the HTTPS In most HTTPS transactions used by ACME, the ACME client is the HTTPS
client and the ACME server is the HTTPS server. client and the ACME server is the HTTPS server. The ACME server acts
as an HTTP and HTTPS client when validating challenges via HTTP.
ACME clients SHOULD send a User-Agent header in accordance with
[RFC7231], including the name and version of the ACME software in
addition to the name and version of the underlying HTTP client
software.
ACME clients SHOULD send an Accept-Language header in accordance with
[RFC7231] to enable localization of error messages.
ACME servers that are intended to be generally accessible need to use ACME servers that are intended to be generally accessible need to use
Cross-Origin Resource Sharing (CORS) in order to be accessible from Cross-Origin Resource Sharing (CORS) in order to be accessible from
browser-based clients [W3C.CR-cors-20130129]. Such servers SHOULD browser-based clients [W3C.CR-cors-20130129]. Such servers SHOULD
set the Access-Control-Allow-Origin header field to the value "*". set the Access-Control-Allow-Origin header field to the value "*".
Binary fields in the JSON objects used by ACME are encoded using Binary fields in the JSON objects used by ACME are encoded using
base64url encoding described in [RFC4648] Section 5, according to the base64url encoding described in [RFC4648] Section 5, according to the
profile specified in JSON Web Signature [RFC7515] Section 2. This profile specified in JSON Web Signature [RFC7515] Section 2. This
encoding uses a URL safe character set. Trailing '=' characters MUST encoding uses a URL safe character set. Trailing '=' characters MUST
skipping to change at page 9, line 49 skipping to change at page 9, line 41
criteria: criteria:
o The JWS MUST be encoded using UTF-8 o The JWS MUST be encoded using UTF-8
o The JWS MUST NOT have the value "none" in its "alg" field o The JWS MUST NOT have the value "none" in its "alg" field
o The JWS Protected Header MUST include the following fields: o The JWS Protected Header MUST include the following fields:
* "alg" * "alg"
* "jwk" * "jwk" (only for requests to new-reg and revoke-cert resources)
* "kid" (for all other requests).
* "nonce" (defined below) * "nonce" (defined below)
* "url" (defined below) * "url" (defined below)
Note that this implies that GET requests are not authenticated. The "jwk" and "kid" fields are mutually exclusive. Servers MUST
Servers MUST NOT respond to GET requests for resources that might be reject requests that contain both.
considered sensitive.
For new-reg requests, and for revoke-cert requests authenticated by
certificate key, there MUST be a "jwk" field.
For all other requests, there MUST be a "kid" field. This field must
contain the account URI received by POSTing to the new-reg resource.
Note that authentication via signed POST implies that GET requests
are not authenticated. Servers MUST NOT respond to GET requests for
resources that might be considered sensitive.
In the examples below, JWS objects are shown in the JSON or flattened In the examples below, JWS objects are shown in the JSON or flattened
JSON serialization, with the protected header and payload expressed JSON serialization, with the protected header and payload expressed
as base64url(content) instead of the actual base64-encoded value, so as base64url(content) instead of the actual base64-encoded value, so
that the content is readable. Some fields are omitted for brevity, that the content is readable. Some fields are omitted for brevity,
marked with "...". marked with "...".
5.3. Request URI Integrity 5.3. Equivalence of JWKs
It is common in deployment the entity terminating TLS for HTTPS to be At some points in the protocol, it is necessary for the server to
different from the entity operating the logical HTTPS server, with a determine whether two JSON Web Key (JWK) [RFC7517] objects represent
"request routing" layer in the middle. For example, an ACME CA might the same key. In performing these checks, the server MUST consider
have a content delivery network terminate TLS connections from two JWKs to match if and only if they have the identical values in
clients so that it can inspect client requests for denial-of-service all fields included in the computation of a JWK thumbprint for that
protection. key. That is, the keys must have the same "kty" value and contain
identical values in the fields used in the computation of a JWK
thumbprint for that key type:
o "RSA": "n", "e"
o "EC": "crv", "x", "y"
Note that this comparison is equivalent to computing the JWK
thumbprints of the two keys and comparing thumbprints. The only
difference is that there is no requirement for a hash computation
(and thus it is independent of the choice of hash function) and no
risk of hash collision.
5.4. Request URI Integrity
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 protection.
These intermediaries can also change values in the request that are These intermediaries can also change values in the request that are
not signed in the HTTPS request, e.g., the request URI and headers. not signed in the HTTPS request, e.g., the request URI and headers.
ACME uses JWS to provide a limited integrity mechanism, which ACME uses JWS to provide a limited integrity mechanism, which
protects against an intermediary changing the request URI to another protects against an intermediary changing the request URI to another
ACME URI of a different type. (It does not protect against changing ACME URI of a different type. (It does not protect against changing
between URIs of the same type, e.g., from one authorization URI to between URIs of the same type, e.g., from one authorization URI to
another). another).
As noted above, all ACME request object carry a "url" parameter in As noted above, all ACME request objects carry a "url" parameter in
their protected header. This header parameter encodes the URL to their protected header. This header parameter encodes the URL to
which the client is directing the request. On receiving such an which the client is directing the request. On receiving such an
object in an HTTP request, the server MUST compare the "url" object in an HTTP request, the server MUST compare the "url"
parameter to the request URI. If the two do not match, then the parameter to the request URI. If the two do not match, then the
server MUST reject the request as unauthorized. server MUST reject the request as unauthorized.
Except for the directory resource, all ACME resources are addressed Except for the directory resource, all ACME resources are addressed
with URLs provided to the client by the server. In such cases, the with URLs provided to the client by the server. For these resources,
client MUST set the "url" field to the exact string provided by the the client MUST set the "url" field to the exact string provided by
server (rather than performing any re-encoding on the URL). 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" fields.
5.3.1. "url" (URL) JWS header parameter 5.4.1. "url" (URL) JWS header parameter
The "url" header parameter specifies the URL to which this JWS object The "url" header parameter specifies the URL to which this JWS object
is directed [RFC3986]. The "url" parameter MUST be carried in the is directed [RFC3986]. The "url" parameter MUST be carried in the
protected header of the JWS. The value of the "nonce" header MUST be protected header of the JWS. The value of the "url" header MUST be a
a JSON string representing the URL. JSON string representing the URL.
5.4. Replay protection 5.5. Replay protection
In order to protect ACME resources from any possible replay attacks, In order to protect ACME resources from any possible replay attacks,
ACME requests have a mandatory anti-replay mechanism. This mechanism ACME requests have a mandatory anti-replay mechanism. This mechanism
is based on the server maintaining a list of nonces that it has is based on the server maintaining a list of nonces that it has
issued to clients, and requiring any signed request from the client issued to clients, and requiring any signed request from the client
to carry such a nonce. to carry such a nonce.
An ACME server MUST include a Replay-Nonce header field in each An ACME server provides nonces to clients using the Replay-Nonce
successful response it provides to a client, with contents as header field, as specified below. The server MUST include a Replay-
specified below. In particular, the ACME server MUST provide a Nonce header field in every successful response to a POST request,
Replay-Nonce header field in response to a HEAD request for any valid and SHOULD provide it in error responses as well.
resource. (This allows clients to easily obtain a fresh nonce.) It
MAY also provide nonces in error responses.
Every JWS sent by an ACME client MUST include, in its protected Every JWS sent by an ACME client MUST include, in its protected
header, the "nonce" header parameter, with contents as defined below. header, the "nonce" header parameter, with contents as defined below.
As part of JWS verification, the ACME server MUST verify that the As part of JWS verification, the ACME server MUST verify that the
value of the "nonce" header is a value that the server previously value of the "nonce" header is a value that the server previously
provided in a Replay-Nonce header field. Once a nonce value has provided in a Replay-Nonce header field. Once a nonce value has
appeared in an ACME request, the server MUST consider it invalid, in appeared in an ACME request, the server MUST consider it invalid, in
the same way as a value it had never issued. the same way as a value it had never issued.
When a server rejects a request because its nonce value was When a server rejects a request because its nonce value was
unacceptable (or not present), it SHOULD provide HTTP status code 400 unacceptable (or not present), it SHOULD provide HTTP status code 400
(Bad Request), and indicate the ACME error code (Bad Request), and indicate the ACME error code
"urn:ietf:params:acme:error:badNonce". "urn:ietf:params:acme:error:badNonce". An error response with the
"badNonce" error code MUST include a Replay-Nonce header with a fresh
nonce. On receiving such a response, a client SHOULD retry the
request using the new nonce.
The precise method used to generate and track nonces is up to the The precise method used to generate and track nonces is up to the
server. For example, the server could generate a random 128-bit server. For example, the server could generate a random 128-bit
value for each response, keep a list of issued nonces, and strike value for each response, keep a list of issued nonces, and strike
nonces from this list as they are used. nonces from this list as they are used.
5.4.1. Replay-Nonce 5.5.1. Replay-Nonce
The "Replay-Nonce" header field includes a server-generated value The "Replay-Nonce" header field includes a server-generated value
that the server can use to detect unauthorized replay in future that the server can use to detect unauthorized replay in future
client requests. The server should generate the value provided in client requests. The server should generate the value provided in
Replay-Nonce in such a way that they are unique to each message, with Replay-Nonce in such a way that they are unique to each message, with
high probability. high probability.
The value of the Replay-Nonce field MUST be an octet string encoded The value of the Replay-Nonce field MUST be an octet string encoded
according to the base64url encoding described in Section 2 of according to the base64url encoding described in Section 2 of
[RFC7515]. Clients MUST ignore invalid Replay-Nonce values. [RFC7515]. Clients MUST ignore invalid Replay-Nonce values.
base64url = [A-Z] / [a-z] / [0-9] / "-" / "_" base64url = [A-Z] / [a-z] / [0-9] / "-" / "_"
Replay-Nonce = *base64url Replay-Nonce = *base64url
The Replay-Nonce header field SHOULD NOT be included in HTTP request The Replay-Nonce header field SHOULD NOT be included in HTTP request
messages. messages.
5.4.2. "nonce" (Nonce) JWS header parameter 5.5.2. "nonce" (Nonce) JWS header parameter
The "nonce" header parameter provides a unique value that enables the The "nonce" header parameter provides a unique value that enables the
verifier of a JWS to recognize when replay has occurred. The "nonce" verifier of a JWS to recognize when replay has occurred. The "nonce"
header parameter MUST be carried in the protected header of the JWS. header parameter MUST be carried in the protected header of the JWS.
The value of the "nonce" header parameter MUST be an octet string, The value of the "nonce" header parameter MUST be an octet string,
encoded according to the base64url encoding described in Section 2 of encoded according to the base64url encoding described in Section 2 of
[RFC7515]. If the value of a "nonce" header parameter is not valid [RFC7515]. If the value of a "nonce" header parameter is not valid
according to this encoding, then the verifier MUST reject the JWS as according to this encoding, then the verifier MUST reject the JWS as
malformed. malformed.
5.5. Rate limits 5.6. Rate limits
Creation of resources can be rate limited to ensure fair usage and Creation of resources can be rate limited to ensure fair usage and
prevent abuse. Once the rate limit is exceeded, the server MUST prevent abuse. Once the rate limit is exceeded, the server MUST
respond with an error with the code "rateLimited". Additionally, the respond with an error with the code "rateLimited". Additionally, the
server SHOULD send a "Retry-After" header indicating when the current server SHOULD send a "Retry-After" header indicating when the current
request may succeed again. If multiple rate limits are in place, request may succeed again. If multiple rate limits are in place,
that is the time where all rate limits allow access again for the that is the time where all rate limits allow access again for the
current request with exactly the same parameters. current request with exactly the same parameters.
In addition to the human readable "detail" field of the error In addition to the human readable "detail" field of the error
response, the server MAY send one or multiple tokens in the "Link" response, the server MAY send one or multiple tokens in the "Link"
header pointing to documentation about the specific hit rate limits header pointing to documentation about the specific hit rate limits
using the "rate-limit" relation. using the "rate-limit" relation.
5.6. Errors 5.7. Errors
Errors can be reported in ACME both at the HTTP layer and within ACME Errors can be reported in ACME both at the HTTP layer and within ACME
payloads. ACME servers can return responses with an HTTP error payloads. ACME servers can return responses with an HTTP error
response code (4XX or 5XX). For example: If the client submits a response code (4XX or 5XX). For example: If the client submits a
request using a method not allowed in this document, then the server request using a method not allowed in this document, then the server
MAY return status code 405 (Method Not Allowed). MAY return status code 405 (Method Not Allowed).
When the server responds with an error status, it SHOULD provide When the server responds with an error status, it SHOULD provide
additional information using problem document [RFC7807]. To additional information using problem document [RFC7807]. To
facilitate automatic response to errors, this document defines the facilitate automatic response to errors, this document defines the
skipping to change at page 13, line 43 skipping to change at page 14, line 43
| rateLimited | The request exceeds a rate limit | | rateLimited | The request exceeds a rate limit |
| | | | | |
| invalidContact | The contact URI for a registration was | | invalidContact | The contact URI for a registration was |
| | invalid | | | invalid |
| | | | | |
| rejectedIdentifier | The server will not issue for the | | rejectedIdentifier | The server will not issue for the |
| | identifier | | | identifier |
| | | | | |
| unsupportedIdentifier | Identifier is not supported, but may be | | unsupportedIdentifier | Identifier is not supported, but may be |
| | in future | | | in future |
| | |
| agreementRequired | The client must agree to terms before |
| | proceeding |
+-----------------------+-------------------------------------------+ +-----------------------+-------------------------------------------+
This list is not exhaustive. The server MAY return errors whose This list is not exhaustive. The server MAY return errors whose
"type" field is set to a URI other than those defined above. Servers "type" field is set to a URI other than those defined above. Servers
MUST NOT use the ACME URN namespace for errors other than the MUST NOT use the ACME URN namespace for errors other than the
standard types. Clients SHOULD display the "detail" field of such standard types. Clients SHOULD display the "detail" field of such
errors. errors.
Authorization and challenge objects can also contain error Authorization and challenge objects can also contain error
information to indicate why the server was unable to validate information to indicate why the server was unable to validate
skipping to change at page 14, line 31 skipping to change at page 15, line 31
o Certificate Revocation o Certificate Revocation
6.1. Resources 6.1. Resources
ACME is structured as a REST application with a few types of ACME is structured as a REST application with a few types of
resources: resources:
o Registration resources, representing information about an account o Registration resources, representing information about an account
o Application resources, represnting an account's requests to issue o Application resources, representing an account's requests to issue
certificates certificates
o Authorization resources, representing an account's authorization o Authorization resources, representing an account's authorization
to act for an identifier to act for an identifier
o Challenge resources, representing a challenge to prove control of o Challenge resources, representing a challenge to prove control of
an identifier an identifier
o Certificate resources, representing issued certificates o Certificate resources, representing issued certificates
o A "directory" resource o A "directory" resource
o A "new-nonce" resource
o A "new-registration" resource o A "new-registration" resource
o A "new-application" resource o A "new-application" resource
o A "revoke-certificate" resource o A "revoke-certificate" resource
o A "key-change" resource o A "key-change" resource
For the "new-X" resources above, the server MUST have exactly one The server MUST provide "directory" and "new-nonce" resources.
resource for each function. This resource may be addressed by
multiple URIs, but all must provide equivalent functionality. For the singular resources above ("directory", "new-nonce", "new-
registration", "new-application", "revoke-certificate", and "key-
change") the resource may be addressed by multiple URIs, but all must
provide equivalent functionality.
ACME uses different URIs for different management functions. Each ACME uses different URIs for different management functions. Each
function is listed in a directory along with its corresponding URI, function is listed in a directory along with its corresponding URI,
so clients only need to be configured with the directory URI. These so clients only need to be configured with the directory URI. These
URIs are connected by a few different link relations [RFC5988]. URIs are connected by a few different link relations [RFC5988].
The "up" link relation is used with challenge resources to indicate The "up" link relation is used with challenge resources to indicate
the authorization resource to which a challenge belongs. It is also the authorization resource to which a challenge belongs. It is also
used from certificate resources to indicate a resource from which the used from certificate resources to indicate a resource from which the
client may fetch a chain of CA certificates that could be used to client may fetch a chain of CA certificates that could be used to
skipping to change at page 15, line 29 skipping to change at page 16, line 32
The "directory" link relation is present on all resources other than The "directory" link relation is present on all resources other than
the directory and indicates the directory URL. the directory and indicates the directory URL.
The following diagram illustrates the relations between resources on The following diagram illustrates the relations between resources on
an ACME server. For the most part, these relations are expressed by an ACME server. For the most part, these relations are expressed by
URLs provided as strings in the resources' JSON representations. URLs provided as strings in the resources' JSON representations.
Lines with labels in quotes indicate HTTP link relations Lines with labels in quotes indicate HTTP link relations
directory directory
| |
|--> new-nonce
| |
---------------------------------------------------- --------------------------------------------------+
| | | | | | |
| | | | | | |
V V V V V V V
new-reg new-app revoke-cert new-reg new-authz new-app revoke-cert
| | ^ | | | ^
| | | "revoke" | | | | "revoke"
V V | V | V |
reg -------------> app -------------> cert ---------+ reg | app ---------> cert ---------+
| ^ | | | ^ |
| | "up" | "up" | | | "up" | "up"
V | V | V | V
authz cert-chain +------> authz cert-chain
| ^ | ^
| | "up" | | "up"
V | V |
challenge challenge
The following table illustrates a typical sequence of requests The following table illustrates a typical sequence of requests
required to establish a new account with the server, prove control of required to establish a new account with the server, prove control of
an identifier, issue a certificate, and fetch an updated certificate an identifier, issue a certificate, and fetch an updated certificate
some time after issuance. The "->" is a mnemonic for a Location some time after issuance. The "->" is a mnemonic for a Location
header pointing to a created resource. header pointing to a created resource.
+--------------------+----------------+------------+ +--------------------+----------------+------------+
| Action | Request | Response | | Action | Request | Response |
+--------------------+----------------+------------+ +--------------------+----------------+------------+
| Get a nonce | HEAD new-nonce | 200 |
| | | |
| Register | POST new-reg | 201 -> reg | | Register | POST new-reg | 201 -> reg |
| | | | | | | |
| Apply for a cert | POST new-app | 201 -> app | | Apply for a cert | POST new-app | 201 -> app |
| | | | | | | |
| Fetch challenges | GET authz | 200 | | Fetch challenges | GET authz | 200 |
| | | | | | | |
| Answer challenges | POST challenge | 200 | | Answer challenges | POST challenge | 200 |
| | | | | | | |
| Poll for status | GET authz | 200 | | Poll for status | GET authz | 200 |
| | | | | | | |
skipping to change at page 16, line 39 skipping to change at page 18, line 8
In order to help clients configure themselves with the right URIs for In order to help clients configure themselves with the right URIs for
each ACME operation, ACME servers provide a directory object. This each ACME operation, ACME servers provide a directory object. This
should be the only URL needed to configure clients. It is a JSON should be the only URL needed to configure clients. It is a JSON
dictionary, whose keys are drawn from the following table and whose dictionary, whose keys are drawn from the following table and whose
values are the corresponding URLs. values are the corresponding URLs.
+-------------+--------------------+ +-------------+--------------------+
| Key | URL in value | | Key | URL in value |
+-------------+--------------------+ +-------------+--------------------+
| new-nonce | New nonce |
| | |
| new-reg | New registration | | new-reg | New registration |
| | | | | |
| new-app | New application | | new-app | New application |
| | | | | |
| new-authz | New authorization |
| | |
| revoke-cert | Revoke certificate | | revoke-cert | Revoke certificate |
| | | | | |
| key-change | Key change | | key-change | Key change |
+-------------+--------------------+ +-------------+--------------------+
There is no constraint on the actual URI of the directory except that There is no constraint on the actual URI of the directory except that
it should be different from the other ACME server resources' URIs, it should be different from the other ACME server resources' URIs,
and that it should not clash with other services. For instance: and that it should not clash with other services. For instance:
o a host which function as both an ACME and Web server may want to o a host which function as both an ACME and Web server may want to
skipping to change at page 17, line 37 skipping to change at page 19, line 9
[RFC6844]. This allows clients to determine the correct issuer [RFC6844]. This allows clients to determine the correct issuer
domain name to use when configuring CAA record. domain name to use when configuring CAA record.
Clients access the directory by sending a GET request to the Clients access the directory by sending a GET request to the
directory URI. directory URI.
HTTP/1.1 200 OK HTTP/1.1 200 OK
Content-Type: application/json Content-Type: application/json
{ {
"new-nonce": "https://example.com/acme/new-nonce",
"new-reg": "https://example.com/acme/new-reg", "new-reg": "https://example.com/acme/new-reg",
"new-app": "https://example.com/acme/new-app", "new-app": "https://example.com/acme/new-app",
"new-authz": "https://example.com/acme/new-authz",
"revoke-cert": "https://example.com/acme/revoke-cert", "revoke-cert": "https://example.com/acme/revoke-cert",
"key-change": "https://example.com/acme/key-change", "key-change": "https://example.com/acme/key-change",
"meta": { "meta": {
"terms-of-service": "https://example.com/acme/terms", "terms-of-service": "https://example.com/acme/terms",
"website": "https://www.example.com/", "website": "https://www.example.com/",
"caa-identities": ["example.com"] "caa-identities": ["example.com"]
} }
} }
6.1.2. Registration Objects 6.1.2. Registration Objects
An ACME registration resource represents a set of metadata associated An ACME registration resource represents a set of metadata associated
to an account key pair. Registration resources have the following to an account key pair. Registration resources have the following
structure: structure:
key (required, dictionary): The public key of the account key pair, key (required, dictionary): The public key of the account key pair,
encoded as a JSON Web Key object [RFC7517]. encoded as a JSON Web Key object [RFC7517]. This field is not
updateable by the client.
status (required, string): "good" or "deactivated" status (required, string): The status of this registration.
Possible values are: "valid", "deactivated", and "revoked".
"deactivated" should be used to indicate user initiated
deactivation whereas "revoked" should be used to indicate
administratively initiated deactivation.
contact (optional, array of string): An array of URIs that the contact (optional, array of string): An array of URIs that the
server can use to contact the client for issues related to this server can use to contact the client for issues related to this
authorization. For example, the server may wish to notify the authorization. For example, the server may wish to notify the
client about server-initiated revocation. client about server-initiated revocation.
agreement (optional, string): A URI referring to a subscriber terms-of-service-agreed (optional, boolean): Including this field in
agreement or terms of service provided by the server (see below). a new-registration request, with a value of true, indicates the
Including this field indicates the client's agreement with the client's agreement with the terms of service. This field is not
referenced terms. updateable by the client.
applications (required, string): A URI from which a list of applications (required, string): A URI from which a list of
authorizations submitted by this account can be fetched via a GET authorizations submitted by this account can be fetched via a GET
request. The result of the GET request MUST be a JSON object request. The result of the GET request MUST be a JSON object
whose "applications" field is an array of strings, where each whose "applications" field is an array of strings, where each
string is the URI of an authorization belonging to this string is the URI of an authorization belonging to this
registration. The server SHOULD include pending applications, and registration. The server SHOULD include pending applications, and
SHOULD NOT include applications that are invalid. The server MAY SHOULD NOT include applications that are invalid. The server MAY
return an incomplete list, along with a Link header with link return an incomplete list, along with a Link header with link
relation "next" indicating a URL to retrieve further entries. relation "next" indicating a URL to retrieve further entries.
This field is not updateable by the client.
certificates (required, string): A URI from which a list of
certificates issued for this account can be fetched via a GET
request. The result of the GET request MUST be a JSON object
whose "certificates" field is an array of strings, where each
string is the URI of a certificate. The server SHOULD NOT include
expired or revoked certificates. The server MAY return an
incomplete list, along with a Link header with link relation
"next" indicating a URL to retrieve further entries.
{ {
"contact": [ "contact": [
"mailto:cert-admin@example.com", "mailto:cert-admin@example.com",
"tel:+12025551212" "tel:+12025551212"
], ],
"agreement": "https://example.com/acme/terms", "terms-of-service-agreed": true,
"authorizations": "https://example.com/acme/reg/1/authz", "applications": "https://example.com/acme/reg/1/apps"
"certificates": "https://example.com/acme/reg/1/cert" }
6.1.2.1. Applications List
Each registration object includes an applications URI from which a
list of applications created by the registration can be fetched via
GET request. The result of the GET request MUST be a JSON object
whose "applications" field is an array of URIs, each identifying an
applications belonging to the registration. The server SHOULD
include pending applications, and SHOULD NOT include applications
that are invalid in the array of URIs. The server MAY return an
incomplete list, along with a Link header with link relation "next"
indicating a URL to retrieve further entries.
HTTP/1.1 200 OK
Content-Type: application/json
Link: href="/acme/reg/1/apps?cursor=2", rel="next"
{
"applications": [
"https://example.com/acme/reg/1/apps/1",
"https://example.com/acme/reg/1/apps/2",
/* 47 more URLs not shown for example brevity */
"https://example.com/acme/reg/1/apps/50"
]
} }
6.1.3. Application Objects 6.1.3. Application Objects
An ACME registration resource represents a client's request for a An ACME application object represents a client's request for a
certificate, and is used to track the progress of that application certificate, and is used to track the progress of that application
through to issuance. Thus, the object contains information about the through to issuance. Thus, the object contains information about the
requested certificate, the server's requirements, and any requested certificate, the server's requirements, and any
certificates that have resulted from this application. certificates that have resulted from this application.
status (required, string): The status of this authorization. status (required, string): The status of this application. Possible
Possible values are: "unknown", "pending", "processing", "valid", values are: "pending", "valid", and "invalid".
and "invalid".
expires (optional, string): The timestamp after which the server expires (optional, string): The timestamp after which the server
will consider this application invalid, encoded in the format will consider this application invalid, encoded in the format
specified in RFC 3339 [RFC3339]. This field is REQUIRED for specified in RFC 3339 [RFC3339]. This field is REQUIRED for
objects with "pending" or "valid" in the status field. objects with "pending" or "valid" in the status field.
csr (required, string): A CSR encoding the parameters for the csr (required, string): A CSR encoding the parameters for the
certificate being requested [RFC2986]. The CSR is sent in the certificate being requested [RFC2986]. The CSR is sent in the
Base64url-encoded version of the DER format. (Note: This field Base64url-encoded version of the DER format. (Note: This field
uses the same modified Base64 encoding rules used elsewhere in uses the same modified Base64 encoding rules used elsewhere in
skipping to change at page 20, line 29 skipping to change at page 22, line 29
{ {
"type": "out-of-band", "type": "out-of-band",
"status": "pending", "status": "pending",
"url": "https://example.com/acme/payment/1234" "url": "https://example.com/acme/payment/1234"
} }
] ]
"certificate": "https://example.com/acme/cert/1234" "certificate": "https://example.com/acme/cert/1234"
} }
[[ Open issue: There are two possible behaviors for the CA here.
Either (a) the CA automatically issues once all the requirements are
fulfilled, or (b) the CA waits for confirmation from the client that
it should issue. If we allow both, we will need a signal in the
application object of whether confirmation is required. I would
prefer that auto-issue be the default, which would imply a syntax
like "confirm": true ]]
[[ Open issue: Should this syntax allow multiple certificates? That
would support reissuance / renewal in a straightforward way,
especially if the CSR / notBefore / notAfter could be updated. ]]
The elements of the "requirements" array are immutable once set, The elements of the "requirements" array are immutable once set,
except for their "status" fields. If any other part of the object except for their "status" fields. If any other part of the object
changes after the object is created, the client MUST consider the changes after the object is created, the client MUST consider the
application invalid. application invalid.
The "requirements" array in the challenge SHOULD reflect everything The "requirements" array in the challenge SHOULD reflect everything
that the CA required the client to do before issuance, even if some that the CA required the client to do before issuance, even if some
requirements were fulfilled in earlier applications. For example, if requirements were fulfilled in earlier applications. For example, if
a CA allows multiple applications to be fufilled based on a single a CA allows multiple applications to be fufilled based on a single
authorization transaction, then it must reflect that authorization in authorization transaction, then it must reflect that authorization in
all of the applications. all of the applications.
Each entry in the "requirements" array expresses a requirement from Each entry in the "requirements" array expresses a requirement from
the CA for the client to takek a particular action. All requirements the CA for the client to take a particular action. All requirements
objects have the following basic fields: objects have the following basic fields:
type (required, string): The type of requirement (see below for type (required, string): The type of requirement (see below for
defined types) defined types)
status (required, string): The status of this requirement. Possible status (required, string): The status of this requirement. Possible
values are: "pending", "valid", and "invalid". values are: "pending", "valid", and "invalid".
All additional fields are specified by the requirement type. All additional fields are specified by the requirement type.
skipping to change at page 21, line 28 skipping to change at page 23, line 16
A requirement with type "authorization" requests that the ACME client A requirement with type "authorization" requests that the ACME client
complete an authorization transaction. The server specifies the complete an authorization transaction. The server specifies the
authorization by pre-provisioning a pending authorization resource authorization by pre-provisioning a pending authorization resource
and providing the URI for this resource in the requirement. and providing the URI for this resource in the requirement.
url (required, string): The URL for the authorization resource url (required, string): The URL for the authorization resource
To fulfill this requirement, the ACME client should fetch the To fulfill this requirement, the ACME client should fetch the
authorization object from the indicated URL, then follow the process authorization object from the indicated URL, then follow the process
for obtaining authorization as specified in Section 6.4. for obtaining authorization as specified in Section 6.5.
6.1.3.2. Out-of-Band Requirement 6.1.3.2. Out-of-Band Requirement
A requirement with type "out-of-band" requests that the ACME client A requirement with type "out-of-band" requests that the ACME client
have a human user visit a web page in order to receive further have a human user visit a web page in order to receive further
instructions for how to fulfill the requirement. The requirement instructions for how to fulfill the requirement. The requirement
object provides a URI for the web page to be visited. object provides a URI for the web page to be visited.
url (required, string): The URL to be visited. The scheme of this url (required, string): The URL to be visited. The scheme of this
URL MUST be "http" or "https" URL MUST be "http" or "https"
To fulfill this requirement, the ACME client should direct the user To fulfill this requirement, the ACME client should direct the user
to the indicated web page. to the indicated web page.
6.1.4. Authorization Objects 6.1.4. Authorization Objects
An ACME authorization object represents server's authorization for an An ACME authorization object represents a server's authorization for
account to represent an identifier. In addition to the identifier, an account to represent an identifier. In addition to the
an authorization includes several metadata fields, such as the status identifier, an authorization includes several metadata fields, such
of the authorization (e.g., "pending", "valid", or "revoked") and as the status of the authorization (e.g., "pending", "valid", or
which challenges were used to validate possession of the identifier. "revoked") and which challenges were used to validate possession of
the identifier.
The structure of an ACME authorization resource is as follows: The structure of an ACME authorization resource is as follows:
identifier (required, dictionary of string): The identifier that the identifier (required, dictionary of string): The identifier that the
account is authorized to represent account is authorized to represent
type (required, string): The type of identifier. type (required, string): The type of identifier.
value (required, string): The identifier itself. value (required, string): The identifier itself.
status (required, string): The status of this authorization. status (required, string): The status of this authorization.
Possible values are: "unknown", "pending", "processing", "valid", Possible values are: "pending", "processing", "valid", "invalid"
"invalid" and "revoked". If this field is missing, then the and "revoked". If this field is missing, then the default value
default value is "pending". is "pending".
expires (optional, string): The timestamp after which the server expires (optional, string): The timestamp after which the server
will consider this authorization invalid, encoded in the format will consider this authorization invalid, encoded in the format
specified in RFC 3339 [RFC3339]. This field is REQUIRED for specified in RFC 3339 [RFC3339]. This field is REQUIRED for
objects with "valid" in the "status field. objects with "valid" in the "status" field.
scope (optional, string): If this field is present, then it MUST scope (optional, string): If this field is present, then it MUST
contain a URI for an application resource, such that this contain a URI for an application resource, such that this
authorization is only valid for that resource. If this field is authorization is only valid for that resource. If this field is
absent, then the CA MUST consider this authorization valid for all absent, then the CA MUST consider this authorization valid for all
applications until the authorization expires. [[ Open issue: More applications until the authorization expires. [[ Open issue: More
flexible scoping? ]] flexible scoping? ]]
challenges (required, array): The challenges that the client needs challenges (required, array): The challenges that the client can
to fulfill in order to prove possession of the identifier (for fulfill in order to prove possession of the identifier (for
pending authorizations). For final authorizations, the challenges pending authorizations). For final authorizations, the challenges
that were used. Each array entry is a dictionary with parameters that were used. Each array entry is a dictionary with parameters
required to validate the challenge, as specified in Section 7. required to validate the challenge, as specified in Section 7. A
client should attempt to fulfill at most one of these challenges,
combinations (optional, array of arrays of integers): A collection and a server should consider any one of the challenges sufficient
of sets of challenges, each of which would be sufficient to prove to make the authorization valid.
possession of the identifier. Clients complete a set of
challenges that covers at least one set in this array. Challenges
are identified by their indices in the challenges array. If no
"combinations" element is included in an authorization object, the
client completes all challenges.
The only type of identifier defined by this specification is a fully- The only type of identifier defined by this specification is a fully-
qualified domain name (type: "dns"). The value of the identifier qualified domain name (type: "dns"). The value of the identifier
MUST be the ASCII representation of the domain name. Wildcard domain MUST be the ASCII representation of the domain name. If a domain
names (with "*" as the first label) MUST NOT be included in name contains Unicode characters it MUST be encoded using the rules
authorization requests. defined in [RFC3492]. Servers MUST verify any identifier values that
begin with the ASCII Compatible Encoding prefix "xn-" as defined in
[RFC5890] are properly encoded. Wildcard domain names (with "*" as
the first label) MUST NOT be included in authorization requests.
{ {
"status": "valid", "status": "valid",
"expires": "2015-03-01T14:09:00Z", "expires": "2015-03-01T14:09:00Z",
"identifier": { "identifier": {
"type": "dns", "type": "dns",
"value": "example.org" "value": "example.org"
}, },
"challenges": [ "challenges": [
{ {
"type": "http-01", "type": "http-01",
"status": "valid", "status": "valid",
"validated": "2014-12-01T12:05:00Z", "validated": "2014-12-01T12:05:00Z",
"keyAuthorization": "SXQe-2XODaDxNR...vb29HhjjLPSggwiE" "keyAuthorization": "SXQe-2XODaDxNR...vb29HhjjLPSggwiE"
} }
] ]
} }
6.2. Registration 6.2. Getting a Nonce
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.
To get a fresh nonce, the client sends a HEAD request to the new-
nonce 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 SHOULD also respond to GET requests
for this resource, returning an empty body (while still providing a
Replay-Nonce header).
HEAD /acme/new-nonce HTTP/1.1
Host: example.com
HTTP/1.1 200 OK
Replay-Nonce: oFvnlFP1wIhRlYS2jTaXbA
Cache-Control: no-store
Caching of responses from the new-nonce resource can cause clients to
be unable to communicate with the ACME server. The server MUST
include a Cache-Control header field with the "no-store" directive in
responses for the new-nonce resource, in order to prevent caching of
this resource.
6.3. Registration
A client creates a new account with the server by sending a POST A client creates a new account with the server by sending a POST
request to the server's new-registration URI. The body of the request to the server's new-registration URI. The body of the
request is a stub registration object containing only the "contact" request is a stub registration object containing only the "contact"
field. field.
POST /acme/new-reg HTTP/1.1 POST /acme/new-reg HTTP/1.1
Host: example.com Host: example.com
Content-Type: application/jose+json Content-Type: application/jose+json
{ {
"protected": base64url({ "protected": base64url({
"alg": "ES256", "alg": "ES256",
"jwk": {...}, "jwk": {...},
"nonce": "6S8IqOGY7eL2lsGoTZYifg", "nonce": "6S8IqOGY7eL2lsGoTZYifg",
"url": "https://example.com/acme/new-reg" "url": "https://example.com/acme/new-reg"
}) })
"payload": base64url({ "payload": base64url({
"terms-of-service-agreed": true,
"contact": [ "contact": [
"mailto:cert-admin@example.com", "mailto:cert-admin@example.com",
"tel:+12025551212" "tel:+12025551212"
] ]
}), }),
"signature": "RZPOnYoPs1PhjszF...-nh6X1qtOFPB519I" "signature": "RZPOnYoPs1PhjszF...-nh6X1qtOFPB519I"
} }
The server MUST ignore any values provided in the "key", The server MUST ignore any values provided in the "key", and
"authorizations", and "certificates" fields in registration bodies "applications" fields in registration bodies sent by the client, as
sent by the client, as well as any other fields that it does not well as any other fields that it does not recognize. If new fields
recognize. If new fields are specified in the future, the are specified in the future, the specification of those fields MUST
specification of those fields MUST describe whether they may be describe whether they may be provided by the client.
provided by the client.
The server SHOULD validate that the contact URLs in the "contact"
field are valid and supported by the server. If the client provides
the server with an invalid or unsupported contact URL, then the
server MUST return an error of type "invalidContact", with a
description describing the error and what types of contact URL the
server considers acceptable.
The server creates a registration object with the included contact The server creates a registration object with the included contact
information. The "key" element of the registration is set to the information. The "key" element of the registration is set to the
public key used to verify the JWS (i.e., the "jwk" element of the JWS public key used to verify the JWS (i.e., the "jwk" element of the JWS
header). The server returns this registration object in a 201 header). The server returns this registration object in a 201
(Created) response, with the registration URI in a Location header (Created) response, with the registration URI in a Location header
field. field.
If the server already has a registration object with the provided If the server already has a registration object with the provided
account key, then it MUST return a 409 (Conflict) response and account key, then it MUST return a 200 (OK) response and provide the
provide the URI of that registration in a Location header field. URI of that registration in a Content-Location header field. This
This allows a client that has an account key but not the allows a client that has an account key but not the corresponding
corresponding registration URI to recover the registration URI. registration URI to recover the registration URI.
If the server wishes to present the client with terms under which the If the server wishes to present the client with terms under which the
ACME service is to be used, it MUST indicate the URI where such terms ACME service is to be used, it MUST indicate the URI where such terms
can be accessed in a Link header with link relation "terms-of- can be accessed in the "terms-of-service" subfield of the "meta"
service". As noted above, the client may indicate its agreement with field in the directory object, and the server MUST reject new-
these terms by updating its registration to include the "agreement" registration requests that do not have the "terms-of-service-agreed"
field, with the terms URI as its value. When these terms change in a set to "true".
way that requires an agreement update, the server MUST use a
different URI in the Link header.
HTTP/1.1 201 Created HTTP/1.1 201 Created
Content-Type: application/json Content-Type: application/json
Replay-Nonce: D8s4D2mLs8Vn-goWuPQeKA
Location: https://example.com/acme/reg/asdf Location: https://example.com/acme/reg/asdf
Link: <https://example.com/acme/terms>;rel="terms-of-service"
Link: <https://example.com/acme/some-directory>;rel="directory" Link: <https://example.com/acme/some-directory>;rel="directory"
{ {
"key": { /* JWK from JWS header */ }, "key": { /* JWK from JWS header */ },
"status": "good", "status": "valid",
"contact": [ "contact": [
"mailto:cert-admin@example.com", "mailto:cert-admin@example.com",
"tel:+12025551212" "tel:+12025551212"
] ]
} }
If the client wishes to update this information in the future, it If the client wishes to update this information in the future, it
sends a POST request with updated information to the registration sends a POST request with updated information to the registration
URI. The server MUST ignore any updates to the "key", URI. The server MUST ignore any updates to the "key", or
"authorizations, or "certificates" fields, and MUST verify that the "applications" fields or any other fields it does not recognize. The
request is signed with the private key corresponding to the "key" server MUST verify that the request is signed with the private key
field of the request before updating the registration. corresponding to the "key" field of the request before updating the
registration.
For example, to update the contact information in the above For example, to update the contact information in the above
registration, the client could send the following request: registration, the client could send the following request:
POST /acme/reg/asdf HTTP/1.1 POST /acme/reg/asdf HTTP/1.1
Host: example.com Host: example.com
Content-Type: application/jose+json Content-Type: application/jose+json
{ {
"protected": base64url({ "protected": base64url({
"alg": "ES256", "alg": "ES256",
"jwk": {...}, "kid": "https://example.com/acme/reg/asdf",
"nonce": "ax5RnthDqp_Yf4_HZnFLmA", "nonce": "ax5RnthDqp_Yf4_HZnFLmA",
"url": "https://example.com/acme/reg/asdf" "url": "https://example.com/acme/reg/asdf"
}) })
"payload": base64url({ "payload": base64url({
"contact": [ "contact": [
"mailto:certificates@example.com", "mailto:certificates@example.com",
"tel:+12125551212" "tel:+12125551212"
] ]
}), }),
"signature": "hDXzvcj8T6fbFbmn...rDzXzzvzpRy64N0o" "signature": "hDXzvcj8T6fbFbmn...rDzXzzvzpRy64N0o"
} }
Servers SHOULD NOT respond to GET requests for registration resources Servers SHOULD NOT respond to GET requests for registration resources
as these requests are not authenticated. If a client wishes to query as these requests are not authenticated. If a client wishes to query
the server for information about its account (e.g., to examine the the server for information about its account (e.g., to examine the
"contact" or "certificates" fields), then it SHOULD do so by sending "contact" or "certificates" fields), then it SHOULD do so by sending
a POST request with an empty update. That is, it should send a JWS a POST request with an empty update. That is, it should send a JWS
whose payload is trivial ({}). whose payload is trivial ({}).
6.2.1. Account Key Roll-over 6.3.1. Changes of Terms of Service
As described above, a client can indicate its agreement with the CA's
terms of service by setting the "terms-of-service-agreed" field in
its registration object to "true".
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:agreementRequired". This response MUST
include a Link header with link relation "terms-of-service" and the
latest terms-of-service URL.
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.
HTTP/1.1 403 Forbidden
Replay-Nonce: IXVHDyxIRGcTE0VSblhPzw
Content-Type: application/problem+json
Content-Language: en
{
"type": "urn:ietf:params:acme:error:agreementRequired"
"detail": "Terms of service have changed"
"instance": "http://example.com/agreement/?token=W8Ih3PswD-8"
}
6.3.2. Account Key Roll-over
A client may wish to change the public key that is associated with a A client may wish to change the public key that is associated with a
registration in order to recover from a key compromise or proactively registration in order to recover from a key compromise or proactively
mitigate the impact of an unnoticed key compromise. mitigate the impact of an unnoticed key compromise.
To change the key associate with an account, the client sends a POST To change the key associated with an account, the client first
request containing a key-change object with the following fields: constructs a key-change object describing the change that it would
like the server to make:
oldKey (required, JWK): The JWK representation of the original key account (required, string): The URL for account being modified. The
(i.e., the client's current account key) content of this field MUST be the exact string provided in the
Location header field in response to the new-registration request
that created the account.
newKey (requrired, JWK): The JWK representation of the new key newKey (required, JWK): The JWK representation of the new key
The JWS of this POST must have two signatures: one signature from the
existing key on the account, and one signature from the new key that The client then encapsulates the key-change object in a JWS, signed
the client proposes to use. This demonstrates that the client with the requested new account key (i.e., the key matching the
actually has control of the private key corresponding to the new "newKey" value).
public key. The protected header must contain a JWK field containing
the current account key. The outer JWS MUST meet the normal requirements for an ACME JWS (see
Section 5.2). The inner JWS MUST meet the normal requirements, with
the following exceptions:
o The inner JWS MUST have the same "url" parameter as the outer JWS.
o The inner JWS is NOT REQUIRED to have a "nonce" parameter. The
server MUST ignore any value provided for the "nonce" header
parameter.
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.
POST /acme/key-change HTTP/1.1 POST /acme/key-change HTTP/1.1
Host: example.com Host: example.com
Content-Type: application/jose+json Content-Type: application/jose+json
{ {
"payload": base64url({ "protected": base64url({
"oldKey": /* Old key in JWK form */ "alg": "ES256",
"newKey": /* New key in JWK form */ "jwk": /* old key */,
"nonce": "K60BWPrMQG9SDxBDS_xtSw",
"url": "https://example.com/acme/key-change"
}), }),
"signatures": [{ "payload": base64url({
"protected": base64url({
"alg": "ES256",
"jwk": /* old key */,
"nonce": "pq00v-D1KB0sReG4jFfqVg",
"url": "https://example.com/acme/key-change"
}),
"signature": "XFvVbo9diBlIBvhE...UI62sNT6MZsCJpQo"
}, {
"protected": base64url({ "protected": base64url({
"alg": "ES256", "alg": "ES256",
"jwk": /* new key */, "jwk": /* new key */,
"nonce": "vYjyueEYhMjpVQHe_unw4g",
"url": "https://example.com/acme/key-change"
}), }),
"signature": "q20gG1f1r9cD6tBM...a48h0CkP11tl5Doo" "payload": base64url({
}] "account": "https://example.com/acme/reg/asdf",
"newKey": /* new key */
})
"signature": "Xe8B94RD30Azj2ea...8BmZIRtcSKPSd8gU"
}),
"signature": "5TWiqIYQfIDfALQv...x9C2mg8JGPxl5bI4"
} }
On receiving key-change request, the server MUST perform the On receiving key-change request, the server MUST perform the
following steps in addition to the typical JWS validation: following steps in addition to the typical JWS validation:
1. Check that the JWS protected header container a "jwk" field 1. Validate the POST request belongs to a currently active account,
containing a key that matches a currently active account. as described in Message Transport.
2. Check that there are exactly two signatures on the JWS. 2. Check that the payload of the JWS is a well-formed JWS object
(the "inner JWS")
3. Check that one of the signatures validates using the account key 3. Check that the JWS protected header of the inner JWS has a "jwk"
from (1). field.
4. Check that the "key" field contains a well-formed JWK that meets 4. Check that the inner JWS verifies using the key in its "jwk"
key strength requirements. field
5. Check that the "key" field is not equivalent to the current 5. Check that the payload of the inner JWS is a well-formed key-
account key or any other currently active account key. change object (as described above)
6. Check that one of the two signatures on the JWS validates using 6. Check that the "url" parameters of the inner and outer JWSs are
the JWK from the "key" field. the same
7. Check that the "account" field of the key-change object contains
the URL for the registration matching the old key
8. Check that the "newKey" field of the key-change object contains
the key used to sign the inner JWS.
If all of these checks pass, then the server updates the If all of these checks pass, then the server updates the
corresponding registration by replacing the old account key with the corresponding registration by replacing the old account key with the
new public key and returns status code 200. Otherwise, the server new public key and returns status code 200. Otherwise, the server
responds with an error status code and a problem document describing responds with an error status code and a problem document describing
the error. the error.
6.2.2. Account deactivation 6.3.3. Account deactivation
A client may deactivate an account by posting a signed update to the A client may deactivate an account by posting a signed update to the
server with a status field of "deactivated." Clients may wish to do server with a status field of "deactivated." Clients may wish to do
this when the account key is compromised. this when the account key is compromised.
POST /acme/reg/asdf HTTP/1.1 POST /acme/reg/asdf HTTP/1.1
Host: example.com Host: example.com
Content-Type: application/jose+json Content-Type: application/jose+json
{ {
"protected": base64url({ "protected": base64url({
"alg": "ES256", "alg": "ES256",
"jwk": {...}, "kid": "https://example.com/acme/reg/asdf",
"nonce": "ntuJWWSic4WVNSqeUmshgg", "nonce": "ntuJWWSic4WVNSqeUmshgg",
"url": "https://example.com/acme/reg/asdf" "url": "https://example.com/acme/reg/asdf"
}) })
"payload": base64url({ "payload": base64url({
"status": "deactivated" "status": "deactivated"
}), }),
"signature": "earzVLd3m5M4xJzR...bVTqn7R08AKOVf3Y" "signature": "earzVLd3m5M4xJzR...bVTqn7R08AKOVf3Y"
} }
The server MUST verify that the request is signed by the account key. The server MUST verify that the request is signed by the account key.
skipping to change at page 28, line 5 skipping to change at page 32, line 5
a 200 (OK) status code and the current contents of the registration a 200 (OK) status code and the current contents of the registration
object. object.
Once an account is deactivated, the server MUST NOT accept further Once an account is deactivated, the server MUST NOT accept further
requests authorized by that account's key. It is up to server policy requests authorized by that account's key. It is up to server policy
how long to retain data related to that account, whether to revoke how long to retain data related to that account, whether to revoke
certificates issued by that account, and whether to send email to certificates issued by that account, and whether to send email to
that account's contacts. ACME does not provide a way to reactivate a that account's contacts. ACME does not provide a way to reactivate a
deactivated account. deactivated account.
6.3. Applying for Certificate Issuance 6.4. Applying for Certificate Issuance
The holder of an account key pair may use ACME to submit an The holder of an account key pair may use ACME to submit an
application for a certificate to be issued. The client makes this application for a certificate to be issued. The client makes this
request by sending a POST request to the server's new-application request by sending a POST request to the server's new-application
resource. The body of the POST is a JWS object whose JSON payload is resource. The body of the POST is a JWS object whose JSON payload is
a subset of the application object defined in Section 6.1.3, a subset of the application object defined in Section 6.1.3,
containing the fields that describe the certificate to be issued: containing the fields that describe the certificate to be issued:
csr (required, string): A CSR encoding the parameters for the csr (required, string): A CSR encoding the parameters for the
certificate being requested [RFC2986]. The CSR is sent in the certificate being requested [RFC2986]. The CSR is sent in the
skipping to change at page 28, line 33 skipping to change at page 32, line 33
notAfter (optional, string): The requested value of the notAfter notAfter (optional, string): The requested value of the notAfter
field in the certificate, in the date format defined in [RFC3339] field in the certificate, in the date format defined in [RFC3339]
POST /acme/new-app HTTP/1.1 POST /acme/new-app HTTP/1.1
Host: example.com Host: example.com
Content-Type: application/jose+json Content-Type: application/jose+json
{ {
"protected": base64url({ "protected": base64url({
"alg": "ES256", "alg": "ES256",
"jwk": {...}, "kid": "https://example.com/acme/reg/asdf",
"nonce": "5XJ1L3lEkMG7tR6pA00clA", "nonce": "5XJ1L3lEkMG7tR6pA00clA",
"url": "https://example.com/acme/new-app" "url": "https://example.com/acme/new-app"
}) })
"payload": base64url({ "payload": base64url({
"csr": "5jNudRx6Ye4HzKEqT5...FS6aKdZeGsysoCo4H9P", "csr": "5jNudRx6Ye4HzKEqT5...FS6aKdZeGsysoCo4H9P",
"notBefore": "2016-01-01T00:00:00Z", "notBefore": "2016-01-01T00:00:00Z",
"notAfter": "2016-01-08T00:00:00Z" "notAfter": "2016-01-08T00:00:00Z"
}), }),
"signature": "H6ZXtGjTZyUnPeKn...wEA4TklBdh3e454g" "signature": "H6ZXtGjTZyUnPeKn...wEA4TklBdh3e454g"
} }
skipping to change at page 29, line 15 skipping to change at page 33, line 15
in a certain way, it should indicate the required changes using an in a certain way, it should indicate the required changes using an
appropriate error code and description. appropriate error code and description.
If the server is willing to issue the requested certificate, it If the server is willing to issue the requested certificate, it
responds with a 201 (Created) response. The body of this response is responds with a 201 (Created) response. The body of this response is
an application object reflecting the client's request and any an application object reflecting the client's request and any
requirements the client must fulfill before the certificate will be requirements the client must fulfill before the certificate will be
issued. issued.
HTTP/1.1 201 Created HTTP/1.1 201 Created
Replay-Nonce: MYAuvOpaoIiywTezizk5vw
Location: https://example.com/acme/app/asdf Location: https://example.com/acme/app/asdf
{ {
"status": "pending", "status": "pending",
"expires": "2015-03-01T14:09:00Z", "expires": "2015-03-01T14:09:00Z",
"csr": "jcRf4uXra7FGYW5ZMewvV...rhlnznwy8YbpMGqwidEXfE", "csr": "jcRf4uXra7FGYW5ZMewvV...rhlnznwy8YbpMGqwidEXfE",
"notBefore": "2016-01-01T00:00:00Z", "notBefore": "2016-01-01T00:00:00Z",
"notAfter": "2016-01-08T00:00:00Z", "notAfter": "2016-01-08T00:00:00Z",
skipping to change at page 29, line 49 skipping to change at page 33, line 50
The application object returned by the server represents a promise The application object returned by the server represents a promise
that if the client fulfills the server's requirements before the that if the client fulfills the server's requirements before the
"expires" time, then the server will issue the requested certificate. "expires" time, then the server will issue the requested certificate.
In the application object, any object in the "requirements" array In the application object, any object in the "requirements" array
whose status is "pending" represents an action that the client must whose status is "pending" represents an action that the client must
perform before the server will issue the certificate. If the client perform before the server will issue the certificate. If the client
fails to complete the required actions before the "expires" time, fails to complete the required actions before the "expires" time,
then the server SHOULD change the status of the application to then the server SHOULD change the status of the application to
"invalid" and MAY delete the application resource. "invalid" and MAY delete the application resource.
The server SHOULD issue the requested certificate and update the The server MUST issue the requested certificate and update the
application resource with a URL for the certificate as soon as the application resource with a URL for the certificate as soon as the
client has fulfilled the server's requirements. If the client has client has fulfilled the server's requirements. If the client has
already satisfied the server's requirements at the time of this already satisfied the server's requirements at the time of this
request (e.g., by obtaining authorization for all of the identifiers request (e.g., by obtaining authorization for all of the identifiers
in the certificate in previous transactions), then the server MAY in the certificate in previous transactions), then the server MUST
proactively issue the requested certificate and provide a URL for it proactively issue the requested certificate and provide a URL for it
in the "certificate" field of the application. The server MUST, in the "certificate" field of the application. The server MUST,
however, still list the satisfied requirements in the "requirements" however, still list the satisfied requirements in the "requirements"
array, with the state "valid". array, with the state "valid".
Once the client believes it has fulfilled the server's requirements, Once the client believes it has fulfilled the server's requirements,
it should send a GET request to the application resource to obtain it should send a GET request to the application resource to obtain
its current state. The status of the application will indicate what its current state. The status of the application will indicate what
action the client should take: action the client should take:
skipping to change at page 30, line 33 skipping to change at page 34, line 34
o "processing": The server agrees that the requirements have been o "processing": The server agrees that the requirements have been
fulfilled, and is in the process of generating the certificate. fulfilled, and is in the process of generating the certificate.
Retry after the time given in the "Retry-After" header field of Retry after the time given in the "Retry-After" header field of
the response, if any. the response, if any.
o "valid": The server has issued the certificate and provisioned its o "valid": The server has issued the certificate and provisioned its
URL to the "certificate" field of the application. Download the URL to the "certificate" field of the application. Download the
certificate. certificate.
6.3.1. Downloading the Certificate 6.4.1. Pre-Authorization
The application process described above presumes that authorization
objects are created reactively, in response to an application for
issuance. 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 servers are created, and only create a certificate when a
server starts up.
In some cases, a CA running an ACME server might have a completely
external, non-ACME process for authorizing a client to issue for an
identifier. In these case, the CA should provision its ACME server
with authorization objects corresponding to thsee authorizations and
reflect them as alread-valid requirements in any issuance
applications requested by the client.
If a CA wishes to allow pre-authorization within ACME, it can offer a
"new authorization" resource in its directory by adding the key "new-
authz" with a URL for the new authorization resource.
To request authorization for an identifier, the client sends a POST
request to the new-authorization resource specifying the identifier
for which authorization is being requested and how the server should
behave with respect to existing authorizations for this identifier.
identifier (required, dictionary of string): The identifier that the
account is authorized to represent
type (required, string): The type of identifier.
value (required, string): The identifier itself.
existing (optional, string): How an existing authorization should be
handled. Possible values are "accept" and "require".
POST /acme/new-authz HTTP/1.1
Host: example.com
Content-Type: application/jose+json
{
"protected": base64url({
"alg": "ES256",
"jwk": {...},
"nonce": "uQpSjlRb4vQVCjVYAyyUWg",
"url": "https://example.com/acme/new-authz"
})
"payload": base64url({
"identifier": {
"type": "dns",
"value": "example.net"
},
"existing": "accept"
}),
"signature": "nuSDISbWG8mMgE7H...QyVUL68yzf3Zawps"
}
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 a 403
(Forbidden) error, with a problem document describing the reason for
the rejection.
If the authorization request specifies "existing" with a value of
"accept" or "require", before proceeding, the server SHOULD determine
whether there are any existing, valid authorization resources for the
account and given identifier. If one or more such authorizations
exists, a response SHOULD returned with status code 303 (See Other)
and a Location header pointing to the existing resource URL;
processing of the request then stops. If there are multiple such
authorizations, the authorization with the latest expiry date SHOULD
be returned. If no existing authorizations were found and the value
for "existing" was "require", then the server MUST return status code
404 (Not Found); if it was "accept" or was any other value or was
absent, processing continues as follows.
If the server is willing to proceed, it builds a pending
authorization object from the inputs submitted by the client.
o "identifier" the identifier submitted by the client
o "status": MUST be "pending" unless the server has out-of-band
information about the client's authorization status
o "challenges" and "combinations": As selected by the server's
policy for this identifier
The server allocates a new URI for this authorization, and returns a
201 (Created) response, with the authorization URI in a Location
header field, and the JSON authorization object in the body. The
client then follows the process described in Section 6.5 to complete
the authorization process.
6.4.2. Downloading the Certificate
To download the issued certificate, the client simply sends a GET To download the issued certificate, the client simply sends a GET
request to the certificate URL. request to the certificate URL.
The default format of the certificate is DER (application/pkix-cert). The default format of the certificate is PEM (application/x-pem-file)
The client may request other formats by including an Accept header in as specified by [RFC7468]. This format should contain the end-entity
its request. For example, the client may use the media type certificate first, followed by any intermediate certificates that are
application/x-pem-file to request the certificate in PEM format. needed to build a path to a trusted root. Servers SHOULD NOT include
self-signed trust anchors. The client may request other formats by
including an Accept header in its request. For example, the client
may use the media type application/pkix-cert to request the end-
entity certificate in DER format.
The server provides metadata about the certificate in HTTP headers. The server MAY provide one or more link relation header fields
In particular, the server MUST send one or more link relation header [RFC5988] with relation "alternate". Each such field should express
fields [RFC5988] with relation "up", each indicating a single an alternative certificate chain starting with the same end-entity
certificate resource for the issuer of this certificate. The server certificate. This can be used to express paths to various trust
MAY also include the "up" links from these resources to enable the anchors. Clients can fetch these alternates and use their own
client to build a full certificate chain. heuristics to decide which is optimal.
The server MUST also provide a link relation header field with The server MUST also provide a link relation header field with
relation "author" to indicate the application under which this relation "author" to indicate the application under which this
certificate was issued. certificate was issued.
If the CA participates in Certificate Transparency (CT) [RFC6962], If the CA participates in Certificate Transparency (CT) [RFC6962],
then they may want to provide the client with a Signed Certificate then they may want to provide the client with a Signed Certificate
Timestamp (SCT) that can be used to prove that a certificate was Timestamp (SCT) that can be used to prove that a certificate was
submitted to a CT log. An SCT can be included as an extension in the submitted to a CT log. An SCT can be included as an extension in the
certificate or as an extension to OCSP responses for the certificate. certificate or as an extension to OCSP responses for the certificate.
skipping to change at page 31, line 30 skipping to change at page 37, line 32
Accept: application/pkix-cert Accept: application/pkix-cert
HTTP/1.1 200 OK HTTP/1.1 200 OK
Content-Type: application/pkix-cert Content-Type: application/pkix-cert
Link: <https://example.com/acme/ca-cert>;rel="up";title="issuer" Link: <https://example.com/acme/ca-cert>;rel="up";title="issuer"
Link: <https://example.com/acme/revoke-cert>;rel="revoke" Link: <https://example.com/acme/revoke-cert>;rel="revoke"
Link: <https://example.com/acme/app/asdf>;rel="author" Link: <https://example.com/acme/app/asdf>;rel="author"
Link: <https://example.com/acme/sct/asdf>;rel="ct-sct" Link: <https://example.com/acme/sct/asdf>;rel="ct-sct"
Link: <https://example.com/acme/some-directory>;rel="directory" Link: <https://example.com/acme/some-directory>;rel="directory"
[DER-encoded certificate] -----BEGIN CERTIFICATE-----
[End-entity certificate contents]
-----END CERTIFICATE-----
-----BEGIN CERTIFICATE-----
[Issuer certificate contents]
-----END CERTIFICATE-----
-----BEGIN CERTIFICATE-----
[Other certificate contents]
-----END CERTIFICATE-----
A certificate resource represents a single, immutable certificate. A certificate resource represents a single, immutable certificate.
If the client wishes to obtain a renewed certificate, the client If the client wishes to obtain a renewed certificate, the client
initiates a new application process to request one. initiates a new application process to request one.
Because certificate resources are immutable once issuance is Because certificate resources are immutable once issuance is
complete, the server MAY enable the caching of the resource by adding complete, the server MAY enable the caching of the resource by adding
Expires and Cache-Control headers specifying a point in time in the Expires and Cache-Control headers specifying a point in time in the
distant future. These headers have no relation to the certificate's distant future. These headers have no relation to the certificate's
period of validity. period of validity.
6.4. Identifier Authorization 6.5. Identifier Authorization
The identifier authorization process establishes the authorization of The identifier authorization process establishes the authorization of
an account to manage certificates for a given identifier. This an account to manage certificates for a given identifier. This
process must assure the server of two things: First, that the client process must assure the server of two things: First, that the client
controls the private key of the account key pair, and second, that controls the private key of the account key pair, and second, that
the client holds the identifier in question. This process may be the client holds the identifier in question. This process may be
repeated to associate multiple identifiers to a key pair (e.g., to repeated to associate multiple identifiers to a key pair (e.g., to
request certificates with multiple identifiers), or to associate request certificates with multiple identifiers), or to associate
multiple accounts with an identifier (e.g., to allow multiple multiple accounts with an identifier (e.g., to allow multiple
entities to manage certificates). The server may declare that an entities to manage certificates). The server may declare that an
authorization is only valid for a specific application by setting the authorization is only valid for a specific application by setting the
"scope" field of the authorization to the URI for that application. "scope" field of the authorization to the URI for that application.
Authorization resources are created by the server in response to Authorization resources are created by the server in response to
certificate applications submitted by an account key holder; their certificate applications or authorization requests submitted by an
URLs are provided to the client in "authorization" requirement account key holder; their URLs are provided to the client in the
objects. The authorization object is implicitly tied to the account responses to these requests. The authorization object is implicitly
key used to sign the new-application request. tied to the account key used to sign the request.
When a client receives an application from the server with an When a client receives an application from the server with an
"authorization" requirement, it downloads the authorization resource "authorization" requirement, it downloads the authorization resource
by sending a GET request to the indicated URL. by sending a GET request to the indicated URL. If the client
initiates authorization using a request to the new authorization
resource, it will have already recevied the pending authorization
object in the response to that request.
GET /acme/authz/1234 HTTP/1.1 GET /acme/authz/1234 HTTP/1.1
Host: example.com Host: example.com
HTTP/1.1 200 OK HTTP/1.1 200 OK
Content-Type: application/json Content-Type: application/json
Link: <https://example.com/acme/some-directory>;rel="directory" Link: <https://example.com/acme/some-directory>;rel="directory"
{ {
"status": "pending", "status": "pending",
"identifier": { "identifier": {
"type": "dns", "type": "dns",
"value": "example.org" "value": "example.org"
}, },
"challenges": [ "challenges": [
{ {
"type": "http-01", "type": "http-01",
"uri": "https://example.com/authz/asdf/0", "url": "https://example.com/authz/asdf/0",
"token": "IlirfxKKXAsHtmzK29Pj8A" "token": "IlirfxKKXAsHtmzK29Pj8A"
}, },
{ {
"type": "dns-01", "type": "dns-01",
"uri": "https://example.com/authz/asdf/1", "url": "https://example.com/authz/asdf/1",
"token": "DGyRejmCefe7v4NfDGDKfA" "token": "DGyRejmCefe7v4NfDGDKfA"
} }
], ],
"combinations": [[0], [1]]
} }
6.4.1. Responding to Challenges 6.5.1. Responding to Challenges
To prove control of the identifier and receive authorization, the To prove control of the identifier and receive authorization, the
client needs to respond with information to complete the challenges. client needs to respond with information to complete the challenges.
To do this, the client updates the authorization object received from To do this, the client updates the authorization object received from
the server by filling in any required information in the elements of the server by filling in any required information in the elements of
the "challenges" dictionary. (This is also the stage where the the "challenges" dictionary. (This is also the stage where the
client should perform any actions required by the challenge.) client should perform any actions required by the challenge.)
The client sends these updates back to the server in the form of a The client sends these updates back to the server in the form of a
JSON object with the response fields required by the challenge type, JSON object with the response fields required by the challenge type,
skipping to change at page 33, line 30 skipping to change at page 40, line 12
For example, if the client were to respond to the "http-01" challenge For example, if the client were to respond to the "http-01" challenge
in the above authorization, it would send the following request: in the above authorization, it would send the following request:
POST /acme/authz/asdf/0 HTTP/1.1 POST /acme/authz/asdf/0 HTTP/1.1
Host: example.com Host: example.com
Content-Type: application/jose+json Content-Type: application/jose+json
{ {
"protected": base64url({ "protected": base64url({
"alg": "ES256", "alg": "ES256",
"jwk": {...}, "kid": "https://example.com/acme/reg/asdf",
"nonce": "Q_s3MWoqT05TrdkM2MTDcw", "nonce": "Q_s3MWoqT05TrdkM2MTDcw",
"url": "https://example.com/acme/authz/asdf/0" "url": "https://example.com/acme/authz/asdf/0"
}) })
"payload": base64url({ "payload": base64url({
"type": "http-01", "type": "http-01",
"keyAuthorization": "IlirfxKKXA...vb29HhjjLPSggwiE" "keyAuthorization": "IlirfxKKXA...vb29HhjjLPSggwiE"
}), }),
"signature": "9cbg5JO1Gf5YLjjz...SpkUfcdPai9uVYYQ" "signature": "9cbg5JO1Gf5YLjjz...SpkUfcdPai9uVYYQ"
} }
skipping to change at page 34, line 7 skipping to change at page 40, line 37
The server provides a 200 (OK) response with the updated challenge The server provides a 200 (OK) response with the updated challenge
object as its body. object as its body.
If the client's response is invalid for some reason, or does not If the client's response is invalid for some reason, or does not
provide the server with appropriate information to validate the provide the server with appropriate information to validate the
challenge, then the server MUST return an HTTP error. On receiving challenge, then the server MUST return an HTTP error. On receiving
such an error, the client SHOULD undo any actions that have been such an error, the client SHOULD undo any actions that have been
taken to fulfill the challenge, e.g., removing files that have been taken to fulfill the challenge, e.g., removing files that have been
provisioned to a web server. provisioned to a web server.
Presumably, the client's responses provide the server with enough The server is said to "finalize" the authorization when it has
information to validate one or more challenges. The server is said completed one of the validations, by assigning the authorization a
to "finalize" the authorization when it has completed all the
validations it is going to complete, and assigns the authorization a
status of "valid" or "invalid", corresponding to whether it considers status of "valid" or "invalid", corresponding to whether it considers
the account authorized for the identifier. If the final state is the account authorized for the identifier. If the final state is
"valid", the server MUST add an "expires" field to the authorization. "valid", the server MUST add an "expires" field to the authorization.
When finalizing an authorization, the server MAY remove the When finalizing an authorization, the server MAY remove challenges
"combinations" field (if present) or remove any challenges still other than the one that was completed. The server SHOULD NOT remove
pending. The server SHOULD NOT remove challenges with status challenges with status "invalid".
"invalid".
Usually, the validation process will take some time, so the client Usually, the validation process will take some time, so the client
will need to poll the authorization resource to see when it is will need to poll the authorization resource to see when it is
finalized. For challenges where the client can tell when the server finalized. For challenges where the client can tell when the server
has validated the challenge (e.g., by seeing an HTTP or DNS request 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 from the server), the client SHOULD NOT begin polling until it has
seen the validation request from the server. seen the validation request from the server.
To check on the status of an authorization, the client sends a GET To check on the status of an authorization, the client sends a GET
request to the authorization URI, and the server responds with the request to the authorization URI, and the server responds with the
skipping to change at page 35, line 30 skipping to change at page 41, line 37
{ {
"type": "http-01" "type": "http-01"
"status": "valid", "status": "valid",
"validated": "2014-12-01T12:05:00Z", "validated": "2014-12-01T12:05:00Z",
"token": "IlirfxKKXAsHtmzK29Pj8A", "token": "IlirfxKKXAsHtmzK29Pj8A",
"keyAuthorization": "IlirfxKKXA...vb29HhjjLPSggwiE" "keyAuthorization": "IlirfxKKXA...vb29HhjjLPSggwiE"
} }
] ]
} }
6.4.2. Deactivating an Authorization 6.5.2. Deactivating an Authorization
If a client wishes to relinquish its authorization to issue If a client wishes to relinquish its authorization to issue
certificates for an identifier, then it may request that the server certificates for an identifier, then it may request that the server
deactivate each authorization associated with that identifier by deactivate each authorization associated with that identifier by
sending a POST request with the static object {"status": sending a POST request with the static object {"status":
"deactivated"}. "deactivated"}.
POST /acme/authz/asdf HTTP/1.1 POST /acme/authz/asdf HTTP/1.1
Host: example.com Host: example.com
Content-Type: application/jose+json Content-Type: application/jose+json
{ {
"protected": base64url({ "protected": base64url({
"alg": "ES256", "alg": "ES256",
"jwk": {...}, "kid": "https://example.com/acme/reg/asdf",
"nonce": "xWCM9lGbIyCgue8di6ueWQ", "nonce": "xWCM9lGbIyCgue8di6ueWQ",
"url": "https://example.com/acme/authz/asdf" "url": "https://example.com/acme/authz/asdf"
}) })
"payload": base64url({ "payload": base64url({
"status": "deactivated" "status": "deactivated"
}), }),
"signature": "srX9Ji7Le9bjszhu...WTFdtujObzMtZcx4" "signature": "srX9Ji7Le9bjszhu...WTFdtujObzMtZcx4"
} }
The server MUST verify that the request is signed by the account key The server MUST verify that the request is signed by the account key
corresponding to the account that owns the authorization. If the corresponding to the account that owns the authorization. If the
server accepts the deactivation, it should reply with a 200 (OK) server accepts the deactivation, it should reply with a 200 (OK)
status code and the current contents of the registration object. status code and the current contents of the authorization object.
The server MUST NOT treat deactivated authorization objects as The server MUST NOT treat deactivated authorization objects as
sufficient for issuing certificates. sufficient for issuing certificates.
6.5. Certificate Revocation 6.6. Certificate Revocation
To request that a certificate be revoked, the client sends a POST To request that a certificate be revoked, the client sends a POST
request to the ACME server's revoke-cert URI. The body of the POST request to the ACME server's revoke-cert URI. The body of the POST
is a JWS object whose JSON payload contains the certificate to be is a JWS object whose JSON payload contains the certificate to be
revoked: revoked:
certificate (required, string): The certificate to be revoked, in certificate (required, string): The certificate to be revoked, in
the base64url-encoded version of the DER format. (Note: This the base64url-encoded version of the DER format. (Note: This
field uses the same modified Base64 encoding rules used elsewhere field uses the same modified Base64 encoding rules used elsewhere
in this document, so it is different from PEM.) in this document, so it is different from PEM.)
skipping to change at page 37, line 12 skipping to change at page 43, line 12
responses and CRLs. The server MAY disallow a subset of responses and CRLs. The server MAY disallow a subset of
reasonCodes from being used by the user. reasonCodes from being used by the user.
POST /acme/revoke-cert HTTP/1.1 POST /acme/revoke-cert HTTP/1.1
Host: example.com Host: example.com
Content-Type: application/jose+json Content-Type: application/jose+json
{ {
"protected": base64url({ "protected": base64url({
"alg": "ES256", "alg": "ES256",
"jwk": {...}, "kid": "https://example.com/acme/reg/asdf", // OR "jwk"
"nonce": "JHb54aT_KTXBWQOzGYkt9A", "nonce": "JHb54aT_KTXBWQOzGYkt9A",
"url": "https://example.com/acme/revoke-cert" "url": "https://example.com/acme/revoke-cert"
}) })
"payload": base64url({ "payload": base64url({
"certificate": "MIIEDTCCAvegAwIBAgIRAP8...", "certificate": "MIIEDTCCAvegAwIBAgIRAP8...",
"reason": 1 "reason": 1
}), }),
"signature": "Q1bURgJoEslbD1c5...3pYdSMLio57mQNN4" "signature": "Q1bURgJoEslbD1c5...3pYdSMLio57mQNN4"
} }
skipping to change at page 37, line 39 skipping to change at page 44, line 6
o the public key in the certificate. o the public key in the certificate.
o an account key that is authorized to act for all of the o an account key that is authorized to act for all of the
identifier(s) in the certificate. identifier(s) in the certificate.
If the revocation succeeds, the server responds with status code 200 If the revocation succeeds, the server responds with status code 200
(OK). If the revocation fails, the server returns an error. (OK). If the revocation fails, the server returns an error.
HTTP/1.1 200 OK HTTP/1.1 200 OK
Replay-Nonce: IXVHDyxIRGcTE0VSblhPzw
Content-Length: 0 Content-Length: 0
--- or --- --- or ---
HTTP/1.1 403 Forbidden HTTP/1.1 403 Forbidden
Replay-Nonce: IXVHDyxIRGcTE0VSblhPzw
Content-Type: application/problem+json Content-Type: application/problem+json
Content-Language: en Content-Language: en
{ {
"type": "urn:ietf:params:acme:error:unauthorized" "type": "urn:ietf:params:acme:error:unauthorized"
"detail": "No authorization provided for name example.net" "detail": "No authorization provided for name example.net"
"instance": "http://example.com/doc/unauthorized" "instance": "http://example.com/doc/unauthorized"
} }
7. Identifier Validation Challenges 7. Identifier Validation Challenges
skipping to change at page 38, line 48 skipping to change at page 45, line 17
2. Content of response objects 2. Content of response objects
3. How the server uses the challenge and response to verify control 3. How the server uses the challenge and response to verify control
of an identifier of an identifier
Challenge objects all contain the following basic fields: Challenge objects all contain the following basic fields:
type (required, string): The type of challenge encoded in the type (required, string): The type of challenge encoded in the
object. object.
uri (required, string): The URI to which a response can be posted. url (required, string): The URL to which a response can be posted.
status (required, string): The status of this authorization. status (required, string): The status of this authorization.
Possible values are: "pending", "valid", and "invalid". Possible values are: "pending", "valid", and "invalid".
validated (optional, string): The time at which this challenge was validated (optional, string): The time at which this challenge was
completed by the server, encoded in the format specified in RFC completed by the server, encoded in the format specified in RFC
3339 [RFC3339]. This field is REQUIRED if the "status" field is 3339 [RFC3339]. This field is REQUIRED if the "status" field is
"valid". "valid".
error (optional, dictionary of string): The error that occurred error (optional, dictionary of string): The error that occurred
skipping to change at page 39, line 40 skipping to change at page 46, line 8
identifier they apply to. identifier they apply to.
[[ Editor's Note: In pre-RFC versions of this specification, [[ Editor's Note: In pre-RFC versions of this specification,
challenges are labeled by type, and with the version of the draft in challenges are labeled by type, and with the version of the draft in
which they were introduced. For example, if an HTTP challenge were which they were introduced. For example, if an HTTP challenge were
introduced in version -03 and a breaking change made in version -05, introduced in version -03 and a breaking change made in version -05,
then there would be a challenge labeled "http-03" and one labeled then there would be a challenge labeled "http-03" and one labeled
"http-05" - but not one labeled "http-04", since challenge in version "http-05" - but not one labeled "http-04", since challenge in version
-04 was compatible with one in version -04. ]] -04 was compatible with one in version -04. ]]
[[ Editor's Note: Operators SHOULD NOT issue "combinations" arrays in
authorization objects that require the client to perform multiple
challenges over the same type, e.g., ["http-03", "http-05"].
Challenges within a type are testing the same capability of the
domain owner, and it may not be possible to satisfy both at once. ]]
7.1. Key Authorizations 7.1. Key Authorizations
Several of the challenges in this document makes use of a key Several of the challenges in this document makes use of a key
authorization string. A key authorization is a string that expresses authorization string. A key authorization is a string that expresses
a domain holder's authorization for a specified key to satisfy a a domain holder's authorization for a specified key to satisfy a
specified challenge, by concatenating the token for the challenge specified challenge, by concatenating the token for the challenge
with a key fingerprint, separated by a "." character: with a key fingerprint, separated by a "." character:
key-authz = token || '.' || base64url(JWK\_Thumbprint(accountKey)) key-authz = token || '.' || base64url(JWK\_Thumbprint(accountKey))
skipping to change at page 41, line 19 skipping to change at page 47, line 33
The path at which the resource is provisioned is comprised of the The path at which the resource is provisioned is comprised of the
fixed prefix ".well-known/acme-challenge/", followed by the "token" fixed prefix ".well-known/acme-challenge/", followed by the "token"
value in the challenge. The value of the resource MUST be the ASCII value in the challenge. The value of the resource MUST be the ASCII
representation of the key authorization. representation of the key authorization.
.well-known/acme-challenge/evaGxfADs6pSRb2LAv9IZf17Dt3juxGJ-PCt92wr-oA .well-known/acme-challenge/evaGxfADs6pSRb2LAv9IZf17Dt3juxGJ-PCt92wr-oA
The client's response to this challenge indicates its agreement to The client's response to this challenge indicates its agreement to
this challenge by sending the server the key authorization covering this challenge by sending the server the key authorization covering
the challenge's token and the client's account key. In addition, the the challenge's token and the client's account key.
client MAY advise the server at which IP the challenge is
provisioned.
keyAuthorization (required, string): The key authorization for this keyAuthorization (required, string): The key authorization for this
challenge. This value MUST match the token from the challenge and challenge. This value MUST match the token from the challenge and
the client's account key. the client's account key.
/* BEGIN JWS-signed content */ /* BEGIN JWS-signed content */
{ {
"keyAuthorization": "evaGxfADs...62jcerQ" "keyAuthorization": "evaGxfADs...62jcerQ"
} }
/* END JWS-signed content */ /* END JWS-signed content */
skipping to change at page 42, line 5 skipping to change at page 48, line 18
1. Form a URI by populating the URI template [RFC6570] 1. Form a URI by populating the URI template [RFC6570]
"http://{domain}/.well-known/acme-challenge/{token}", where: "http://{domain}/.well-known/acme-challenge/{token}", where:
* the domain field is set to the domain name being verified; and * the domain field is set to the domain name being verified; and
* the token field is set to the token in the challenge. * the token field is set to the token in the challenge.
2. Verify that the resulting URI is well-formed. 2. Verify that the resulting URI is well-formed.
3. Dereference the URI using an HTTP GET request. 3. Dereference the URI using an HTTP GET request. This request MUST
be sent to TCP port 80 on the server.
4. Verify that the body of the response is well-formed key 4. Verify that the body of the response is well-formed key
authorization. The server SHOULD ignore whitespace characters at authorization. The server SHOULD ignore whitespace characters at
the end of the body. the end of the body.
5. Verify that key authorization provided by the server matches the 5. Verify that key authorization provided by the server matches the
token for this challenge and the client's account key. token for this challenge and the client's account key.
If all of the above verifications succeed, then the validation is If all of the above verifications succeed, then the validation is
successful. If the request fails, or the body does not pass these successful. If the request fails, or the body does not pass these
skipping to change at page 43, line 41 skipping to change at page 50, line 11
challenge and the client's account key. If they do not match, then challenge and the client's account key. If they do not match, then
the server MUST return an HTTP error in response to the POST request the server MUST return an HTTP error in response to the POST request
in which the client sent the challenge. in which the client sent the challenge.
Given a challenge/response pair, the ACME server verifies the Given a challenge/response pair, the ACME server verifies the
client's control of the domain by verifying that the TLS server was client's control of the domain by verifying that the TLS server was
configured appropriately, using these steps: configured appropriately, using these steps:
1. Compute SAN A and SAN B in the same way as the client. 1. Compute SAN A and SAN B in the same way as the client.
2. Open a TLS connection to the domain name being validated on the 2. Open a TLS connection to the domain name being validated,
requested port, presenting SAN A in the SNI field. In the presenting SAN A in the SNI field. This connection MUST be sent
ClientHello initiating the TLS handshake, the server MUST include to TCP port 443 on the server. In the ClientHello initiating the
a server_name extension (i.e., SNI) containing SAN A. The server TLS handshake, the server MUST include a server_name extension
SHOULD ensure that it does not reveal SAN B in any way when (i.e., SNI) containing SAN A. The server SHOULD ensure that it
making the TLS connection, such that the presentation of SAN B in does not reveal SAN B in any way when making the TLS connection,
the returned certificate proves association with the client. such that the presentation of SAN B in the returned certificate
proves association with the client.
3. Verify that the certificate contains a subjectAltName extension 3. Verify that the certificate contains a subjectAltName extension
containing dNSName entries of SAN A and SAN B and no other containing dNSName entries of SAN A and SAN B and no other
entries. The comparison MUST be insensitive to case and ordering entries. The comparison MUST be insensitive to case and ordering
of names. of names.
It is RECOMMENDED that the ACME server validation TLS connections It is RECOMMENDED that the ACME server validation TLS connections
from multiple vantage points to reduce the risk of DNS hijacking from multiple vantage points to reduce the risk of DNS hijacking
attacks. attacks.
skipping to change at page 46, line 4 skipping to change at page 52, line 18
of an identifier, for example if validation requires some manual of an identifier, for example if validation requires some manual
steps. In such cases, the server may provide an "out of band" (OOB) steps. In such cases, the server may provide an "out of band" (OOB)
challenge to request that the client perform some action outside of challenge to request that the client perform some action outside of
ACME in order to validate possession of the identifier. ACME in order to validate possession of the identifier.
The OOB challenge requests that the client have a human user visit a The OOB challenge requests that the client have a human user visit a
web page to receive instructions on how to validate possession of the web page to receive instructions on how to validate possession of the
identifier, by providing a URL for that web page. identifier, by providing a URL for that web page.
type (required, string): The string "oob-01" type (required, string): The string "oob-01"
url (required, string): The URL to be visited. The scheme of this
URL MUST be "http" or "https" href (required, string): The URL to be visited. The scheme of this
URL MUST be "http" or "https". Note that this field is distinct
from the "url" field of the challenge, which identifies the
challenge itself.
{ {
"type": "oob-01", "type": "oob-01",
"url": "https://example.com/validate/evaGxfADs6pSRb2LAv9IZ" "href": "https://example.com/validate/evaGxfADs6pSRb2LAv9IZ"
} }
A client responds to this challenge by presenting the indicated URL A client responds to this challenge by presenting the indicated URL
for a human user to navigate to. If the user choses to complete this for a human user to navigate to. If the user choses to complete this
challege (by vising the website and completing its instructions), the challege (by vising the website and completing its instructions), the
client indicates this by sending a simple acknowledgement response to client indicates this by sending a simple acknowledgement response to
the server. the server.
type (required, string): The string "oob-01" type (required, string): The string "oob-01"
skipping to change at page 47, line 12 skipping to change at page 53, line 25
Related information: N/A Related information: N/A
8.2. Replay-Nonce HTTP Header 8.2. Replay-Nonce HTTP Header
The "Message Headers" registry should be updated with the following The "Message Headers" registry should be updated with the following
additional value: additional value:
| Header Field Name | Protocol | Status | Reference | | Header Field Name | Protocol | Status | Reference |
+:------------+:------+:------+:-----------+ | Replay-Nonce | http | +:------------+:------+:------+:-----------+ | Replay-Nonce | http |
standard | Section 5.4.1 | standard | Section 5.5.1 |
8.3. "url" JWS Header Parameter 8.3. "url" JWS Header Parameter
The "JSON Web Signature and Encryption Header Parameters" registry The "JSON Web Signature and Encryption Header Parameters" registry
should be updated with the following additional value: should be updated with the following additional value:
o Header Parameter Name: "url" o Header Parameter Name: "url"
o Header Parameter Description: URL o Header Parameter Description: URL
o Header Parameter Usage Location(s): JWE, JWS o Header Parameter Usage Location(s): JWE, JWS
o Change Controller: IESG o Change Controller: IESG
o Specification Document(s): Section 5.3.1 of RFC XXXX o Specification Document(s): Section 5.4.1 of RFC XXXX
[[ RFC EDITOR: Please replace XXXX above with the RFC number assigned [[ RFC EDITOR: Please replace XXXX above with the RFC number assigned
to this document ]] to this document ]]
8.4. "nonce" JWS Header Parameter 8.4. "nonce" JWS Header Parameter
The "JSON Web Signature and Encryption Header Parameters" registry The "JSON Web Signature and Encryption Header Parameters" registry
should be updated with the following additional value: should be updated with the following additional value:
o Header Parameter Name: "nonce" o Header Parameter Name: "nonce"
skipping to change at page 47, line 40 skipping to change at page 54, line 4
to this document ]] to this document ]]
8.4. "nonce" JWS Header Parameter 8.4. "nonce" JWS Header Parameter
The "JSON Web Signature and Encryption Header Parameters" registry The "JSON Web Signature and Encryption Header Parameters" registry
should be updated with the following additional value: should be updated with the following additional value:
o Header Parameter Name: "nonce" o Header Parameter Name: "nonce"
o Header Parameter Description: Nonce o Header Parameter Description: Nonce
o Header Parameter Usage Location(s): JWE, JWS o Header Parameter Usage Location(s): JWE, JWS
o Change Controller: IESG o Change Controller: IESG
o Specification Document(s): Section 5.4.2 of RFC XXXX o Specification Document(s): Section 5.5.2 of RFC XXXX
[[ RFC EDITOR: Please replace XXXX above with the RFC number assigned [[ RFC EDITOR: Please replace XXXX above with the RFC number assigned
to this document ]] to this document ]]
8.5. URN Sub-namespace for ACME (urn:ietf:params:acme) 8.5. URN Sub-namespace for ACME (urn:ietf:params:acme)
The "IETF URN Sub-namespace for Registered Protocol Parameter The "IETF URN Sub-namespace for Registered Protocol Parameter
Identifiers" registry should be updated with the following additional Identifiers" registry should be updated with the following additional
value, following the template in [RFC3553]: value, following the template in [RFC3553]:
skipping to change at page 49, line 4 skipping to change at page 55, line 11
provided in the "type" field of problem documents in ACME. provided in the "type" field of problem documents in ACME.
Template: Template:
o Code: The label to be included in the URN for this error, o Code: The label to be included in the URN for this error,
following "urn:ietf:params:acme:" following "urn:ietf:params:acme:"
o Description: A human-readable description of the error o Description: A human-readable description of the error
o Reference: Where the error is defined o Reference: Where the error is defined
Initial contents: The codes and descriptions in the table in Initial contents: The codes and descriptions in the table in
Section 5.6 above, with the Reference field set to point to this Section 5.7 above, with the Reference field set to point to this
specification. specification.
8.6.2. Resource Types 8.6.2. Resource Types
This registry lists the types of resources that ACME servers may list This registry lists the types of resources that ACME servers may list
in their directory objects. in their directory objects.
Template: Template:
o Key: The value to be used as a dictionary key in the directory o Key: The value to be used as a dictionary key in the directory
skipping to change at page 50, line 18 skipping to change at page 56, line 25
| dns | RFC XXXX | | dns | RFC XXXX |
+-------+-----------+ +-------+-----------+
[[ RFC EDITOR: Please replace XXXX above with the RFC number assigned [[ RFC EDITOR: Please replace XXXX above with the RFC number assigned
to this document ]] to this document ]]
8.6.4. Challenge Types 8.6.4. Challenge Types
This registry lists the ways that ACME servers can offer to validate This registry lists the ways that ACME servers can offer to validate
control of an identifier. The "Identifier Type" field in template control of an identifier. The "Identifier Type" field in template
MUST be contained in the Label column of the ACME Identifier Types must be contained in the Label column of the ACME Identifier Types
registry. registry.
Template: Template:
o Label: The value to be put in the "type" field of challenge o Label: The value to be put in the "type" field of challenge
objects using this validation mechanism objects using this validation mechanism
o Identifier Type: The type of identifier that this mechanism o Identifier Type: The type of identifier that this mechanism
applies to applies to
skipping to change at page 51, line 22 skipping to change at page 57, line 30
In this section, we discuss the threat model that underlies ACME and In this section, we discuss the threat model that underlies ACME and
the ways that ACME achieves these security goals within that threat the ways that ACME achieves these security goals within that threat
model. We also discuss the denial-of-service risks that ACME servers model. We also discuss the denial-of-service risks that ACME servers
face, and a few other miscellaneous considerations. face, and a few other miscellaneous considerations.
9.1. Threat model 9.1. Threat model
As a service on the Internet, ACME broadly exists within the Internet As a service on the Internet, ACME broadly exists within the Internet
threat model [RFC3552]. In analyzing ACME, it is useful to think of threat model [RFC3552]. In analyzing ACME, it is useful to think of
an ACME server interacting with other Internet hosts along three an ACME server interacting with other Internet hosts along two
"channels": "channels":
o An ACME channel, over which the ACME HTTPS requests are exchanged o An ACME channel, over which the ACME HTTPS requests are exchanged
o A validation channel, over which the ACME server performs o A validation channel, over which the ACME server performs
additional requests to validate a client's control of an additional requests to validate a client's control of an
identifier identifier
o A contact channel, over which the ACME server sends messages to
the registered contacts for ACME clients
+------------+ +------------+
| ACME | ACME Channel | ACME | ACME Channel
| Client |--------------------+ | Client |--------------------+
+------------+ | +------------+ |
^ V V
| Contact Channel +------------+ +------------+
+--------------------| ACME | | ACME |
| Server | | Server |
+------------+ +------------+
+------------+ | +------------+ |
| Validation |<-------------------+ | Validation |<-------------------+
| Server | Validation Channel | Server | Validation Channel
+------------+ +------------+
In practice, the risks to these channels are not entirely separate, In practice, the risks to these channels are not entirely separate,
but they are different in most cases. Each of the three channels, but they are different in most cases. Each channel, for example,
for example, uses a different communications pattern: the ACME uses a different communications pattern: the ACME channel will
channel will comprise inbound HTTPS connections to the ACME server, comprise inbound HTTPS connections to the ACME server and the
the validation channel outbound HTTP or DNS requests, and the contact validation channel outbound HTTP or DNS requests.
channel will use channels such as email and PSTN.
Broadly speaking, ACME aims to be secure against active and passive Broadly speaking, ACME aims to be secure against active and passive
attackers on any individual channel. Some vulnerabilities arise attackers on any individual channel. Some vulnerabilities arise
(noted below), when an attacker can exploit both the ACME channel and (noted below), when an attacker can exploit both the ACME channel and
one of the others. one of the others.
On the ACME channel, in addition to network-layer attackers, we also On the ACME channel, in addition to network-layer attackers, we also
need to account for application-layer man in the middle attacks, and need to account for application-layer man in the middle attacks, and
for abusive use of the protocol itself. Protection against for abusive use of the protocol itself. Protection against
application-layer MitM addresses potential attackers such as Content application-layer MitM addresses potential attackers such as Content
Distribution Networks (CDNs) and middleboxes with a TLS MitM Distribution Networks (CDNs) and middleboxes with a TLS MitM
function. Preventing abusive use of ACME means ensuring that an function. Preventing abusive use of ACME means ensuring that an
attacker with access to the validation or contact channels can't attacker with access to the validation channel can't obtain
obtain illegitimate authorization by acting as an ACME client illegitimate authorization by acting as an ACME client (legitimately,
(legitimately, in terms of the protocol). in terms of the protocol).
9.2. Integrity of Authorizations 9.2. Integrity of Authorizations
ACME allows anyone to request challenges for an identifier by ACME allows anyone to request challenges for an identifier by
registering an account key and sending a new-application request registering an account key and sending a new-application request
under that account key. The integrity of the authorization process under that account key. The integrity of the authorization process
thus depends on the identifier validation challenges to ensure that thus depends on the identifier validation challenges to ensure that
the challenge can only be completed by someone who both (1) holds the 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 private key of the account key pair, and (2) controls the identifier
in question. in question.
skipping to change at page 58, line 41 skipping to change at page 65, line 5
[RFC2986] Nystrom, M. and B. Kaliski, "PKCS #10: Certification [RFC2986] Nystrom, M. and B. Kaliski, "PKCS #10: Certification
Request Syntax Specification Version 1.7", RFC 2986, Request Syntax Specification Version 1.7", RFC 2986,
DOI 10.17487/RFC2986, November 2000, DOI 10.17487/RFC2986, November 2000,
<http://www.rfc-editor.org/info/rfc2986>. <http://www.rfc-editor.org/info/rfc2986>.
[RFC3339] Klyne, G. and C. Newman, "Date and Time on the Internet: [RFC3339] Klyne, G. and C. Newman, "Date and Time on the Internet:
Timestamps", RFC 3339, DOI 10.17487/RFC3339, July 2002, Timestamps", RFC 3339, DOI 10.17487/RFC3339, July 2002,
<http://www.rfc-editor.org/info/rfc3339>. <http://www.rfc-editor.org/info/rfc3339>.
[RFC3492] Costello, A., "Punycode: A Bootstring encoding of Unicode
for Internationalized Domain Names in Applications
(IDNA)", RFC 3492, DOI 10.17487/RFC3492, March 2003,
<http://www.rfc-editor.org/info/rfc3492>.
[RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform [RFC3986] Berners-Lee, T., Fielding, R., and L. Masinter, "Uniform
Resource Identifier (URI): Generic Syntax", STD 66, Resource Identifier (URI): Generic Syntax", STD 66,
RFC 3986, DOI 10.17487/RFC3986, January 2005, RFC 3986, DOI 10.17487/RFC3986, January 2005,
<http://www.rfc-editor.org/info/rfc3986>. <http://www.rfc-editor.org/info/rfc3986>.
[RFC4648] Josefsson, S., "The Base16, Base32, and Base64 Data [RFC4648] Josefsson, S., "The Base16, Base32, and Base64 Data
Encodings", RFC 4648, DOI 10.17487/RFC4648, October 2006, Encodings", RFC 4648, DOI 10.17487/RFC4648, October 2006,
<http://www.rfc-editor.org/info/rfc4648>. <http://www.rfc-editor.org/info/rfc4648>.
[RFC5246] Dierks, T. and E. Rescorla, "The Transport Layer Security [RFC5246] Dierks, T. and E. Rescorla, "The Transport Layer Security
(TLS) Protocol Version 1.2", RFC 5246, (TLS) Protocol Version 1.2", RFC 5246,
DOI 10.17487/RFC5246, August 2008, DOI 10.17487/RFC5246, August 2008,
<http://www.rfc-editor.org/info/rfc5246>. <http://www.rfc-editor.org/info/rfc5246>.
[RFC5280] Cooper, D., Santesson, S., Farrell, S., Boeyen, S., [RFC5280] Cooper, D., Santesson, S., Farrell, S., Boeyen, S.,
Housley, R., and W. Polk, "Internet X.509 Public Key Housley, R., and W. Polk, "Internet X.509 Public Key
Infrastructure Certificate and Certificate Revocation List Infrastructure Certificate and Certificate Revocation List
(CRL) Profile", RFC 5280, DOI 10.17487/RFC5280, May 2008, (CRL) Profile", RFC 5280, DOI 10.17487/RFC5280, May 2008,
<http://www.rfc-editor.org/info/rfc5280>. <http://www.rfc-editor.org/info/rfc5280>.
[RFC5890] Klensin, J., "Internationalized Domain Names for
Applications (IDNA): Definitions and Document Framework",
RFC 5890, DOI 10.17487/RFC5890, August 2010,
<http://www.rfc-editor.org/info/rfc5890>.
[RFC5988] Nottingham, M., "Web Linking", RFC 5988, [RFC5988] Nottingham, M., "Web Linking", RFC 5988,
DOI 10.17487/RFC5988, October 2010, DOI 10.17487/RFC5988, October 2010,
<http://www.rfc-editor.org/info/rfc5988>. <http://www.rfc-editor.org/info/rfc5988>.
[RFC6066] Eastlake 3rd, D., "Transport Layer Security (TLS) [RFC6066] Eastlake 3rd, D., "Transport Layer Security (TLS)
Extensions: Extension Definitions", RFC 6066, Extensions: Extension Definitions", RFC 6066,
DOI 10.17487/RFC6066, January 2011, DOI 10.17487/RFC6066, January 2011,
<http://www.rfc-editor.org/info/rfc6066>. <http://www.rfc-editor.org/info/rfc6066>.
[RFC6570] Gregorio, J., Fielding, R., Hadley, M., Nottingham, M., [RFC6570] Gregorio, J., Fielding, R., Hadley, M., Nottingham, M.,
skipping to change at page 59, line 39 skipping to change at page 66, line 9
[RFC6844] Hallam-Baker, P. and R. Stradling, "DNS Certification [RFC6844] Hallam-Baker, P. and R. Stradling, "DNS Certification
Authority Authorization (CAA) Resource Record", RFC 6844, Authority Authorization (CAA) Resource Record", RFC 6844,
DOI 10.17487/RFC6844, January 2013, DOI 10.17487/RFC6844, January 2013,
<http://www.rfc-editor.org/info/rfc6844>. <http://www.rfc-editor.org/info/rfc6844>.
[RFC7159] Bray, T., Ed., "The JavaScript Object Notation (JSON) Data [RFC7159] Bray, T., Ed., "The JavaScript Object Notation (JSON) Data
Interchange Format", RFC 7159, DOI 10.17487/RFC7159, March Interchange Format", RFC 7159, DOI 10.17487/RFC7159, March
2014, <http://www.rfc-editor.org/info/rfc7159>. 2014, <http://www.rfc-editor.org/info/rfc7159>.
[RFC7231] Fielding, R., Ed. and J. Reschke, Ed., "Hypertext Transfer
Protocol (HTTP/1.1): Semantics and Content", RFC 7231,
DOI 10.17487/RFC7231, June 2014,
<http://www.rfc-editor.org/info/rfc7231>.
[RFC7468] Josefsson, S. and S. Leonard, "Textual Encodings of PKIX,
PKCS, and CMS Structures", RFC 7468, DOI 10.17487/RFC7468,
April 2015, <http://www.rfc-editor.org/info/rfc7468>.
[RFC7515] Jones, M., Bradley, J., and N. Sakimura, "JSON Web [RFC7515] Jones, M., Bradley, J., and N. Sakimura, "JSON Web
Signature (JWS)", RFC 7515, DOI 10.17487/RFC7515, May Signature (JWS)", RFC 7515, DOI 10.17487/RFC7515, May
2015, <http://www.rfc-editor.org/info/rfc7515>. 2015, <http://www.rfc-editor.org/info/rfc7515>.
[RFC7517] Jones, M., "JSON Web Key (JWK)", RFC 7517, [RFC7517] Jones, M., "JSON Web Key (JWK)", RFC 7517,
DOI 10.17487/RFC7517, May 2015, DOI 10.17487/RFC7517, May 2015,
<http://www.rfc-editor.org/info/rfc7517>. <http://www.rfc-editor.org/info/rfc7517>.
[RFC7518] Jones, M., "JSON Web Algorithms (JWA)", RFC 7518, [RFC7518] Jones, M., "JSON Web Algorithms (JWA)", RFC 7518,
DOI 10.17487/RFC7518, May 2015, DOI 10.17487/RFC7518, May 2015,
 End of changes. 132 change blocks. 
337 lines changed or deleted 614 lines changed or added

This html diff was produced by rfcdiff 1.45. The latest version is available from http://tools.ietf.org/tools/rfcdiff/