mirror of
https://github.com/coredns/coredns.git
synced 2025-12-06 10:25:10 -05:00
plugin/k8s_external: Set authoritative bit in responses (#5284)
set authoritative bit in responses Signed-off-by: Chris O'Haver <cohaver@infoblox.com>
This commit is contained in:
@@ -11,6 +11,7 @@ import (
|
||||
func (e *External) serveApex(state request.Request) (int, error) {
|
||||
m := new(dns.Msg)
|
||||
m.SetReply(state.Req)
|
||||
m.Authoritative = true
|
||||
switch state.QType() {
|
||||
case dns.TypeSOA:
|
||||
m.Answer = []dns.RR{e.soa(state)}
|
||||
@@ -37,6 +38,7 @@ func (e *External) serveSubApex(state request.Request) (int, error) {
|
||||
|
||||
m := new(dns.Msg)
|
||||
m.SetReply(state.Req)
|
||||
m.Authoritative = true
|
||||
|
||||
// base is either dns. of ns1.dns (or another name), if it's longer return nxdomain
|
||||
switch labels := dns.CountLabel(base); labels {
|
||||
|
||||
Reference in New Issue
Block a user