Description |
This article describes how to resolve issues with Let’s Encrypt certificate auto-renewal. |
Scope | FortiGate, Let's Encrypt Certificates, ACME certificate. |
Solution |
ACME certificate support is a new feature introduced in FortiOS 7.0.
There are 3 requirements for the Let's Encrypt certificate auto-renewal:
If SSL VPN is enabled on the FortiGate and the ACME listening interface is the same as the SSL VPN port, additional requirements must be applied to avoid port conflict. Ensure no local-in policies are configured to block traffic on ports 443 and 80.
Disable https-redirect settings on the SSL VPN settings or change SSL VPN port 443 to a non-default port so it does not conflict with the ACME port 443.
If an active Virtual IP is used for a Static NAT or Port Forwarding on port 443 that uses the IP address as the ACME listening interface, this will prevent the certificate from being renewed. Change the External Virtual IP or the External Service port in the Port Forwarding so it does not conflict with ACME port 443.
Related article: Technical Tip: ACME certificate enrollment with SSL VPN.
If all of the requirements described above have been satisfied but the certificate auto-renewal is still not taking place, run the following commands on FortiGate. If FortiGate is set up in HA, run the following commands on all HA cluster members:
diagnose sys acme regenerate-client-config
get vpn certificate local details <Local certificate name> diagnose sys acme status-full <Certificate’s CN domain>
To change the ACME listening interface/source-ip:
config system acme set interface <interface-name> set source-ip <ipv4-address> end
Increase window size (acme-renew-window) for ACME renewal. By default, the acme-renew-window settings are set to 30:
This means that the ACME certificate will renew 30 days before expiration, not after 30 days.
If the issue persists, remove the reference configuration of the ACME certificate (in case the certificate is currently used in SSL VPN or admin-server certificate settings). It is possible to temporarily change the ACME certificate in SSL VPN or admin-server certificate to the built-in Fortinet certificate of FortiGate, then force config regeneration and certificate renewal:
diagnose sys acme regenerate-client-config
Sample output when the ACME certificate is renewed:
get vpn certificate local details acme-cert Fingerprint: 9A:03:0F:41:29:D7:01:45:04:F3:16:C0:BD:63:A2:DB ACME details:
diagnose sys acme status-full test.ftntlab.de
In FortiOS version 7.2.6, run the following configuration in the CLI to renew the certificate:
config vpn certificate local edit <acme_cert> set acme-rsa-key-size 4096 end end
After, restart the ACME process with the following command:
diagnose sys acme restart
Note: If the FortiGate is not reachable on ports 80 or 443, it will be possible to see the timeout renewal failures. It is possible to validate that the FortiGate/ACME service is reachable on these ports from another device. For example, from an external server, it is possible to test with 'telnet' or 'curl' commands:
TELNET:
user@server:~$ telnet vpn.domain.net 80
Output indicating the TCP connection has been established:
user@server:~$ telnet vpn.domain.net 80
user@server:~$ curl http://vpn.domain.net
Output showing the acme service is reachable on the FortiGate:
user@server:~$ curl http://vpn.domain.net
If the ports do not show as reachable, it is recommended to trace the connection upstream to see what is preventing access to the FortiGate on these ports.
The following error may occur in some cases:
Fetching abc.fortiddns.com/.well-known/acme-challenge/ftkuFziZB5YczMNLDLKOCAaMFmdMbjvijBCFlLOpTsY: Error getting validation data 2023/06/19 14:39:19 Starting challenges for domains: x.x.x.x:Fetching http://abc.fortiddns.com/.well-known/acme-challenge/ftkuFziZB5YczMNLDLKOCAaMFmdMbjvijBCFlLOpTsY: Error getting validation data, problem: urn:ietf:params:acme:error:connection
This error may be due to validation failures on port 80 when trying to renew the certificate.
Follow the above steps to resolve this error.
Update Regarding LetsEncrypt Expiration Notifications:
LetsEncrypt has released a statement noting e-mail notifications will no longer be provided as reminders for an expiring certificate. This means FortiGate administrators using this feature need to monitor or utilize 3rd party tools to track certificate expiration. More information can be found on this official LetsEncrypt page.
Related articles: Technical Tip: Expiring Let’s Encrypt Certificates ACME certificate support - FortiGate 7.0.0 |
The Fortinet Security Fabric brings together the concepts of convergence and consolidation to provide comprehensive cybersecurity protection for all users, devices, and applications and across all network edges.
Copyright 2025 Fortinet, Inc. All Rights Reserved.