certbot-dns-cpanel icon indicating copy to clipboard operation
certbot-dns-cpanel copied to clipboard

Fix for the subdomain issue

Open sevaa opened this issue 3 years ago • 2 comments

When an account has a domain and a subdomain underneath it, Cpanel API returns them as separate zones (e. g. test.example.com and example.com). However, it will only let you create an _acme-challenge.test.example.com record via adding _acme-challenge.test to the example.com domain - trying to add _acme-challenge to the test.example.com errors out.

This PR changes the "find the zone for this domain" logic to look for the topmost (shortest) name.

sevaa avatar Jan 05 '23 18:01 sevaa

I change the code according to your PR but got an issue when the TLD is like .or.jp etc..

nfl001 avatar Mar 05 '24 06:03 nfl001

Thanks for letting me know. What would you like me to do?

sevaa avatar Mar 05 '24 16:03 sevaa