1
0
mirror of https://github.com/StackExchange/dnscontrol.git synced 2024-05-11 05:55:12 +00:00

Fix NAPTR record support.

This commit is contained in:
Peter Dunaskin
2019-03-29 12:01:52 +01:00
parent 7566c0428e
commit e2726dda64
7 changed files with 13 additions and 13 deletions

View File

@@ -80,14 +80,14 @@ func (dc *DomainConfig) Punycode() error {
}
rec.SetLabelFromFQDN(t, dc.Name)
switch rec.Type { // #rtype_variations
case "ALIAS", "MX", "NS", "CNAME", "PTR", "NAPTR", "SRV", "URL", "URL301", "FRAME", "R53_ALIAS":
case "ALIAS", "MX", "NS", "CNAME", "PTR", "SRV", "URL", "URL301", "FRAME", "R53_ALIAS":
// These rtypes are hostnames, therefore need to be converted (unlike, for example, an AAAA record)
t, err := idna.ToASCII(rec.GetTargetField())
rec.SetTarget(t)
if err != nil {
return err
}
case "A", "AAAA", "CAA", "SSHFP", "TXT", "TLSA":
case "A", "AAAA", "CAA", "NAPTR", "SSHFP", "TXT", "TLSA":
// Nothing to do.
default:
msg := fmt.Sprintf("Punycode rtype %v unimplemented", rec.Type)