mirror of
https://github.com/StackExchange/dnscontrol.git
synced 2024-11-10 17:26:10 +08:00
BUG: Support RFC2317 by allowing slash in CNAME target (#1360)
Co-authored-by: Tom Limoncelli <tlimoncelli@stackoverflow.com>
This commit is contained in:
parent
2dcc9b1c11
commit
998a25aa08
1 changed files with 4 additions and 1 deletions
|
@ -36,7 +36,10 @@ func checkTarget(target string) error {
|
|||
if target == "" {
|
||||
return fmt.Errorf("empty target")
|
||||
}
|
||||
if strings.ContainsAny(target, `'" +,|!£$%&/()=?^*ç°§;:<>[]()@`) {
|
||||
if strings.ContainsAny(target, `'" +,|!£$%&()=?^*ç°§;:<>[]()@`) {
|
||||
return fmt.Errorf("target (%v) includes invalid char", target)
|
||||
}
|
||||
if !strings.HasSuffix(target, ".in-addr.arpa.") && strings.Contains(target, "/") {
|
||||
return fmt.Errorf("target (%v) includes invalid char", target)
|
||||
}
|
||||
// If it contains a ".", it must end in a ".".
|
||||
|
|
Loading…
Reference in a new issue