EDNS0 padding is RFC

This commit is contained in:
Willem Toorop 2016-07-14 13:40:49 +02:00
parent 74b57d4679
commit b4e7a82e11
2 changed files with 7 additions and 2 deletions

View File

@ -421,7 +421,8 @@ enum gldns_enum_edns_option
GLDNS_EDNS_DHU = 6, /* RFC6975 */
GLDNS_EDNS_N3U = 7, /* RFC6975 */
GLDNS_EDNS_CLIENT_SUBNET = 8, /* draft-vandergaast-edns-client-subnet */
GLDNS_EDNS_KEEPALIVE = 11 /* draft-ietf-dnsop-edns-tcp-keepalive*/
GLDNS_EDNS_KEEPALIVE = 11, /* draft-ietf-dnsop-edns-tcp-keepalive*/
GLDNS_EDNS_PADDING = 12 /* RFC7830 */
};
typedef enum gldns_enum_edns_option gldns_edns_option;

View File

@ -166,6 +166,7 @@ static gldns_lookup_table gldns_edns_options_data[] = {
{ 7, "N3U" },
{ 8, "edns-client-subnet" },
{ 11, "edns-tcp-keepalive"},
{ 12, "Padding" },
{ 0, NULL}
};
gldns_lookup_table* gldns_edns_options = gldns_edns_options_data;
@ -1886,7 +1887,10 @@ int gldns_wire2str_edns_option_print(char** s, size_t* sl,
break;
case GLDNS_EDNS_KEEPALIVE:
w += gldns_wire2str_edns_keepalive_print(s, sl, optdata, optlen);
break;
break;
case GLDNS_EDNS_PADDING:
w += print_hex_buf(s, sl, optdata, optlen);
break;
default:
/* unknown option code */
w += print_hex_buf(s, sl, optdata, optlen);