From 04ac548915931025091fd0107df377ce4634c7f4 Mon Sep 17 00:00:00 2001 From: Philippe Pittoli Date: Mon, 25 Nov 2024 11:27:56 +0100 Subject: [PATCH] For powerdns, CAA values have to be quoted. --- src/storage/zone.cr | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/storage/zone.cr b/src/storage/zone.cr index 35876b3..4f644e1 100644 --- a/src/storage/zone.cr +++ b/src/storage/zone.cr @@ -766,11 +766,11 @@ class DNSManager::Storage::Zone def to_s(io : IO) io << "(#{ "%4d" % @rrid }) " io << "#{ "%.30s" % @name} #{ "%6d" % @ttl} CAA " - io << "#{ "%.3s" % @caa.flag} #{ "%.15s" % @caa.tag} #{@caa.value}\n" + io << "#{ "%.3s" % @caa.flag} #{ "%.15s" % @caa.tag} #{quoted_string @caa.value}\n" end def to_bind9(io : IO) - io << "#{@name} #{@ttl} IN CAA #{@caa.flag} #{@caa.tag.to_s.downcase} #{@caa.value}\n" + io << "#{@name} #{@ttl} IN CAA #{@caa.flag} #{@caa.tag.to_s.downcase} #{quoted_string @caa.value}\n" end def get_errors : Array(Error)