Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

header-navigation
keyboard_arrow_up
close
keyboard_arrow_left
Public Key Infrastructure User Guide
Table of Contents Expand all
list Table of Contents
file_download PDF
{ "lLangCode": "en", "lName": "English", "lCountryCode": "us", "transcode": "en_US" }
English
keyboard_arrow_right

ACME Protocol

date_range 09-Dec-24

Learn about ACME protocol and how to enroll the certificate.

What is ACME Protocol

Automated Certificate Management Environment (ACME) protocol is a new PKI enrollment standard used by several PKI servers such as Let’s Encrypt. The Let’s encrypt certificate allows for free usage of Web server certificates in SRX Series Firewalls, and this can be used in Juniper Secure Connect and J-Web. The Junos OS automatically re-enroll Let’s Encrypt certificates on occurance of every 25 days.

The ACME protocol allows the enrollment of certificates from Let’s Encrypt server or ACME enabled servers. The SRX Series Firewalls enrolls the certificates from Let’s Encrypt server and Juniper Secure Connect validates the certificates without copying and downloading any CA certificates.

When using Let’s Encrypt, ensure that the Let’s Encrypt server is able to resolve the domain name to the IP address of the SRX Series Firewall interface as shown in Figure 1. It must be able to reach the SRX Series Firewall interface on TCP port 80. During the certificate enrollment, the SRX Series Firewall will temporarily allow this incoming request automatically. If your SRX Series Firewall or an intermediate firewall or a router is blocking the TCP port 80, certificate enrollment will fail.

Figure 1: Name Resolution for Let's EncryptName Resolution for Let's Encrypt

Limitations

  • ACME specification - The dns-01 and external account binding are not supported.

  • ACME cannot be used when J-Web listen to port 80

  • Wildcard certificate is not supported such as *.mydomain.com, instead you can enroll multiple dns names.

Enroll Local Certificate Using Let’s Encrypt Server

This example shows how to enroll the local certificate using Let's Encrypt.

  1. Specify the CA profile.

    content_copy zoom_out_map
    [edit]
    
    user@host# 
    set security pki ca-profile ISRG_Root_X1 ca-identity ISRG_Root_X1
    
    user@host# set security pki ca-profile ISRG_Root_X1 revocation-check disable
    user@host# set security pki ca-profile Lets_Encrypt ca-identity Lets_Encrypt

    user@host# 
    set security pki ca-profile Lets_Encrypt enrollment url https://acme-v02.api.letsencrypt.org/directory
  2. Commit the configuration.

    content_copy zoom_out_map
    [edit]
    user@host# commit
  3. Load the CA certificate.

    content_copy zoom_out_map
    [edit]
    user@host> request security pki ca-certificate load ca-profile ISRG_Root_X1 filename ISRG_Root_X1.pem
    
  4. Create ACME key ID.

    content_copy zoom_out_map
    [edit]
    user@host> request security pki generate-key-pair size 2048 type rsa acme-key-id mydomain
  5. Preparing enrollment of local certificate.

    content_copy zoom_out_map
    [edit]
    user@host> request security pki generate-key-pair size 2048 type rsa certificate-id service-mydomain
    
  6. Enroll a certificate with one domain name.

    content_copy zoom_out_map
    [edit]
    user@host> request security pki local-certificate enroll acme acme-key-id mydoamin certificate-id service-mydomain ca-profile Lets_Encrypt domain-name jweb.mydomain.com email jweb@acmejnpr.net letsencrypt-enrollment yes terms-of-service agree
    

    Enroll a certificate with multiple domain names.

    content_copy zoom_out_map
    [edit]
    user@host> request security pki local-certificate enroll acme acme-key-id mydomain certificate-id service-mydomain ca-profile Lets_Encrypt domain-name jweb.mydomain.com,remote-acess.mydomain.com  email jweb@acmejnpr.net letsencrypt-enrollment yes terms-of-service agree
    
  7. Once the enrollment is finished the issued certificate will be loaded in certificate-id service-mydomian.

Manual Re-Enroll Local Certificate

To re-enroll a local certificate online:

  1. Initiate the re-enrollment request.

    content_copy zoom_out_map
    [edit]
    user@host> request security pki local-certificate re-enroll acme acme-key-id mydomain certificate-id serice-mydomain ca-profile Lets_Encrypt re-generate-keypair
    
  2. Once the re-enrollment is finished the issued certificate will be loaded in certificate-id service-mydomian.

Delete ACME Account

To delete the ACME account:

  1. Delete the ACME account.

    content_copy zoom_out_map
    [edit]
    user@host> clear security pki acme account acme-key-id mydomain ca-profile Lets_Encrypt

    You can delete the ACME account key only if the ACME is activated or created by the enrollment.

footer-navigation