1 /* packet-zbee-zdp-management.c
2 * Dissector helper routines for the management services of the ZigBee Device Profile
3 * By Owen Kirby <osk@exegin.com>
4 * Copyright 2009 Exegin Technologies Limited
6 * Wireshark - Network traffic analyzer
7 * By Gerald Combs <gerald@wireshark.org>
8 * Copyright 1998 Gerald Combs
10 * SPDX-License-Identifier: GPL-2.0-or-later
16 #include <epan/packet.h>
17 #include <epan/addr_resolv.h>
19 #include "packet-zbee.h"
20 #include "packet-zbee-zdp.h"
21 #include "packet-zbee-tlv.h"
23 /**************************************
25 **************************************
28 *Parses and displays a single network descriptor
30 *@param tvb pointer to buffer containing raw packet.
31 *@param tree pointer to data tree Wireshark uses to display packet.
34 zdp_parse_nwk_desc(proto_tree
*tree
, tvbuff_t
*tvb
, unsigned *offset
, uint8_t version
)
36 proto_tree
*network_tree
;
41 if (version
>= ZBEE_VERSION_2007
) {
42 network_tree
= proto_tree_add_subtree(tree
, tvb
, *offset
, 12, ett_zbee_zdp_nwk_desc
, NULL
, "Network descriptor");
43 /* Extended PAN Identifiers are used in ZigBee 2006 & later. */
44 proto_tree_add_item(network_tree
, hf_zbee_zdp_pan_eui64
, tvb
, *offset
, 8, ENC_LITTLE_ENDIAN
);
48 network_tree
= proto_tree_add_subtree(tree
, tvb
, *offset
, 6, ett_zbee_zdp_nwk_desc
, NULL
, "Network descriptor");
49 /* Short PAN Identifiers are used in ZigBee 2003 and earlier. */
50 proto_tree_add_item(network_tree
, hf_zbee_zdp_pan_uint
, tvb
, *offset
, 2, ENC_LITTLE_ENDIAN
);
54 proto_tree_add_item(network_tree
, hf_zbee_zdp_channel
, tvb
, *offset
, 1, ENC_LITTLE_ENDIAN
);
57 proto_tree_add_item(network_tree
, hf_zbee_zdp_profile
, tvb
, *offset
, 1, ENC_LITTLE_ENDIAN
);
58 proto_tree_add_item(network_tree
, hf_zbee_zdp_profile_version
, tvb
, *offset
, 1, ENC_LITTLE_ENDIAN
);
61 ti
= proto_tree_add_item(network_tree
, hf_zbee_zdp_beacon
, tvb
, *offset
, 1, ENC_LITTLE_ENDIAN
);
62 proto_tree_add_item(network_tree
, hf_zbee_zdp_superframe
, tvb
, *offset
, 1, ENC_LITTLE_ENDIAN
);
63 beacon
= tvb_get_uint8(tvb
, *offset
) & 0x0f;
65 proto_item_append_text(ti
, " (Beacons Disabled)");
69 proto_tree_add_item(network_tree
, hf_zbee_zdp_permit_joining
, tvb
, *offset
, 1, ENC_LITTLE_ENDIAN
);
72 } /* zdp_parse_nwk_desc */
75 *Parses and displays a neighbor table entry.
77 *@param tvb pointer to buffer containing raw packet.
78 *@param tree pointer to data tree Wireshark uses to display packet.
81 zdp_parse_neighbor_table_entry(proto_tree
*tree
, tvbuff_t
*tvb
, unsigned *offset
, uint8_t version
)
83 proto_tree
*table_tree
;
84 proto_item
*ti
= NULL
;
87 if (version
>= ZBEE_VERSION_2007
) {
88 table_tree
= proto_tree_add_subtree(tree
, tvb
, *offset
, 8, ett_zbee_zdp_table_entry
, &ti
, "Table Entry");
89 /* ZigBee 2006 & later use an extended PAN Identifier. */
90 proto_tree_add_item(table_tree
, hf_zbee_zdp_extended_pan
, tvb
, *offset
, 8, ENC_LITTLE_ENDIAN
);
94 table_tree
= proto_tree_add_subtree(tree
, tvb
, *offset
, 2, ett_zbee_zdp_table_entry
, &ti
, "Table Entry");
95 /* ZigBee 2003 & earlier use a short PAN Identifier. */
96 proto_tree_add_item(table_tree
, hf_zbee_zdp_pan_uint
, tvb
, *offset
, 2, ENC_LITTLE_ENDIAN
);
100 proto_tree_add_item(table_tree
, hf_zbee_zdp_ext_addr
, tvb
, *offset
+ len
, 8, ENC_LITTLE_ENDIAN
);
103 proto_tree_add_item(table_tree
, hf_zbee_zdp_addr
, tvb
, *offset
+ len
, 2, ENC_LITTLE_ENDIAN
);
106 if (version
>= ZBEE_VERSION_2007
) {
107 proto_tree_add_item(table_tree
, hf_zbee_zdp_table_entry_type
, tvb
, *offset
+ len
, 1, ENC_NA
);
108 proto_tree_add_item(table_tree
, hf_zbee_zdp_table_entry_idle_rx_0c
, tvb
, *offset
+ len
, 1, ENC_NA
);
109 proto_tree_add_item(table_tree
, hf_zbee_zdp_table_entry_relationship_70
, tvb
, *offset
+ len
, 1, ENC_NA
);
112 proto_tree_add_item(table_tree
, hf_zbee_zdp_table_entry_type
, tvb
, *offset
+ len
, 1, ENC_NA
);
113 proto_tree_add_item(table_tree
, hf_zbee_zdp_table_entry_idle_rx_04
, tvb
, *offset
+ len
, 1, ENC_NA
);
114 proto_tree_add_item(table_tree
, hf_zbee_zdp_table_entry_relationship_18
, tvb
, *offset
+ len
, 1, ENC_NA
);
118 if (version
<= ZBEE_VERSION_2004
) {
119 /* In ZigBee 2003 & earlier, the depth field is before the permit joining field. */
120 proto_tree_add_item(table_tree
, hf_zbee_zdp_depth
, tvb
, *offset
+ len
, 1, ENC_NA
);
124 proto_tree_add_item(table_tree
, hf_zbee_zdp_permit_joining_03
, tvb
, *offset
+ len
, 1, ENC_NA
);
127 if (version
>= ZBEE_VERSION_2007
) {
128 /* In ZigBee 2006 & later, the depth field is after the permit joining field. */
129 proto_tree_add_item(table_tree
, hf_zbee_zdp_depth
, tvb
, *offset
+ len
, 1, ENC_NA
);
133 proto_tree_add_item(table_tree
, hf_zbee_zdp_lqi
, tvb
, *offset
+ len
, 1, ENC_NA
);
136 if (tree
) proto_item_set_len(ti
, len
);
138 } /* zdp_parse_neighbor_table_entry */
141 *Parses and displays a routing table entry.
143 *@param tvb pointer to buffer containing raw packet.
144 *@param tree pointer to data tree Wireshark uses to display packet.
147 zdp_parse_routing_table_entry(proto_tree
*tree
, tvbuff_t
*tvb
, unsigned *offset
)
151 proto_tree
*field_tree
;
156 ti
= proto_tree_add_item(tree
, hf_zbee_zdp_rtg_entry
, tvb
, *offset
+ len
, 2 + 1 + 2, ENC_NA
);
157 field_tree
= proto_item_add_subtree(ti
, ett_zbee_zdp_rtg
);
159 proto_tree_add_item(field_tree
, hf_zbee_zdp_rtg_destination
, tvb
, *offset
+ len
, 2, ENC_LITTLE_ENDIAN
);
160 dest
= tvb_get_letohs(tvb
, *offset
+ len
);
163 proto_tree_add_item(field_tree
, hf_zbee_zdp_rtg_status
, tvb
, *offset
+ len
, 1, ENC_LITTLE_ENDIAN
);
164 status
= tvb_get_uint8(tvb
, *offset
+ len
);
167 proto_tree_add_item(field_tree
, hf_zbee_zdp_rtg_next_hop
, tvb
, *offset
+ len
, 2, ENC_LITTLE_ENDIAN
);
168 next
= tvb_get_letohs(tvb
, *offset
+ len
);
171 /* Display the next hop first, because it looks a lot cleaner that way. */
172 proto_item_append_text(ti
, " {Destination: 0x%04x, Next Hop: 0x%04x, Status: %s}", dest
, next
, val_to_str_const(status
, zbee_zdp_rtg_status_vals
, "Unknown"));
174 } /* zdp_parse_routing_table_entry */
177 /**************************************
178 * MANAGEMENT REQUESTS
179 **************************************
182 *ZigBee Device Profile dissector for the network discovery
184 *@param tvb pointer to buffer containing raw packet.
185 *@param pinfo pointer to packet information fields
186 *@param tree pointer to data tree Wireshark uses to display packet.
189 dissect_zbee_zdp_req_mgmt_nwk_disc(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
, int hf_channel
)
197 /* Get the channel bitmap. */
198 channels
= tvb_get_letohl(tvb
, offset
);
201 ti
= proto_tree_add_uint_format(tree
, hf_channel
, tvb
, offset
, 4, channels
, "Scan Channels: ");
203 for (i
=0; i
<27; i
++) {
204 if (channels
& (1<<i
)) {
205 if (first
) proto_item_append_text(ti
, "%d", i
);
206 else proto_item_append_text(ti
, ", %d", i
);
207 if (channels
& (2<<i
)) {
208 while ((channels
&(2<<i
)) && (i
<26)) i
++;
209 proto_item_append_text(ti
, "-%d", i
);
214 if (first
) proto_item_append_text(ti
, "None");
218 proto_tree_add_item(tree
, hf_zbee_zdp_duration
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
220 proto_tree_add_item(tree
, hf_zbee_zdp_index
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
223 /* Dump any leftover bytes. */
224 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
225 } /* dissect_zbee_zdp_req_mgmt_nwk_disc */
228 *ZigBee Device Profile dissector for the link quality information
230 *@param tvb pointer to buffer containing raw packet.
231 *@param pinfo pointer to packet information fields
232 *@param tree pointer to data tree Wireshark uses to display packet.
235 dissect_zbee_zdp_req_mgmt_lqi(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
239 proto_tree_add_item(tree
, hf_zbee_zdp_index
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
242 /* Dump any leftover bytes. */
243 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
244 } /* dissect_zbee_zdp_req_mgmt_lqi */
247 *ZigBee Device Profile dissector for the routing table
249 *@param tvb pointer to buffer containing raw packet.
250 *@param pinfo pointer to packet information fields
251 *@param tree pointer to data tree Wireshark uses to display packet.
254 dissect_zbee_zdp_req_mgmt_rtg(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
258 proto_tree_add_item(tree
, hf_zbee_zdp_index
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
261 /* Dump any leftover bytes. */
262 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
263 } /* dissect_zbee_zdp_req_mgmt_rtg */
266 *ZigBee Device Profile dissector for the binding table
268 *@param tvb pointer to buffer containing raw packet.
269 *@param pinfo pointer to packet information fields
270 *@param tree pointer to data tree Wireshark uses to display packet.
273 dissect_zbee_zdp_req_mgmt_bind(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
277 proto_tree_add_item(tree
, hf_zbee_zdp_index
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
280 /* Dump any leftover bytes. */
281 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
282 } /* dissect_zbee_zdp_req_mgmt_bind */
285 *ZigBee Device Profile dissector for the leave request.
287 *@param tvb pointer to buffer containing raw packet.
288 *@param pinfo pointer to packet information fields
289 *@param tree pointer to data tree Wireshark uses to display packet.
292 dissect_zbee_zdp_req_mgmt_leave(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
, uint8_t version
)
296 static int * const flags
[] = {
297 &hf_zbee_zdp_leave_children
,
298 &hf_zbee_zdp_leave_rejoin
,
302 ext_addr
= zbee_parse_eui64(tree
, hf_zbee_zdp_ext_addr
, tvb
, &offset
, 8, NULL
);
303 if (version
>= ZBEE_VERSION_2007
) {
304 /* Flags present on ZigBee 2006 & later. */
305 proto_tree_add_bitmask_list(tree
, tvb
, offset
, 1, flags
, ENC_NA
);
309 zbee_append_info(tree
, pinfo
, ", Device: %s", eui64_to_display(pinfo
->pool
, ext_addr
));
311 /* Dump any leftover bytes. */
312 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
313 } /* dissect_zbee_zdp_req_mgmt_bind */
316 *ZigBee Device Profile dissector for the direct join request.
318 *@param tvb pointer to buffer containing raw packet.
319 *@param pinfo pointer to packet information fields
320 *@param tree pointer to data tree Wireshark uses to display packet.
323 dissect_zbee_zdp_req_mgmt_direct_join(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
329 ext_addr
= zbee_parse_eui64(tree
, hf_zbee_zdp_ext_addr
, tvb
, &offset
, 8, NULL
);
330 /*cinfo =*/ zdp_parse_cinfo(tree
, ett_zbee_zdp_cinfo
, tvb
, &offset
);
332 zbee_append_info(tree
, pinfo
, ", Device: %s", eui64_to_display(pinfo
->pool
, ext_addr
));
334 /* Dump any leftover bytes. */
335 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
336 } /* dissect_zbee_zdp_req_mgmt_direct_join */
339 *ZigBee Device Profile dissector for the permit joining
341 *@param tvb pointer to buffer containing raw packet.
342 *@param pinfo pointer to packet information fields
343 *@param tree pointer to data tree Wireshark uses to display packet.
346 dissect_zbee_zdp_req_mgmt_permit_join(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
350 proto_tree_add_item(tree
, hf_zbee_zdp_duration
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
353 proto_tree_add_item(tree
, hf_zbee_zdp_significance
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
356 if (tvb_captured_length_remaining(tvb
, offset
))
358 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_REQ_MGMT_PERMIT_JOIN
);
360 /* Dump any leftover bytes. */
361 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
363 } /* dissect_zbee_zdp_req_mgmt_permit_join */
366 *ZigBee Device Profile dissector for the cache request.
368 *@param tvb pointer to buffer containing raw packet.
369 *@param pinfo pointer to packet information fields
370 *@param tree pointer to data tree Wireshark uses to display packet.
373 dissect_zbee_zdp_req_mgmt_cache(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
377 proto_tree_add_item(tree
, hf_zbee_zdp_index
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
380 /* Dump any leftover bytes. */
381 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
382 } /* dissect_zbee_zdp_req_mgmt_cache */
385 *ZigBee Device Profile dissector for the nwk update request.
387 *@param tvb pointer to buffer containing raw packet.
388 *@param pinfo pointer to packet information fields
389 *@param tree pointer to data tree Wireshark uses to display packet.
392 dissect_zbee_zdp_req_mgmt_nwkupdate(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
397 zdp_parse_chanmask(tree
, tvb
, &offset
, hf_zbee_zdp_channel_page
, hf_zbee_zdp_channel_mask
);
398 proto_tree_add_item_ret_uint(tree
, hf_zbee_zdp_duration
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
, &duration
);
401 if (duration
== ZBEE_ZDP_NWKUPDATE_PARAMETERS
) {
402 proto_tree_add_item(tree
, hf_zbee_zdp_update_id
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
404 proto_tree_add_item(tree
, hf_zbee_zdp_manager
, tvb
, offset
, 2, ENC_LITTLE_ENDIAN
);
407 else if (duration
== ZBEE_ZDP_NWKUPDATE_CHANNEL_HOP
) {
408 proto_tree_add_item(tree
, hf_zbee_zdp_update_id
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
411 else if (duration
<= ZBEE_ZDP_NWKUPDATE_SCAN_MAX
) {
412 proto_tree_add_item(tree
, hf_zbee_zdp_scan_count
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
416 /* Dump any leftover bytes. */
417 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
418 } /* dissect_zbee_zdp_req_mgmt_nwkupdate */
421 *ZigBee Device Profile dissector for the enhanced nwk update request.
423 *@param tvb pointer to buffer containing raw packet.
424 *@param pinfo pointer to packet information fields
425 *@param tree pointer to data tree Wireshark uses to display packet.
428 dissect_zbee_zdp_req_mgmt_nwkupdate_enh(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
431 uint32_t i
, duration
, count
;
433 proto_tree_add_item_ret_uint(tree
, hf_zbee_zdp_channel_page_count
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
, &count
);
436 for (i
=0; i
<count
; i
++) {
437 zdp_parse_chanmask(tree
, tvb
, &offset
, hf_zbee_zdp_channel_page
, hf_zbee_zdp_channel_mask
);
440 proto_tree_add_item_ret_uint(tree
, hf_zbee_zdp_duration
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
, &duration
);
443 if (duration
== ZBEE_ZDP_NWKUPDATE_PARAMETERS
) {
444 proto_tree_add_item(tree
, hf_zbee_zdp_update_id
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
446 proto_tree_add_item(tree
, hf_zbee_zdp_manager
, tvb
, offset
, 2, ENC_LITTLE_ENDIAN
);
449 else if (duration
== ZBEE_ZDP_NWKUPDATE_CHANNEL_HOP
) {
450 proto_tree_add_item(tree
, hf_zbee_zdp_update_id
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
453 else if (duration
<= ZBEE_ZDP_NWKUPDATE_SCAN_MAX
) {
454 proto_tree_add_item(tree
, hf_zbee_zdp_scan_count
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
458 /* Dump any leftover bytes. */
459 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
460 } /* dissect_zbee_zdp_req_mgmt_nwkupdate_enh */
463 *ZigBee Device Profile dissector for the IEEE Joining List Request.
465 *@param tvb pointer to buffer containing raw packet.
466 *@param pinfo pointer to packet information fields
467 *@param tree pointer to data tree Wireshark uses to display packet.
470 dissect_zbee_zdp_req_mgmt_ieee_join_list(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
474 proto_tree_add_item(tree
, hf_zbee_zdp_ieee_join_start_index
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
477 /* Dump any leftover bytes. */
478 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
479 } /* dissect_zbee_zdp_req_mgmt_ieee_join_list */
482 *ZigBee Device Profile dissector for the NWK Beacon Survey Request.
484 *@param tvb pointer to buffer containing raw packet.
485 *@param pinfo pointer to packet information fields
486 *@param tree pointer to data tree Wireshark uses to display packet.
489 dissect_zbee_zdp_req_mgmt_nwk_beacon_survey(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
493 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_REQ_MGMT_NWK_BEACON_SURVEY
);
495 /* Dump any leftover bytes. */
496 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
497 } /* dissect_zbee_zdp_req_mgmt_nwk_beacon_survey */
500 *ZigBee Device Profile dissector for the NWK Beacon Survey Response.
502 *@param tvb pointer to buffer containing raw packet.
503 *@param pinfo pointer to packet information fields
504 *@param tree pointer to data tree Wireshark uses to display packet.
507 dissect_zbee_zdp_rsp_mgmt_nwk_beacon_survey(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
511 zdp_parse_status(tree
, tvb
, &offset
);
513 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_RSP_MGMT_NWK_BEACON_SURVEY
);
515 /* Dump any leftover bytes. */
516 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
517 } /* dissect_zbee_zdp_rsp_mgmt_nwk_beacon_survey */
520 *ZigBee Device Profile dissector for the Security Start Key Negotiation Request.
522 *@param tvb pointer to buffer containing raw packet.
523 *@param pinfo pointer to packet information fields
524 *@param tree pointer to data tree Wireshark uses to display packet.
527 dissect_zbee_zdp_req_security_start_key_negotiation(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
531 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_REQ_SECURITY_START_KEY_NEGOTIATION
);
533 /* Dump any leftover bytes. */
534 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
535 } /* dissect_zbee_zdp_req_security_start_key_negotiation */
538 *ZigBee Device Profile dissector for the Security Get Authentication Token Request.
540 *@param tvb pointer to buffer containing raw packet.
541 *@param pinfo pointer to packet information fields
542 *@param tree pointer to data tree Wireshark uses to display packet.
545 dissect_zbee_zdp_req_security_get_auth_token(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
549 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_REQ_SECURITY_GET_AUTH_TOKEN
);
551 /* Dump any leftover bytes. */
552 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
553 } /* dissect_zbee_zdp_req_security_get_auth_token */
556 *ZigBee Device Profile dissector for the Security Get Authentication Level Request.
558 *@param tvb pointer to buffer containing raw packet.
559 *@param pinfo pointer to packet information fields
560 *@param tree pointer to data tree Wireshark uses to display packet.
563 dissect_zbee_zdp_req_security_get_auth_level(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
567 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_REQ_SECURITY_GET_AUTH_LEVEL
);
569 /* Dump any leftover bytes. */
570 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
571 } /* dissect_zbee_zdp_req_security_get_auth_level */
574 *ZigBee Device Profile dissector for the Security Set Configuration Request.
576 *@param tvb pointer to buffer containing raw packet.
577 *@param pinfo pointer to packet information fields
578 *@param tree pointer to data tree Wireshark uses to display packet.
581 dissect_zbee_zdp_req_security_set_configuration(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
585 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_REQ_SECURITY_SET_CONFIGURATION
);
587 /* Dump any leftover bytes. */
588 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
589 } /* dissect_zbee_zdp_req_security_set_configuration */
592 *ZigBee Device Profile dissector for the Security Get Configuration Request.
594 *@param tvb pointer to buffer containing raw packet.
595 *@param pinfo pointer to packet information fields
596 *@param tree pointer to data tree Wireshark uses to display packet.
599 dissect_zbee_zdp_req_security_get_configuration(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
604 unsigned remaining_length
;
606 remaining_length
= tvb_captured_length_remaining(tvb
, offset
);
607 if (remaining_length
> 0U)
609 count
= tvb_get_uint8(tvb
, offset
);
610 proto_tree_add_item(tree
, hf_zbee_zdp_tlv_count
, tvb
, offset
, 1, ENC_NA
);
613 for (i
= 0; i
< count
; i
++)
615 proto_tree_add_item(tree
, hf_zbee_zdp_tlv_id
, tvb
, offset
, 1, ENC_NA
);
620 /* Dump any leftover bytes. */
621 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
622 } /* dissect_zbee_zdp_req_security_get_configuration */
625 *ZigBee Device Profile dissector for the Security Start Key Update Request.
627 *@param tvb pointer to buffer containing raw packet.
628 *@param pinfo pointer to packet information fields
629 *@param tree pointer to data tree Wireshark uses to display packet.
632 dissect_zbee_zdp_req_security_start_key_update(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
636 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_REQ_SECURITY_START_KEY_UPDATE
);
638 /* Dump any leftover bytes. */
639 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
640 } /* dissect_zbee_zdp_req_security_start_key_update */
643 *ZigBee Device Profile dissector for the Security Decommission Request.
645 *@param tvb pointer to buffer containing raw packet.
646 *@param pinfo pointer to packet information fields
647 *@param tree pointer to data tree Wireshark uses to display packet.
650 dissect_zbee_zdp_req_security_decommission(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
654 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_REQ_SECURITY_DECOMMISSION
);
656 /* Dump any leftover bytes. */
657 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
658 } /* dissect_zbee_zdp_req_security_decommission */
661 *ZigBee Device Profile dissector for the Security Challenge Request.
663 *@param tvb pointer to buffer containing raw packet.
664 *@param pinfo pointer to packet information fields
665 *@param tree pointer to data tree Wireshark uses to display packet.
668 dissect_zbee_zdp_req_security_challenge(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
672 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_REQ_SECURITY_CHALLENGE
);
674 /* Dump any leftover bytes. */
675 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
677 /**************************************
678 * MANAGEMENT RESPONSES
679 **************************************
682 *ZigBee Device Profile dissector for the network discovery
684 *@param tvb pointer to buffer containing raw packet.
685 *@param pinfo pointer to packet information fields
686 *@param tree pointer to data tree Wireshark uses to display packet.
689 dissect_zbee_zdp_rsp_mgmt_nwk_disc(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
, uint8_t version
)
691 proto_tree
*field_tree
= NULL
;
695 uint32_t i
, table_count
;
697 status
= zdp_parse_status(tree
, tvb
, &offset
);
698 proto_tree_add_item(tree
, hf_zbee_zdp_table_size
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
700 proto_tree_add_item(tree
, hf_zbee_zdp_index
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
702 proto_tree_add_item_ret_uint(tree
, hf_zbee_zdp_table_count
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
, &table_count
);
705 if (tree
&& table_count
) {
706 field_tree
= proto_tree_add_subtree(tree
, tvb
, offset
, -1, ett_zbee_zdp_nwk
, NULL
, "Network List");
708 for (i
=0; i
<table_count
; i
++) {
709 zdp_parse_nwk_desc(field_tree
, tvb
, &offset
, version
);
712 zbee_append_info(tree
, pinfo
, ", Status: %s", zdp_status_name(status
));
714 /* Dump any leftover bytes. */
715 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
716 } /* dissect_zbee_zdp_rsp_mgmt_nwk_disc */
719 *ZigBee Device Profile dissector for the link quality information
721 *@param tvb pointer to buffer containing raw packet.
722 *@param pinfo pointer to packet information fields
723 *@param tree pointer to data tree Wireshark uses to display packet.
726 dissect_zbee_zdp_rsp_mgmt_lqi(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
, uint8_t version
)
728 proto_tree
*field_tree
= NULL
;
732 uint32_t i
, table_count
;
734 status
= zdp_parse_status(tree
, tvb
, &offset
);
735 proto_tree_add_item(tree
, hf_zbee_zdp_table_size
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
737 proto_tree_add_item(tree
, hf_zbee_zdp_index
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
739 proto_tree_add_item_ret_uint(tree
, hf_zbee_zdp_table_count
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
, &table_count
);
743 field_tree
= proto_tree_add_subtree(tree
, tvb
, offset
, -1, ett_zbee_zdp_lqi
, NULL
, "Neighbor Table");
744 for (i
=0; i
<table_count
; i
++) {
745 zdp_parse_neighbor_table_entry(field_tree
, tvb
, &offset
, version
);
749 zbee_append_info(tree
, pinfo
, ", Status: %s", zdp_status_name(status
));
751 /* Dump any leftover bytes. */
752 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
753 } /* dissect_zbee_zdp_rsp_mgmt_lqi */
756 *ZigBee Device Profile dissector for the routing table
758 *@param tvb pointer to buffer containing raw packet.
759 *@param pinfo pointer to packet information fields
760 *@param tree pointer to data tree Wireshark uses to display packet.
763 dissect_zbee_zdp_rsp_mgmt_rtg(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
766 proto_tree
*field_tree
= NULL
;
770 uint32_t i
, table_count
;
772 status
= zdp_parse_status(tree
, tvb
, &offset
);
773 proto_tree_add_item(tree
, hf_zbee_zdp_table_size
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
775 proto_tree_add_item(tree
, hf_zbee_zdp_index
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
777 proto_tree_add_item_ret_uint(tree
, hf_zbee_zdp_table_count
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
, &table_count
);
780 if (tree
&& table_count
) {
781 ti
= proto_tree_add_item(tree
, hf_zbee_zdp_rtg
, tvb
, offset
, -1, ENC_NA
);
782 field_tree
= proto_item_add_subtree(ti
, ett_zbee_zdp_rtg
);
784 for (i
=0; i
<table_count
; i
++) {
785 zdp_parse_routing_table_entry(field_tree
, tvb
, &offset
);
788 zbee_append_info(tree
, pinfo
, ", Status: %s", zdp_status_name(status
));
790 /* Dump any leftover bytes. */
791 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
792 } /* dissect_zbee_zdp_rsp_mgmt_rtg */
795 *ZigBee Device Profile dissector for the binding table
797 *@param tvb pointer to buffer containing raw packet.
798 *@param pinfo pointer to packet information fields
799 *@param tree pointer to data tree Wireshark uses to display packet.
802 dissect_zbee_zdp_rsp_mgmt_bind(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
, uint8_t version
)
804 proto_tree
*field_tree
= NULL
;
808 uint32_t i
, table_count
;
810 status
= zdp_parse_status(tree
, tvb
, &offset
);
811 proto_tree_add_item(tree
, hf_zbee_zdp_table_size
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
813 proto_tree_add_item(tree
, hf_zbee_zdp_index
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
815 proto_tree_add_item_ret_uint(tree
, hf_zbee_zdp_table_count
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
, &table_count
);
819 if (tree
&& table_count
) {
820 field_tree
= proto_tree_add_subtree(tree
, tvb
, offset
, -1, ett_zbee_zdp_bind
, NULL
, "Binding Table");
822 for (i
=0; i
<table_count
; i
++) {
823 zdp_parse_bind_table_entry(field_tree
, tvb
, &offset
, version
);
826 zbee_append_info(tree
, pinfo
, ", Status: %s", zdp_status_name(status
));
828 /* Dump any leftover bytes. */
829 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
830 } /* dissect_zbee_zdp_rsp_mgmt_bind */
833 *ZigBee Device Profile dissector for the leave response.
835 *@param tvb pointer to buffer containing raw packet.
836 *@param pinfo pointer to packet information fields
837 *@param tree pointer to data tree Wireshark uses to display packet.
840 dissect_zbee_zdp_rsp_mgmt_leave(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
845 status
= zdp_parse_status(tree
, tvb
, &offset
);
847 zbee_append_info(tree
, pinfo
, ", Status: %s", zdp_status_name(status
));
849 /* Dump any leftover bytes. */
850 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
851 } /* dissect_zbee_zdp_rsp_mgmt_bind */
854 *ZigBee Device Profile dissector for the direct join response.
856 *@param tvb pointer to buffer containing raw packet.
857 *@param pinfo pointer to packet information fields
858 *@param tree pointer to data tree Wireshark uses to display packet.
861 dissect_zbee_zdp_rsp_mgmt_direct_join(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
866 status
= zdp_parse_status(tree
, tvb
, &offset
);
868 zbee_append_info(tree
, pinfo
, ", Status: %s", zdp_status_name(status
));
870 /* Dump any leftover bytes. */
871 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
872 } /* dissect_zbee_zdp_rsp_mgmt_direct_join */
875 *ZigBee Device Profile dissector for the permit joining response.
877 *@param tvb pointer to buffer containing raw packet.
878 *@param pinfo pointer to packet information fields
879 *@param tree pointer to data tree Wireshark uses to display packet.
882 dissect_zbee_zdp_rsp_mgmt_permit_join(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
887 status
= zdp_parse_status(tree
, tvb
, &offset
);
889 zbee_append_info(tree
, pinfo
, ", Status: %s", zdp_status_name(status
));
891 /* Dump any leftover bytes. */
892 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
893 } /* dissect_zbee_zdp_rsp_mgmt_permit_join */
896 *ZigBee Device Profile dissector for the cache response.
898 *@param tvb pointer to buffer containing raw packet.
899 *@param pinfo pointer to packet information fields
900 *@param tree pointer to data tree Wireshark uses to display packet.
903 dissect_zbee_zdp_rsp_mgmt_cache(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
905 proto_tree
*field_tree
= NULL
;
910 uint32_t i
, table_count
;
912 status
= zdp_parse_status(tree
, tvb
, &offset
);
913 proto_tree_add_item(tree
, hf_zbee_zdp_table_size
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
915 proto_tree_add_item(tree
, hf_zbee_zdp_index
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
917 proto_tree_add_item_ret_uint(tree
, hf_zbee_zdp_table_count
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
, &table_count
);
921 field_tree
= proto_tree_add_subtree(tree
, tvb
, offset
, table_count
*(2+8),
922 ett_zbee_zdp_cache
, NULL
, "Discovery Cache");
924 for (i
=0; i
<table_count
; i
++) {
925 uint16_t addr16
= tvb_get_letohs(tvb
, offset
+8);
927 ti
= proto_tree_add_item(field_tree
, hf_zbee_zdp_cache_address
, tvb
, offset
, 8, ENC_LITTLE_ENDIAN
);
928 /* XXX - make 16-bit address filterable? */
929 proto_item_append_text(ti
, " = 0x%04x", addr16
);
930 proto_item_set_len(ti
, 8+2);
935 zbee_append_info(tree
, pinfo
, ", Status: %s", zdp_status_name(status
));
937 /* Dump any leftover bytes. */
938 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
939 } /* dissect_zbee_zdp_rsp_mgmt_bind */
942 *ZigBee Device Profile dissector for both the enhanced and
943 *non-enhanced nwk update notify.
945 *@param tvb pointer to buffer containing raw packet.
946 *@param pinfo pointer to packet information fields
947 *@param tree pointer to data tree Wireshark uses to display packet.
950 dissect_zbee_zdp_not_mgmt_nwkupdate(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
956 uint32_t channels
, channel_count
;
958 /*status =*/ zdp_parse_status(tree
, tvb
, &offset
);
959 channels
= zdp_parse_chanmask(tree
, tvb
, &offset
, hf_zbee_zdp_channel_page
, hf_zbee_zdp_channel_mask
);
960 proto_tree_add_item(tree
, hf_zbee_zdp_tx_total
, tvb
, offset
, 2, ENC_LITTLE_ENDIAN
);
962 proto_tree_add_item(tree
, hf_zbee_zdp_tx_fail
, tvb
, offset
, 2, ENC_LITTLE_ENDIAN
);
964 proto_tree_add_item_ret_uint(tree
, hf_zbee_zdp_channel_count
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
, &channel_count
);
967 /* Display the channel list. */
968 for (i
=0, j
=0; i
<(8*4); i
++) {
971 if ( ! ((1<<i
) & channels
) ) {
972 /* Channel not scanned. */
975 if (j
>=channel_count
) {
976 /* Channel list has ended. */
979 /* Get and display the channel energy. */
980 energy
= tvb_get_uint8(tvb
, offset
);
981 proto_tree_add_uint_format(tree
, hf_zbee_zdp_channel_energy
, tvb
, offset
, 1, energy
, "Channel %d Energy: 0x%02x", i
, energy
);
983 /* Increment the number of channels we found energy values for. */
987 /* Dump any leftover bytes. */
988 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
989 } /* dissect_zbee_zdp_not_mgmt_nwkupdate */
992 *ZigBee Device Profile dissector for the IEEE Joining List Response.
994 *@param tvb pointer to buffer containing raw packet.
995 *@param pinfo pointer to packet information fields
996 *@param tree pointer to data tree Wireshark uses to display packet.
999 dissect_zbee_zdp_rsp_mgmt_ieee_join_list(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
1001 uint32_t i
, status
, list_total
, list_count
;
1002 unsigned offset
= 0;
1004 status
= zdp_parse_status(tree
, tvb
, &offset
);
1005 if (status
== 0x00) {
1006 proto_tree_add_item(tree
, hf_zbee_zdp_ieee_join_update_id
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
1008 proto_tree_add_item(tree
, hf_zbee_zdp_ieee_join_policy
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
1010 proto_tree_add_item_ret_uint(tree
, hf_zbee_zdp_ieee_join_list_total
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
, &list_total
);
1013 if (list_total
> 0) {
1014 proto_tree_add_item(tree
, hf_zbee_zdp_ieee_join_list_start
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
1016 proto_tree_add_item_ret_uint(tree
, hf_zbee_zdp_ieee_join_list_count
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
, &list_count
);
1019 for(i
=0; i
<list_count
; i
++) {
1020 zbee_parse_eui64(tree
, hf_zbee_zdp_ieee_join_list_ieee
, tvb
, &offset
, 8, NULL
);
1024 /* Dump any leftover bytes. */
1025 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
1026 } /* dissect_zbee_zdp_rsp_mgmt_ieee_join_list */
1029 *ZigBee Device Profile dissector for the unsolicited nwk update notify.
1031 *@param tvb pointer to buffer containing raw packet.
1032 *@param pinfo pointer to packet information fields
1033 *@param tree pointer to data tree Wireshark uses to display packet.
1036 dissect_zbee_zdp_not_mgmt_unsolicited_nwkupdate(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
1038 unsigned offset
= 0;
1040 zdp_parse_status(tree
, tvb
, &offset
);
1041 zdp_parse_chanmask(tree
, tvb
, &offset
, hf_zbee_zdp_channel_page
, hf_zbee_zdp_channel_mask
);
1042 proto_tree_add_item(tree
, hf_zbee_zdp_tx_total
, tvb
, offset
, 2, ENC_LITTLE_ENDIAN
);
1044 proto_tree_add_item(tree
, hf_zbee_zdp_tx_fail
, tvb
, offset
, 2, ENC_LITTLE_ENDIAN
);
1046 proto_tree_add_item(tree
, hf_zbee_zdp_tx_retries
, tvb
, offset
, 2, ENC_LITTLE_ENDIAN
);
1048 proto_tree_add_item(tree
, hf_zbee_zdp_period_time_results
, tvb
, offset
, 1, ENC_LITTLE_ENDIAN
);
1051 /* Dump any leftover bytes. */
1052 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
1053 } /* dissect_zbee_zdp_not_mgmt_unsolicited_nwkupdate */
1056 *ZigBee Device Profile dissector for the security start key negotiation response.
1058 *@param tvb pointer to buffer containing raw packet.
1059 *@param pinfo pointer to packet information fields
1060 *@param tree pointer to data tree Wireshark uses to display packet.
1063 dissect_zbee_zdp_rsp_security_start_key_negotiation(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
1065 unsigned offset
= 0;
1067 zdp_parse_status(tree
, tvb
, &offset
);
1068 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_RSP_SECURITY_START_KEY_NEGOTIATION
);
1070 /* Dump any leftover bytes. */
1071 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
1072 } /* dissect_zbee_zdp_rsp_security_start_key_negotiation */
1075 *ZigBee Device Profile dissector for the security get authentication token response.
1077 *@param tvb pointer to buffer containing raw packet.
1078 *@param pinfo pointer to packet information fields
1079 *@param tree pointer to data tree Wireshark uses to display packet.
1082 dissect_zbee_zdp_rsp_security_get_auth_token(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
1084 unsigned offset
= 0;
1086 zdp_parse_status(tree
, tvb
, &offset
);
1087 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_RSP_SECURITY_GET_AUTH_TOKEN
);
1089 /* Dump any leftover bytes. */
1090 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
1091 } /* dissect_zbee_zdp_rsp_security_get_auth_token */
1094 *ZigBee Device Profile dissector for the security get authentication level response.
1096 *@param tvb pointer to buffer containing raw packet.
1097 *@param pinfo pointer to packet information fields
1098 *@param tree pointer to data tree Wireshark uses to display packet.
1101 dissect_zbee_zdp_rsp_security_get_auth_level(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
1103 unsigned offset
= 0;
1105 zdp_parse_status(tree
, tvb
, &offset
);
1106 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_RSP_SECURITY_GET_AUTH_LEVEL
);
1108 /* Dump any leftover bytes. */
1109 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
1110 } /* dissect_zbee_zdp_rsp_security_get_auth_level */
1113 *ZigBee Device Profile dissector for the security set configuration response.
1115 *@param tvb pointer to buffer containing raw packet.
1116 *@param pinfo pointer to packet information fields
1117 *@param tree pointer to data tree Wireshark uses to display packet.
1120 dissect_zbee_zdp_rsp_security_set_configuration(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
1122 unsigned offset
= 0;
1124 zdp_parse_status(tree
, tvb
, &offset
);
1125 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_RSP_SECURITY_SET_CONFIGURATION
);
1127 /* Dump any leftover bytes. */
1128 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
1129 } /* dissect_zbee_zdp_rsp_security_set_configuration */
1132 *ZigBee Device Profile dissector for the security get configuration response.
1134 *@param tvb pointer to buffer containing raw packet.
1135 *@param pinfo pointer to packet information fields
1136 *@param tree pointer to data tree Wireshark uses to display packet.
1139 dissect_zbee_zdp_rsp_security_get_configuration(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
1141 unsigned offset
= 0;
1143 zdp_parse_status(tree
, tvb
, &offset
);
1144 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_RSP_SECURITY_GET_CONFIGURATION
);
1146 /* Dump any leftover bytes. */
1147 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
1148 } /* dissect_zbee_zdp_rsp_security_get_configuration */
1151 *ZigBee Device Profile dissector for the security start key update response.
1153 *@param tvb pointer to buffer containing raw packet.
1154 *@param pinfo pointer to packet information fields
1155 *@param tree pointer to data tree Wireshark uses to display packet.
1158 dissect_zbee_zdp_rsp_security_start_key_update(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
1160 unsigned offset
= 0;
1162 zdp_parse_status(tree
, tvb
, &offset
);
1163 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_RSP_SECURITY_START_KEY_UPDATE
);
1165 /* Dump any leftover bytes. */
1166 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
1167 } /* dissect_zbee_zdp_rsp_security_start_key_update */
1170 *ZigBee Device Profile dissector for the security start key update response.
1172 *@param tvb pointer to buffer containing raw packet.
1173 *@param pinfo pointer to packet information fields
1174 *@param tree pointer to data tree Wireshark uses to display packet.
1177 dissect_zbee_zdp_rsp_security_decommission(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
1179 unsigned offset
= 0;
1181 zdp_parse_status(tree
, tvb
, &offset
);
1182 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_RSP_SECURITY_DECOMMISSION
);
1184 /* Dump any leftover bytes. */
1185 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
1186 } /* dissect_zbee_zdp_rsp_security_decommission */
1189 *ZigBee Device Profile dissector for the Security Challenge Response.
1191 *@param tvb pointer to buffer containing raw packet.
1192 *@param pinfo pointer to packet information fields
1193 *@param tree pointer to data tree Wireshark uses to display packet.
1196 dissect_zbee_zdp_rsp_security_challenge(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
)
1198 unsigned offset
= 0;
1200 zdp_parse_status(tree
, tvb
, &offset
);
1201 offset
= dissect_zbee_tlvs(tvb
, pinfo
, tree
, offset
, NULL
, ZBEE_TLV_SRC_TYPE_ZBEE_ZDP
, ZBEE_ZDP_RSP_SECURITY_CHALLENGE
);
1203 /* Dump any leftover bytes. */
1204 zdp_dump_excess(tvb
, offset
, pinfo
, tree
);
1208 * Editor modelines - https://www.wireshark.org/tools/modelines.html
1213 * indent-tabs-mode: nil
1216 * vi: set shiftwidth=4 tabstop=8 expandtab:
1217 * :indentSize=4:tabSize=8:noTabs=true: