aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-dns.c
diff options
context:
space:
mode:
authorjake <jake@f5534014-38df-0310-8fa8-9805f1628bb7>2009-08-05 18:17:18 +0000
committerjake <jake@f5534014-38df-0310-8fa8-9805f1628bb7>2009-08-05 18:17:18 +0000
commit6bb7a11e0813ee0b7f7b9b1f3dd52789a2d3386c (patch)
tree866113049905829da9c3f58446ba006305f7baae /epan/dissectors/packet-dns.c
parent3cc53f58e4c0f0aa7b91c0c6919066470b0f0f91 (diff)
From Ivan Sy:
Add support for Support for DHCID RR (RFC 4701). git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@29305 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'epan/dissectors/packet-dns.c')
-rw-r--r--epan/dissectors/packet-dns.c22
1 files changed, 21 insertions, 1 deletions
diff --git a/epan/dissectors/packet-dns.c b/epan/dissectors/packet-dns.c
index fb715eeb9d..3321048045 100644
--- a/epan/dissectors/packet-dns.c
+++ b/epan/dissectors/packet-dns.c
@@ -108,6 +108,7 @@ static int hf_dns_time = -1;
static int hf_dns_sshfp_fingerprint = -1;
static int hf_dns_hip_hit = -1;
static int hf_dns_hip_pk = -1;
+static int hf_dns_dhcid_rdata = -1;
static gint ett_dns = -1;
static gint ett_dns_qd = -1;
@@ -208,6 +209,7 @@ typedef struct _dns_conv_info_t {
#define T_RRSIG 46 /* future RFC 2535bis */
#define T_NSEC 47 /* future RFC 2535bis */
#define T_DNSKEY 48 /* future RFC 2535bis */
+#define T_DHCID 49 /* DHCID RR (RFC 4701) */
#define T_NSEC3 50 /* Next secure hash (RFC 5155) */
#define T_NSEC3PARAM 51 /* NSEC3 parameters (RFC 5155) */
#define T_HIP 55 /* Host Identity Protocol (HIP) RR (RFC 5205) */
@@ -459,7 +461,7 @@ static const value_string dns_types[] = {
{ T_RRSIG, "RRSIG" }, /* future RFC 2535bis */
{ T_NSEC, "NSEC" }, /* future RFC 2535bis */
{ T_DNSKEY, "DNSKEY" }, /* future RFC 2535bis */
-
+ { T_DHCID, "DHCID" }, /* DHCID RR (RFC 4701) */
{ T_NSEC3, "NSEC3" }, /* Next secure hash (RFC 5155) */
{ T_NSEC3PARAM, "NSEC3PARAM" }, /* Next secure hash (RFC 5155) */
{ T_HIP, "HIP" }, /* Host Identity Protocol (HIP) RR (RFC 5205) */
@@ -2659,6 +2661,20 @@ dissect_dns_answer(tvbuff_t *tvb, int offsetx, int dns_data_offset,
}
break;
+ case T_DHCID:
+ {
+ if (cinfo != NULL)
+ col_append_fstr(cinfo, COL_INFO, " %s", name);
+
+ if (dns_tree != NULL) {
+ if (data_len < 1)
+ goto bad_rr;
+ proto_tree_add_item(rr_tree, hf_dns_dhcid_rdata, tvb, cur_offset, data_len, FALSE);
+
+ }
+ }
+ break;
+
/* TODO: parse more record types */
default:
@@ -3314,6 +3330,10 @@ proto_register_dns(void)
{ &hf_dns_hip_pk,
{ "HIP Public Key", "dns.hip.pk",
FT_BYTES, BASE_NONE, NULL, 0,
+ NULL, HFILL }},
+ { &hf_dns_dhcid_rdata,
+ { "DHCID Data", "dns.dhcid.rdata",
+ FT_BYTES, BASE_NONE, NULL, 0,
NULL, HFILL }}
};
static gint *ett[] = {