2 * Routines for RX packet dissection
3 * Copyright 1999, Nathan Neulinger <nneul@umr.edu>
4 * Based on routines from tcpdump patches by
5 * Ken Hornstein <kenh@cmf.nrl.navy.mil>
7 * $Id: packet-rx.c,v 1.32 2002/02/01 16:37:18 nneul Exp $
9 * Ethereal - Network traffic analyzer
10 * By Gerald Combs <gerald@ethereal.com>
11 * Copyright 1998 Gerald Combs
13 * Copied from packet-tftp.c
15 * This program is free software; you can redistribute it and/or
16 * modify it under the terms of the GNU General Public License
17 * as published by the Free Software Foundation; either version 2
18 * of the License, or (at your option) any later version.
20 * This program is distributed in the hope that it will be useful,
21 * but WITHOUT ANY WARRANTY; without even the implied warranty of
22 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
23 * GNU General Public License for more details.
25 * You should have received a copy of the GNU General Public License
26 * along with this program; if not, write to the Free Software
27 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
36 #ifdef HAVE_SYS_TYPES_H
37 # include <sys/types.h>
40 #ifdef HAVE_NETINET_IN_H
41 # include <netinet/in.h>
46 #include <epan/packet.h>
47 #include "packet-rx.h"
48 #include <epan/resolv.h>
50 #define UDP_PORT_RX_LOW 7000
51 #define UDP_PORT_RX_HIGH 7009
52 #define UDP_PORT_RX_AFS_BACKUPS 7021
54 static const value_string rx_types[] = {
55 { RX_PACKET_TYPE_DATA, "data" },
56 { RX_PACKET_TYPE_ACK, "ack" },
57 { RX_PACKET_TYPE_BUSY, "busy" },
58 { RX_PACKET_TYPE_ABORT, "abort" },
59 { RX_PACKET_TYPE_ACKALL, "ackall" },
60 { RX_PACKET_TYPE_CHALLENGE, "challenge" },
61 { RX_PACKET_TYPE_RESPONSE, "response" },
62 { RX_PACKET_TYPE_DEBUG, "debug" },
63 { RX_PACKET_TYPE_PARAMS, "params" },
64 { RX_PACKET_TYPE_VERSION, "version" },
68 static const value_string rx_flags[] = {
69 { RX_CLIENT_INITIATED, "client-init" },
70 { RX_REQUEST_ACK, "req-ack" },
71 { RX_LAST_PACKET, "last-pckt" },
72 { RX_MORE_PACKETS, "more-pckts" },
73 { RX_FREE_PACKET, "free-pckt" },
77 static const value_string rx_reason[] = {
78 { RX_ACK_REQUESTED, "Ack Requested" },
79 { RX_ACK_DUPLICATE, "Duplicate Packet" },
80 { RX_ACK_OUT_OF_SEQUENCE, "Out Of Sequence" },
81 { RX_ACK_EXEEDS_WINDOW, "Exceeds Window" },
82 { RX_ACK_NOSPACE, "No Space" },
83 { RX_ACK_PING, "Ping" },
84 { RX_ACK_PING_RESPONSE, "Ping Response" },
85 { RX_ACK_DELAY, "Delay" },
89 static const value_string rx_ack_type[] = {
90 { RX_ACK_TYPE_NACK, "NACK" },
91 { RX_ACK_TYPE_ACK, "ACK" },
95 static int proto_rx = -1;
96 static int hf_rx_epoch = -1;
97 static int hf_rx_cid = -1;
98 static int hf_rx_seq = -1;
99 static int hf_rx_serial = -1;
100 static int hf_rx_callnumber = -1;
101 static int hf_rx_type = -1;
102 static int hf_rx_flags = -1;
103 static int hf_rx_flags_clientinit = -1;
104 static int hf_rx_flags_request_ack = -1;
105 static int hf_rx_flags_last_packet = -1;
106 static int hf_rx_flags_more_packets = -1;
107 static int hf_rx_flags_free_packet = -1;
108 static int hf_rx_userstatus = -1;
109 static int hf_rx_securityindex = -1;
110 static int hf_rx_spare = -1;
111 static int hf_rx_serviceid = -1;
112 static int hf_rx_bufferspace = -1;
113 static int hf_rx_maxskew = -1;
114 static int hf_rx_first_packet = -1;
115 static int hf_rx_prev_packet = -1;
116 static int hf_rx_reason = -1;
117 static int hf_rx_numacks = -1;
118 static int hf_rx_ack_type = -1;
119 static int hf_rx_ack = -1;
120 static int hf_rx_challenge = -1;
121 static int hf_rx_version = -1;
122 static int hf_rx_nonce = -1;
123 static int hf_rx_inc_nonce = -1;
124 static int hf_rx_min_level = -1;
125 static int hf_rx_level = -1;
126 static int hf_rx_response = -1;
127 static int hf_rx_encrypted = -1;
128 static int hf_rx_kvno = -1;
129 static int hf_rx_ticket_len = -1;
130 static int hf_rx_ticket = -1;
131 static int hf_rx_ifmtu = -1;
132 static int hf_rx_maxmtu = -1;
133 static int hf_rx_rwind = -1;
134 static int hf_rx_maxpackets = -1;
135 static int hf_rx_abort = -1;
136 static int hf_rx_abortcode = -1;
138 static gint ett_rx = -1;
139 static gint ett_rx_flags = -1;
140 static gint ett_rx_ack = -1;
141 static gint ett_rx_challenge = -1;
142 static gint ett_rx_response = -1;
143 static gint ett_rx_encrypted = -1;
144 static gint ett_rx_abort = -1;
146 static dissector_handle_t afs_handle;
149 dissect_rx_response_encrypted(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, int offset)
153 int old_offset=offset;
157 item = proto_tree_add_item(parent_tree, hf_rx_encrypted, tvb, offset, -1, FALSE);
158 tree = proto_item_add_subtree(item, ett_rx_encrypted);
160 /* epoch : 4 bytes */
163 ts.secs = tvb_get_ntohl(tvb, offset);
166 proto_tree_add_time(tree, hf_rx_epoch, tvb,
172 proto_tree_add_item(tree, hf_rx_cid, tvb, offset, 4, FALSE);
175 /*FIXME dont know how to handle this checksum, skipping it */
178 /* sequrityindex : 1 byte */
179 proto_tree_add_item(tree, hf_rx_securityindex, tvb, offset, 1, FALSE);
182 for (i=0; i<RX_MAXCALLS; i++) {
183 /* callnumber : 4 bytes */
184 callnumber = tvb_get_ntohl(tvb, offset);
185 proto_tree_add_uint(tree, hf_rx_callnumber, tvb,
186 offset, 4, callnumber);
190 /* inc nonce : 4 bytes */
191 proto_tree_add_item(tree, hf_rx_inc_nonce, tvb, offset, 4, FALSE);
194 /* level : 4 bytes */
195 proto_tree_add_item(tree, hf_rx_level, tvb, offset, 4, FALSE);
198 proto_item_set_len(item, offset-old_offset);
204 dissect_rx_response(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, int offset, guint32 seq, guint32 callnumber)
209 int old_offset=offset;
211 if (check_col(pinfo->cinfo, COL_INFO)) {
212 col_add_fstr(pinfo->cinfo, COL_INFO,
217 "Destination Port: %s ",
219 (unsigned long)callnumber,
220 get_udp_port(pinfo->srcport),
221 get_udp_port(pinfo->destport)
225 item = proto_tree_add_item(parent_tree, hf_rx_response, tvb, offset, -1, FALSE);
226 tree = proto_item_add_subtree(item, ett_rx_response);
228 version = tvb_get_ntohl(tvb, offset);
229 proto_tree_add_uint(tree, hf_rx_version, tvb,
237 /* encrypted : struct */
238 offset = dissect_rx_response_encrypted(tvb, pinfo, tree, offset);
241 proto_tree_add_item(tree, hf_rx_kvno, tvb, offset, 4, FALSE);
245 tl = tvb_get_ntohl(tvb, offset);
246 proto_tree_add_uint(tree, hf_rx_ticket_len, tvb,
250 proto_tree_add_item(tree, hf_rx_ticket, tvb, offset, tl, FALSE);
254 proto_item_set_len(item, offset-old_offset);
259 dissect_rx_abort(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, int offset, guint32 seq, guint32 callnumber)
263 int old_offset=offset;
265 if (check_col(pinfo->cinfo, COL_INFO)) {
266 col_add_fstr(pinfo->cinfo, COL_INFO,
271 "Destination Port: %s ",
273 (unsigned long)callnumber,
274 get_udp_port(pinfo->srcport),
275 get_udp_port(pinfo->destport)
279 item = proto_tree_add_item(parent_tree, hf_rx_abort, tvb, offset, -1, FALSE);
280 tree = proto_item_add_subtree(item, ett_rx_abort);
283 proto_tree_add_item(tree, hf_rx_abortcode, tvb, offset, 4, FALSE);
286 proto_item_set_len(item, offset-old_offset);
292 dissect_rx_challenge(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, int offset, guint32 seq, guint32 callnumber)
297 int old_offset=offset;
299 if (check_col(pinfo->cinfo, COL_INFO)) {
300 col_add_fstr(pinfo->cinfo, COL_INFO,
305 "Destination Port: %s ",
307 (unsigned long)callnumber,
308 get_udp_port(pinfo->srcport),
309 get_udp_port(pinfo->destport)
313 item = proto_tree_add_item(parent_tree, hf_rx_challenge, tvb, offset, -1, FALSE);
314 tree = proto_item_add_subtree(item, ett_rx_challenge);
316 version = tvb_get_ntohl(tvb, offset);
317 proto_tree_add_uint(tree, hf_rx_version, tvb,
322 proto_tree_add_item(tree, hf_rx_nonce, tvb, offset, 4, FALSE);
325 proto_tree_add_item(tree, hf_rx_min_level, tvb, offset, 4, FALSE);
329 proto_item_set_len(item, offset-old_offset);
334 dissect_rx_acks(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, int offset, guint32 seq, guint32 callnumber)
339 int old_offset = offset;
341 if (check_col(pinfo->cinfo, COL_INFO)) {
342 col_add_fstr(pinfo->cinfo, COL_INFO,
347 "Destination Port: %s ",
349 (unsigned long)callnumber,
350 get_udp_port(pinfo->srcport),
351 get_udp_port(pinfo->destport)
355 item = proto_tree_add_item(parent_tree, hf_rx_ack, tvb, offset, -1, FALSE);
356 tree = proto_item_add_subtree(item, ett_rx_ack);
359 /* bufferspace: 2 bytes*/
360 proto_tree_add_item(tree, hf_rx_bufferspace, tvb, offset, 2, FALSE);
363 /* maxskew: 2 bytes*/
364 proto_tree_add_item(tree, hf_rx_maxskew, tvb, offset, 2, FALSE);
367 /* first packet: 4 bytes*/
368 proto_tree_add_item(tree, hf_rx_first_packet, tvb, offset, 4, FALSE);
371 /* prev packet: 4 bytes*/
372 proto_tree_add_item(tree, hf_rx_prev_packet, tvb, offset, 4, FALSE);
375 /* serial : 4 bytes */
376 proto_tree_add_item(tree, hf_rx_serial, tvb, offset, 4, FALSE);
379 /* reason : 1 byte */
380 proto_tree_add_item(tree, hf_rx_reason, tvb, offset, 1, FALSE);
384 num = tvb_get_guint8(tvb, offset);
385 proto_tree_add_uint(tree, hf_rx_numacks, tvb, offset, 1, num);
389 proto_tree_add_item(tree, hf_rx_ack_type, tvb, offset, 1,
394 /* Some implementations adds some extra fields.
395 * As far as I can see, these first add 3 padding bytes and then
396 * up to 4 32-bit values. (0,3,4 have been witnessed)
398 * RX as a protocol seems to be completely nondefined and seems to lack
399 * any sort of documentation other than "read the source of any of the
400 * (compatible?) implementations.
402 if (tvb_length_remaining(tvb, offset)>3) {
403 offset += 3; /* guess. some implementations adds 3 bytes */
405 if (tvb_reported_length_remaining(tvb, offset) >= 4){
406 proto_tree_add_item(tree, hf_rx_ifmtu, tvb, offset, 4,
410 if (tvb_reported_length_remaining(tvb, offset) >= 4){
411 proto_tree_add_item(tree, hf_rx_maxmtu, tvb, offset, 4,
415 if (tvb_reported_length_remaining(tvb, offset) >= 4){
416 proto_tree_add_item(tree, hf_rx_rwind, tvb, offset, 4,
420 if (tvb_reported_length_remaining(tvb, offset) >= 4){
421 proto_tree_add_item(tree, hf_rx_maxpackets, tvb, offset, 4,
427 proto_item_set_len(item, offset-old_offset);
433 dissect_rx_flags(tvbuff_t *tvb, struct rxinfo *rxinfo, proto_tree *parent_tree, int offset)
439 flags = tvb_get_guint8(tvb, offset);
440 rxinfo->flags = flags;
442 item = proto_tree_add_uint(parent_tree, hf_rx_flags, tvb,
444 tree = proto_item_add_subtree(item, ett_rx_flags);
446 proto_tree_add_uint(tree, hf_rx_flags_free_packet, tvb,
448 proto_tree_add_uint(tree, hf_rx_flags_more_packets, tvb,
450 proto_tree_add_uint(tree, hf_rx_flags_last_packet, tvb,
452 proto_tree_add_uint(tree, hf_rx_flags_request_ack, tvb,
454 proto_tree_add_uint(tree, hf_rx_flags_clientinit, tvb,
462 dissect_rx(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree)
467 struct rxinfo rxinfo;
469 guint32 seq, callnumber;
472 if (check_col(pinfo->cinfo, COL_PROTOCOL))
473 col_set_str(pinfo->cinfo, COL_PROTOCOL, "RX");
474 if (check_col(pinfo->cinfo, COL_INFO))
475 col_clear(pinfo->cinfo, COL_INFO);
477 item = proto_tree_add_protocol_format(parent_tree, proto_rx, tvb,
478 offset, 28, "RX Protocol");
479 tree = proto_item_add_subtree(item, ett_rx);
481 /* epoch : 4 bytes */
484 ts.secs = tvb_get_ntohl(tvb, offset);
487 proto_tree_add_time(tree, hf_rx_epoch, tvb,
493 proto_tree_add_item(tree, hf_rx_cid, tvb, offset, 4, FALSE);
496 /* callnumber : 4 bytes */
497 callnumber = tvb_get_ntohl(tvb, offset);
498 proto_tree_add_uint(tree, hf_rx_callnumber, tvb,
499 offset, 4, callnumber);
501 rxinfo.callnumber = callnumber;
504 seq = tvb_get_ntohl(tvb, offset);
505 proto_tree_add_uint(tree, hf_rx_seq, tvb,
510 /* serial : 4 bytes */
511 proto_tree_add_item(tree, hf_rx_serial, tvb, offset, 4, FALSE);
515 type = tvb_get_guint8(tvb, offset);
516 proto_tree_add_uint(tree, hf_rx_type, tvb,
522 offset = dissect_rx_flags(tvb, &rxinfo, tree, offset);
524 /* userstatus : 1 byte */
525 proto_tree_add_item(tree, hf_rx_userstatus, tvb, offset, 1, FALSE);
528 /* sequrityindex : 1 byte */
529 proto_tree_add_item(tree, hf_rx_securityindex, tvb, offset, 1, FALSE);
533 * How clever: even though the AFS header files indicate that the
534 * serviceId is first, it's really encoded _after_ the spare field.
535 * I wasted a day figuring that out!
539 proto_tree_add_item(tree, hf_rx_spare, tvb, offset, 2, FALSE);
542 /* service id : 2 bytes */
543 serviceid = tvb_get_ntohs(tvb, offset);
544 proto_tree_add_uint(tree, hf_rx_serviceid, tvb,
545 offset, 2, serviceid);
547 rxinfo.serviceid = serviceid;
550 case RX_PACKET_TYPE_ACK:
551 /*dissect_rx_acks(tvb, pinfo, parent_tree, offset,
552 cant create it in a parallell tree, then ett seasrch
554 dissect_rx_acks(tvb, pinfo, tree, offset,
557 case RX_PACKET_TYPE_ACKALL:
558 /* does not contain any payload */
559 if (check_col(pinfo->cinfo, COL_INFO)) {
560 col_add_fstr(pinfo->cinfo, COL_INFO,
565 "Destination Port: %s ",
567 (unsigned long)callnumber,
568 get_udp_port(pinfo->srcport),
569 get_udp_port(pinfo->destport)
573 case RX_PACKET_TYPE_CHALLENGE:
574 dissect_rx_challenge(tvb, pinfo, tree, offset, seq, callnumber);
576 case RX_PACKET_TYPE_RESPONSE:
577 dissect_rx_response(tvb, pinfo, tree, offset, seq, callnumber);
579 case RX_PACKET_TYPE_DATA: {
581 pinfo->private_data = &rxinfo;
582 next_tvb = tvb_new_subset(tvb, offset, -1, -1);
583 call_dissector(afs_handle, next_tvb, pinfo, parent_tree);
586 case RX_PACKET_TYPE_ABORT:
587 dissect_rx_abort(tvb, pinfo, tree, offset, seq, callnumber);
594 proto_register_rx(void)
596 static hf_register_info hf[] = {
598 "Epoch", "rx.epoch", FT_ABSOLUTE_TIME, BASE_DEC,
599 NULL, 0, "Epoch", HFILL }},
602 "CID", "rx.cid", FT_UINT32, BASE_DEC,
603 NULL, 0, "CID", HFILL }},
605 { &hf_rx_callnumber, {
606 "Call Number", "rx.callnumber", FT_UINT32, BASE_DEC,
607 NULL, 0, "Call Number", HFILL }},
610 "Sequence Number", "rx.seq", FT_UINT32, BASE_DEC,
611 NULL, 0, "Sequence Number", HFILL }},
614 "Serial", "rx.serial", FT_UINT32, BASE_DEC,
615 NULL, 0, "Serial", HFILL }},
618 "Type", "rx.type", FT_UINT8, BASE_DEC,
619 VALS(rx_types), 0, "Type", HFILL }},
622 "Flags", "rx.flags", FT_UINT8, BASE_HEX,
623 NULL, 0, "Flags", HFILL }},
625 { &hf_rx_flags_clientinit, {
626 "Client Initiated", "rx.flags.client_init", FT_UINT8, BASE_BIN,
627 NULL, RX_CLIENT_INITIATED, "Client Initiated", HFILL }},
629 { &hf_rx_flags_request_ack, {
630 "Request Ack", "rx.flags.request_ack", FT_UINT8, BASE_BIN,
631 NULL, RX_REQUEST_ACK, "Request Ack", HFILL }},
633 { &hf_rx_flags_last_packet, {
634 "Last Packet", "rx.flags.last_packet", FT_UINT8, BASE_BIN,
635 NULL, RX_LAST_PACKET, "Last Packet", HFILL }},
637 { &hf_rx_flags_more_packets, {
638 "More Packets", "rx.flags.more_packets", FT_UINT8, BASE_BIN,
639 NULL, RX_MORE_PACKETS, "More Packets", HFILL }},
641 { &hf_rx_flags_free_packet, {
642 "Free Packet", "rx.flags.free_packet", FT_UINT8, BASE_BIN,
643 NULL, RX_FREE_PACKET, "Free Packet", HFILL }},
645 { &hf_rx_userstatus, {
646 "User Status", "rx.userstatus", FT_UINT32, BASE_DEC,
647 NULL, 0, "User Status", HFILL }},
649 { &hf_rx_securityindex, {
650 "Security Index", "rx.securityindex", FT_UINT32, BASE_DEC,
651 NULL, 0, "Security Index", HFILL }},
654 "Spare/Checksum", "rx.spare", FT_UINT16, BASE_DEC,
655 NULL, 0, "Spare/Checksum", HFILL }},
657 { &hf_rx_serviceid, {
658 "Service ID", "rx.serviceid", FT_UINT16, BASE_DEC,
659 NULL, 0, "Service ID", HFILL }},
661 { &hf_rx_bufferspace, {
662 "Bufferspace", "rx.bufferspace", FT_UINT16, BASE_DEC,
663 NULL, 0, "Number Of Packets Available", HFILL }},
666 "Max Skew", "rx.maxskew", FT_UINT16, BASE_DEC,
667 NULL, 0, "Max Skew", HFILL }},
669 { &hf_rx_first_packet, {
670 "First Packet", "rx.first", FT_UINT32, BASE_DEC,
671 NULL, 0, "First Packet", HFILL }},
673 { &hf_rx_prev_packet, {
674 "Prev Packet", "rx.prev", FT_UINT32, BASE_DEC,
675 NULL, 0, "Previous Packet", HFILL }},
678 "Reason", "rx.reason", FT_UINT8, BASE_DEC,
679 VALS(rx_reason), 0, "Reason For This ACK", HFILL }},
682 "Num ACKs", "rx.num_acks", FT_UINT8, BASE_DEC,
683 NULL, 0, "Number Of ACKs", HFILL }},
686 "ACK Type", "rx.ack_type", FT_UINT8, BASE_DEC,
687 VALS(rx_ack_type), 0, "Type Of ACKs", HFILL }},
690 "ACK Packet", "rx.ack", FT_NONE, BASE_NONE,
691 NULL, 0, "ACK Packet", HFILL }},
693 { &hf_rx_challenge, {
694 "CHALLENGE Packet", "rx.challenge", FT_NONE, BASE_NONE,
695 NULL, 0, "CHALLENGE Packet", HFILL }},
698 "Version", "rx.version", FT_UINT32, BASE_DEC,
699 NULL, 0, "Version Of Challenge/Response", HFILL }},
702 "Nonce", "rx.nonce", FT_UINT32, BASE_HEX,
703 NULL, 0, "Nonce", HFILL }},
705 { &hf_rx_inc_nonce, {
706 "Inc Nonce", "rx.inc_nonce", FT_UINT32, BASE_HEX,
707 NULL, 0, "Incremented Nonce", HFILL }},
709 { &hf_rx_min_level, {
710 "Min Level", "rx.min_level", FT_UINT32, BASE_DEC,
711 NULL, 0, "Min Level", HFILL }},
714 "Level", "rx.level", FT_UINT32, BASE_DEC,
715 NULL, 0, "Level", HFILL }},
718 "RESPONSE Packet", "rx.response", FT_NONE, BASE_NONE,
719 NULL, 0, "RESPONSE Packet", HFILL }},
722 "ABORT Packet", "rx.abort", FT_NONE, BASE_NONE,
723 NULL, 0, "ABORT Packet", HFILL }},
725 { &hf_rx_encrypted, {
726 "Encrypted", "rx.encrypted", FT_NONE, BASE_NONE,
727 NULL, 0, "Encrypted part of response packet", HFILL }},
730 "kvno", "rx.kvno", FT_UINT32, BASE_DEC,
731 NULL, 0, "kvno", HFILL }},
733 { &hf_rx_ticket_len, {
734 "Ticket len", "rx.ticket_len", FT_UINT32, BASE_DEC,
735 NULL, 0, "Ticket Length", HFILL }},
738 "ticket", "rx.ticket", FT_BYTES, BASE_HEX,
739 NULL, 0, "Ticket", HFILL }},
742 "Interface MTU", "rx.if_mtu", FT_UINT32, BASE_DEC,
743 NULL, 0, "Interface MTU", HFILL }},
746 "Max MTU", "rx.max_mtu", FT_UINT32, BASE_DEC,
747 NULL, 0, "Max MTU", HFILL }},
750 "rwind", "rx.rwind", FT_UINT32, BASE_DEC,
751 NULL, 0, "rwind", HFILL }},
753 { &hf_rx_maxpackets, {
754 "Max Packets", "rx.max_packets", FT_UINT32, BASE_DEC,
755 NULL, 0, "Max Packets", HFILL }},
757 { &hf_rx_abortcode, {
758 "Abort Code", "rx.abort_code", FT_UINT32, BASE_DEC,
759 NULL, 0, "Abort Code", HFILL }},
762 static gint *ett[] = {
772 proto_rx = proto_register_protocol("RX Protocol", "RX", "rx");
773 proto_register_field_array(proto_rx, hf, array_length(hf));
774 proto_register_subtree_array(ett, array_length(ett));
778 proto_reg_handoff_rx(void)
780 dissector_handle_t rx_handle;
785 * Get handle for the AFS dissector.
787 afs_handle = find_dissector("afs");
789 /* Ports in the range UDP_PORT_RX_LOW to UDP_PORT_RX_HIGH
790 are all used for various AFS services. */
791 rx_handle = create_dissector_handle(dissect_rx, proto_rx);
792 for (port = UDP_PORT_RX_LOW; port <= UDP_PORT_RX_HIGH; port++)
793 dissector_add("udp.port", port, rx_handle);
794 dissector_add("udp.port", UDP_PORT_RX_AFS_BACKUPS, rx_handle);