From 086e157ea157bd85b14a563eb0be7189ab7936e6 Mon Sep 17 00:00:00 2001 From: mzack Date: Fri, 6 Aug 2021 13:48:51 +0200 Subject: [PATCH] Enabling EDNS by default --- client.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/client.go b/client.go index c8c688c..5eb8539 100644 --- a/client.go +++ b/client.go @@ -155,7 +155,6 @@ func (c *Client) QueryMultiple(host string, requestTypes []uint16) (*DNSData, er return nil, err } } - msg.SetEdns0(4096, false) } question := dns.Question{ @@ -165,6 +164,9 @@ func (c *Client) QueryMultiple(host string, requestTypes []uint16) (*DNSData, er } msg.Question[0] = question + // Enable Extension Mechanisms for DNS for all messages + msg.SetEdns0(4096, false) + var resp *dns.Msg for i := 0; i < c.maxRetries; i++ { index := atomic.AddUint32(&c.serversIndex, 1)