Feature Request: DNS-01 for non-wildcard certificates – a small patch with significant benefits

#1
Hi everyone,

First of all, I am a huge fan of OpenLiteSpeed and have been using it happily for years across multiple servers.

However, while developing our own centralized DNS and certificate management system, we encountered an unnecessary limitation in the built-in ACME implementation: DNS-01 validation is only used for wildcard certificates, even when a DNS provider is explicitly configured.

For administrators managing larger server infrastructures, DNS-01 offers significant advantages, especially in environments involving:

  • Numerous domains across multiple IP addresses.
  • IP-based virtual hosts.
  • Web servers behind NAT and restrictive firewalls.
  • Servers within private networks.
  • Internal services without public HTTP access.
  • Multiple servers sharing a single public IP address.
  • Centralized DNS and certificate management.
DNS-01 eliminates the need to open or forward port 80 for certificate validation and makes certificate issuance independent of the web server's public reachability. This can save a considerable amount of administrative work.

We have already developed and successfully tested our own centralized DNS-based certificate management system, including a custom ACME DNS provider and an external wrapper for OpenLiteSpeed.

After investigating the current OpenLiteSpeed source code, we developed a native C++ patch that:

  • Enables DNS-01 for non-wildcard certificates when a DNS provider is configured.
  • Preserves the existing behavior for VHosts without a DNS provider.
  • Supports automatic migration of existing certificates between HTTP-01 and DNS-01 during their regular renewal.
  • Keeps existing valid certificates in place without requiring manual deletion or reconfiguration.
The proposed patch has passed syntax compilation checks without introducing any new warnings. The configuration migration functions have also been tested individually. Full server integration testing is still pending.

I have submitted a detailed feature request on GitHub, including the complete technical analysis, proposed implementation, review notes and test matrix:

https://github.com/litespeedtech/openlitespeed/issues/560

I have also attached the proposed source code patch to this forum post.

I would be very interested to hear what other OpenLiteSpeed users and the development team think about this enhancement.

Hopefully, this small contribution can make an already excellent web server even better.

Thank you for your great work on OpenLiteSpeed!
 

Attachments

Top