2000-04-15 22:11:26 +00:00
|
|
|
/* packet-esis.c
|
2002-08-28 21:04:11 +00:00
|
|
|
* Routines for ISO/OSI End System to Intermediate System
|
2001-08-13 00:56:18 +00:00
|
|
|
* Routing Exchange Protocol ISO 9542.
|
2000-04-15 22:11:26 +00:00
|
|
|
*
|
2014-03-05 07:53:22 +00:00
|
|
|
* Ralf Schneider <Ralf.Schneider@t-online.de>
|
2000-04-15 22:11:26 +00:00
|
|
|
*
|
2006-05-21 04:49:01 +00:00
|
|
|
* Wireshark - Network traffic analyzer
|
|
|
|
* By Gerald Combs <gerald@wireshark.org>
|
2000-04-15 22:11:26 +00:00
|
|
|
* Copyright 1998 Gerald Combs
|
2002-08-28 21:04:11 +00:00
|
|
|
*
|
2000-04-15 22:11:26 +00:00
|
|
|
* 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.
|
2002-08-28 21:04:11 +00:00
|
|
|
*
|
2000-04-15 22:11:26 +00:00
|
|
|
* 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.
|
2002-08-28 21:04:11 +00:00
|
|
|
*
|
2000-04-15 22:11:26 +00:00
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with this program; if not, write to the Free Software
|
2012-06-28 22:56:06 +00:00
|
|
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
|
2001-12-03 04:00:26 +00:00
|
|
|
*/
|
2000-04-15 22:11:26 +00:00
|
|
|
|
2012-09-20 02:03:38 +00:00
|
|
|
#include "config.h"
|
2000-04-15 22:11:26 +00:00
|
|
|
|
|
|
|
#include <glib.h>
|
2002-01-21 07:37:49 +00:00
|
|
|
#include <epan/packet.h>
|
2013-11-09 15:44:29 +00:00
|
|
|
#include <wsutil/pint.h>
|
2005-09-17 00:02:31 +00:00
|
|
|
#include <epan/nlpid.h>
|
2000-04-15 22:11:26 +00:00
|
|
|
#include "packet-osi.h"
|
|
|
|
#include "packet-osi-options.h"
|
|
|
|
#include "packet-esis.h"
|
|
|
|
|
2013-03-17 09:11:21 +00:00
|
|
|
void proto_register_esis(void);
|
|
|
|
void proto_reg_handoff_esis(void);
|
2000-04-15 22:11:26 +00:00
|
|
|
|
|
|
|
/* esis base header */
|
|
|
|
static int proto_esis = -1;
|
|
|
|
|
|
|
|
static int hf_esis_nlpi = -1;
|
|
|
|
static int hf_esis_length = -1;
|
|
|
|
static int hf_esis_version = -1;
|
|
|
|
static int hf_esis_reserved = -1;
|
|
|
|
static int hf_esis_type = -1;
|
|
|
|
static int hf_esis_holdtime = -1;
|
|
|
|
static int hf_esis_checksum = -1;
|
2013-08-06 01:11:55 +00:00
|
|
|
/* Generated from convert_proto_tree_add_text.pl */
|
|
|
|
static int hf_esis_dal = -1;
|
|
|
|
static int hf_esis_number_of_source_addresses = -1;
|
|
|
|
static int hf_esis_netl = -1;
|
|
|
|
static int hf_esis_sal = -1;
|
|
|
|
static int hf_esis_bsnpal = -1;
|
2013-12-19 22:05:07 +00:00
|
|
|
static int hf_esis_net = -1;
|
|
|
|
static int hf_esis_da = -1;
|
|
|
|
static int hf_esis_bsnpa = -1;
|
2000-04-15 22:11:26 +00:00
|
|
|
|
|
|
|
static gint ett_esis = -1;
|
|
|
|
static gint ett_esis_area_addr = -1;
|
|
|
|
|
|
|
|
static const value_string esis_vals[] = {
|
|
|
|
{ ESIS_ESH_PDU, "ES HELLO"},
|
|
|
|
{ ESIS_ISH_PDU, "IS HELLO"},
|
|
|
|
{ ESIS_RD_PDU, "RD REQUEST"},
|
|
|
|
{ 0, NULL} };
|
|
|
|
|
|
|
|
/* internal prototypes */
|
|
|
|
|
2003-12-13 02:17:44 +00:00
|
|
|
static void esis_dissect_esh_pdu( guint8 len, tvbuff_t *tvb,
|
2002-04-07 22:00:34 +00:00
|
|
|
proto_tree *treepd);
|
2003-12-13 02:17:44 +00:00
|
|
|
static void esis_dissect_ish_pdu( guint8 len, tvbuff_t *tvb,
|
2002-04-07 22:00:34 +00:00
|
|
|
proto_tree *tree);
|
2003-12-13 02:17:44 +00:00
|
|
|
static void esis_dissect_redirect_pdu( guint8 len, tvbuff_t *tvb,
|
2002-04-07 22:00:34 +00:00
|
|
|
proto_tree *tree);
|
2000-04-15 22:11:26 +00:00
|
|
|
|
|
|
|
/* ################## Descriptions ###########################################*/
|
|
|
|
/* Parameters for the ESH PDU
|
|
|
|
* Source Address Parameter:
|
|
|
|
*
|
|
|
|
* Octet: Length: Parameter Type:
|
2011-01-21 00:19:03 +00:00
|
|
|
* 10 1 Number of Source Addresses ( NSAPs served by this Network
|
2000-04-15 22:11:26 +00:00
|
|
|
* 11 1 Source Address Length Indicator ( SAL ) # Entity )
|
|
|
|
* 12-m-1 variable Source Address ( NSAP )
|
|
|
|
* m Options, dissected in osi.c
|
|
|
|
*
|
|
|
|
*
|
|
|
|
* Parameter for the ISH PDU:
|
|
|
|
* Network Entity Title Parameter:
|
|
|
|
*
|
|
|
|
* Octet: Length: Parameter Type:
|
|
|
|
* 10 1 Network Entity Title Length Indicator ( NETL )
|
|
|
|
* 11-m-1 variable Network Entity Title ( NET )
|
|
|
|
* m Options, dissected in osi.c
|
|
|
|
*
|
|
|
|
*
|
|
|
|
* Parameter for the RD PDU:
|
|
|
|
* When re-directed to an IS:
|
|
|
|
*
|
|
|
|
* Octet: Length: Parameter Type:
|
|
|
|
* 10 1 Destination Address Length Indicator ( DAL )
|
|
|
|
* 11>m-1 variable Destination Address ( DA )
|
|
|
|
* m 1 Subnetwork Address Length Indicator ( BSNPAL )
|
|
|
|
* m+1>n-1 variable Subnetwork Address ( BSNPA )
|
|
|
|
* n 1 Network Entity Title Length Indicator ( NETL )
|
|
|
|
* n+1>p-1 variable Network Entity Title ( NET )
|
|
|
|
* p Options, dissected in osi.c
|
|
|
|
*
|
|
|
|
*
|
|
|
|
* Parameter for the RD PDU:
|
|
|
|
* When re-directed to an ES:
|
|
|
|
*
|
|
|
|
* Octet: Length: Parameter Type:
|
|
|
|
* 10 1 Destination Address Length Indicator ( DAL )
|
|
|
|
* 11>m-1 variable Destination Address ( DA )
|
|
|
|
* m 1 Subnetwork Address Length Indicator ( BSNPAL )
|
|
|
|
* m+1>n-1 variable Subnetwork Address ( BSNPA )
|
|
|
|
* n 1 Network Entity Title Length Indicator ( NETL ) == 0
|
|
|
|
* n+1 Options, dissected in osi.c
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
/* ############################ Tool Functions ############################## */
|
|
|
|
|
|
|
|
|
|
|
|
/* ############################## Dissection Functions ###################### */
|
|
|
|
/*
|
|
|
|
* Name: dissect_esis_unknown()
|
|
|
|
*
|
|
|
|
* Description:
|
|
|
|
* There was some error in the protocol and we are in unknown space
|
|
|
|
* here. Add a tree item to cover the error and go on. Note
|
|
|
|
* that we make sure we don't go off the end of the bleedin packet here!
|
|
|
|
*
|
|
|
|
* This is just a copy of isis.c and isis.h, so I keep the stuff also
|
|
|
|
* and adapt the names to cover possible protocol errors! Ive really no
|
2009-04-08 13:41:30 +00:00
|
|
|
* idea whether I need this or not.
|
2002-08-28 21:04:11 +00:00
|
|
|
*
|
2000-04-15 22:11:26 +00:00
|
|
|
* Input
|
2002-04-07 22:00:34 +00:00
|
|
|
* tvbuff_t * : tvbuff with packet data.
|
2000-04-15 22:11:26 +00:00
|
|
|
* proto_tree * : tree of display data. May be NULL.
|
|
|
|
* char * : format text
|
2002-04-07 22:00:34 +00:00
|
|
|
* subsequent args : arguments to format
|
2000-04-15 22:11:26 +00:00
|
|
|
*
|
|
|
|
* Output:
|
|
|
|
* void (may modify proto tree)
|
|
|
|
*/
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
static void
|
2005-07-30 01:01:02 +00:00
|
|
|
esis_dissect_unknown( tvbuff_t *tvb, proto_tree *tree, const char *fmat, ...){
|
2000-04-15 22:11:26 +00:00
|
|
|
va_list ap;
|
|
|
|
|
|
|
|
va_start(ap, fmat);
|
2002-01-24 09:20:54 +00:00
|
|
|
proto_tree_add_text_valist(tree, tvb, 0, -1, fmat, ap);
|
2000-04-15 22:11:26 +00:00
|
|
|
va_end(ap);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
static void
|
2003-12-13 02:17:44 +00:00
|
|
|
esis_dissect_esh_pdu( guint8 len, tvbuff_t *tvb, proto_tree *tree) {
|
2000-04-15 22:11:26 +00:00
|
|
|
proto_tree *esis_area_tree;
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
int offset = 0;
|
2000-04-15 22:11:26 +00:00
|
|
|
int no_sa = 0;
|
|
|
|
int sal = 0;
|
2002-08-28 21:04:11 +00:00
|
|
|
|
2000-04-15 22:11:26 +00:00
|
|
|
proto_item *ti;
|
2002-08-28 21:04:11 +00:00
|
|
|
|
2000-04-15 22:11:26 +00:00
|
|
|
if (tree) {
|
|
|
|
offset += ESIS_HDR_FIXED_LENGTH;
|
|
|
|
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
no_sa = tvb_get_guint8(tvb, offset);
|
2000-04-15 22:11:26 +00:00
|
|
|
len -= 1;
|
|
|
|
|
2013-09-20 19:40:26 +00:00
|
|
|
ti = proto_tree_add_uint( tree, hf_esis_number_of_source_addresses, tvb, offset, 1, no_sa);
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
offset++;
|
2002-08-28 21:04:11 +00:00
|
|
|
|
2000-04-15 22:11:26 +00:00
|
|
|
esis_area_tree = proto_item_add_subtree( ti, ett_esis_area_addr );
|
|
|
|
while ( no_sa-- > 0 ) {
|
2012-04-26 16:47:37 +00:00
|
|
|
sal = (int) tvb_get_guint8(tvb, offset);
|
2013-08-06 01:11:55 +00:00
|
|
|
proto_tree_add_uint_format_value(esis_area_tree, hf_esis_sal, tvb, offset, 1, sal, "%2u Octets", sal);
|
2012-04-26 16:47:37 +00:00
|
|
|
offset++;
|
|
|
|
proto_tree_add_text(esis_area_tree, tvb, offset, sal,
|
|
|
|
" SA: %s",
|
|
|
|
print_nsap_net( tvb_get_ptr(tvb, offset, sal), sal ) );
|
|
|
|
offset += sal;
|
|
|
|
len -= ( sal + 1 );
|
2000-04-15 22:11:26 +00:00
|
|
|
}
|
2002-04-30 23:56:58 +00:00
|
|
|
dissect_osi_options( len, tvb, offset, tree );
|
2002-08-28 21:04:11 +00:00
|
|
|
}
|
2003-12-21 05:51:34 +00:00
|
|
|
} /* esis_dissect_esh_pdu */
|
2000-04-15 22:11:26 +00:00
|
|
|
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
static void
|
2003-12-13 02:17:44 +00:00
|
|
|
esis_dissect_ish_pdu( guint8 len, tvbuff_t *tvb, proto_tree *tree) {
|
2002-08-28 21:04:11 +00:00
|
|
|
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
int offset = 0;
|
2000-04-15 22:11:26 +00:00
|
|
|
int netl = 0;
|
|
|
|
|
|
|
|
if (tree) {
|
|
|
|
offset += ESIS_HDR_FIXED_LENGTH;
|
|
|
|
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
netl = (int) tvb_get_guint8(tvb, offset);
|
2002-08-28 21:04:11 +00:00
|
|
|
proto_tree_add_text( tree, tvb, offset, netl + 1,
|
2002-01-24 07:24:56 +00:00
|
|
|
"### Network Entity Title Section ###");
|
2013-08-06 01:11:55 +00:00
|
|
|
proto_tree_add_uint_format_value(tree, hf_esis_netl, tvb, offset++, 1, netl, "%2u Octets", netl);
|
2013-12-19 22:05:07 +00:00
|
|
|
proto_tree_add_string( tree, hf_esis_net, tvb, offset, netl, print_nsap_net( tvb_get_ptr(tvb, offset, netl), netl ) );
|
2000-04-15 22:11:26 +00:00
|
|
|
offset += netl;
|
|
|
|
len -= ( netl + 1 );
|
|
|
|
|
2002-04-30 23:56:58 +00:00
|
|
|
dissect_osi_options( len, tvb, offset, tree );
|
2000-04-15 22:11:26 +00:00
|
|
|
}
|
2003-12-21 05:51:34 +00:00
|
|
|
}
|
2000-04-15 22:11:26 +00:00
|
|
|
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
static void
|
2003-12-13 02:17:44 +00:00
|
|
|
esis_dissect_redirect_pdu( guint8 len, tvbuff_t *tvb, proto_tree *tree) {
|
2000-04-15 22:11:26 +00:00
|
|
|
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
int offset = 0;
|
2000-04-15 22:11:26 +00:00
|
|
|
int tmpl = 0;
|
|
|
|
|
|
|
|
if (tree) {
|
|
|
|
offset += ESIS_HDR_FIXED_LENGTH;
|
|
|
|
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
tmpl = (int) tvb_get_guint8(tvb, offset);
|
2002-08-28 21:04:11 +00:00
|
|
|
proto_tree_add_text( tree, tvb, offset, tmpl + 1,
|
2000-04-15 22:11:26 +00:00
|
|
|
"### Destination Address Section ###" );
|
2013-08-06 01:11:55 +00:00
|
|
|
proto_tree_add_uint_format_value(tree, hf_esis_dal, tvb, offset++, 1, tmpl, "%2u Octets", tmpl);
|
2013-12-19 22:05:07 +00:00
|
|
|
proto_tree_add_string( tree, hf_esis_da, tvb, offset, tmpl,
|
2012-04-26 16:47:37 +00:00
|
|
|
print_nsap_net( tvb_get_ptr(tvb, offset, tmpl), tmpl ) );
|
2000-04-15 22:11:26 +00:00
|
|
|
offset += tmpl;
|
|
|
|
len -= ( tmpl + 1 );
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
tmpl = (int) tvb_get_guint8(tvb, offset);
|
2000-04-15 22:11:26 +00:00
|
|
|
|
2002-08-28 21:04:11 +00:00
|
|
|
proto_tree_add_text( tree, tvb, offset, tmpl + 1,
|
2000-04-15 22:11:26 +00:00
|
|
|
"### Subnetwork Address Section ###");
|
2013-08-06 01:11:55 +00:00
|
|
|
proto_tree_add_uint_format_value(tree, hf_esis_bsnpal, tvb, offset++, 1, tmpl, "%2u Octets", tmpl);
|
2013-12-23 15:18:48 +00:00
|
|
|
proto_tree_add_item( tree, hf_esis_bsnpa, tvb, offset, tmpl, ENC_NA);
|
2000-04-15 22:11:26 +00:00
|
|
|
offset += tmpl;
|
|
|
|
len -= ( tmpl + 1 );
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
tmpl = (int) tvb_get_guint8(tvb, offset);
|
2000-04-15 22:11:26 +00:00
|
|
|
|
|
|
|
if ( 0 == tmpl ) {
|
2002-08-28 21:04:11 +00:00
|
|
|
proto_tree_add_text( tree, tvb, offset, 1,
|
2000-04-15 22:11:26 +00:00
|
|
|
"### No Network Entity Title Section ###" );
|
|
|
|
offset++;
|
|
|
|
len--;
|
|
|
|
}
|
|
|
|
else {
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
proto_tree_add_text( tree, tvb, offset, 1,
|
2000-04-15 22:11:26 +00:00
|
|
|
"### Network Entity Title Section ###" );
|
2013-08-06 01:11:55 +00:00
|
|
|
proto_tree_add_uint_format_value(tree, hf_esis_netl, tvb, offset++, 1, tmpl, "%2u Octets", tmpl );
|
2013-12-19 22:05:07 +00:00
|
|
|
proto_tree_add_string( tree, hf_esis_net, tvb, offset, tmpl,
|
2012-04-26 16:47:37 +00:00
|
|
|
print_nsap_net( tvb_get_ptr(tvb, offset, tmpl), tmpl ) );
|
2000-04-15 22:11:26 +00:00
|
|
|
offset += tmpl;
|
|
|
|
len -= ( tmpl + 1 );
|
|
|
|
}
|
2002-04-30 23:56:58 +00:00
|
|
|
dissect_osi_options( len, tvb, offset, tree );
|
2000-04-15 22:11:26 +00:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
* Name: dissect_esis()
|
2002-08-28 21:04:11 +00:00
|
|
|
*
|
2000-04-15 22:11:26 +00:00
|
|
|
* Description:
|
|
|
|
* Main entry area for esis de-mangling. This will build the
|
|
|
|
* main esis tree data and call the sub-protocols as needed.
|
|
|
|
*
|
|
|
|
* Input:
|
2002-04-07 22:00:34 +00:00
|
|
|
* tvbuff * : tvbuff referring to packet data
|
|
|
|
* packet_info * : info for current packet
|
|
|
|
* proto_tree * : tree of display data. May be NULL.
|
2000-04-15 22:11:26 +00:00
|
|
|
*
|
|
|
|
* Output:
|
|
|
|
* void, but we will add to the proto_tree if it is not NULL.
|
|
|
|
*/
|
2000-04-17 01:36:31 +00:00
|
|
|
static void
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
dissect_esis(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree) {
|
2012-04-26 16:47:37 +00:00
|
|
|
const char *pdu_type_string = NULL;
|
|
|
|
const char *pdu_type_format_string = "PDU Type : %s (R:%s%s%s)";
|
|
|
|
esis_hdr_t ehdr;
|
|
|
|
proto_item *ti;
|
|
|
|
proto_tree *esis_tree = NULL;
|
|
|
|
guint8 variable_len;
|
|
|
|
guint tmp_uint = 0;
|
|
|
|
const char *cksum_status;
|
|
|
|
|
|
|
|
col_set_str(pinfo->cinfo, COL_PROTOCOL, "ESIS");
|
|
|
|
col_clear(pinfo->cinfo, COL_INFO);
|
|
|
|
|
|
|
|
tvb_memcpy(tvb, (guint8 *)&ehdr, 0, sizeof ehdr);
|
|
|
|
|
|
|
|
if (tree) {
|
|
|
|
ti = proto_tree_add_item(tree, proto_esis, tvb, 0, -1, ENC_NA);
|
|
|
|
esis_tree = proto_item_add_subtree(ti, ett_esis);
|
|
|
|
|
|
|
|
if (ehdr.esis_version != ESIS_REQUIRED_VERSION){
|
|
|
|
esis_dissect_unknown(tvb, esis_tree,
|
|
|
|
"Unknown ESIS version (%u vs %u)",
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
ehdr.esis_version, ESIS_REQUIRED_VERSION );
|
2012-04-26 16:47:37 +00:00
|
|
|
return;
|
|
|
|
}
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
|
2012-04-26 16:47:37 +00:00
|
|
|
if (ehdr.esis_length < ESIS_HDR_FIXED_LENGTH) {
|
|
|
|
esis_dissect_unknown(tvb, esis_tree,
|
|
|
|
"Bogus ESIS length (%u, must be >= %u)",
|
2003-12-13 02:17:44 +00:00
|
|
|
ehdr.esis_length, ESIS_HDR_FIXED_LENGTH );
|
2012-04-26 16:47:37 +00:00
|
|
|
return;
|
|
|
|
}
|
|
|
|
proto_tree_add_uint( esis_tree, hf_esis_nlpi, tvb, 0, 1, ehdr.esis_nlpi );
|
|
|
|
proto_tree_add_uint( esis_tree, hf_esis_length, tvb,
|
|
|
|
1, 1, ehdr.esis_length );
|
|
|
|
proto_tree_add_uint( esis_tree, hf_esis_version, tvb, 2, 1,
|
|
|
|
ehdr.esis_version );
|
|
|
|
proto_tree_add_uint( esis_tree, hf_esis_reserved, tvb, 3, 1,
|
|
|
|
ehdr.esis_reserved );
|
|
|
|
|
|
|
|
pdu_type_string = val_to_str(ehdr.esis_type&OSI_PDU_TYPE_MASK,
|
|
|
|
esis_vals, "Unknown (0x%x)");
|
|
|
|
|
|
|
|
proto_tree_add_uint_format( esis_tree, hf_esis_type, tvb, 4, 1,
|
|
|
|
ehdr.esis_type,
|
|
|
|
pdu_type_format_string,
|
|
|
|
pdu_type_string,
|
2013-12-23 01:16:00 +00:00
|
|
|
(ehdr.esis_type&0x80) ? "1" : "0",
|
|
|
|
(ehdr.esis_type&0x40) ? "1" : "0",
|
|
|
|
(ehdr.esis_type&0x20) ? "1" : "0");
|
2012-04-26 16:47:37 +00:00
|
|
|
|
2013-11-29 18:59:06 +00:00
|
|
|
tmp_uint = pntoh16( ehdr.esis_holdtime );
|
2013-09-16 10:39:06 +00:00
|
|
|
proto_tree_add_uint_format_value(esis_tree, hf_esis_holdtime, tvb, 5, 2,
|
|
|
|
tmp_uint, "%u seconds",
|
2012-04-26 16:47:37 +00:00
|
|
|
tmp_uint );
|
|
|
|
|
2013-11-29 18:59:06 +00:00
|
|
|
tmp_uint = pntoh16( ehdr.esis_checksum );
|
2012-04-26 16:47:37 +00:00
|
|
|
|
|
|
|
switch (calc_checksum( tvb, 0, ehdr.esis_length, tmp_uint )) {
|
|
|
|
|
|
|
|
case NO_CKSUM:
|
|
|
|
cksum_status = "Not Used";
|
|
|
|
break;
|
|
|
|
|
|
|
|
case DATA_MISSING:
|
|
|
|
cksum_status = "Not checkable - not all of packet was captured";
|
|
|
|
break;
|
|
|
|
|
|
|
|
case CKSUM_OK:
|
|
|
|
cksum_status = "Is good";
|
|
|
|
break;
|
|
|
|
|
|
|
|
case CKSUM_NOT_OK:
|
|
|
|
cksum_status = "Is wrong";
|
|
|
|
break;
|
|
|
|
|
|
|
|
default:
|
|
|
|
cksum_status = NULL;
|
|
|
|
DISSECTOR_ASSERT_NOT_REACHED();
|
|
|
|
}
|
2013-09-16 10:39:06 +00:00
|
|
|
proto_tree_add_uint_format_value( esis_tree, hf_esis_checksum, tvb, 7, 2,
|
|
|
|
tmp_uint, "0x%x ( %s )",
|
2012-04-26 16:47:37 +00:00
|
|
|
tmp_uint, cksum_status );
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
* Let us make sure we use the same names for all our decodes
|
|
|
|
* here. First, dump the name into info column, and THEN
|
|
|
|
* dispatch the sub-type.
|
|
|
|
*/
|
2013-06-14 01:02:11 +00:00
|
|
|
col_add_str(pinfo->cinfo, COL_INFO,
|
2012-04-26 16:47:37 +00:00
|
|
|
val_to_str( ehdr.esis_type&OSI_PDU_TYPE_MASK, esis_vals,
|
|
|
|
"Unknown (0x%x)" ) );
|
|
|
|
|
|
|
|
variable_len = ehdr.esis_length - ESIS_HDR_FIXED_LENGTH;
|
|
|
|
|
|
|
|
switch (ehdr.esis_type & OSI_PDU_TYPE_MASK) {
|
|
|
|
case ESIS_ESH_PDU:
|
|
|
|
esis_dissect_esh_pdu( variable_len, tvb, esis_tree);
|
|
|
|
break;
|
|
|
|
case ESIS_ISH_PDU:
|
|
|
|
esis_dissect_ish_pdu( variable_len, tvb, esis_tree);
|
|
|
|
break;
|
|
|
|
case ESIS_RD_PDU:
|
|
|
|
esis_dissect_redirect_pdu( variable_len, tvb, esis_tree);
|
|
|
|
break;
|
|
|
|
default:
|
|
|
|
esis_dissect_unknown(tvb, esis_tree,
|
|
|
|
"Unknown ESIS packet type 0x%x",
|
|
|
|
ehdr.esis_type & OSI_PDU_TYPE_MASK );
|
|
|
|
}
|
2000-04-15 22:11:26 +00:00
|
|
|
} /* dissect_esis */
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
Tvbuffify the IP, ICMP, TCP, UDP, OSI CLNP, OSI COTP, OSI CLTP, and OSI
ESIS dissectors.
Register the IP dissector and have dissectors that call it directly
(rather than through a port table) call it through a handle.
Add a routine "tvb_set_reported_length()" which a dissector can use if
it was handed a tvbuff that contains more data than is actually in its
part of the packet - for example, handing a padded Ethernet frame to IP;
the routine sets the reported length of the tvbuff (and also adjusts the
actual length, as appropriate). Then use it in IP.
Given that, "ethertype()" can determine how much of the Ethernet frame
was actually part of an IP datagram (and can do the same for other
protocols under Ethernet that use "tvb_set_reported_length()"; have it
return the actual length, and have "dissect_eth()" and "dissect_vlan()"
use that to mark trailer data in Ethernet II frames as well as in 802.3
frames.
svn path=/trunk/; revision=2658
2000-11-18 10:38:33 +00:00
|
|
|
* Name: proto_register_esis()
|
2000-04-15 22:11:26 +00:00
|
|
|
*
|
|
|
|
* Description:
|
2012-04-26 16:47:37 +00:00
|
|
|
* main register for esis protocol set. We register some display
|
|
|
|
* formats and the protocol module variables.
|
2000-04-15 22:11:26 +00:00
|
|
|
*
|
2012-04-26 16:47:37 +00:00
|
|
|
* NOTE: this procedure to autolinked by the makefile process that
|
|
|
|
* builds register.c
|
2000-04-15 22:11:26 +00:00
|
|
|
*
|
2002-08-28 21:04:11 +00:00
|
|
|
* Input:
|
2012-04-26 16:47:37 +00:00
|
|
|
* void
|
2000-04-15 22:11:26 +00:00
|
|
|
*
|
|
|
|
* Output:
|
2012-04-26 16:47:37 +00:00
|
|
|
* void
|
2000-04-15 22:11:26 +00:00
|
|
|
*/
|
2002-08-28 21:04:11 +00:00
|
|
|
void
|
2000-04-15 22:11:26 +00:00
|
|
|
proto_register_esis(void) {
|
|
|
|
static hf_register_info hf[] = {
|
|
|
|
{ &hf_esis_nlpi,
|
2002-08-28 21:04:11 +00:00
|
|
|
{ "Network Layer Protocol Identifier", "esis.nlpi",
|
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
|
|
|
FT_UINT8, BASE_HEX, VALS(nlpid_vals), 0x0, NULL, HFILL }},
|
2012-04-26 16:47:37 +00:00
|
|
|
|
2000-04-15 22:11:26 +00:00
|
|
|
{ &hf_esis_length,
|
2012-04-26 16:47:37 +00:00
|
|
|
{ "PDU Length", "esis.length", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
|
|
|
|
|
2000-04-15 22:11:26 +00:00
|
|
|
{ &hf_esis_version,
|
2012-04-26 16:47:37 +00:00
|
|
|
{ "Version (==1)", "esis.ver", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
|
|
|
|
|
2000-04-15 22:11:26 +00:00
|
|
|
{ &hf_esis_reserved,
|
2012-04-26 16:47:37 +00:00
|
|
|
{ "Reserved(==0)", "esis.res", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
|
|
|
|
|
2000-04-15 22:11:26 +00:00
|
|
|
{ &hf_esis_type,
|
2012-04-26 16:47:37 +00:00
|
|
|
{ "PDU Type", "esis.type", FT_UINT8, BASE_DEC, VALS(esis_vals), 0xff, NULL, HFILL }},
|
|
|
|
|
2000-04-15 22:11:26 +00:00
|
|
|
{ &hf_esis_holdtime,
|
2012-04-26 16:47:37 +00:00
|
|
|
{ "Holding Time", "esis.htime", FT_UINT16, BASE_DEC, NULL, 0x0, "s", HFILL }},
|
|
|
|
|
2000-04-15 22:11:26 +00:00
|
|
|
{ &hf_esis_checksum,
|
2013-08-06 01:11:55 +00:00
|
|
|
{ "Checksum", "esis.chksum", FT_UINT16, BASE_HEX, NULL, 0x0, NULL, HFILL }},
|
|
|
|
|
|
|
|
/* Generated from convert_proto_tree_add_text.pl */
|
|
|
|
{ &hf_esis_number_of_source_addresses, { "Number of Source Addresses (SA, Format: NSAP)", "esis.number_of_source_addresses", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
|
|
|
|
{ &hf_esis_sal, { "SAL", "esis.sal", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
|
|
|
|
{ &hf_esis_netl, { "NETL", "esis.netl", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
|
|
|
|
{ &hf_esis_dal, { "DAL", "esis.dal", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
|
|
|
|
{ &hf_esis_bsnpal, { "BSNPAL", "esis.bsnpal", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
|
2013-12-19 22:05:07 +00:00
|
|
|
{ &hf_esis_net, { "NET", "esis.net", FT_STRING, BASE_NONE, NULL, 0x0, NULL, HFILL }},
|
|
|
|
{ &hf_esis_da, { "DA", "esis.da", FT_STRING, BASE_NONE, NULL, 0x0, NULL, HFILL }},
|
2013-12-23 15:18:48 +00:00
|
|
|
{ &hf_esis_bsnpa, { "BSNPA", "esis.bsnpa", FT_SYSTEM_ID, BASE_NONE, NULL, 0x0, NULL, HFILL }},
|
2000-04-15 22:11:26 +00:00
|
|
|
};
|
|
|
|
/*
|
2002-08-28 21:04:11 +00:00
|
|
|
*
|
|
|
|
*
|
2000-04-15 22:11:26 +00:00
|
|
|
*/
|
|
|
|
static gint *ett[] = {
|
|
|
|
&ett_esis,
|
|
|
|
&ett_esis_area_addr,
|
|
|
|
};
|
|
|
|
|
2001-01-03 06:56:03 +00:00
|
|
|
proto_esis = proto_register_protocol( PROTO_STRING_ESIS, "ESIS", "esis");
|
2000-04-15 22:11:26 +00:00
|
|
|
proto_register_field_array(proto_esis, hf, array_length(hf));
|
|
|
|
proto_register_subtree_array(ett, array_length(ett));
|
2008-09-27 14:02:23 +00:00
|
|
|
register_dissector("esis", dissect_esis, proto_esis);
|
2003-12-21 05:51:34 +00:00
|
|
|
}
|
2000-04-17 01:36:31 +00:00
|
|
|
|
|
|
|
void
|
|
|
|
proto_reg_handoff_esis(void)
|
|
|
|
{
|
2001-12-03 04:00:26 +00:00
|
|
|
dissector_handle_t esis_handle;
|
|
|
|
|
2008-09-27 14:02:23 +00:00
|
|
|
esis_handle = find_dissector("esis");
|
2013-09-12 20:34:19 +00:00
|
|
|
dissector_add_uint("osinl.incl", NLPID_ISO9542_ESIS, esis_handle);
|
2000-04-17 01:36:31 +00:00
|
|
|
}
|