diff --git a/proxy/dns/dns.go b/proxy/dns/dns.go index 741f128f8..79343c9d0 100644 --- a/proxy/dns/dns.go +++ b/proxy/dns/dns.go @@ -216,6 +216,13 @@ func (h *Handler) handleIPQuery(id uint16, qType dnsmessage.Type, domain string, RCode: dnsmessage.RCodeSuccess, Response: true, }) + builder.EnableCompression() + common.Must(builder.StartQuestions()) + common.Must(builder.Question(dnsmessage.Question{ + Name: dnsmessage.MustNewName(domain), + Class: dnsmessage.ClassINET, + Type: qType, + })) common.Must(builder.StartAnswers()) rHeader := dnsmessage.ResourceHeader{Name: dnsmessage.MustNewName(domain), Class: dnsmessage.ClassINET, TTL: 600}