2 * Declarations of exported routines from MPLS dissector
3 * Author: Carlos Pignataro <cpignata@cisco.com>
4 * Copyright 2005, cisco Systems, Inc.
6 * (c) Copyright 2006, _FF_ Francesco Fondelli <francesco.fondelli@gmail.com>
7 * added MPLS OAM support, ITU-T Y.1711
8 * (c) Copyright 2011, Shobhank Sharma <ssharma5@ncsu.edu>
9 * added MPLS Generic Associated Channel as per RFC 5586
13 * Wireshark - Network traffic analyzer
14 * By Gerald Combs <gerald@wireshark.org>
15 * Copyright 1998 Gerald Combs
17 * This program is free software; you can redistribute it and/or
18 * modify it under the terms of the GNU General Public License
19 * as published by the Free Software Foundation; either version 2
20 * of the License, or (at your option) any later version.
22 * This program is distributed in the hope that it will be useful,
23 * but WITHOUT ANY WARRANTY; without even the implied warranty of
24 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25 * GNU General Public License for more details.
27 * You should have received a copy of the GNU General Public License
28 * along with this program; if not, write to the Free Software
29 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
35 /* Special labels in MPLS */
37 MPLS_LABEL_IP4_EXPLICIT_NULL
= 0,
38 MPLS_LABEL_ROUTER_ALERT
,
39 MPLS_LABEL_IP6_EXPLICIT_NULL
,
40 MPLS_LABEL_IMPLICIT_NULL
,
41 MPLS_LABEL_GACH
= 13, /* aka GAL */
42 MPLS_LABEL_OAM_ALERT
= 14,
43 MPLS_LABEL_MAX_RESERVED
= 15,
44 MPLS_LABEL_INVALID
= -1
48 * FF: private data passed from the MPLS dissector to subdissectors
52 guint32 label
; /* last mpls label in label stack */
53 guint8 exp
; /* former EXP bits of last mpls shim in stack */
54 guint8 bos
; /* BOS bit of last mpls shim in stack */
55 guint8 ttl
; /* TTL bits of last mpls shim in stack */
58 extern const value_string special_labels
[];
59 extern void decode_mpls_label(tvbuff_t
*tvb
, int offset
,
60 guint32
*label
, guint8
*exp
,
61 guint8
*bos
, guint8
*ttl
);
63 extern gboolean
dissect_try_cw_first_nibble(tvbuff_t
*tvb
, packet_info
*pinfo
,
65 int dissect_mpls_echo(tvbuff_t
*tvb
, packet_info
*pinfo
, proto_tree
*tree
, void *data _U_
);