Index: /trunk/pdns/pdns/dnsrecords.hh
===================================================================
--- /trunk/pdns/pdns/dnsrecords.hh	(revision 823)
+++ /trunk/pdns/pdns/dnsrecords.hh	(revision 976)
@@ -195,4 +195,15 @@
   uint8_t d_algorithm, d_fptype;
   string d_fingerprint;
+};
+
+class KEYRecordContent : public DNSRecordContent
+{
+public:
+  includeboilerplate(KEY)
+
+private:
+  uint16_t d_flags;
+  uint8_t d_protocol, d_algorithm;
+  string d_certificate;
 };
 
Index: /trunk/pdns/pdns/dnsrecords.cc
===================================================================
--- /trunk/pdns/pdns/dnsrecords.cc	(revision 823)
+++ /trunk/pdns/pdns/dnsrecords.cc	(revision 976)
@@ -235,4 +235,11 @@
 		 conv.xfr32BitInt(d_st.expire);
 		 conv.xfr32BitInt(d_st.minimum);
+		 );
+#undef KEY
+boilerplate_conv(KEY, ns_t_key, 
+		 conv.xfr16BitInt(d_flags); 
+		 conv.xfr8BitInt(d_protocol); 
+		 conv.xfr8BitInt(d_algorithm); 
+		 conv.xfrBlob(d_certificate);
 		 );
 
@@ -297,4 +304,5 @@
    NAPTRRecordContent::report();
    RPRecordContent::report();
+   KEYRecordContent::report();
    DNSKEYRecordContent::report();
    RRSIGRecordContent::report();
