From: Aki Tuomi Date: Tue, 21 May 2013 09:33:08 +0000 (+0300) Subject: Small changes to CERT X-Git-Tag: auth-3.3-rc1~6^2~3 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=689516b38189aed9bc4d6bfeaeab854c3b1eaa1c;p=pdns Small changes to CERT --- diff --git a/pdns/dnsrecords.cc b/pdns/dnsrecords.cc index d67259bb7..611def6f3 100644 --- a/pdns/dnsrecords.cc +++ b/pdns/dnsrecords.cc @@ -192,11 +192,13 @@ boilerplate_conv(KEY, ns_t_key, boilerplate_conv(CERT, 37, conv.xfr16BitInt(d_type); + if (d_type == 0) throw MOADNSException("CERT type 0 is reserved"); + conv.xfr16BitInt(d_tag); conv.xfr8BitInt(d_algorithm); - conv.xfrBlob(d_certificate); - ) - + conv.xfrBlob(d_certificate); + ) + boilerplate_conv(TLSA, 52, conv.xfr8BitInt(d_certusage); conv.xfr8BitInt(d_selector);