mirror of
https://github.com/coredns/coredns.git
synced 2026-10-09 03:55:21 -04:00
plugin: use Zones.Contains when any match suffices (#8505)
This commit is contained in:
@@ -39,7 +39,7 @@ func (t *TSIGServer) ServeDNS(ctx context.Context, w dns.ResponseWriter, r *dns.
|
||||
switch {
|
||||
case tsigRR == nil && !t.tsigRequired(state.QType(), r.Opcode):
|
||||
fallthrough
|
||||
case plugin.Zones(t.Zones).Matches(state.Name()) == "":
|
||||
case !plugin.Zones(t.Zones).Contains(state.Name()):
|
||||
return plugin.NextOrFailure(t.Name(), t.Next, ctx, w, r)
|
||||
case tsigRR == nil:
|
||||
log.Debugf("rejecting '%s' request without TSIG\n", dns.TypeToString[state.QType()])
|
||||
|
||||
Reference in New Issue
Block a user