From 385d7b0582acdff8da018136f4575816c3c54b0b Mon Sep 17 00:00:00 2001 From: Jordan Whited Date: Wed, 13 May 2020 14:06:49 -0700 Subject: [PATCH] fix PTR answer target --- wgsd.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/wgsd.go b/wgsd.go index 2603854..4e234c6 100644 --- a/wgsd.go +++ b/wgsd.go @@ -76,9 +76,9 @@ func (p *WGSD) ServeDNS(ctx context.Context, w dns.ResponseWriter, Class: dns.ClassINET, Ttl: 0, }, - Ptr: fmt.Sprintf("%s.%s", + Ptr: fmt.Sprintf("%s.%s%s", base64.StdEncoding.EncodeToString(peer.PublicKey[:]), - p.zone), + spPrefix, p.zone), }) } w.WriteMsg(m) // nolint: errcheck