mirror of
https://github.com/coredns/coredns.git
synced 2026-03-03 03:13:10 -05:00
plugin/forward: fix parsing error when handling TLS+IPv6 address (#7848)
This commit is contained in:
@@ -46,6 +46,7 @@ func HostPortOrFile(s ...string) ([]string, error) {
|
||||
|
||||
if err != nil {
|
||||
// Parse didn't work, it is not a addr:port combo
|
||||
host = strings.Trim(host, "[]")
|
||||
hostNoZone := stripZone(host)
|
||||
if net.ParseIP(hostNoZone) == nil {
|
||||
ss, err := tryFile(host)
|
||||
|
||||
Reference in New Issue
Block a user