Skip to content

Accounts and revocation

An ACME account is a key pair the client keeps. Besides getting certificates, ACME clients can (RFC 8555):

What certbot lego BastionXP CA
Renew: a new certificate for the same names certbot renew lego renew bxp acme renew
Revoke a certificate certbot revoke lego revoke bxp acme revoke
Give the account a new key – – bxp acme rollover-key
Close the account for good certbot unregister – bxp acme deactivate

Renewal

ACME has no renewal operation: a renewal is a new order, and the names are proved again. Any certificate key may be reused or replaced; RFC 8555 sets no rule (certbot makes a new key unless --reuse-key).

A certificate's key may never be the key of any ACME account (RFC 8555, section 11.1): BastionXP CA refuses such a CSR.

Revocation

  • Only the account whose order got the certificate, or whoever holds the certificate's key, can revoke it.
  • Reasons: unspecified (0), key compromise (1), superseded (4), cessation of operation (5). Others are refused with badRevocationReason.
  • The request must carry the whole certificate, which must be exactly the one in the CA's list (a forged certificate with a real serial is refused).
  • A revocation over ACME is the same as bxp revoke on the CA machine: the CRL and OCSP show it at once. A second revocation answers alreadyRevoked.

The administrator can revoke any certificate, whichever way it was requested: bxp revoke <serial>.

Key rollover

An account can get a new key (RFC 8555, section 7.3.5): the request is signed with the old key and carries one signed with the new key, so both agree. The account stays the same.

Deactivation

An account can be closed for good (RFC 8555, section 7.3.6):

  • every later request signed by it is refused, and its key cannot open it again, nor a new account;
  • its certificates stay valid, and their own keys can still revoke them.

Not supported

  • Changing an account's contacts.
  • External Account Binding (EAB).

When clients renew

The CA tells ACME clients when to renew each certificate (ACME Renewal Information, RFC 9773). Clients that support it ask it before they renew:

Certificate The CA suggests renewing
valid between two thirds and five sixths of its lifetime: 16 to 20 hours after issue for a 24-hour certificate
revoked now
issued by an intermediate that has since been replaced (it can no longer be revoked) now

Clients ask again after an hour at most, so after a revocation, a client that runs every hour has a new certificate within about an hour. certbot, lego, acme.sh and bxp acme renew ask; a client that does not keeps to its own rule.

A client renewing a certificate can say which one it replaces. The CA accepts that from the account that got the certificate, for an order with a name in common, and once per certificate. bxp list acme-orders shows it.

See what clients asked for

On the CA machine, bxp list shows the ACME accounts and orders. Under each order is every name it asked for: proved or not, with which challenge, and why a proof failed. Start here when a client does not get its certificate:

$ bxp list acme-orders --failed --name web.example.com --config bastionxp-ca.yaml
Order rpT6x_j5XN9-lSRH4JI7-g  invalid  account xZkEA_FUsACaYaZVZqjPwA  expires 2026-11-18 16:22
  web.example.com  invalid  http-01  connection: cannot fetch http://web.example.com/.well-known/acme-challenge/...: connection refused
Command Shows
bxp list acme-orders Every order, newest first, with its names. --failed: only orders where a proof failed. --name: only orders for that name.
bxp list acme-accounts Each client that registered: its account ID, status, contact and when it registered.

Both take --format json, for scripts and to attach to a bug report.

A client has 24 hours to finish an order. Once it has expired, an order is removed when the next order comes in, except:

  • an order that got a certificate stays while the certificate is valid: it says which account may revoke or replace the certificate;
  • a failed order is kept for 7 more days, so that --failed can still show why a client did not get its certificate.