pan-net-security / certbot-dns-powerdns

PowerDNS DNS Authenticator plugin for Certbot
25 stars 16 forks source link

Error with subdomain #18

Open DrGeek opened 2 years ago

DrGeek commented 2 years ago

I couldn't use this plugin for subdomain until I changed those 2 lines :

 def _perform(self, domain, validation_name, validation):
        self._get_powerdns_client().add_txt_record(
            domain.split('.')[-2]+'.'+domain.split('.')[-1], validation_name, validation)

    def _cleanup(self, domain, validation_name, validation):
        self._get_powerdns_client().del_txt_record(
            domain.split('.')[-2]+'.'+domain.split('.')[-1], validation_name, validation)