Down- and upstream padding a la RFC7830 & RFC8467

This commit is contained in:
Willem Toorop
2020-04-02 18:34:03 +02:00
parent 94e92b197a
commit 4f78b37c61
20 changed files with 7866 additions and 9388 deletions
+2
View File
@@ -1016,6 +1016,7 @@ parse_extract_edns(struct msg_parse* msg, struct edns_data* edns,
edns->bits = sldns_read_uint16(&found->rr_last->ttl_data[2]);
edns->udp_size = ntohs(found->rrset_class);
edns->opt_list = NULL;
edns->padding_block_size = 0;
/* take the options */
rdata_len = found->rr_first->size-2;
@@ -1089,6 +1090,7 @@ parse_edns_from_pkt(sldns_buffer* pkt, struct edns_data* edns,
edns->edns_version = sldns_buffer_read_u8(pkt);
edns->bits = sldns_buffer_read_u16(pkt);
edns->opt_list = NULL;
edns->padding_block_size = 0;
/* take the options */
rdata_len = sldns_buffer_read_u16(pkt);