1999-10-20 16:41:20 +00:00
|
|
|
/* packet-rx.c
|
|
|
|
* Routines for RX packet dissection
|
|
|
|
* Copyright 1999, Nathan Neulinger <nneul@umr.edu>
|
|
|
|
* Based on routines from tcpdump patches by
|
|
|
|
* Ken Hornstein <kenh@cmf.nrl.navy.mil>
|
|
|
|
*
|
2004-07-18 00:24:25 +00:00
|
|
|
* $Id$
|
1999-10-20 16:41:20 +00:00
|
|
|
*
|
2006-05-21 04:49:01 +00:00
|
|
|
* Wireshark - Network traffic analyzer
|
|
|
|
* By Gerald Combs <gerald@wireshark.org>
|
1999-10-20 16:41:20 +00:00
|
|
|
* Copyright 1998 Gerald Combs
|
|
|
|
*
|
|
|
|
* Copied from packet-tftp.c
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or
|
|
|
|
* modify it under the terms of the GNU General Public License
|
|
|
|
* as published by the Free Software Foundation; either version 2
|
|
|
|
* of the License, or (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, write to the Free Software
|
|
|
|
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifdef HAVE_CONFIG_H
|
|
|
|
# include "config.h"
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#include <stdio.h>
|
|
|
|
|
|
|
|
#include <string.h>
|
|
|
|
#include <glib.h>
|
2002-01-21 07:37:49 +00:00
|
|
|
#include <epan/packet.h>
|
1999-10-20 16:41:20 +00:00
|
|
|
#include "packet-rx.h"
|
2004-08-06 19:57:49 +00:00
|
|
|
#include <epan/addr_resolv.h>
|
1999-10-20 16:41:20 +00:00
|
|
|
|
2005-02-28 19:47:46 +00:00
|
|
|
/*
|
|
|
|
* See
|
|
|
|
*
|
|
|
|
* http://web.mit.edu/kolya/afs/rx/rx-spec
|
|
|
|
*
|
|
|
|
* XXX - is the "Epoch" really a UN*X time? The high-order bit, according
|
|
|
|
* to that spec, is a flag bit.
|
|
|
|
*/
|
|
|
|
|
2000-04-14 06:42:52 +00:00
|
|
|
#define UDP_PORT_RX_LOW 7000
|
|
|
|
#define UDP_PORT_RX_HIGH 7009
|
|
|
|
#define UDP_PORT_RX_AFS_BACKUPS 7021
|
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
static const value_string rx_types[] = {
|
|
|
|
{ RX_PACKET_TYPE_DATA, "data" },
|
|
|
|
{ RX_PACKET_TYPE_ACK, "ack" },
|
|
|
|
{ RX_PACKET_TYPE_BUSY, "busy" },
|
|
|
|
{ RX_PACKET_TYPE_ABORT, "abort" },
|
|
|
|
{ RX_PACKET_TYPE_ACKALL, "ackall" },
|
|
|
|
{ RX_PACKET_TYPE_CHALLENGE, "challenge" },
|
|
|
|
{ RX_PACKET_TYPE_RESPONSE, "response" },
|
|
|
|
{ RX_PACKET_TYPE_DEBUG, "debug" },
|
|
|
|
{ RX_PACKET_TYPE_PARAMS, "params" },
|
|
|
|
{ RX_PACKET_TYPE_VERSION, "version" },
|
|
|
|
{ 0, NULL },
|
|
|
|
};
|
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
static const value_string rx_reason[] = {
|
|
|
|
{ RX_ACK_REQUESTED, "Ack Requested" },
|
|
|
|
{ RX_ACK_DUPLICATE, "Duplicate Packet" },
|
|
|
|
{ RX_ACK_OUT_OF_SEQUENCE, "Out Of Sequence" },
|
2002-08-28 21:04:11 +00:00
|
|
|
{ RX_ACK_EXEEDS_WINDOW, "Exceeds Window" },
|
2001-05-27 01:48:25 +00:00
|
|
|
{ RX_ACK_NOSPACE, "No Space" },
|
|
|
|
{ RX_ACK_PING, "Ping" },
|
|
|
|
{ RX_ACK_PING_RESPONSE, "Ping Response" },
|
|
|
|
{ RX_ACK_DELAY, "Delay" },
|
2002-02-05 21:02:36 +00:00
|
|
|
{ RX_ACK_IDLE, "Idle" },
|
2001-05-27 01:48:25 +00:00
|
|
|
{ 0, NULL }
|
|
|
|
};
|
|
|
|
|
|
|
|
static const value_string rx_ack_type[] = {
|
|
|
|
{ RX_ACK_TYPE_NACK, "NACK" },
|
|
|
|
{ RX_ACK_TYPE_ACK, "ACK" },
|
|
|
|
{ 0, NULL }
|
|
|
|
};
|
1999-10-20 16:41:20 +00:00
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
static int proto_rx = -1;
|
1999-10-20 16:41:20 +00:00
|
|
|
static int hf_rx_epoch = -1;
|
|
|
|
static int hf_rx_cid = -1;
|
|
|
|
static int hf_rx_seq = -1;
|
|
|
|
static int hf_rx_serial = -1;
|
|
|
|
static int hf_rx_callnumber = -1;
|
|
|
|
static int hf_rx_type = -1;
|
|
|
|
static int hf_rx_flags = -1;
|
|
|
|
static int hf_rx_flags_clientinit = -1;
|
|
|
|
static int hf_rx_flags_request_ack = -1;
|
|
|
|
static int hf_rx_flags_last_packet = -1;
|
|
|
|
static int hf_rx_flags_more_packets = -1;
|
|
|
|
static int hf_rx_flags_free_packet = -1;
|
|
|
|
static int hf_rx_userstatus = -1;
|
|
|
|
static int hf_rx_securityindex = -1;
|
|
|
|
static int hf_rx_spare = -1;
|
|
|
|
static int hf_rx_serviceid = -1;
|
2001-05-27 01:48:25 +00:00
|
|
|
static int hf_rx_bufferspace = -1;
|
|
|
|
static int hf_rx_maxskew = -1;
|
|
|
|
static int hf_rx_first_packet = -1;
|
|
|
|
static int hf_rx_prev_packet = -1;
|
|
|
|
static int hf_rx_reason = -1;
|
|
|
|
static int hf_rx_numacks = -1;
|
|
|
|
static int hf_rx_ack_type = -1;
|
|
|
|
static int hf_rx_ack = -1;
|
|
|
|
static int hf_rx_challenge = -1;
|
|
|
|
static int hf_rx_version = -1;
|
|
|
|
static int hf_rx_nonce = -1;
|
|
|
|
static int hf_rx_inc_nonce = -1;
|
|
|
|
static int hf_rx_min_level = -1;
|
|
|
|
static int hf_rx_level = -1;
|
|
|
|
static int hf_rx_response = -1;
|
|
|
|
static int hf_rx_encrypted = -1;
|
|
|
|
static int hf_rx_kvno = -1;
|
|
|
|
static int hf_rx_ticket_len = -1;
|
|
|
|
static int hf_rx_ticket = -1;
|
2001-07-03 00:46:52 +00:00
|
|
|
static int hf_rx_ifmtu = -1;
|
|
|
|
static int hf_rx_maxmtu = -1;
|
|
|
|
static int hf_rx_rwind = -1;
|
|
|
|
static int hf_rx_maxpackets = -1;
|
2002-02-01 16:37:18 +00:00
|
|
|
static int hf_rx_abort = -1;
|
|
|
|
static int hf_rx_abortcode = -1;
|
1999-10-20 16:41:20 +00:00
|
|
|
|
1999-11-16 11:44:20 +00:00
|
|
|
static gint ett_rx = -1;
|
|
|
|
static gint ett_rx_flags = -1;
|
2001-05-27 01:48:25 +00:00
|
|
|
static gint ett_rx_ack = -1;
|
|
|
|
static gint ett_rx_challenge = -1;
|
|
|
|
static gint ett_rx_response = -1;
|
|
|
|
static gint ett_rx_encrypted = -1;
|
2002-02-01 16:37:18 +00:00
|
|
|
static gint ett_rx_abort = -1;
|
1999-11-16 11:44:20 +00:00
|
|
|
|
2001-05-27 05:00:17 +00:00
|
|
|
static dissector_handle_t afs_handle;
|
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
static int
|
2002-04-14 23:22:22 +00:00
|
|
|
dissect_rx_response_encrypted(tvbuff_t *tvb, proto_tree *parent_tree, int offset)
|
1999-10-20 16:41:20 +00:00
|
|
|
{
|
2001-05-27 01:48:25 +00:00
|
|
|
proto_tree *tree;
|
|
|
|
proto_item *item;
|
|
|
|
int old_offset=offset;
|
|
|
|
int i;
|
|
|
|
guint32 callnumber;
|
|
|
|
|
Allow a length of -1 to be specified when adding FT_NONE and FT_PROTOCOL
items to the protocol tree; it's interpreted as "the rest of the data in
the tvbuff". This can be used if
1) the item covers the entire packet or the remaining payload in
the packet
or
2) the item's length won't be known until it's dissected, and
will be then set with "proto_item_set_len()" - if an
exception is thrown in the dissection, it means the item ran
*past* the end of the tvbuff, so saying it runs to the end of
the tvbuff is reasonable.
Convert a number of "proto_tree_add_XXX()" calls using
"tvb_length_remaining()", values derived from the result of
"tvb_length()", or 0 (in the case of items whose length is unknown) to
use -1 instead (using 0 means that if an exception is thrown, selecting
the item highlights nothing; using -1 means it highlights all the data
for that item that's available).
In some places where "tvb_length()" or "tvb_length_remaining()" was used
to determine how large a packet is, use "tvb_reported_length()" or
"tvb_reported_length_remaining()", instead - the first two calls
indicate how much captured data was in the packet, the latter two calls
indicate how large the packet actually was (and the fact that using the
latter could cause BoundsError exceptions to be thrown is a feature - if
such an exception is thrown, the frame really *was* short, and it should
be tagged as such).
Replace some "proto_tree_add_XXX()" calls with equivalent
"proto_tree_add_item()" calls.
Fix some indentation.
svn path=/trunk/; revision=4578
2002-01-20 22:12:39 +00:00
|
|
|
item = proto_tree_add_item(parent_tree, hf_rx_encrypted, tvb, offset, -1, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
tree = proto_item_add_subtree(item, ett_rx_encrypted);
|
|
|
|
|
|
|
|
/* epoch : 4 bytes */
|
|
|
|
{
|
2001-09-14 07:10:13 +00:00
|
|
|
nstime_t ts;
|
|
|
|
ts.secs = tvb_get_ntohl(tvb, offset);
|
|
|
|
ts.nsecs = 0;
|
2002-08-28 21:04:11 +00:00
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
proto_tree_add_time(tree, hf_rx_epoch, tvb,
|
2001-09-14 07:10:13 +00:00
|
|
|
offset, 4, &ts);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 4;
|
|
|
|
}
|
|
|
|
|
|
|
|
/* cid : 4 bytes */
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_cid, tvb, offset, 4, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 4;
|
|
|
|
|
|
|
|
/*FIXME dont know how to handle this checksum, skipping it */
|
|
|
|
offset += 4;
|
|
|
|
|
|
|
|
/* sequrityindex : 1 byte */
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_securityindex, tvb, offset, 1, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 4;
|
|
|
|
|
|
|
|
for (i=0; i<RX_MAXCALLS; i++) {
|
|
|
|
/* callnumber : 4 bytes */
|
|
|
|
callnumber = tvb_get_ntohl(tvb, offset);
|
|
|
|
proto_tree_add_uint(tree, hf_rx_callnumber, tvb,
|
|
|
|
offset, 4, callnumber);
|
|
|
|
offset += 4;
|
|
|
|
}
|
1999-10-20 16:41:20 +00:00
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
/* inc nonce : 4 bytes */
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_inc_nonce, tvb, offset, 4, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 4;
|
Add the "Edit:Protocols..." feature which currently only implements
the following:
It is now possible to enable/disable a particular protocol decoding
(i.e. the protocol dissector is void or not). When a protocol
is disabled, it is displayed as Data and of course, all linked
sub-protocols are disabled as well.
Disabling a protocol could be interesting:
- in case of buggy dissectors
- in case of wrong heuristics
- for performance reasons
- to decode the data as another protocol (TODO)
Currently (if I am not wrong), all dissectors but NFS can be disabled
(and dissectors that do not register protocols :-)
I do not like the way the RPC sub-dissectors are disabled (in the
sub-dissectors) since this could be done in the RPC dissector itself,
knowing the sub-protocol hfinfo entry (this is why, I've not modified
the NFS one yet).
Two functions are added in proto.c :
gboolean proto_is_protocol_enabled(int n);
void proto_set_decoding(int n, gboolean enabled);
and two MACROs which can be used in dissectors:
OLD_CHECK_DISPLAY_AS_DATA(index, pd, offset, fd, tree)
CHECK_DISPLAY_AS_DATA(index, tvb, pinfo, tree)
See also the XXX in proto_dlg.c and proto.c around the new functions.
svn path=/trunk/; revision=2267
2000-08-13 14:09:15 +00:00
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
/* level : 4 bytes */
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_level, tvb, offset, 4, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 4;
|
2002-08-28 21:04:11 +00:00
|
|
|
|
|
|
|
proto_item_set_len(item, offset-old_offset);
|
2001-05-27 01:48:25 +00:00
|
|
|
return offset;
|
|
|
|
}
|
2002-08-28 21:04:11 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
static int
|
|
|
|
dissect_rx_response(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, int offset, guint32 seq, guint32 callnumber)
|
|
|
|
{
|
|
|
|
proto_tree *tree;
|
|
|
|
proto_item *item;
|
|
|
|
guint32 version, tl;
|
|
|
|
int old_offset=offset;
|
1999-10-20 16:41:20 +00:00
|
|
|
|
2001-12-10 00:26:21 +00:00
|
|
|
if (check_col(pinfo->cinfo, COL_INFO)) {
|
|
|
|
col_add_fstr(pinfo->cinfo, COL_INFO,
|
2001-05-27 01:48:25 +00:00
|
|
|
"RESPONSE "
|
|
|
|
"Seq: %lu "
|
|
|
|
"Call: %lu "
|
|
|
|
"Source Port: %s "
|
|
|
|
"Destination Port: %s ",
|
|
|
|
(unsigned long)seq,
|
|
|
|
(unsigned long)callnumber,
|
|
|
|
get_udp_port(pinfo->srcport),
|
|
|
|
get_udp_port(pinfo->destport)
|
|
|
|
);
|
|
|
|
}
|
|
|
|
|
Allow a length of -1 to be specified when adding FT_NONE and FT_PROTOCOL
items to the protocol tree; it's interpreted as "the rest of the data in
the tvbuff". This can be used if
1) the item covers the entire packet or the remaining payload in
the packet
or
2) the item's length won't be known until it's dissected, and
will be then set with "proto_item_set_len()" - if an
exception is thrown in the dissection, it means the item ran
*past* the end of the tvbuff, so saying it runs to the end of
the tvbuff is reasonable.
Convert a number of "proto_tree_add_XXX()" calls using
"tvb_length_remaining()", values derived from the result of
"tvb_length()", or 0 (in the case of items whose length is unknown) to
use -1 instead (using 0 means that if an exception is thrown, selecting
the item highlights nothing; using -1 means it highlights all the data
for that item that's available).
In some places where "tvb_length()" or "tvb_length_remaining()" was used
to determine how large a packet is, use "tvb_reported_length()" or
"tvb_reported_length_remaining()", instead - the first two calls
indicate how much captured data was in the packet, the latter two calls
indicate how large the packet actually was (and the fact that using the
latter could cause BoundsError exceptions to be thrown is a feature - if
such an exception is thrown, the frame really *was* short, and it should
be tagged as such).
Replace some "proto_tree_add_XXX()" calls with equivalent
"proto_tree_add_item()" calls.
Fix some indentation.
svn path=/trunk/; revision=4578
2002-01-20 22:12:39 +00:00
|
|
|
item = proto_tree_add_item(parent_tree, hf_rx_response, tvb, offset, -1, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
tree = proto_item_add_subtree(item, ett_rx_response);
|
1999-10-20 16:41:20 +00:00
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
version = tvb_get_ntohl(tvb, offset);
|
|
|
|
proto_tree_add_uint(tree, hf_rx_version, tvb,
|
|
|
|
offset, 4, version);
|
|
|
|
offset += 4;
|
1999-10-20 16:41:20 +00:00
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
if (version==2) {
|
|
|
|
/* skip unused */
|
|
|
|
offset += 4;
|
1999-10-20 16:41:20 +00:00
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
/* encrypted : struct */
|
2002-04-14 23:22:22 +00:00
|
|
|
offset = dissect_rx_response_encrypted(tvb, tree, offset);
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
/* kvno */
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_kvno, tvb, offset, 4, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 4;
|
2002-08-28 21:04:11 +00:00
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
/* ticket_len */
|
|
|
|
tl = tvb_get_ntohl(tvb, offset);
|
|
|
|
proto_tree_add_uint(tree, hf_rx_ticket_len, tvb,
|
|
|
|
offset, 4, tl);
|
|
|
|
offset += 4;
|
2002-08-28 21:04:11 +00:00
|
|
|
|
2005-04-13 20:59:39 +00:00
|
|
|
tvb_ensure_bytes_exist(tvb, offset, tl);
|
2001-05-27 01:48:25 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_ticket, tvb, offset, tl, FALSE);
|
2002-08-28 21:04:11 +00:00
|
|
|
offset += tl;
|
2001-05-27 01:48:25 +00:00
|
|
|
}
|
|
|
|
|
2002-08-28 21:04:11 +00:00
|
|
|
proto_item_set_len(item, offset-old_offset);
|
2001-05-27 01:48:25 +00:00
|
|
|
return offset;
|
|
|
|
}
|
2001-03-26 15:27:55 +00:00
|
|
|
|
2002-02-01 16:37:18 +00:00
|
|
|
static int
|
|
|
|
dissect_rx_abort(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, int offset, guint32 seq, guint32 callnumber)
|
|
|
|
{
|
|
|
|
proto_tree *tree;
|
|
|
|
proto_item *item;
|
|
|
|
int old_offset=offset;
|
|
|
|
|
|
|
|
if (check_col(pinfo->cinfo, COL_INFO)) {
|
|
|
|
col_add_fstr(pinfo->cinfo, COL_INFO,
|
|
|
|
"ABORT "
|
|
|
|
"Seq: %lu "
|
|
|
|
"Call: %lu "
|
|
|
|
"Source Port: %s "
|
|
|
|
"Destination Port: %s ",
|
|
|
|
(unsigned long)seq,
|
|
|
|
(unsigned long)callnumber,
|
|
|
|
get_udp_port(pinfo->srcport),
|
|
|
|
get_udp_port(pinfo->destport)
|
|
|
|
);
|
|
|
|
}
|
|
|
|
|
|
|
|
item = proto_tree_add_item(parent_tree, hf_rx_abort, tvb, offset, -1, FALSE);
|
|
|
|
tree = proto_item_add_subtree(item, ett_rx_abort);
|
|
|
|
|
|
|
|
/* kvno */
|
|
|
|
proto_tree_add_item(tree, hf_rx_abortcode, tvb, offset, 4, FALSE);
|
|
|
|
offset += 4;
|
2002-08-28 21:04:11 +00:00
|
|
|
|
|
|
|
proto_item_set_len(item, offset-old_offset);
|
2002-02-01 16:37:18 +00:00
|
|
|
return offset;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
static int
|
|
|
|
dissect_rx_challenge(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, int offset, guint32 seq, guint32 callnumber)
|
|
|
|
{
|
|
|
|
proto_tree *tree;
|
|
|
|
proto_item *item;
|
|
|
|
guint32 version;
|
|
|
|
int old_offset=offset;
|
|
|
|
|
2001-12-10 00:26:21 +00:00
|
|
|
if (check_col(pinfo->cinfo, COL_INFO)) {
|
|
|
|
col_add_fstr(pinfo->cinfo, COL_INFO,
|
2001-05-27 01:48:25 +00:00
|
|
|
"CHALLENGE "
|
|
|
|
"Seq: %lu "
|
|
|
|
"Call: %lu "
|
|
|
|
"Source Port: %s "
|
|
|
|
"Destination Port: %s ",
|
|
|
|
(unsigned long)seq,
|
|
|
|
(unsigned long)callnumber,
|
|
|
|
get_udp_port(pinfo->srcport),
|
|
|
|
get_udp_port(pinfo->destport)
|
|
|
|
);
|
1999-10-20 16:41:20 +00:00
|
|
|
}
|
|
|
|
|
Allow a length of -1 to be specified when adding FT_NONE and FT_PROTOCOL
items to the protocol tree; it's interpreted as "the rest of the data in
the tvbuff". This can be used if
1) the item covers the entire packet or the remaining payload in
the packet
or
2) the item's length won't be known until it's dissected, and
will be then set with "proto_item_set_len()" - if an
exception is thrown in the dissection, it means the item ran
*past* the end of the tvbuff, so saying it runs to the end of
the tvbuff is reasonable.
Convert a number of "proto_tree_add_XXX()" calls using
"tvb_length_remaining()", values derived from the result of
"tvb_length()", or 0 (in the case of items whose length is unknown) to
use -1 instead (using 0 means that if an exception is thrown, selecting
the item highlights nothing; using -1 means it highlights all the data
for that item that's available).
In some places where "tvb_length()" or "tvb_length_remaining()" was used
to determine how large a packet is, use "tvb_reported_length()" or
"tvb_reported_length_remaining()", instead - the first two calls
indicate how much captured data was in the packet, the latter two calls
indicate how large the packet actually was (and the fact that using the
latter could cause BoundsError exceptions to be thrown is a feature - if
such an exception is thrown, the frame really *was* short, and it should
be tagged as such).
Replace some "proto_tree_add_XXX()" calls with equivalent
"proto_tree_add_item()" calls.
Fix some indentation.
svn path=/trunk/; revision=4578
2002-01-20 22:12:39 +00:00
|
|
|
item = proto_tree_add_item(parent_tree, hf_rx_challenge, tvb, offset, -1, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
tree = proto_item_add_subtree(item, ett_rx_challenge);
|
|
|
|
|
|
|
|
version = tvb_get_ntohl(tvb, offset);
|
|
|
|
proto_tree_add_uint(tree, hf_rx_version, tvb,
|
|
|
|
offset, 4, version);
|
|
|
|
offset += 4;
|
|
|
|
|
|
|
|
if (version==2) {
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_nonce, tvb, offset, 4, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 4;
|
|
|
|
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_min_level, tvb, offset, 4, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 4;
|
|
|
|
}
|
|
|
|
|
2002-08-28 21:04:11 +00:00
|
|
|
proto_item_set_len(item, offset-old_offset);
|
2001-05-27 01:48:25 +00:00
|
|
|
return offset;
|
|
|
|
}
|
|
|
|
|
|
|
|
static int
|
|
|
|
dissect_rx_acks(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, int offset, guint32 seq, guint32 callnumber)
|
|
|
|
{
|
|
|
|
proto_tree *tree;
|
|
|
|
proto_item *item;
|
|
|
|
guint8 num;
|
|
|
|
int old_offset = offset;
|
|
|
|
|
2001-12-10 00:26:21 +00:00
|
|
|
if (check_col(pinfo->cinfo, COL_INFO)) {
|
|
|
|
col_add_fstr(pinfo->cinfo, COL_INFO,
|
2001-05-27 01:48:25 +00:00
|
|
|
"ACK "
|
1999-10-22 03:55:17 +00:00
|
|
|
"Seq: %lu "
|
|
|
|
"Call: %lu "
|
1999-10-20 16:41:20 +00:00
|
|
|
"Source Port: %s "
|
|
|
|
"Destination Port: %s ",
|
2001-05-27 01:48:25 +00:00
|
|
|
(unsigned long)seq,
|
|
|
|
(unsigned long)callnumber,
|
|
|
|
get_udp_port(pinfo->srcport),
|
|
|
|
get_udp_port(pinfo->destport)
|
1999-10-20 16:41:20 +00:00
|
|
|
);
|
2001-05-27 01:48:25 +00:00
|
|
|
}
|
|
|
|
|
Allow a length of -1 to be specified when adding FT_NONE and FT_PROTOCOL
items to the protocol tree; it's interpreted as "the rest of the data in
the tvbuff". This can be used if
1) the item covers the entire packet or the remaining payload in
the packet
or
2) the item's length won't be known until it's dissected, and
will be then set with "proto_item_set_len()" - if an
exception is thrown in the dissection, it means the item ran
*past* the end of the tvbuff, so saying it runs to the end of
the tvbuff is reasonable.
Convert a number of "proto_tree_add_XXX()" calls using
"tvb_length_remaining()", values derived from the result of
"tvb_length()", or 0 (in the case of items whose length is unknown) to
use -1 instead (using 0 means that if an exception is thrown, selecting
the item highlights nothing; using -1 means it highlights all the data
for that item that's available).
In some places where "tvb_length()" or "tvb_length_remaining()" was used
to determine how large a packet is, use "tvb_reported_length()" or
"tvb_reported_length_remaining()", instead - the first two calls
indicate how much captured data was in the packet, the latter two calls
indicate how large the packet actually was (and the fact that using the
latter could cause BoundsError exceptions to be thrown is a feature - if
such an exception is thrown, the frame really *was* short, and it should
be tagged as such).
Replace some "proto_tree_add_XXX()" calls with equivalent
"proto_tree_add_item()" calls.
Fix some indentation.
svn path=/trunk/; revision=4578
2002-01-20 22:12:39 +00:00
|
|
|
item = proto_tree_add_item(parent_tree, hf_rx_ack, tvb, offset, -1, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
tree = proto_item_add_subtree(item, ett_rx_ack);
|
|
|
|
|
|
|
|
|
|
|
|
/* bufferspace: 2 bytes*/
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_bufferspace, tvb, offset, 2, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 2;
|
2002-08-28 21:04:11 +00:00
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
/* maxskew: 2 bytes*/
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_maxskew, tvb, offset, 2, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 2;
|
2002-08-28 21:04:11 +00:00
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
/* first packet: 4 bytes*/
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_first_packet, tvb, offset, 4, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 4;
|
2002-08-28 21:04:11 +00:00
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
/* prev packet: 4 bytes*/
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_prev_packet, tvb, offset, 4, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 4;
|
|
|
|
|
2002-08-28 21:04:11 +00:00
|
|
|
/* serial : 4 bytes */
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_serial, tvb, offset, 4, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 4;
|
|
|
|
|
|
|
|
/* reason : 1 byte */
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_reason, tvb, offset, 1, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 1;
|
|
|
|
|
|
|
|
/* nACKs */
|
|
|
|
num = tvb_get_guint8(tvb, offset);
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_uint(tree, hf_rx_numacks, tvb, offset, 1, num);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 1;
|
|
|
|
|
|
|
|
while(num--){
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_ack_type, tvb, offset, 1,
|
|
|
|
FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 1;
|
|
|
|
}
|
2001-07-03 00:46:52 +00:00
|
|
|
|
|
|
|
/* Some implementations adds some extra fields.
|
|
|
|
* As far as I can see, these first add 3 padding bytes and then
|
|
|
|
* up to 4 32-bit values. (0,3,4 have been witnessed)
|
|
|
|
*
|
|
|
|
* RX as a protocol seems to be completely nondefined and seems to lack
|
|
|
|
* any sort of documentation other than "read the source of any of the
|
|
|
|
* (compatible?) implementations.
|
|
|
|
*/
|
|
|
|
if (tvb_length_remaining(tvb, offset)>3) {
|
|
|
|
offset += 3; /* guess. some implementations adds 3 bytes */
|
|
|
|
|
2001-08-20 02:11:13 +00:00
|
|
|
if (tvb_reported_length_remaining(tvb, offset) >= 4){
|
|
|
|
proto_tree_add_item(tree, hf_rx_ifmtu, tvb, offset, 4,
|
|
|
|
FALSE);
|
2001-07-03 00:46:52 +00:00
|
|
|
offset += 4;
|
|
|
|
}
|
2001-08-20 02:11:13 +00:00
|
|
|
if (tvb_reported_length_remaining(tvb, offset) >= 4){
|
|
|
|
proto_tree_add_item(tree, hf_rx_maxmtu, tvb, offset, 4,
|
|
|
|
FALSE);
|
2001-07-03 00:46:52 +00:00
|
|
|
offset += 4;
|
|
|
|
}
|
2001-08-20 02:11:13 +00:00
|
|
|
if (tvb_reported_length_remaining(tvb, offset) >= 4){
|
|
|
|
proto_tree_add_item(tree, hf_rx_rwind, tvb, offset, 4,
|
|
|
|
FALSE);
|
2001-07-03 00:46:52 +00:00
|
|
|
offset += 4;
|
|
|
|
}
|
2001-08-20 02:11:13 +00:00
|
|
|
if (tvb_reported_length_remaining(tvb, offset) >= 4){
|
|
|
|
proto_tree_add_item(tree, hf_rx_maxpackets, tvb, offset, 4,
|
|
|
|
FALSE);
|
2001-07-03 00:46:52 +00:00
|
|
|
offset += 4;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2002-08-28 21:04:11 +00:00
|
|
|
proto_item_set_len(item, offset-old_offset);
|
2001-05-27 01:48:25 +00:00
|
|
|
return offset;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
static int
|
2001-08-04 04:04:35 +00:00
|
|
|
dissect_rx_flags(tvbuff_t *tvb, struct rxinfo *rxinfo, proto_tree *parent_tree, int offset)
|
2001-05-27 01:48:25 +00:00
|
|
|
{
|
|
|
|
proto_tree *tree;
|
|
|
|
proto_item *item;
|
|
|
|
guint8 flags;
|
|
|
|
|
|
|
|
flags = tvb_get_guint8(tvb, offset);
|
2001-08-04 04:04:35 +00:00
|
|
|
rxinfo->flags = flags;
|
1999-10-20 16:41:20 +00:00
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
item = proto_tree_add_uint(parent_tree, hf_rx_flags, tvb,
|
|
|
|
offset, 1, flags);
|
|
|
|
tree = proto_item_add_subtree(item, ett_rx_flags);
|
|
|
|
|
2003-01-31 03:17:56 +00:00
|
|
|
proto_tree_add_boolean(tree, hf_rx_flags_free_packet, tvb,
|
2001-05-27 01:48:25 +00:00
|
|
|
offset, 1, flags);
|
2003-01-31 03:17:56 +00:00
|
|
|
proto_tree_add_boolean(tree, hf_rx_flags_more_packets, tvb,
|
2001-05-27 01:48:25 +00:00
|
|
|
offset, 1, flags);
|
2003-01-31 03:17:56 +00:00
|
|
|
proto_tree_add_boolean(tree, hf_rx_flags_last_packet, tvb,
|
2001-05-27 01:48:25 +00:00
|
|
|
offset, 1, flags);
|
2003-01-31 03:17:56 +00:00
|
|
|
proto_tree_add_boolean(tree, hf_rx_flags_request_ack, tvb,
|
2001-05-27 01:48:25 +00:00
|
|
|
offset, 1, flags);
|
2003-01-31 03:17:56 +00:00
|
|
|
proto_tree_add_boolean(tree, hf_rx_flags_clientinit, tvb,
|
2001-05-27 01:48:25 +00:00
|
|
|
offset, 1, flags);
|
|
|
|
|
|
|
|
offset += 1;
|
|
|
|
return offset;
|
|
|
|
}
|
|
|
|
|
2007-04-02 08:25:43 +00:00
|
|
|
static int
|
2001-05-27 01:48:25 +00:00
|
|
|
dissect_rx(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree)
|
|
|
|
{
|
|
|
|
proto_tree *tree;
|
|
|
|
proto_item *item;
|
|
|
|
int offset = 0;
|
2001-08-04 04:04:35 +00:00
|
|
|
struct rxinfo rxinfo;
|
2001-05-27 01:48:25 +00:00
|
|
|
guint8 type;
|
2008-03-16 19:36:09 +00:00
|
|
|
nstime_t ts;
|
2001-05-27 01:48:25 +00:00
|
|
|
guint32 seq, callnumber;
|
|
|
|
guint16 serviceid;
|
|
|
|
|
2007-04-02 08:25:43 +00:00
|
|
|
/* Ensure we have enough data */
|
|
|
|
if (tvb_length(tvb) < 28)
|
|
|
|
return 0;
|
|
|
|
|
|
|
|
/* Make sure it's a known type */
|
|
|
|
type = tvb_get_guint8(tvb, 20);
|
|
|
|
if (type == 0 || type == 10 || type == 11 || type == 12 || type > 13)
|
|
|
|
return 0;
|
|
|
|
|
2009-08-09 06:26:46 +00:00
|
|
|
col_set_str(pinfo->cinfo, COL_PROTOCOL, "RX");
|
2009-08-09 07:36:13 +00:00
|
|
|
col_clear(pinfo->cinfo, COL_INFO);
|
2001-05-27 01:48:25 +00:00
|
|
|
|
2002-08-28 21:04:11 +00:00
|
|
|
item = proto_tree_add_protocol_format(parent_tree, proto_rx, tvb,
|
2001-05-27 01:48:25 +00:00
|
|
|
offset, 28, "RX Protocol");
|
|
|
|
tree = proto_item_add_subtree(item, ett_rx);
|
|
|
|
|
|
|
|
/* epoch : 4 bytes */
|
2008-03-16 19:36:09 +00:00
|
|
|
rxinfo.epoch = tvb_get_ntohl(tvb, offset);
|
|
|
|
ts.secs = rxinfo.epoch;
|
|
|
|
ts.nsecs = 0;
|
|
|
|
proto_tree_add_time(tree, hf_rx_epoch, tvb, offset, 4, &ts);
|
|
|
|
offset += 4;
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
/* cid : 4 bytes */
|
2008-03-16 01:38:11 +00:00
|
|
|
rxinfo.cid = tvb_get_ntohl(tvb, offset);
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_cid, tvb, offset, 4, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 4;
|
|
|
|
|
|
|
|
/* callnumber : 4 bytes */
|
|
|
|
callnumber = tvb_get_ntohl(tvb, offset);
|
|
|
|
proto_tree_add_uint(tree, hf_rx_callnumber, tvb,
|
|
|
|
offset, 4, callnumber);
|
|
|
|
offset += 4;
|
2001-08-04 04:04:35 +00:00
|
|
|
rxinfo.callnumber = callnumber;
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
/* seq : 4 bytes */
|
|
|
|
seq = tvb_get_ntohl(tvb, offset);
|
|
|
|
proto_tree_add_uint(tree, hf_rx_seq, tvb,
|
|
|
|
offset, 4, seq);
|
|
|
|
offset += 4;
|
2001-08-04 04:04:35 +00:00
|
|
|
rxinfo.seq = seq;
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
/* serial : 4 bytes */
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_serial, tvb, offset, 4, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 4;
|
|
|
|
|
|
|
|
/* type : 1 byte */
|
|
|
|
type = tvb_get_guint8(tvb, offset);
|
|
|
|
proto_tree_add_uint(tree, hf_rx_type, tvb,
|
|
|
|
offset, 1, type);
|
|
|
|
offset += 1;
|
2001-08-04 04:04:35 +00:00
|
|
|
rxinfo.type = type;
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
/* flags : 1 byte */
|
2001-08-04 04:04:35 +00:00
|
|
|
offset = dissect_rx_flags(tvb, &rxinfo, tree, offset);
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
/* userstatus : 1 byte */
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_userstatus, tvb, offset, 1, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 1;
|
|
|
|
|
|
|
|
/* sequrityindex : 1 byte */
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_securityindex, tvb, offset, 1, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 1;
|
|
|
|
|
2001-08-20 02:11:13 +00:00
|
|
|
/*
|
|
|
|
* How clever: even though the AFS header files indicate that the
|
|
|
|
* serviceId is first, it's really encoded _after_ the spare field.
|
|
|
|
* I wasted a day figuring that out!
|
|
|
|
*/
|
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
/* spare */
|
2001-08-20 02:11:13 +00:00
|
|
|
proto_tree_add_item(tree, hf_rx_spare, tvb, offset, 2, FALSE);
|
2001-05-27 01:48:25 +00:00
|
|
|
offset += 2;
|
|
|
|
|
|
|
|
/* service id : 2 bytes */
|
|
|
|
serviceid = tvb_get_ntohs(tvb, offset);
|
|
|
|
proto_tree_add_uint(tree, hf_rx_serviceid, tvb,
|
|
|
|
offset, 2, serviceid);
|
|
|
|
offset += 2;
|
2001-08-04 04:04:35 +00:00
|
|
|
rxinfo.serviceid = serviceid;
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
switch (type) {
|
|
|
|
case RX_PACKET_TYPE_ACK:
|
2002-08-28 21:04:11 +00:00
|
|
|
/*dissect_rx_acks(tvb, pinfo, parent_tree, offset,
|
2001-05-27 01:48:25 +00:00
|
|
|
cant create it in a parallell tree, then ett seasrch
|
|
|
|
wont work */
|
2002-08-28 21:04:11 +00:00
|
|
|
dissect_rx_acks(tvb, pinfo, tree, offset,
|
2001-05-27 01:48:25 +00:00
|
|
|
seq, callnumber);
|
|
|
|
break;
|
|
|
|
case RX_PACKET_TYPE_ACKALL:
|
|
|
|
/* does not contain any payload */
|
2001-12-10 00:26:21 +00:00
|
|
|
if (check_col(pinfo->cinfo, COL_INFO)) {
|
|
|
|
col_add_fstr(pinfo->cinfo, COL_INFO,
|
2001-05-27 01:48:25 +00:00
|
|
|
"ACKALL "
|
|
|
|
"Seq: %lu "
|
|
|
|
"Call: %lu "
|
|
|
|
"Source Port: %s "
|
|
|
|
"Destination Port: %s ",
|
|
|
|
(unsigned long)seq,
|
|
|
|
(unsigned long)callnumber,
|
|
|
|
get_udp_port(pinfo->srcport),
|
|
|
|
get_udp_port(pinfo->destport)
|
|
|
|
);
|
|
|
|
}
|
|
|
|
break;
|
|
|
|
case RX_PACKET_TYPE_CHALLENGE:
|
|
|
|
dissect_rx_challenge(tvb, pinfo, tree, offset, seq, callnumber);
|
|
|
|
break;
|
|
|
|
case RX_PACKET_TYPE_RESPONSE:
|
|
|
|
dissect_rx_response(tvb, pinfo, tree, offset, seq, callnumber);
|
|
|
|
break;
|
|
|
|
case RX_PACKET_TYPE_DATA: {
|
|
|
|
tvbuff_t *next_tvb;
|
2009-05-19 17:16:14 +00:00
|
|
|
void* pd_save;
|
|
|
|
pd_save = pinfo->private_data;
|
2001-11-03 00:58:52 +00:00
|
|
|
pinfo->private_data = &rxinfo;
|
2009-08-16 12:36:22 +00:00
|
|
|
next_tvb = tvb_new_subset_remaining(tvb, offset);
|
2001-05-27 05:00:17 +00:00
|
|
|
call_dissector(afs_handle, next_tvb, pinfo, parent_tree);
|
2009-05-19 17:16:14 +00:00
|
|
|
pinfo->private_data = pd_save;
|
2001-05-27 01:48:25 +00:00
|
|
|
};
|
|
|
|
break;
|
2002-02-01 16:37:18 +00:00
|
|
|
case RX_PACKET_TYPE_ABORT:
|
|
|
|
dissect_rx_abort(tvb, pinfo, tree, offset, seq, callnumber);
|
|
|
|
break;
|
1999-10-20 16:41:20 +00:00
|
|
|
}
|
2001-05-27 01:48:25 +00:00
|
|
|
|
2007-04-02 08:25:43 +00:00
|
|
|
return(tvb_length(tvb));
|
1999-10-20 16:41:20 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
void
|
|
|
|
proto_register_rx(void)
|
|
|
|
{
|
|
|
|
static hf_register_info hf[] = {
|
|
|
|
{ &hf_rx_epoch, {
|
2009-12-19 03:17:44 +00:00
|
|
|
"Epoch", "rx.epoch", FT_ABSOLUTE_TIME, ABSOLUTE_TIME_LOCAL,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_cid, {
|
|
|
|
"CID", "rx.cid", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_callnumber, {
|
|
|
|
"Call Number", "rx.callnumber", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_seq, {
|
|
|
|
"Sequence Number", "rx.seq", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_serial, {
|
|
|
|
"Serial", "rx.serial", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_type, {
|
|
|
|
"Type", "rx.type", FT_UINT8, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
VALS(rx_types), 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_flags, {
|
|
|
|
"Flags", "rx.flags", FT_UINT8, BASE_HEX,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_flags_clientinit, {
|
2003-01-31 03:17:56 +00:00
|
|
|
"Client Initiated", "rx.flags.client_init", FT_BOOLEAN, 8,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, RX_CLIENT_INITIATED, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_flags_request_ack, {
|
2003-01-31 03:17:56 +00:00
|
|
|
"Request Ack", "rx.flags.request_ack", FT_BOOLEAN, 8,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, RX_REQUEST_ACK, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_flags_last_packet, {
|
2003-01-31 03:17:56 +00:00
|
|
|
"Last Packet", "rx.flags.last_packet", FT_BOOLEAN, 8,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, RX_LAST_PACKET, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_flags_more_packets, {
|
2003-01-31 03:17:56 +00:00
|
|
|
"More Packets", "rx.flags.more_packets", FT_BOOLEAN, 8,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, RX_MORE_PACKETS, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_flags_free_packet, {
|
2003-01-31 03:17:56 +00:00
|
|
|
"Free Packet", "rx.flags.free_packet", FT_BOOLEAN, 8,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, RX_FREE_PACKET, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
2003-01-31 03:17:56 +00:00
|
|
|
/* XXX - what about RX_SLOW_START_OR_JUMBO? */
|
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_userstatus, {
|
|
|
|
"User Status", "rx.userstatus", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_securityindex, {
|
|
|
|
"Security Index", "rx.securityindex", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_spare, {
|
|
|
|
"Spare/Checksum", "rx.spare", FT_UINT16, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
{ &hf_rx_serviceid, {
|
|
|
|
"Service ID", "rx.serviceid", FT_UINT16, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_bufferspace, {
|
|
|
|
"Bufferspace", "rx.bufferspace", FT_UINT16, BASE_DEC,
|
2001-06-18 02:18:27 +00:00
|
|
|
NULL, 0, "Number Of Packets Available", HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_maxskew, {
|
|
|
|
"Max Skew", "rx.maxskew", FT_UINT16, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_first_packet, {
|
|
|
|
"First Packet", "rx.first", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_prev_packet, {
|
|
|
|
"Prev Packet", "rx.prev", FT_UINT32, BASE_DEC,
|
2001-06-18 02:18:27 +00:00
|
|
|
NULL, 0, "Previous Packet", HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_reason, {
|
|
|
|
"Reason", "rx.reason", FT_UINT8, BASE_DEC,
|
2001-06-18 02:18:27 +00:00
|
|
|
VALS(rx_reason), 0, "Reason For This ACK", HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_numacks, {
|
|
|
|
"Num ACKs", "rx.num_acks", FT_UINT8, BASE_DEC,
|
2001-06-18 02:18:27 +00:00
|
|
|
NULL, 0, "Number Of ACKs", HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_ack_type, {
|
|
|
|
"ACK Type", "rx.ack_type", FT_UINT8, BASE_DEC,
|
2001-06-18 02:18:27 +00:00
|
|
|
VALS(rx_ack_type), 0, "Type Of ACKs", HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_ack, {
|
|
|
|
"ACK Packet", "rx.ack", FT_NONE, BASE_NONE,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_challenge, {
|
|
|
|
"CHALLENGE Packet", "rx.challenge", FT_NONE, BASE_NONE,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_version, {
|
|
|
|
"Version", "rx.version", FT_UINT32, BASE_DEC,
|
2001-06-18 02:18:27 +00:00
|
|
|
NULL, 0, "Version Of Challenge/Response", HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_nonce, {
|
|
|
|
"Nonce", "rx.nonce", FT_UINT32, BASE_HEX,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_inc_nonce, {
|
|
|
|
"Inc Nonce", "rx.inc_nonce", FT_UINT32, BASE_HEX,
|
2001-06-18 02:18:27 +00:00
|
|
|
NULL, 0, "Incremented Nonce", HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_min_level, {
|
|
|
|
"Min Level", "rx.min_level", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_level, {
|
|
|
|
"Level", "rx.level", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_response, {
|
|
|
|
"RESPONSE Packet", "rx.response", FT_NONE, BASE_NONE,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
2002-02-01 16:37:18 +00:00
|
|
|
{ &hf_rx_abort, {
|
|
|
|
"ABORT Packet", "rx.abort", FT_NONE, BASE_NONE,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2002-02-01 16:37:18 +00:00
|
|
|
|
2001-05-27 01:48:25 +00:00
|
|
|
{ &hf_rx_encrypted, {
|
|
|
|
"Encrypted", "rx.encrypted", FT_NONE, BASE_NONE,
|
2001-06-18 02:18:27 +00:00
|
|
|
NULL, 0, "Encrypted part of response packet", HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_kvno, {
|
|
|
|
"kvno", "rx.kvno", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_ticket_len, {
|
|
|
|
"Ticket len", "rx.ticket_len", FT_UINT32, BASE_DEC,
|
2001-06-18 02:18:27 +00:00
|
|
|
NULL, 0, "Ticket Length", HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
|
|
|
{ &hf_rx_ticket, {
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
"ticket", "rx.ticket", FT_BYTES, BASE_NONE,
|
2001-06-18 02:18:27 +00:00
|
|
|
NULL, 0, "Ticket", HFILL }},
|
2001-05-27 01:48:25 +00:00
|
|
|
|
2001-07-03 00:46:52 +00:00
|
|
|
{ &hf_rx_ifmtu, {
|
|
|
|
"Interface MTU", "rx.if_mtu", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-07-03 00:46:52 +00:00
|
|
|
|
|
|
|
{ &hf_rx_maxmtu, {
|
|
|
|
"Max MTU", "rx.max_mtu", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-07-03 00:46:52 +00:00
|
|
|
|
|
|
|
{ &hf_rx_rwind, {
|
|
|
|
"rwind", "rx.rwind", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-07-03 00:46:52 +00:00
|
|
|
|
|
|
|
{ &hf_rx_maxpackets, {
|
|
|
|
"Max Packets", "rx.max_packets", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2001-07-03 00:46:52 +00:00
|
|
|
|
2002-02-01 16:37:18 +00:00
|
|
|
{ &hf_rx_abortcode, {
|
|
|
|
"Abort Code", "rx.abort_code", FT_UINT32, BASE_DEC,
|
From Kovarththanan Rajaratnam via bug 3548:
(1) Trailing/leading spaces are removed from 'name's/'blurb's
(2) Duplicate 'blurb's are replaced with NULL
(3) Empty ("") 'blurb's are replaced with NULL
(4) BASE_NONE, NULL, 0x0 are used for 'display', 'strings' and 'bitmask' fields
for FT_NONE, FT_BYTES, FT_IPv4, FT_IPv6, FT_ABSOLUTE_TIME, FT_RELATIVE_TIME,
FT_PROTOCOL, FT_STRING and FT_STRINGZ field types
(5) Only allow non-zero value for 'display' if 'bitmask' is non-zero
svn path=/trunk/; revision=28770
2009-06-18 21:30:42 +00:00
|
|
|
NULL, 0, NULL, HFILL }},
|
2002-02-01 16:37:18 +00:00
|
|
|
|
1999-10-20 16:41:20 +00:00
|
|
|
};
|
1999-11-16 11:44:20 +00:00
|
|
|
static gint *ett[] = {
|
|
|
|
&ett_rx,
|
|
|
|
&ett_rx_flags,
|
2001-05-27 01:48:25 +00:00
|
|
|
&ett_rx_ack,
|
|
|
|
&ett_rx_challenge,
|
|
|
|
&ett_rx_response,
|
|
|
|
&ett_rx_encrypted,
|
2002-02-01 16:37:18 +00:00
|
|
|
&ett_rx_abort
|
1999-11-16 11:44:20 +00:00
|
|
|
};
|
1999-10-20 16:41:20 +00:00
|
|
|
|
2001-01-03 06:56:03 +00:00
|
|
|
proto_rx = proto_register_protocol("RX Protocol", "RX", "rx");
|
1999-10-20 16:41:20 +00:00
|
|
|
proto_register_field_array(proto_rx, hf, array_length(hf));
|
1999-11-16 11:44:20 +00:00
|
|
|
proto_register_subtree_array(ett, array_length(ett));
|
1999-10-20 16:41:20 +00:00
|
|
|
}
|
2000-04-14 06:42:52 +00:00
|
|
|
|
|
|
|
void
|
|
|
|
proto_reg_handoff_rx(void)
|
|
|
|
{
|
2001-12-03 04:00:26 +00:00
|
|
|
dissector_handle_t rx_handle;
|
|
|
|
|
2000-04-14 06:42:52 +00:00
|
|
|
int port;
|
|
|
|
|
2001-05-27 05:00:17 +00:00
|
|
|
/*
|
|
|
|
* Get handle for the AFS dissector.
|
|
|
|
*/
|
|
|
|
afs_handle = find_dissector("afs");
|
|
|
|
|
2000-04-14 06:42:52 +00:00
|
|
|
/* Ports in the range UDP_PORT_RX_LOW to UDP_PORT_RX_HIGH
|
|
|
|
are all used for various AFS services. */
|
2007-04-02 08:25:43 +00:00
|
|
|
rx_handle = new_create_dissector_handle(dissect_rx, proto_rx);
|
2000-04-14 06:42:52 +00:00
|
|
|
for (port = UDP_PORT_RX_LOW; port <= UDP_PORT_RX_HIGH; port++)
|
2001-12-03 04:00:26 +00:00
|
|
|
dissector_add("udp.port", port, rx_handle);
|
|
|
|
dissector_add("udp.port", UDP_PORT_RX_AFS_BACKUPS, rx_handle);
|
2000-04-14 06:42:52 +00:00
|
|
|
}
|