Learn how to automatically provision and manage TLS certificates using ACME Certificate Authorities like Let’s Encrypt with Infisical PKI
The Infisical ACME integration allows you to connect with ACME (Automatic Certificate Management Environment) Certificate Authorities to automatically issue and manage publicly trusted TLS certificates for your subscribers. This integration enables you to leverage established public CA infrastructure like Let’s Encrypt while centralizing your certificate management within Infisical.
ACME is a protocol that automates the process of certificate issuance and renewal through domain validation challenges. The integration is perfect for obtaining trusted X.509 certificates for public-facing services and is capable of automatically renewing certificates as needed.
As part of the workflow, you configure DNS provider credentials, register an ACME CA provider with Infisical, and create subscribers to represent the certificates you wish to issue. Each issued certificate is automatically managed through its lifecycle, including renewal before expiration.
We recommend reading about ACME protocol and DNS-01 challenges for a fuller understanding of the underlying technology.
A typical workflow for using Infisical with ACME Certificate Authorities consists of the following steps:
The DNS-01 challenge is the method used by ACME CA providers to verify that you control a domain before issuing a certificate. Here’s how Infisical handles this process:
Challenge Request: When you request a certificate, the ACME provider (like Let’s Encrypt) issues a challenge token.
DNS Record Creation: Infisical creates a TXT record at _acme-challenge.<YOUR_DOMAIN>
with a value derived from the challenge token.
DNS Propagation: The TXT record must propagate through the DNS system (usually takes a few minutes, depending on TTL settings).
Validation: The ACME provider checks for the existence of this TXT record to verify domain control.
Cleanup: After validation completes successfully, Infisical automatically removes the TXT record from your DNS.
This automated process eliminates the need for manual intervention in domain validation, streamlining certificate issuance.
In the following steps, we explore how to set up ACME Certificate Authority integration with Infisical using Let’s Encrypt as an example.
Set Up AWS Connection with Required Permissions
Before proceeding with the ACME CA registration, you need to set up an AWS connection with the appropriate permissions for DNS validation:
Navigate to your Organization Settings > App Connections and create a new AWS connection.
Ensure your AWS connection has the following minimum permissions for Route53 DNS validation:
Replace YOUR_HOSTED_ZONE_ID
with your actual Route53 hosted zone ID.
For detailed instructions on setting up an AWS connection, see the AWS Connection documentation.
Register ACME Certificate Authority
Create ACME CA
To register an ACME CA, head to your Project > Internal PKI > Certificate Authorities and press the + button in the External Certificate Authorities section.
Fill out the details for the ACME CA registration:
Here’s guidance on each field:
https://acme-v02.api.letsencrypt.org/directory
for Let’s Encrypt).Finally, press Create to register the ACME CA with Infisical.
Verify ACME CA Registration
Once registered, your ACME CA will appear in the External Certificate Authorities section.
From here, you can:
You can now use this ACME CA to issue certificates for your subscribers.
Create Subscriber for ACME CA
Next, create a subscriber that uses your ACME CA for certificate issuance. Navigate to your Project > Subscribers and create a new subscriber.
Configure the subscriber with:
example.com
)Check out the Subscribers page for detailed instructions on creating and managing subscribers.
Issue Certificate
Once your subscriber is configured, you can issue certificates either through the Infisical UI or programmatically via the API.
When you request a certificate:
The certificate will be automatically renewed before expiration according to your subscriber configuration.
Use Certificate in Your Applications
The issued certificate and private key are now available through Infisical and can be:
Let’s Encrypt is a free, automated, and open Certificate Authority that provides domain-validated SSL/TLS certificates. Here’s how the integration works with Infisical:
https://acme-v02.api.letsencrypt.org/directory
https://acme-staging-v02.api.letsencrypt.org/directory
Always test your ACME integration using Let’s Encrypt’s staging environment first. This allows you to verify your DNS configuration and certificate issuance process without consuming your production rate limits.
What DNS validation methods are supported?
Currently, Infisical supports DNS-01 validation through AWS Route53. The DNS-01 challenge method is preferred for ACME integrations because it:
Support for additional DNS providers is planned for future releases.
Can I use wildcard certificates with ACME CAs?
Yes! ACME CAs like Let’s Encrypt support wildcard certificates (e.g., *.example.com
) when using DNS-01 validation. Simply specify the wildcard domain in your subscriber configuration.
Note that wildcard certificates still require DNS-01 validation - HTTP-01 validation cannot be used for wildcard certificates.
How long are ACME certificates valid?
Most ACME providers issue certificates with 90-day validity periods. This shorter validity period is designed to:
When configured, Infisical automatically handles certificate renewal for subscribers.
Can I use multiple ACME providers?
Yes! You can register multiple ACME CAs in the same project:
Each subscriber can be configured to use a specific ACME CA based on your requirements.