Answer REFUSED when we don't host the zone

Change from SERVFAIL to diff. between error and no such zone hosted.

Fixes: #68
This commit is contained in:
Miek Gieben
2016-04-02 18:11:56 +01:00
parent 2adbdf34d9
commit 4a2a95561f

View File

@@ -306,9 +306,9 @@ func (s *Server) ServeDNS(w dns.ResponseWriter, r *dns.Msg) {
return
}
// Still here? Error out with SERVFAIL and some logging
// Still here? Error out with REFUSED and some logging
remoteHost := w.RemoteAddr().String()
DefaultErrorFunc(w, r, dns.RcodeServerFailure)
DefaultErrorFunc(w, r, dns.RcodeRefused)
log.Printf("[INFO] %s - No such zone at %s (Remote: %s)", q, s.Addr, remoteHost)
}