Revert "TODO epan/dissectors/asn1/kerberos/packet-kerberos-template.c new GSS flags"
[wireshark-sm.git] / epan / dissectors / packet-lmp.c
blob5b467e0ef1c50ea787e4b1697e009035f67f79db
1 /* packet-lmp.c
2 * Routines for LMP packet disassembly
4 * (c) Copyright Ashok Narayanan <ashokn@cisco.com>
6 * Wireshark - Network traffic analyzer
7 * By Gerald Combs <gerald@wireshark.org>
8 * Copyright 1998 Gerald Combs
10 * SPDX-License-Identifier: GPL-2.0-or-later
14 * Code for dissecting the Link Management Protocol (LMP). The latest LMP
15 * specification is in draft-ieft-ccamp-lmp-10.txt. This version also includes
16 * support for dissecting LMP service discovery extensions defined in the
17 * UNI 1.0 specification.
19 * Support for LMP service discovery extensions added by Manu Pathak
20 * (mapathak@cisco.com), June 2005.
22 * Support for RFC4207 (SONET/SDH encoding for LMP test messages) added
23 * by Roberto Morro (roberto.morro [AT] tilab.com), August 2007
25 * Support for (provisional) oif-p0040.010.006 added by Roberto Morro,
26 * August 2007
29 #include "config.h"
31 #include <epan/packet.h>
32 #include <epan/prefs.h>
33 #include <epan/in_cksum.h>
34 #include <epan/expert.h>
35 #include <epan/to_str.h>
36 #include <epan/tfs.h>
37 #include <epan/unit_strings.h>
39 #include <wsutil/array.h>
40 #include "packet-rsvp.h"
42 void proto_register_lmp(void);
43 void proto_reg_handoff_lmp(void);
45 static int proto_lmp;
47 #define UDP_PORT_LMP_DEFAULT 701
49 static bool lmp_checksum_config;
51 static dissector_handle_t lmp_handle;
53 /*----------------------------------------------------------------------
54 * LMP message types
56 typedef enum {
57 LMP_MSG_CONFIG=1,
58 LMP_MSG_CONFIG_ACK,
59 LMP_MSG_CONFIG_NACK,
60 LMP_MSG_HELLO,
61 LMP_MSG_BEGIN_VERIFY,
62 LMP_MSG_BEGIN_VERIFY_ACK,
63 LMP_MSG_BEGIN_VERIFY_NACK,
64 LMP_MSG_END_VERIFY,
65 LMP_MSG_END_VERIFY_ACK,
66 LMP_MSG_TEST,
67 LMP_MSG_TEST_STATUS_SUCCESS,
68 LMP_MSG_TEST_STATUS_FAILURE,
69 LMP_MSG_TEST_STATUS_ACK,
70 LMP_MSG_LINK_SUMMARY,
71 LMP_MSG_LINK_SUMMARY_ACK,
72 LMP_MSG_LINK_SUMMARY_NACK,
73 LMP_MSG_CHANNEL_STATUS,
74 LMP_MSG_CHANNEL_STATUS_ACK,
75 LMP_MSG_CHANNEL_STATUS_REQ,
76 LMP_MSG_CHANNEL_STATUS_RESP,
77 LMP_MSG_TRACE_MONITOR,
78 LMP_MSG_TRACE_MONITOR_ACK,
79 LMP_MSG_TRACE_MONITOR_NACK,
80 LMP_MSG_TRACE_MISMATCH,
81 LMP_MSG_TRACE_MISMATCH_ACK,
82 LMP_MSG_TRACE_REQUEST,
83 LMP_MSG_TRACE_REPORT,
84 LMP_MSG_TRACE_REQUEST_NACK,
85 LMP_MSG_INSERT_TRACE,
86 LMP_MSG_INSERT_TRACE_ACK,
87 LMP_MSG_INSERT_TRACE_NACK,
88 LMP_MSG_SERVICE_CONFIG=50,
89 LMP_MSG_SERVICE_CONFIG_ACK,
90 LMP_MSG_SERVICE_CONFIG_NACK,
91 LMP_MSG_DISCOVERY_RESP=241,
92 LMP_MSG_DISCOVERY_RESP_ACK,
93 LMP_MSG_DISCOVERY_RESP_NACK
94 } lmp_message_types;
96 static const value_string message_type_vals[] = {
97 {LMP_MSG_CONFIG, "Config Message. "},
98 {LMP_MSG_CONFIG_ACK, "ConfigAck Message. "},
99 {LMP_MSG_CONFIG_NACK, "ConfigNack Message. "},
100 {LMP_MSG_HELLO, "Hello Message. "},
101 {LMP_MSG_BEGIN_VERIFY, "BeginVerify Message. "},
102 {LMP_MSG_BEGIN_VERIFY_ACK, "BeginVerifyAck Message. "},
103 {LMP_MSG_BEGIN_VERIFY_NACK, "BeginVerifyNack Message. "},
104 {LMP_MSG_END_VERIFY, "EndVerify Message. "},
105 {LMP_MSG_END_VERIFY_ACK, "EndVerifyAck Message. "},
106 {LMP_MSG_TEST, "Test Message. "},
107 {LMP_MSG_TEST_STATUS_SUCCESS, "TestStatusSuccess Message. "},
108 {LMP_MSG_TEST_STATUS_FAILURE, "TestStatusFailure Message. "},
109 {LMP_MSG_TEST_STATUS_ACK, "TestStatusAck Message. "},
110 {LMP_MSG_LINK_SUMMARY, "LinkSummary Message. "},
111 {LMP_MSG_LINK_SUMMARY_ACK, "LinkSummaryAck Message. "},
112 {LMP_MSG_LINK_SUMMARY_NACK, "LinkSummaryNack Message. "},
113 {LMP_MSG_CHANNEL_STATUS, "ChannelStatus Message. "},
114 {LMP_MSG_CHANNEL_STATUS_ACK, "ChannelStatusAck Message. "},
115 {LMP_MSG_CHANNEL_STATUS_REQ, "ChannelStatusRequest Message. "},
116 {LMP_MSG_CHANNEL_STATUS_RESP, "ChannelStatusResponse Message. "},
117 {LMP_MSG_TRACE_MONITOR, "TraceMonitor Message. "},
118 {LMP_MSG_TRACE_MONITOR_ACK, "TraceMonitorAck Message. "},
119 {LMP_MSG_TRACE_MONITOR_NACK, "TraceMonitorNack Message. "},
120 {LMP_MSG_TRACE_MISMATCH, "TraceMismatch Message. "},
121 {LMP_MSG_TRACE_MISMATCH_ACK, "TraceMismatchAck Message. "},
122 {LMP_MSG_TRACE_REQUEST, "TraceRequest Message. "},
123 {LMP_MSG_TRACE_REPORT, "TraceReport Message. "},
124 {LMP_MSG_TRACE_REQUEST_NACK, "TraceReportNack Message. "},
125 {LMP_MSG_INSERT_TRACE, "InsertTrace Message. "},
126 {LMP_MSG_INSERT_TRACE_ACK, "InsertTraceAck Message. "},
127 {LMP_MSG_INSERT_TRACE_NACK, "InsertTraceNack Message. "},
128 {LMP_MSG_SERVICE_CONFIG, "ServiceConfig Message. "},
129 {LMP_MSG_SERVICE_CONFIG_ACK, "ServiceConfigAck Message. "},
130 {LMP_MSG_SERVICE_CONFIG_NACK, "ServiceConfigNack Message. "},
131 {LMP_MSG_DISCOVERY_RESP, "DiscoveryResponse Message. "},
132 {LMP_MSG_DISCOVERY_RESP_ACK, "DiscoveryResponseAck Message. "},
133 {LMP_MSG_DISCOVERY_RESP_NACK, "DiscoveryResponseNack Message. "},
134 {0, NULL}
137 /*------------------------------------------------------------------------------
138 * LMP object classes
140 #define LMP_CLASS_NULL 0
142 #define LMP_CLASS_CCID 1
143 #define LMP_CLASS_NODE_ID 2
144 #define LMP_CLASS_LINK_ID 3
145 #define LMP_CLASS_INTERFACE_ID 4
146 #define LMP_CLASS_MESSAGE_ID 5
147 #define LMP_CLASS_CONFIG 6
148 #define LMP_CLASS_HELLO 7
149 #define LMP_CLASS_BEGIN_VERIFY 8
150 #define LMP_CLASS_BEGIN_VERIFY_ACK 9
151 #define LMP_CLASS_VERIFY_ID 10
152 #define LMP_CLASS_TE_LINK 11
153 #define LMP_CLASS_DATA_LINK 12
154 #define LMP_CLASS_CHANNEL_STATUS 13
155 #define LMP_CLASS_CHANNEL_STATUS_REQUEST 14
156 #define LMP_LAST_CONTIGUOUS_CLASS LMP_CLASS_CHANNEL_STATUS_REQUEST
157 #define LMP_CLASS_ERROR 20
158 #define LMP_CLASS_TRACE 21
159 #define LMP_CLASS_TRACE_REQ 22
160 #define LMP_CLASS_SERVICE_CONFIG 51
161 #define LMP_CLASS_DA_DCN_ADDRESS 248
162 #define LMP_CLASS_LOCAL_LAD_INFO 249
163 #define LMP_CLASS_MAX 250
165 static const value_string lmp_class_vals[] = {
167 {LMP_CLASS_CCID, "CCID"},
168 {LMP_CLASS_NODE_ID, "NODE_ID"},
169 {LMP_CLASS_LINK_ID, "LINK_ID"},
170 {LMP_CLASS_INTERFACE_ID, "INTERFACE_ID"},
171 {LMP_CLASS_MESSAGE_ID, "MESSAGE_ID"},
172 {LMP_CLASS_CONFIG, "CONFIG"},
173 {LMP_CLASS_HELLO, "HELLO"},
174 {LMP_CLASS_BEGIN_VERIFY, "BEGIN_VERIFY"},
175 {LMP_CLASS_BEGIN_VERIFY_ACK, "BEGIN_VERIFY_ACK"},
176 {LMP_CLASS_VERIFY_ID, "VERIFY_ID"},
177 {LMP_CLASS_TE_LINK, "TE_LINK"},
178 {LMP_CLASS_DATA_LINK, "DATA_LINK"},
179 {LMP_CLASS_CHANNEL_STATUS, "CHANNEL_STATUS"},
180 {LMP_CLASS_CHANNEL_STATUS_REQUEST, "CHANNEL_STATUS_REQUEST"},
181 {LMP_CLASS_ERROR, "ERROR"},
182 {LMP_CLASS_TRACE, "TRACE"},
183 {LMP_CLASS_TRACE_REQ, "TRACE_REQ"},
184 {LMP_CLASS_SERVICE_CONFIG, "SERVICE_CONFIG"},
185 {LMP_CLASS_DA_DCN_ADDRESS, "DA_DCN_ADDRESS"},
186 {LMP_CLASS_LOCAL_LAD_INFO, "LOCAL_LAD_INFO"},
187 {0, NULL}
191 /*------------------------------------------------------------------------------
192 * Other constants & stuff
195 /* Channel Status */
196 static const value_string channel_status_str[] = {
197 {1, "Signal Okay (OK)"},
198 {2, "Signal Degraded (SD)"},
199 {3, "Signal Failed (SF)"},
200 {0, NULL}
202 static const value_string channel_status_short_str[] = {
203 {1, "OK"},
204 {2, "SD"},
205 {3, "SF"},
206 {0, NULL}
209 /* Service Discovery Client ServiceConfig object (defined in UNI 1.0) */
211 /* Client Port-Level Service Attribute Object */
213 /* Link Type */
214 static const value_string service_attribute_link_type_str[] = {
215 {5, "SDH ITU-T G.707"},
216 {6, "SONET ANSI T1.105"},
217 {0, NULL}
220 /* Signal Types for SDH */
221 static const value_string service_attribute_signal_types_sdh_str[] = {
222 {5, "VC-3"},
223 {6, "VC-4"},
224 {7, "STM-0"},
225 {8, "STM-1"},
226 {9, "STM-4"},
227 {10, "STM-16"},
228 {11, "STM-64"},
229 {12, "STM-256"},
230 {0, NULL}
233 /* Signal Types for SONET */
234 static const value_string service_attribute_signal_types_sonet_str[] = {
235 {5, "STS-1 SPE"},
236 {6, "STS-3c SPE"},
237 {7, "STS-1"},
238 {8, "STS-3"},
239 {9, "STS-12"},
240 {10, "STS-48"},
241 {11, "STS-192"},
242 {12, "STS-768"},
243 {0, NULL}
246 /* Trace type */
247 static const value_string lmp_trace_type_str[] = {
248 { 1, "SONET Section Trace (J0 Byte)"},
249 { 2, "SONET Path Trace (J1 Byte)"},
250 { 3, "SONET Path Trace (J2 Byte)"},
251 { 4, "SDH Section Trace (J0 Byte)"},
252 { 5, "SDH Path Trace (J1 Byte)"},
253 { 6, "SDH Path Trace (J2 Byte)"},
254 { 0, NULL}
258 * These values are used by the code that handles the Service Discovery
259 * Client Port-Level Service Attributes Object.
261 #define LMP_CLASS_SERVICE_CONFIG_CPSA_SIGNAL_TYPES_SDH 5
262 #define LMP_CLASS_SERVICE_CONFIG_CPSA_SIGNAL_TYPES_SONET 6
264 /*------------------------------------------------------------------------------
265 * LMP Filter values
268 enum hf_lmp_filter_keys {
270 /* Message types ---------------- */
271 LMPF_MSG,
273 LMPF_MSG_CONFIG,
274 LMPF_MSG_CONFIG_ACK,
275 LMPF_MSG_CONFIG_NACK,
276 LMPF_MSG_HELLO,
277 LMPF_MSG_BEGIN_VERIFY,
278 LMPF_MSG_BEGIN_VERIFY_ACK,
279 LMPF_MSG_BEGIN_VERIFY_NACK,
280 LMPF_MSG_END_VERIFY,
281 LMPF_MSG_END_VERIFY_ACK,
282 LMPF_MSG_TEST,
283 LMPF_MSG_TEST_STATUS_SUCCESS,
284 LMPF_MSG_TEST_STATUS_FAILURE,
285 LMPF_MSG_TEST_STATUS_ACK,
286 LMPF_MSG_LINK_SUMMARY,
287 LMPF_MSG_LINK_SUMMARY_ACK,
288 LMPF_MSG_LINK_SUMMARY_NACK,
289 LMPF_MSG_CHANNEL_STATUS,
290 LMPF_MSG_CHANNEL_STATUS_ACK,
291 LMPF_MSG_CHANNEL_STATUS_REQ,
292 LMPF_MSG_CHANNEL_STATUS_RESP,
293 LMPF_MSG_TRACE_MONITOR,
294 LMPF_MSG_TRACE_MONITOR_ACK,
295 LMPF_MSG_TRACE_MONITOR_NACK,
296 LMPF_MSG_TRACE_MISMATCH,
297 LMPF_MSG_TRACE_MISMATCH_ACK,
298 LMPF_MSG_TRACE_REQUEST,
299 LMPF_MSG_TRACE_REPORT,
300 LMPF_MSG_TRACE_REQUEST_NACK,
301 LMPF_MSG_INSERT_TRACE,
302 LMPF_MSG_INSERT_TRACE_ACK,
303 LMPF_MSG_INSERT_TRACE_NACK,
304 LMPF_MSG_SERVICE_CONFIG,
305 LMPF_MSG_SERVICE_CONFIG_ACK,
306 LMPF_MSG_SERVICE_CONFIG_NACK,
307 LMPF_MSG_DISCOVERY_RESP,
308 LMPF_MSG_DISCOVERY_RESP_ACK,
309 LMPF_MSG_DISCOVERY_RESP_NACK,
311 LMPF_MSG_MAX,
313 /* LMP Message Header Fields ------------------ */
314 LMPF_HDR_FLAGS,
315 LMPF_HDR_FLAGS_CC_DOWN,
316 LMPF_HDR_FLAGS_REBOOT,
318 /* LMP Object Class Filters -------------------- */
319 LMPF_OBJECT,
321 LMPF_CLASS_CCID,
322 LMPF_CLASS_NODE_ID,
323 LMPF_CLASS_LINK_ID,
324 LMPF_CLASS_INTERFACE_ID,
325 LMPF_CLASS_MESSAGE_ID,
326 LMPF_CLASS_CONFIG,
327 LMPF_CLASS_HELLO,
328 LMPF_CLASS_BEGIN_VERIFY,
329 LMPF_CLASS_BEGIN_VERIFY_ACK,
330 LMPF_CLASS_VERIFY_ID,
331 LMPF_CLASS_TE_LINK,
332 LMPF_CLASS_DATA_LINK,
333 LMPF_CLASS_CHANNEL_STATUS,
334 LMPF_CLASS_CHANNEL_STATUS_REQUEST,
335 LMPF_CLASS_ERROR,
336 LMPF_CLASS_TRACE,
337 LMPF_CLASS_TRACE_REQ,
338 LMPF_CLASS_SERVICE_CONFIG,
339 LMPF_CLASS_DA_DCN_ADDRESS,
340 LMPF_CLASS_LOCAL_LAD_INFO,
342 LMPF_VAL_CTYPE,
343 LMPF_VAL_LOCAL_CCID,
344 LMPF_VAL_REMOTE_CCID,
345 LMPF_VAL_LOCAL_NODE_ID,
346 LMPF_VAL_REMOTE_NODE_ID,
347 LMPF_VAL_LOCAL_LINK_ID_IPV4,
348 LMPF_VAL_LOCAL_LINK_ID_IPV6,
349 LMPF_VAL_LOCAL_LINK_ID_UNNUM,
350 LMPF_VAL_REMOTE_LINK_ID_IPV4,
351 LMPF_VAL_REMOTE_LINK_ID_IPV6,
352 LMPF_VAL_REMOTE_LINK_ID_UNNUM,
353 LMPF_VAL_LOCAL_INTERFACE_ID_IPV4,
354 LMPF_VAL_LOCAL_INTERFACE_ID_IPV6,
355 LMPF_VAL_LOCAL_INTERFACE_ID_UNNUM,
356 LMPF_VAL_REMOTE_INTERFACE_ID_IPV4,
357 LMPF_VAL_REMOTE_INTERFACE_ID_IPV6,
358 LMPF_VAL_REMOTE_INTERFACE_ID_UNNUM,
359 LMPF_VAL_CHANNEL_STATUS_INTERFACE_ID_IPV4,
360 LMPF_VAL_CHANNEL_STATUS_INTERFACE_ID_IPV6,
361 LMPF_VAL_CHANNEL_STATUS_INTERFACE_ID_UNNUM,
362 LMPF_VAL_MESSAGE_ID,
363 LMPF_VAL_MESSAGE_ID_ACK,
364 LMPF_VAL_CONFIG_HELLO,
365 LMPF_VAL_CONFIG_HELLO_DEAD,
366 LMPF_VAL_HELLO_TXSEQ,
367 LMPF_VAL_HELLO_RXSEQ,
369 LMPF_VAL_BEGIN_VERIFY_FLAGS,
370 LMPF_VAL_BEGIN_VERIFY_FLAGS_ALL_LINKS,
371 LMPF_VAL_BEGIN_VERIFY_FLAGS_LINK_TYPE,
372 LMPF_VAL_BEGIN_VERIFY_INTERVAL,
373 LMPF_VAL_BEGIN_VERIFY_ENCTYPE,
374 LMPF_VAL_BEGIN_VERIFY_TRANSPORT,
375 LMPF_VAL_BEGIN_VERIFY_TRANSMISSION_RATE,
376 LMPF_VAL_BEGIN_VERIFY_WAVELENGTH,
377 LMPF_VAL_VERIFY_ID,
379 LMPF_VAL_TE_LINK_FLAGS,
380 LMPF_VAL_TE_LINK_FLAGS_FAULT_MGMT,
381 LMPF_VAL_TE_LINK_FLAGS_LINK_VERIFY,
382 LMPF_VAL_TE_LINK_LOCAL_IPV4,
383 LMPF_VAL_TE_LINK_LOCAL_IPV6,
384 LMPF_VAL_TE_LINK_LOCAL_UNNUM,
385 LMPF_VAL_TE_LINK_REMOTE_IPV4,
386 LMPF_VAL_TE_LINK_REMOTE_IPV6,
387 LMPF_VAL_TE_LINK_REMOTE_UNNUM,
389 LMPF_VAL_DATA_LINK_FLAGS,
390 LMPF_VAL_DATA_LINK_FLAGS_PORT,
391 LMPF_VAL_DATA_LINK_FLAGS_ALLOCATED,
392 LMPF_VAL_DATA_LINK_LOCAL_IPV4,
393 LMPF_VAL_DATA_LINK_LOCAL_IPV6,
394 LMPF_VAL_DATA_LINK_LOCAL_UNNUM,
395 LMPF_VAL_DATA_LINK_REMOTE_IPV4,
396 LMPF_VAL_DATA_LINK_REMOTE_IPV6,
397 LMPF_VAL_DATA_LINK_REMOTE_UNNUM,
398 LMPF_VAL_DATA_LINK_SUBOBJ,
399 LMPF_VAL_DATA_LINK_SUBOBJ_SWITCHING_TYPE,
400 LMPF_VAL_DATA_LINK_SUBOBJ_LSP_ENCODING,
402 LMPF_VAL_ERROR,
403 LMPF_VAL_ERROR_VERIFY_UNSUPPORTED_LINK,
404 LMPF_VAL_ERROR_VERIFY_UNWILLING,
405 LMPF_VAL_ERROR_VERIFY_TRANSPORT,
406 LMPF_VAL_ERROR_VERIFY_TE_LINK_ID,
407 LMPF_VAL_ERROR_VERIFY_UNKNOWN_CTYPE,
408 LMPF_VAL_ERROR_SUMMARY_BAD_PARAMETERS,
409 LMPF_VAL_ERROR_SUMMARY_RENEGOTIATE,
410 LMPF_VAL_ERROR_SUMMARY_BAD_TE_LINK,
411 LMPF_VAL_ERROR_SUMMARY_BAD_DATA_LINK,
412 LMPF_VAL_ERROR_SUMMARY_UNKNOWN_TEL_CTYPE,
413 LMPF_VAL_ERROR_SUMMARY_UNKNOWN_DL_CTYPE,
414 LMPF_VAL_ERROR_SUMMARY_BAD_REMOTE_LINK_ID,
415 LMPF_VAL_ERROR_CONFIG_BAD_PARAMETERS,
416 LMPF_VAL_ERROR_CONFIG_RENEGOTIATE,
417 LMPF_VAL_ERROR_CONFIG_BAD_CCID,
418 LMPF_VAL_ERROR_TRACE_UNSUPPORTED_TYPE,
419 LMPF_VAL_ERROR_TRACE_INVALID_MSG,
420 LMPF_VAL_ERROR_TRACE_UNKNOWN_CTYPE,
421 LMPF_VAL_ERROR_LAD_AREA_ID_MISMATCH,
422 LMPF_VAL_ERROR_LAD_TCP_ID_MISMATCH,
423 LMPF_VAL_ERROR_LAD_DA_DCN_MISMATCH,
424 LMPF_VAL_ERROR_LAD_CAPABILITY_MISMATCH,
425 LMPF_VAL_ERROR_LAD_UNKNOWN_CTYPE,
427 LMPF_VAL_TRACE_LOCAL_TYPE,
428 LMPF_VAL_TRACE_LOCAL_LEN,
429 LMPF_VAL_TRACE_LOCAL_MSG,
430 LMPF_VAL_TRACE_REMOTE_TYPE,
431 LMPF_VAL_TRACE_REMOTE_LEN,
432 LMPF_VAL_TRACE_REMOTE_MSG,
434 LMPF_VAL_TRACE_REQ_TYPE,
436 LMPF_VAL_SERVICE_CONFIG_SP_FLAGS,
437 LMPF_VAL_SERVICE_CONFIG_SP_FLAGS_RSVP,
438 LMPF_VAL_SERVICE_CONFIG_SP_FLAGS_LDP,
439 LMPF_VAL_SERVICE_CONFIG_CPSA_TP_FLAGS,
440 LMPF_VAL_SERVICE_CONFIG_CPSA_TP_FLAGS_PATH_OVERHEAD,
441 LMPF_VAL_SERVICE_CONFIG_CPSA_TP_FLAGS_LINE_OVERHEAD,
442 LMPF_VAL_SERVICE_CONFIG_CPSA_TP_FLAGS_SECTION_OVERHEAD,
443 LMPF_VAL_SERVICE_CONFIG_CPSA_CCT_FLAGS,
444 LMPF_VAL_SERVICE_CONFIG_CPSA_CCT_FLAGS_CC_SUPPORTED,
445 LMPF_VAL_SERVICE_CONFIG_CPSA_MIN_NCC,
446 LMPF_VAL_SERVICE_CONFIG_CPSA_MAX_NCC,
447 LMPF_VAL_SERVICE_CONFIG_CPSA_MIN_NVC,
448 LMPF_VAL_SERVICE_CONFIG_CPSA_MAX_NVC,
449 LMPF_VAL_SERVICE_CONFIG_CPSA_INTERFACE_ID,
450 LMPF_VAL_SERVICE_CONFIG_NSA_TRANSPARENCY_FLAGS,
451 LMPF_VAL_SERVICE_CONFIG_NSA_TRANSPARENCY_FLAGS_SOH,
452 LMPF_VAL_SERVICE_CONFIG_NSA_TRANSPARENCY_FLAGS_LOH,
453 LMPF_VAL_SERVICE_CONFIG_NSA_TCM_FLAGS,
454 LMPF_VAL_SERVICE_CONFIG_NSA_TCM_FLAGS_TCM_SUPPORTED,
455 LMPF_VAL_SERVICE_CONFIG_NSA_NETWORK_DIVERSITY_FLAGS,
456 LMPF_VAL_SERVICE_CONFIG_NSA_NETWORK_DIVERSITY_FLAGS_NODE,
457 LMPF_VAL_SERVICE_CONFIG_NSA_NETWORK_DIVERSITY_FLAGS_LINK,
458 LMPF_VAL_SERVICE_CONFIG_NSA_NETWORK_DIVERSITY_FLAGS_SRLG,
460 LMPF_VAL_LOCAL_DA_DCN_ADDR,
461 LMPF_VAL_REMOTE_DA_DCN_ADDR,
463 LMPF_VAL_LOCAL_LAD_INFO_NODE_ID,
464 LMPF_VAL_LOCAL_LAD_INFO_AREA_ID,
465 LMPF_VAL_LOCAL_LAD_INFO_TE_LINK_ID,
466 LMPF_VAL_LOCAL_LAD_INFO_COMPONENT_ID,
467 LMPF_VAL_LOCAL_LAD_INFO_SC_PC_ID,
468 LMPF_VAL_LOCAL_LAD_INFO_SC_PC_ADDR,
470 LMPF_VAL_LAD_INFO_SUBOBJ,
471 LMPF_VAL_LAD_INFO_SUBOBJ_PRI_AREA_ID,
472 LMPF_VAL_LAD_INFO_SUBOBJ_PRI_RC_PC_ID,
473 LMPF_VAL_LAD_INFO_SUBOBJ_PRI_RC_PC_ADDR,
474 LMPF_VAL_LAD_INFO_SUBOBJ_SEC_AREA_ID,
475 LMPF_VAL_LAD_INFO_SUBOBJ_SEC_RC_PC_ID,
476 LMPF_VAL_LAD_INFO_SUBOBJ_SEC_RC_PC_ADDR,
477 LMPF_VAL_LAD_INFO_SUBOBJ_SWITCHING_TYPE,
478 LMPF_VAL_LAD_INFO_SUBOBJ_LSP_ENCODING,
480 LMPF_CHECKSUM,
481 LMPF_CHECKSUM_STATUS,
483 LMPF_MAX
486 static int hf_lmp_filter[LMPF_MAX];
487 static int hf_lmp_data;
489 /* Generated from convert_proto_tree_add_text.pl */
490 static int hf_lmp_maximum_reservable_bandwidth;
491 static int hf_lmp_verify_transport_mechanism;
492 static int hf_lmp_interface_id_ipv6;
493 static int hf_lmp_minimum_reservable_bandwidth;
494 static int hf_lmp_object_length;
495 static int hf_lmp_interface_id_unnumbered;
496 static int hf_lmp_signal_types_sdh;
497 static int hf_lmp_link_type;
498 static int hf_lmp_number_of_data_links;
499 static int hf_lmp_version;
500 static int hf_lmp_interface_id_ipv4;
501 static int hf_lmp_header_length;
502 static int hf_lmp_uni_version;
503 static int hf_lmp_subobject_type;
504 static int hf_lmp_object_class;
505 static int hf_lmp_negotiable;
506 static int hf_lmp_signal_types_sonet;
507 static int hf_lmp_header_flags;
508 static int hf_lmp_verify_interval;
509 static int hf_lmp_wavelength;
510 static int hf_lmp_channel_status;
511 static int hf_lmp_verifydeadinterval;
512 static int hf_lmp_data_link_remote_id_ipv6;
513 static int hf_lmp_link;
514 static int hf_lmp_subobject_length;
515 static int hf_lmp_transmission_rate;
516 static int hf_lmp_verify_transport_response;
517 static int hf_lmp_data_link_local_id_ipv6;
518 static int hf_lmp_free_timeslots;
520 static expert_field ei_lmp_checksum_incorrect;
521 static expert_field ei_lmp_invalid_msg_type;
522 static expert_field ei_lmp_invalid_class;
523 static expert_field ei_lmp_trace_len;
524 static expert_field ei_lmp_obj_len;
526 static int
527 lmp_valid_class(int lmp_class)
529 /* Contiguous classes */
530 if (lmp_class > LMP_CLASS_NULL && lmp_class <= LMP_LAST_CONTIGUOUS_CLASS)
531 return 1;
533 /* Noncontiguous classes */
534 if (lmp_class == LMP_CLASS_ERROR ||
535 lmp_class == LMP_CLASS_TRACE ||
536 lmp_class == LMP_CLASS_TRACE_REQ ||
537 lmp_class == LMP_CLASS_SERVICE_CONFIG ||
538 lmp_class == LMP_CLASS_DA_DCN_ADDRESS ||
539 lmp_class == LMP_CLASS_LOCAL_LAD_INFO)
540 return 1;
542 return 0;
545 static int
546 lmp_msg_to_filter_num(int msg_type)
548 if (msg_type <= LMP_MSG_INSERT_TRACE_NACK)
549 return LMPF_MSG + msg_type;
551 switch (msg_type) {
552 case LMP_MSG_SERVICE_CONFIG:
553 return LMPF_MSG_SERVICE_CONFIG;
555 case LMP_MSG_SERVICE_CONFIG_ACK:
556 return LMPF_MSG_SERVICE_CONFIG_ACK;
558 case LMP_MSG_SERVICE_CONFIG_NACK:
559 return LMPF_MSG_SERVICE_CONFIG_NACK;
561 case LMP_MSG_DISCOVERY_RESP:
562 return LMPF_MSG_DISCOVERY_RESP;
564 case LMP_MSG_DISCOVERY_RESP_ACK:
565 return LMPF_MSG_DISCOVERY_RESP_ACK;
567 case LMP_MSG_DISCOVERY_RESP_NACK:
568 return LMPF_MSG_DISCOVERY_RESP_NACK;
570 default:
571 return -1;
576 static int
577 lmp_class_to_filter_num(int lmp_class)
581 * The contiguous values can all be handled in the same way. The ERROR and
582 * Service Config objects, whose C-Type values are not contiguously assigned,
583 * must be handled separately.
585 switch (lmp_class) {
587 case LMP_CLASS_CCID:
588 case LMP_CLASS_NODE_ID:
589 case LMP_CLASS_LINK_ID:
590 case LMP_CLASS_INTERFACE_ID:
591 case LMP_CLASS_MESSAGE_ID:
592 case LMP_CLASS_CONFIG:
593 case LMP_CLASS_HELLO:
594 case LMP_CLASS_BEGIN_VERIFY:
595 case LMP_CLASS_BEGIN_VERIFY_ACK:
596 case LMP_CLASS_VERIFY_ID:
597 case LMP_CLASS_TE_LINK:
598 case LMP_CLASS_DATA_LINK:
599 case LMP_CLASS_CHANNEL_STATUS:
600 case LMP_CLASS_CHANNEL_STATUS_REQUEST:
601 return LMPF_OBJECT + lmp_class;
603 case LMP_CLASS_ERROR:
604 return LMPF_CLASS_ERROR;
606 case LMP_CLASS_TRACE:
607 return LMPF_CLASS_TRACE;
609 case LMP_CLASS_TRACE_REQ:
610 return LMPF_CLASS_TRACE_REQ;
612 case LMP_CLASS_SERVICE_CONFIG:
613 return LMPF_CLASS_SERVICE_CONFIG;
615 case LMP_CLASS_DA_DCN_ADDRESS:
616 return LMPF_CLASS_DA_DCN_ADDRESS;
618 case LMP_CLASS_LOCAL_LAD_INFO:
619 return LMPF_CLASS_LOCAL_LAD_INFO;
621 default:
622 return -1;
627 /*------------------------------------------------------------------------------
628 * LMP Subtrees
630 * We have two types of subtrees - a statically defined, constant set and
631 * a class set - one for each class. The static ones are before all the class ones
633 enum {
634 LMP_TREE_MAIN,
635 LMP_TREE_HEADER,
636 LMP_TREE_HEADER_FLAGS,
637 LMP_TREE_OBJECT_HEADER,
638 LMP_TREE_ERROR_FLAGS,
639 LMP_TREE_BEGIN_VERIFY_FLAGS,
640 LMP_TREE_BEGIN_VERIFY_TRANSPORT_FLAGS,
641 LMP_TREE_TE_LINK_FLAGS,
642 LMP_TREE_DATA_LINK_FLAGS,
643 LMP_TREE_DATA_LINK_SUBOBJ,
644 LMP_TREE_CHANNEL_STATUS_ID,
645 LMP_TREE_SERVICE_CONFIG_SP_FLAGS,
646 LMP_TREE_SERVICE_CONFIG_CPSA_TP_FLAGS,
647 LMP_TREE_SERVICE_CONFIG_CPSA_CCT_FLAGS,
648 LMP_TREE_SERVICE_CONFIG_NSA_TRANSPARENCY_FLAGS,
649 LMP_TREE_SERVICE_CONFIG_NSA_TCM_FLAGS,
650 LMP_TREE_SERVICE_CONFIG_NSA_NETWORK_DIVERSITY_FLAGS,
651 LMP_TREE_LAD_INFO_SUBOBJ,
653 LMP_TREE_CLASS_START
656 #define NUM_LMP_SUBTREES (LMP_TREE_CLASS_START + LMP_CLASS_MAX)
658 static int lmp_subtree[NUM_LMP_SUBTREES];
660 static int lmp_class_to_subtree(int lmp_class)
662 if (lmp_valid_class(lmp_class)) {
663 if (lmp_class == LMP_CLASS_SERVICE_CONFIG) {
664 return lmp_subtree[LMP_TREE_CLASS_START + LMP_CLASS_SERVICE_CONFIG];
666 if (lmp_class == LMP_CLASS_DA_DCN_ADDRESS) {
667 return lmp_subtree[LMP_TREE_CLASS_START + LMP_CLASS_DA_DCN_ADDRESS];
669 if (lmp_class == LMP_CLASS_LOCAL_LAD_INFO) {
670 return lmp_subtree[LMP_TREE_CLASS_START + LMP_CLASS_LOCAL_LAD_INFO];
673 return lmp_subtree[LMP_TREE_CLASS_START + lmp_class];
675 return -1;
678 static const true_false_string tfs_active_monitoring_not_allocated = { "Allocated - Active Monitoring", "Not Allocated" };
680 /*------------------------------------------------------------------------------
681 * Da code
684 static int
685 dissect_lmp(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _U_)
687 int offset = 0;
688 proto_tree *lmp_tree = NULL, *ti, *ti2;
689 proto_tree *lmp_header_tree;
690 proto_tree *lmp_object_tree;
691 proto_tree *lmp_object_header_tree;
692 proto_tree *lmp_subobj_tree;
693 proto_item *hidden_item, *msg_item;
695 uint8_t message_type;
696 vec_t cksum_vec[1];
697 int j, k, l, len;
698 int msg_length;
699 int obj_length;
700 int mylen;
701 int offset2;
703 col_set_str(pinfo->cinfo, COL_PROTOCOL, "LMP");
704 col_clear(pinfo->cinfo, COL_INFO);
706 message_type = tvb_get_uint8(tvb, offset+3);
707 col_add_str(pinfo->cinfo, COL_INFO,
708 val_to_str(message_type, message_type_vals, "Unknown (%u). "));
710 if (tree) {
711 static int * const header_flags[] = {
712 &hf_lmp_filter[LMPF_HDR_FLAGS_CC_DOWN],
713 &hf_lmp_filter[LMPF_HDR_FLAGS_REBOOT],
714 NULL
717 msg_length = tvb_get_ntohs(tvb, offset+4);
718 ti = proto_tree_add_item(tree, proto_lmp, tvb, offset, msg_length, ENC_NA);
719 lmp_tree = proto_item_add_subtree(ti, lmp_subtree[LMP_TREE_MAIN]);
720 lmp_header_tree = proto_tree_add_subtree_format(
721 lmp_tree, tvb, offset, 12,
722 lmp_subtree[LMP_TREE_HEADER], NULL, "LMP Header. %s",
723 val_to_str(message_type, message_type_vals, "Unknown Message (%u). "));
724 proto_tree_add_item(lmp_header_tree, hf_lmp_version, tvb, offset, 1, ENC_BIG_ENDIAN);
726 proto_tree_add_bitmask(lmp_header_tree, tvb, offset+2, hf_lmp_header_flags, lmp_subtree[LMP_TREE_HEADER_FLAGS], header_flags, ENC_NA);
727 msg_item = proto_tree_add_uint(lmp_header_tree, hf_lmp_filter[LMPF_MSG], tvb,
728 offset+3, 1, message_type);
729 proto_tree_add_uint_format_value(lmp_header_tree, hf_lmp_header_length, tvb, offset+4, 2, msg_length, "%d bytes",
730 msg_length);
731 /* if (LMPF_MSG + message_type < LMPF_MSG_MAX && message_type > 0) {*/
732 /* this "if" is still a hack, but compared to the former one at least correct */
733 if ((message_type >= LMP_MSG_CONFIG && message_type <= LMP_MSG_CHANNEL_STATUS_RESP) ||
734 (message_type >= LMP_MSG_SERVICE_CONFIG && message_type <= LMP_MSG_SERVICE_CONFIG_NACK) ||
735 (message_type >= LMP_MSG_DISCOVERY_RESP && message_type <= LMP_MSG_DISCOVERY_RESP_NACK) ) {
736 hidden_item = proto_tree_add_boolean(lmp_header_tree,
737 hf_lmp_filter[lmp_msg_to_filter_num(message_type)],
738 tvb, offset+3, 1, 1);
739 proto_item_set_hidden(hidden_item);
740 } else {
741 expert_add_info_format(pinfo, msg_item, &ei_lmp_invalid_msg_type,
742 "Invalid message type: %u", message_type);
743 return tvb_captured_length(tvb);
746 if (lmp_checksum_config) {
747 if (!pinfo->fragmented && (int) tvb_captured_length(tvb) >= msg_length) {
748 /* The packet isn't part of a fragmented datagram and isn't truncated, so we can checksum it. */
749 SET_CKSUM_VEC_TVB(cksum_vec[0], tvb, 0, msg_length);
750 proto_tree_add_checksum(lmp_header_tree, tvb, offset+6, hf_lmp_filter[LMPF_CHECKSUM], hf_lmp_filter[LMPF_CHECKSUM_STATUS], &ei_lmp_checksum_incorrect, pinfo,
751 in_cksum(cksum_vec, 1), ENC_BIG_ENDIAN, PROTO_CHECKSUM_VERIFY|PROTO_CHECKSUM_IN_CKSUM);
752 } else {
753 proto_tree_add_checksum(lmp_header_tree, tvb, offset+6, hf_lmp_filter[LMPF_CHECKSUM], hf_lmp_filter[LMPF_CHECKSUM_STATUS], &ei_lmp_checksum_incorrect, pinfo, 0, ENC_BIG_ENDIAN, PROTO_CHECKSUM_NO_FLAGS);
755 } else {
756 proto_tree_add_checksum(lmp_header_tree, tvb, offset+6, hf_lmp_filter[LMPF_CHECKSUM], hf_lmp_filter[LMPF_CHECKSUM_STATUS], &ei_lmp_checksum_incorrect, pinfo, 0, ENC_BIG_ENDIAN, PROTO_CHECKSUM_NOT_PRESENT);
759 offset += 8;
760 len = 8;
761 while (len < msg_length) {
762 uint8_t lmp_class;
763 uint8_t type;
764 uint8_t negotiable;
765 int filter_num;
766 proto_item* trace_item;
768 obj_length = tvb_get_ntohs(tvb, offset+2);
769 if (obj_length == 0) {
770 proto_tree_add_expert(tree, pinfo, &ei_lmp_obj_len, tvb, offset+2, 2);
771 break;
773 lmp_class = tvb_get_uint8(tvb, offset+1);
774 type = tvb_get_uint8(tvb, offset);
775 negotiable = (type >> 7); type &= 0x7f;
776 hidden_item = proto_tree_add_uint(lmp_tree, hf_lmp_filter[LMPF_OBJECT], tvb,
777 offset, 1, lmp_class);
778 proto_item_set_generated(hidden_item);
779 filter_num = lmp_class_to_filter_num(lmp_class);
780 if (filter_num != -1 && lmp_valid_class(lmp_class)) {
781 ti = proto_tree_add_item(lmp_tree,
782 hf_lmp_filter[filter_num],
783 tvb, offset, obj_length, ENC_NA); /* all possibilities are FT_NONE */
784 } else {
785 expert_add_info_format(pinfo, hidden_item, &ei_lmp_invalid_class,
786 "Invalid class: %u", lmp_class);
787 return tvb_captured_length(tvb);
789 lmp_object_tree = proto_item_add_subtree(ti, lmp_class_to_subtree(lmp_class));
791 lmp_object_header_tree = proto_tree_add_subtree_format(lmp_object_tree, tvb, offset, 4,
792 lmp_subtree[LMP_TREE_OBJECT_HEADER], &ti2,
793 "Header. Class %d, C-Type %d, Length %d, %s",
794 lmp_class, type, obj_length,
795 negotiable ? "Negotiable" : "Not Negotiable");
797 proto_tree_add_item(lmp_object_header_tree, hf_lmp_negotiable, tvb, offset, 1, ENC_NA);
798 proto_tree_add_item(lmp_object_header_tree, hf_lmp_object_length, tvb, offset+2, 2, ENC_BIG_ENDIAN);
799 proto_tree_add_item(lmp_object_header_tree, hf_lmp_object_class, tvb, offset+1, 1, ENC_BIG_ENDIAN);
800 proto_tree_add_uint(lmp_object_header_tree, hf_lmp_filter[LMPF_VAL_CTYPE],
801 tvb, offset, 1, type);
802 offset2 = offset+4;
803 mylen = obj_length - 4;
805 switch (lmp_class) {
807 case LMP_CLASS_NULL:
808 break;
810 case LMP_CLASS_CCID:
811 switch(type) {
813 case 1:
814 l = LMPF_VAL_LOCAL_CCID;
815 proto_item_append_text(ti, ": %d", tvb_get_ntohl(tvb, offset2));
816 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[l], tvb,
817 offset2, 4, ENC_BIG_ENDIAN);
818 break;
820 case 2:
821 l = LMPF_VAL_REMOTE_CCID;
822 proto_item_append_text(ti, ": %d", tvb_get_ntohl(tvb, offset2));
823 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[l], tvb,
824 offset2, 4, ENC_BIG_ENDIAN);
825 break;
826 default:
827 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
828 break;
830 break;
832 case LMP_CLASS_NODE_ID:
833 switch(type) {
835 case 1:
836 l = LMPF_VAL_LOCAL_NODE_ID;
837 proto_item_append_text(ti, ": %s", tvb_ip_to_str(pinfo->pool, tvb, offset2));
838 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[l], tvb,
839 offset2, 4, ENC_BIG_ENDIAN);
840 break;
842 case 2:
843 l = LMPF_VAL_REMOTE_NODE_ID;
844 proto_item_append_text(ti, ": %s", tvb_ip_to_str(pinfo->pool, tvb, offset2));
845 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[l], tvb,
846 offset2, 4, ENC_BIG_ENDIAN);
847 break;
849 default:
850 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
851 break;
853 break;
855 case LMP_CLASS_LINK_ID:
857 switch(type) {
859 case 1:
860 case 2:
861 l = (type == 1)? LMPF_VAL_LOCAL_LINK_ID_IPV4:
862 LMPF_VAL_REMOTE_LINK_ID_IPV4;
863 proto_item_append_text(ti, ": IPv4 %s", tvb_ip_to_str(pinfo->pool, tvb, offset2));
864 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[l], tvb,
865 offset2, 4, ENC_BIG_ENDIAN);
866 break;
868 case 3:
869 case 4:
870 l = (type == 3)? LMPF_VAL_LOCAL_LINK_ID_IPV6:
871 LMPF_VAL_REMOTE_LINK_ID_IPV6;
872 proto_item_append_text(ti, ": IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset2));
873 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[l], tvb,
874 offset2, 16, ENC_NA);
875 break;
876 case 5:
877 case 6:
878 l = (type == 5)? LMPF_VAL_LOCAL_LINK_ID_UNNUM:
879 LMPF_VAL_REMOTE_LINK_ID_UNNUM;
880 proto_item_append_text(ti, ": Unnumbered %d",
881 tvb_get_ntohl(tvb, offset2));
882 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[l], tvb,
883 offset2, 4, ENC_BIG_ENDIAN);
884 break;
886 default:
887 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
888 break;
890 break;
892 case LMP_CLASS_INTERFACE_ID:
894 switch(type) {
896 case 1:
897 case 2:
898 l = (type == 1)? LMPF_VAL_LOCAL_INTERFACE_ID_IPV4:
899 LMPF_VAL_REMOTE_INTERFACE_ID_IPV4;
900 proto_item_append_text(ti, ": IPv4 %s", tvb_ip_to_str(pinfo->pool, tvb, offset2));
901 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[l], tvb,
902 offset2, 4, ENC_BIG_ENDIAN);
903 break;
905 case 3:
906 case 4:
907 l = (type == 3)? LMPF_VAL_LOCAL_INTERFACE_ID_IPV6:
908 LMPF_VAL_REMOTE_INTERFACE_ID_IPV6;
909 proto_item_append_text(ti, ": IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset2));
910 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[l], tvb,
911 offset2, 16, ENC_NA);
912 break;
914 case 5:
915 case 6:
916 l = (type == 5)? LMPF_VAL_LOCAL_INTERFACE_ID_UNNUM:
917 LMPF_VAL_REMOTE_INTERFACE_ID_UNNUM;
918 proto_item_append_text(ti, ": Unnumbered %d",
919 tvb_get_ntohl(tvb, offset2));
920 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[l], tvb,
921 offset2, 4, ENC_BIG_ENDIAN);
922 break;
924 default:
925 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
926 break;
928 break;
930 case LMP_CLASS_MESSAGE_ID:
932 switch(type) {
934 case 1:
936 l = LMPF_VAL_MESSAGE_ID;
937 proto_item_append_text(ti, ": %d", tvb_get_ntohl(tvb, offset2));
938 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[l], tvb,
939 offset2, 4, ENC_BIG_ENDIAN);
940 break;
942 case 2:
943 l = LMPF_VAL_MESSAGE_ID_ACK;
944 proto_item_append_text(ti, ": %d", tvb_get_ntohl(tvb, offset2));
945 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[l], tvb,
946 offset2, 4, ENC_BIG_ENDIAN);
947 break;
949 default:
950 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
951 break;
953 break;
955 case LMP_CLASS_CONFIG:
957 switch(type) {
959 case 1:
960 proto_item_append_text(ti, ": HelloInterval: %d, HelloDeadInterval: %d",
961 tvb_get_ntohs(tvb, offset2),
962 tvb_get_ntohs(tvb, offset2+2));
963 proto_tree_add_item(lmp_object_tree,
964 hf_lmp_filter[LMPF_VAL_CONFIG_HELLO],
965 tvb, offset2, 2, ENC_BIG_ENDIAN);
966 proto_tree_add_item(lmp_object_tree,
967 hf_lmp_filter[LMPF_VAL_CONFIG_HELLO_DEAD],
968 tvb, offset2+2, 2, ENC_BIG_ENDIAN);
969 break;
971 default:
972 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
973 break;
975 break;
977 case LMP_CLASS_HELLO:
979 switch(type) {
981 case 1:
982 proto_item_append_text(ti, ": TxSeq %d, RxSeq: %d",
983 tvb_get_ntohl(tvb, offset2),
984 tvb_get_ntohl(tvb, offset2+4));
985 proto_tree_add_item(lmp_object_tree,
986 hf_lmp_filter[LMPF_VAL_HELLO_TXSEQ],
987 tvb, offset2, 4, ENC_BIG_ENDIAN);
988 proto_tree_add_item(lmp_object_tree,
989 hf_lmp_filter[LMPF_VAL_HELLO_RXSEQ],
990 tvb, offset2+4, 4, ENC_BIG_ENDIAN);
991 break;
993 default:
994 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
995 break;
997 break;
999 case LMP_CLASS_BEGIN_VERIFY:
1001 switch(type) {
1003 case 1:
1005 float transmission_rate;
1006 static int * const verify_flags[] = {
1007 &hf_lmp_filter[LMPF_VAL_BEGIN_VERIFY_FLAGS_ALL_LINKS],
1008 &hf_lmp_filter[LMPF_VAL_BEGIN_VERIFY_FLAGS_LINK_TYPE],
1009 NULL
1012 proto_tree_add_bitmask(lmp_object_tree, tvb, offset2, hf_lmp_filter[LMPF_VAL_BEGIN_VERIFY_FLAGS], lmp_subtree[LMP_TREE_BEGIN_VERIFY_FLAGS], verify_flags, ENC_BIG_ENDIAN);
1014 proto_tree_add_item(lmp_object_tree, hf_lmp_verify_interval, tvb, offset2+2, 2, ENC_BIG_ENDIAN);
1015 proto_tree_add_item(lmp_object_tree, hf_lmp_number_of_data_links, tvb, offset2+4, 4, ENC_BIG_ENDIAN);
1016 proto_tree_add_item(lmp_object_tree,
1017 hf_lmp_filter[LMPF_VAL_BEGIN_VERIFY_ENCTYPE],
1018 tvb, offset2+8, 1, ENC_BIG_ENDIAN);
1019 proto_tree_add_item(lmp_object_tree, hf_lmp_verify_transport_mechanism, tvb, offset2+10, 2, ENC_BIG_ENDIAN);
1020 transmission_rate = tvb_get_ntohieee_float(tvb, offset2+12)*8/1000000;
1021 proto_tree_add_float_format_value(lmp_object_tree, hf_lmp_transmission_rate, tvb, offset2+12, 4,
1022 transmission_rate, "%.3f Mbps", transmission_rate);
1023 proto_tree_add_item(lmp_object_tree, hf_lmp_wavelength, tvb, offset2+16, 4, ENC_BIG_ENDIAN);
1025 break;
1027 default:
1028 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
1029 break;
1031 break;
1033 case LMP_CLASS_BEGIN_VERIFY_ACK:
1035 switch(type) {
1037 case 1:
1038 proto_item_append_text(ti, ": VerifyDeadInterval: %d, TransportResponse: 0x%0x",
1039 tvb_get_ntohs(tvb, offset2),
1040 tvb_get_ntohs(tvb, offset2+2));
1041 proto_tree_add_item(lmp_object_tree, hf_lmp_verifydeadinterval, tvb, offset2, 2, ENC_BIG_ENDIAN);
1042 proto_tree_add_item(lmp_object_tree, hf_lmp_verify_transport_response, tvb, offset2+2, 2, ENC_BIG_ENDIAN);
1043 break;
1045 default:
1046 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
1047 break;
1049 break;
1051 case LMP_CLASS_VERIFY_ID:
1053 switch(type) {
1055 case 1:
1056 proto_item_append_text(ti, ": %d",
1057 tvb_get_ntohl(tvb, offset2));
1058 proto_tree_add_item(lmp_object_tree,
1059 hf_lmp_filter[LMPF_VAL_VERIFY_ID],
1060 tvb, offset2, 4,
1061 ENC_BIG_ENDIAN);
1062 break;
1063 default:
1064 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
1065 break;
1067 break;
1069 case LMP_CLASS_TE_LINK:
1071 static int * const link_flags[] = {
1072 &hf_lmp_filter[LMPF_VAL_TE_LINK_FLAGS_FAULT_MGMT],
1073 &hf_lmp_filter[LMPF_VAL_TE_LINK_FLAGS_LINK_VERIFY],
1074 NULL
1077 ti2 = proto_tree_add_bitmask(lmp_object_tree, tvb, offset2, hf_lmp_filter[LMPF_VAL_TE_LINK_FLAGS], lmp_subtree[LMP_TREE_TE_LINK_FLAGS], link_flags, ENC_NA);
1078 l = tvb_get_uint8(tvb, offset2);
1079 proto_item_append_text(ti2, ": %s%s",
1080 (l&0x01) ? "Fault-Mgmt-Supported " : "",
1081 (l&0x02) ? "Link-Verification-Supported " : "");
1083 switch(type) {
1085 case 1:
1086 proto_item_append_text(ti, ": IPv4: Local %s, Remote %s",
1087 tvb_ip_to_str(pinfo->pool, tvb, offset2+4),
1088 tvb_ip_to_str(pinfo->pool, tvb, offset2+8));
1089 proto_tree_add_item(lmp_object_tree,
1090 hf_lmp_filter[LMPF_VAL_TE_LINK_LOCAL_IPV4],
1091 tvb, offset2+4, 4, ENC_BIG_ENDIAN);
1092 proto_tree_add_item(lmp_object_tree,
1093 hf_lmp_filter[LMPF_VAL_TE_LINK_REMOTE_IPV4],
1094 tvb, offset2+8, 4, ENC_BIG_ENDIAN);
1095 break;
1097 case 2:
1098 proto_item_append_text(ti, ": IPv6: Local %s, Remote %s",
1099 tvb_ip6_to_str(pinfo->pool, tvb, offset2+4),
1100 tvb_ip6_to_str(pinfo->pool, tvb, offset2+20));
1101 proto_tree_add_item(lmp_object_tree,
1102 hf_lmp_filter[LMPF_VAL_TE_LINK_LOCAL_IPV6],
1103 tvb, offset2+4, 16, ENC_NA);
1104 proto_tree_add_item(lmp_object_tree,
1105 hf_lmp_filter[LMPF_VAL_TE_LINK_REMOTE_IPV6],
1106 tvb, offset2+20, 16, ENC_NA);
1107 break;
1109 case 3:
1110 proto_item_append_text(ti, ": Unnumbered: Local %d, Remote %d",
1111 tvb_get_ntohl(tvb, offset2+4),
1112 tvb_get_ntohl(tvb, offset2+8));
1114 proto_tree_add_item(lmp_object_tree,
1115 hf_lmp_filter[LMPF_VAL_TE_LINK_LOCAL_UNNUM],
1116 tvb, offset2+4, 4, ENC_BIG_ENDIAN);
1118 proto_tree_add_item(lmp_object_tree,
1119 hf_lmp_filter[LMPF_VAL_TE_LINK_REMOTE_UNNUM],
1120 tvb, offset2+8, 4, ENC_BIG_ENDIAN);
1121 break;
1122 default:
1123 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
1124 break;
1127 break;
1129 case LMP_CLASS_DATA_LINK:
1131 static int * const link_flags[] = {
1132 &hf_lmp_filter[LMPF_VAL_DATA_LINK_FLAGS_PORT],
1133 &hf_lmp_filter[LMPF_VAL_DATA_LINK_FLAGS_ALLOCATED],
1134 NULL
1137 ti2 = proto_tree_add_bitmask(lmp_object_tree, tvb, offset2, hf_lmp_filter[LMPF_VAL_DATA_LINK_FLAGS], lmp_subtree[LMP_TREE_DATA_LINK_FLAGS], link_flags, ENC_NA);
1138 l = tvb_get_uint8(tvb, offset2);
1139 proto_item_append_text(ti2, ": %s%s",
1140 (l&0x01) ? "Interface-Type-Port " : "Interface-Type-Component-Link ",
1141 (l&0x02) ? "Allocated " : "Unallocated ");
1142 switch(type) {
1144 case 1:
1145 proto_item_append_text(ti, ": IPv4: Local %s, Remote %s",
1146 tvb_ip_to_str(pinfo->pool, tvb, offset2+4),
1147 tvb_ip_to_str(pinfo->pool, tvb, offset2+8));
1149 proto_tree_add_item(lmp_object_tree,
1150 hf_lmp_filter[LMPF_VAL_DATA_LINK_LOCAL_IPV4],
1151 tvb, offset2+4, 4, ENC_BIG_ENDIAN);
1153 proto_tree_add_item(lmp_object_tree,
1154 hf_lmp_filter[LMPF_VAL_DATA_LINK_REMOTE_IPV4],
1155 tvb, offset2+8, 4, ENC_BIG_ENDIAN);
1156 l = 12;
1157 break;
1159 case 2:
1160 proto_item_append_text(ti, ": IPv6: Local %s, Remote %s",
1161 tvb_ip6_to_str(pinfo->pool, tvb, offset2+4),
1162 tvb_ip6_to_str(pinfo->pool, tvb, offset2+8));
1163 proto_tree_add_item(lmp_object_tree, hf_lmp_data_link_local_id_ipv6, tvb, offset2+4, 16, ENC_NA);
1164 proto_tree_add_item(lmp_object_tree, hf_lmp_data_link_remote_id_ipv6, tvb, offset2+20, 16, ENC_NA);
1165 l = 36;
1166 break;
1168 case 3:
1169 proto_item_append_text(ti, ": Unnumbered: Local %d, Remote %d",
1170 tvb_get_ntohl(tvb, offset2+4),
1171 tvb_get_ntohl(tvb, offset2+8));
1172 proto_tree_add_item(lmp_object_tree,
1173 hf_lmp_filter[LMPF_VAL_DATA_LINK_LOCAL_UNNUM],
1174 tvb, offset2+4, 4, ENC_BIG_ENDIAN);
1175 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[LMPF_VAL_DATA_LINK_REMOTE_UNNUM],
1176 tvb, offset2+8, 4, ENC_BIG_ENDIAN);
1177 l = 12;
1178 break;
1180 default:
1181 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
1182 break;
1185 while (l < obj_length - 4) {
1186 float bandwidth;
1188 mylen = tvb_get_uint8(tvb, offset2+l+1);
1189 ti2 = proto_tree_add_item(lmp_object_tree,
1190 hf_lmp_filter[LMPF_VAL_DATA_LINK_SUBOBJ],
1191 tvb, offset2+l, mylen, ENC_NA);
1192 lmp_subobj_tree = proto_item_add_subtree(ti2,
1193 lmp_subtree[LMP_TREE_DATA_LINK_SUBOBJ]);
1194 proto_tree_add_item(lmp_subobj_tree, hf_lmp_subobject_type, tvb, offset2+l, 1, ENC_BIG_ENDIAN);
1196 proto_tree_add_item(lmp_subobj_tree, hf_lmp_subobject_length, tvb, offset2+l+1, 1, ENC_BIG_ENDIAN);
1197 switch(tvb_get_uint8(tvb, offset2+l)) {
1199 case 1:
1201 proto_item_set_text(ti2, "Interface Switching Capability: "
1202 "Switching Cap: %s, Encoding Type: %s, "
1203 "Min BW: %.3f Mbps, Max BW: %.3f Mbps",
1204 rval_to_str(tvb_get_uint8(tvb, offset2+l+2),
1205 gmpls_switching_type_rvals, "Unknown (%d)"),
1206 rval_to_str(tvb_get_uint8(tvb, offset2+l+3),
1207 gmpls_lsp_enc_rvals, "Unknown (%d)"),
1208 tvb_get_ntohieee_float(tvb, offset2+l+4)*8/1000000,
1209 tvb_get_ntohieee_float(tvb, offset2+l+8)*8/1000000);
1210 proto_tree_add_item(lmp_subobj_tree,
1211 hf_lmp_filter[LMPF_VAL_DATA_LINK_SUBOBJ_SWITCHING_TYPE],
1212 tvb, offset2+l+2, 1, ENC_BIG_ENDIAN);
1213 proto_tree_add_item(lmp_subobj_tree,
1214 hf_lmp_filter[LMPF_VAL_DATA_LINK_SUBOBJ_LSP_ENCODING],
1215 tvb, offset2+l+3, 1, ENC_BIG_ENDIAN);
1216 bandwidth = tvb_get_ntohieee_float(tvb, offset2+l+4)*8/1000000;
1217 proto_tree_add_float_format_value(lmp_subobj_tree, hf_lmp_minimum_reservable_bandwidth, tvb, offset2+l+4, 4,
1218 bandwidth, "%.3f Mbps", bandwidth);
1219 bandwidth = tvb_get_ntohieee_float(tvb, offset2+l+8)*8/1000000;
1220 proto_tree_add_float_format_value(lmp_subobj_tree, hf_lmp_maximum_reservable_bandwidth, tvb, offset2+l+8, 4,
1221 bandwidth, "%.3f Mbps", bandwidth);
1222 break;
1224 case 2:
1225 proto_item_set_text(ti2, "Wavelength: %d",
1226 tvb_get_ntohl(tvb, offset2+l+2));
1227 proto_tree_add_item(lmp_subobj_tree, hf_lmp_wavelength, tvb, offset2+l+4, 4, ENC_BIG_ENDIAN);
1228 break;
1230 default:
1231 proto_tree_add_item(lmp_subobj_tree, hf_lmp_data, tvb, offset2+l,
1232 tvb_get_uint8(tvb, offset2+l+1), ENC_NA);
1233 break;
1235 if (tvb_get_uint8(tvb, offset2+l+1) == 0)
1236 break;
1238 l += tvb_get_uint8(tvb, offset2+l+1);
1241 break;
1243 case LMP_CLASS_CHANNEL_STATUS:
1245 k = 0; j = 0;
1247 switch(type) {
1249 case 1:
1250 case 3:
1251 k = 8; break;
1253 case 2:
1254 k = 20; break;
1257 if (!k)
1258 break;
1260 for (l=0; l<obj_length - 4; ) {
1262 lmp_subobj_tree = proto_tree_add_subtree(lmp_object_tree, tvb, offset2+l, k,
1263 lmp_subtree[LMP_TREE_CHANNEL_STATUS_ID], &ti2, "Interface-Id");
1264 switch(type) {
1266 case 1:
1267 if (j < 4)
1268 proto_item_append_text(ti, ": [IPv4-%s",
1269 tvb_ip_to_str(pinfo->pool, tvb, offset2+l));
1270 proto_item_append_text(ti2, ": IPv4 %s",
1271 tvb_ip_to_str(pinfo->pool, tvb, offset2+l));
1272 proto_tree_add_item(lmp_subobj_tree, hf_lmp_interface_id_ipv4, tvb, offset2+l, 4, ENC_BIG_ENDIAN);
1273 l += 4;
1274 break;
1276 case 2:
1277 if (j < 4)
1278 proto_item_append_text(ti, ": [IPv6-%s", tvb_ip6_to_str(pinfo->pool, tvb, offset2+l));
1279 proto_item_append_text(ti2, ": IPv6 %s", tvb_ip6_to_str(pinfo->pool, tvb, offset2+l));
1280 proto_tree_add_item(lmp_subobj_tree, hf_lmp_interface_id_ipv6, tvb, offset2, 16, ENC_NA);
1281 l += 16;
1282 break;
1284 case 3:
1285 if (j < 4)
1286 proto_item_append_text(ti, ": [Unnum-%d",
1287 tvb_get_ntohl(tvb, offset2+l));
1288 proto_item_append_text(ti, ": Unnumbered %d",
1289 tvb_get_ntohl(tvb, offset2+l));
1290 proto_tree_add_item(lmp_subobj_tree, hf_lmp_interface_id_unnumbered, tvb, offset2+l, 4, ENC_BIG_ENDIAN);
1291 l += 4;
1292 break;
1294 default:
1295 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2+l, obj_length-4-l, ENC_NA);
1296 break;
1298 if (l == obj_length - 4) break;
1300 proto_tree_add_item(lmp_subobj_tree, hf_lmp_link, tvb, offset2+l, 4, ENC_NA);
1301 if (j < 4)
1302 proto_item_append_text(ti, "-%s,%s], ",
1303 tvb_get_uint8(tvb, offset2+l) & 0x80 ? "Act" : "NA",
1304 val_to_str(tvb_get_ntohl(tvb, offset2+l) & 0x7fffffff,
1305 channel_status_short_str, "UNK (%u)."));
1306 proto_item_append_text(ti2, ": %s, ",
1307 tvb_get_uint8(tvb, offset2+l) & 0x80 ? "Active" : "Not Active");
1308 proto_tree_add_item(lmp_subobj_tree, hf_lmp_channel_status, tvb, offset2+l, 4, ENC_BIG_ENDIAN);
1309 proto_item_append_text(ti2, "%s", val_to_str(tvb_get_ntohl(tvb, offset2+l) & 0x7fffffff,
1310 channel_status_str, "Unknown (%u). "));
1311 j++;
1312 l += 4;
1313 if (j==4 && l < obj_length - 4)
1314 proto_item_append_text(ti, " ...");
1316 break;
1318 case LMP_CLASS_CHANNEL_STATUS_REQUEST:
1319 for (l=0; l<obj_length - 4; ) {
1320 switch(type) {
1321 case 1:
1322 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[LMPF_VAL_CHANNEL_STATUS_INTERFACE_ID_IPV4],
1323 tvb, offset2+l, 4, ENC_BIG_ENDIAN);
1324 l += 4;
1325 break;
1327 case 2:
1328 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[LMPF_VAL_CHANNEL_STATUS_INTERFACE_ID_IPV6],
1329 tvb, offset2+l, 16, ENC_NA);
1330 l += 16;
1331 break;
1333 case 3:
1334 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[LMPF_VAL_CHANNEL_STATUS_INTERFACE_ID_UNNUM],
1335 tvb, offset2+l, 4, ENC_BIG_ENDIAN);
1336 l += 4;
1337 break;
1339 default:
1340 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2+l, obj_length-4-l, ENC_NA);
1341 l = obj_length - 4;
1342 break;
1345 break;
1347 case LMP_CLASS_ERROR:
1348 l = tvb_get_ntohl(tvb, offset2);
1349 ti2 = proto_tree_add_uint(lmp_object_tree, hf_lmp_filter[LMPF_VAL_ERROR],
1350 tvb, offset2, 4, l);
1352 switch(type) {
1354 case 1:
1356 static int * const error_flags[] = {
1357 &hf_lmp_filter[LMPF_VAL_ERROR_VERIFY_UNSUPPORTED_LINK],
1358 &hf_lmp_filter[LMPF_VAL_ERROR_VERIFY_UNWILLING],
1359 &hf_lmp_filter[LMPF_VAL_ERROR_VERIFY_TRANSPORT],
1360 &hf_lmp_filter[LMPF_VAL_ERROR_VERIFY_TE_LINK_ID],
1361 NULL
1364 proto_tree_add_bitmask(lmp_object_tree, tvb, offset2, hf_lmp_filter[LMPF_VAL_ERROR], lmp_subtree[LMP_TREE_ERROR_FLAGS], error_flags, ENC_NA);
1366 proto_item_append_text(ti, ": BEGIN_VERIFY_ERROR: %s%s%s%s",
1367 (l&0x01) ? "Unsupported-Link " : "",
1368 (l&0x02) ? "Unwilling" : "",
1369 (l&0x04) ? "Unsupported-Transport" : "",
1370 (l&0x08) ? "TE-Link-ID" : "");
1372 break;
1374 case 2:
1376 static int * const error_flags[] = {
1377 &hf_lmp_filter[LMPF_VAL_ERROR_SUMMARY_BAD_PARAMETERS],
1378 &hf_lmp_filter[LMPF_VAL_ERROR_SUMMARY_RENEGOTIATE],
1379 &hf_lmp_filter[LMPF_VAL_ERROR_SUMMARY_BAD_TE_LINK],
1380 &hf_lmp_filter[LMPF_VAL_ERROR_SUMMARY_BAD_DATA_LINK],
1381 &hf_lmp_filter[LMPF_VAL_ERROR_SUMMARY_UNKNOWN_TEL_CTYPE],
1382 &hf_lmp_filter[LMPF_VAL_ERROR_SUMMARY_UNKNOWN_DL_CTYPE],
1383 NULL
1386 proto_tree_add_bitmask(lmp_object_tree, tvb, offset2, hf_lmp_filter[LMPF_VAL_ERROR], lmp_subtree[LMP_TREE_ERROR_FLAGS], error_flags, ENC_NA);
1388 proto_item_append_text(ti, ": LINK_SUMMARY_ERROR: %s%s%s%s%s%s",
1389 (l&0x01) ? "Unacceptable-Params " : "",
1390 (l&0x02) ? "Renegotiate" : "",
1391 (l&0x04) ? "Bad-TE-Link" : "",
1392 (l&0x08) ? "Bad-Data-Link" : "",
1393 (l&0x10) ? "Bad-TE-Link-CType" : "",
1394 (l&0x20) ? "Bad-Data-Link-CType" : "");
1396 break;
1398 case 3:
1400 static int * const error_flags[] = {
1401 &hf_lmp_filter[LMPF_VAL_ERROR_TRACE_UNSUPPORTED_TYPE],
1402 &hf_lmp_filter[LMPF_VAL_ERROR_TRACE_INVALID_MSG],
1403 &hf_lmp_filter[LMPF_VAL_ERROR_TRACE_UNKNOWN_CTYPE],
1404 NULL
1407 proto_tree_add_bitmask(lmp_object_tree, tvb, offset2, hf_lmp_filter[LMPF_VAL_ERROR], lmp_subtree[LMP_TREE_ERROR_FLAGS], error_flags, ENC_NA);
1409 proto_item_append_text(ti, ": TRACE_ERROR: %s%s%s",
1410 (l&0x01) ? "Unsupported Trace Type " : "",
1411 (l&0x02) ? "Invalid Trace Message" : "",
1412 (l&0x10) ? "Unknown Object C-Type" : "");
1414 break;
1416 case 4:
1418 static int * const error_flags[] = {
1419 &hf_lmp_filter[LMPF_VAL_ERROR_LAD_AREA_ID_MISMATCH],
1420 &hf_lmp_filter[LMPF_VAL_ERROR_LAD_TCP_ID_MISMATCH],
1421 &hf_lmp_filter[LMPF_VAL_ERROR_LAD_DA_DCN_MISMATCH],
1422 &hf_lmp_filter[LMPF_VAL_ERROR_LAD_CAPABILITY_MISMATCH],
1423 &hf_lmp_filter[LMPF_VAL_ERROR_LAD_UNKNOWN_CTYPE],
1424 NULL
1427 proto_tree_add_bitmask(lmp_object_tree, tvb, offset2, hf_lmp_filter[LMPF_VAL_ERROR], lmp_subtree[LMP_TREE_ERROR_FLAGS], error_flags, ENC_NA);
1429 proto_item_append_text(ti, ": LAD_ERROR: %s%s%s%s%s",
1430 (l&0x01) ? "Domain Routing Area ID mismatch" : "",
1431 (l&0x02) ? "TCP ID mismatch" : "",
1432 (l&0x04) ? "DA DCN mismatch" : "",
1433 (l&0x08) ? "Capability mismatch" : "",
1434 (l&0x10) ? "Unknown Object C-Type" : "");
1436 break;
1438 default:
1439 proto_item_append_text(ti, ": UNKNOWN_ERROR (%d): 0x%04x", type, l);
1440 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
1441 break;
1443 break;
1445 case LMP_CLASS_TRACE:
1446 switch (type) {
1447 case 1:
1448 l = tvb_get_ntohs(tvb, offset2);
1449 proto_tree_add_uint(lmp_object_tree,
1450 hf_lmp_filter[LMPF_VAL_TRACE_LOCAL_TYPE],
1451 tvb, offset2, 2, l);
1452 proto_item_append_text(lmp_object_tree, ": %s",
1453 val_to_str(l, lmp_trace_type_str, "Unknown (%d)"));
1455 l = tvb_get_ntohs(tvb, offset2+2);
1456 trace_item = proto_tree_add_uint(lmp_object_tree,
1457 hf_lmp_filter[LMPF_VAL_TRACE_LOCAL_LEN],
1458 tvb, offset2+2, 2, l);
1459 if (l && l <= obj_length - 8) {
1460 proto_item_append_text(lmp_object_tree, " = %s",
1461 tvb_format_text(pinfo->pool, tvb, offset2+4, l));
1462 proto_tree_add_string(lmp_object_tree,
1463 hf_lmp_filter[LMPF_VAL_TRACE_LOCAL_MSG],
1464 tvb, offset2+4, l, tvb_format_text(pinfo->pool, tvb,
1465 offset2+4,l));
1467 else
1468 expert_add_info(pinfo, trace_item, &ei_lmp_trace_len);
1469 break;
1471 case 2:
1472 l = tvb_get_ntohs(tvb, offset2);
1473 proto_tree_add_uint(lmp_object_tree,
1474 hf_lmp_filter[LMPF_VAL_TRACE_REMOTE_TYPE],
1475 tvb, offset2, 2, l);
1476 proto_item_append_text(lmp_object_tree, ": %s",
1477 val_to_str(l, lmp_trace_type_str, "Unknown (%d)"));
1479 l = tvb_get_ntohs(tvb, offset2+2);
1480 proto_tree_add_uint(lmp_object_tree,
1481 hf_lmp_filter[LMPF_VAL_TRACE_REMOTE_LEN],
1482 tvb, offset2+2, 2, l);
1483 proto_item_append_text(lmp_object_tree, " = %s",
1484 tvb_format_text(pinfo->pool, tvb, offset2+4, l));
1485 proto_tree_add_string(lmp_object_tree,
1486 hf_lmp_filter[LMPF_VAL_TRACE_REMOTE_MSG],
1487 tvb, offset2+4, l, tvb_format_text(pinfo->pool, tvb, offset2+4,l));
1488 break;
1490 default:
1491 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
1492 break;
1495 break;
1497 case LMP_CLASS_TRACE_REQ:
1498 switch (type) {
1499 case 1:
1500 l = tvb_get_ntohs(tvb, offset2);
1501 proto_tree_add_uint(lmp_object_tree,
1502 hf_lmp_filter[LMPF_VAL_TRACE_REQ_TYPE],
1503 tvb, offset2, 2, l);
1504 proto_item_append_text(lmp_object_tree, ": %s",
1505 val_to_str(l, lmp_trace_type_str, "Unknown (%d)"));
1506 break;
1508 default:
1509 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
1510 break;
1513 break;
1515 case LMP_CLASS_SERVICE_CONFIG:
1517 /* Support for the ServiceConfig object defined in the UNI 1.0 spec */
1518 switch (type) {
1520 case 1:
1523 static int * const sp_flags[] = {
1524 &hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_SP_FLAGS_RSVP],
1525 &hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_SP_FLAGS_LDP],
1526 NULL
1529 /* Supported Signaling Protocols Object */
1531 /* Signaling Protocols */
1532 proto_tree_add_bitmask(lmp_object_tree, tvb, offset2, hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_SP_FLAGS], lmp_subtree[LMP_TREE_SERVICE_CONFIG_SP_FLAGS], sp_flags, ENC_NA);
1533 l = tvb_get_uint8(tvb, offset2);
1535 proto_item_append_text(ti2, ": %s %s",
1536 (l & 0x01) ? "RSVP-based UNI signaling supported " : "",
1537 (l & 0x02) ? "LDP-based UNI signaling supported " : "");
1539 /* UNI version */
1540 proto_tree_add_item(lmp_object_tree, hf_lmp_uni_version, tvb, offset2+1, 1, ENC_BIG_ENDIAN);
1542 break;
1544 case 2:
1546 static int * const tp_flags[] = {
1547 &hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_TP_FLAGS_PATH_OVERHEAD],
1548 &hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_TP_FLAGS_LINE_OVERHEAD],
1549 &hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_TP_FLAGS_SECTION_OVERHEAD],
1550 NULL
1553 static int * const cct_flags[] = {
1554 &hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_CCT_FLAGS_CC_SUPPORTED],
1555 NULL
1558 /* Client Port-Level Service Attributes Object */
1560 /* Link Type */
1561 proto_tree_add_item(lmp_object_tree, hf_lmp_link_type, tvb, offset2, 1, ENC_BIG_ENDIAN);
1563 proto_item_append_text(lmp_object_tree, "%s",
1564 val_to_str(tvb_get_uint8(tvb, offset2),
1565 service_attribute_link_type_str,
1566 "Unknown (%u). "));
1568 l = tvb_get_uint8(tvb, offset2+1);
1569 /* Signal type for SDH */
1570 if (l == LMP_CLASS_SERVICE_CONFIG_CPSA_SIGNAL_TYPES_SDH) {
1571 /* Signal types for an SDH link */
1572 proto_tree_add_item(lmp_object_tree, hf_lmp_signal_types_sdh, tvb, offset2+1, 1, ENC_BIG_ENDIAN);
1574 proto_item_append_text(lmp_object_tree, "%s",
1575 val_to_str(tvb_get_uint8(tvb, offset2+1),
1576 service_attribute_signal_types_sdh_str,
1577 "Unknown (%u). "));
1580 if (l == LMP_CLASS_SERVICE_CONFIG_CPSA_SIGNAL_TYPES_SONET) {
1581 /* Signal types for a SONET link */
1582 proto_tree_add_item(lmp_object_tree, hf_lmp_signal_types_sonet, tvb, offset2+1, 1, ENC_BIG_ENDIAN);
1584 proto_item_append_text(lmp_object_tree, "%s",
1585 val_to_str(tvb_get_uint8(tvb, offset2+1),
1586 service_attribute_signal_types_sonet_str,
1587 "Unknown (%u). "));
1590 /* TP Transparency */
1591 proto_tree_add_bitmask(lmp_object_tree, tvb, offset2+2, hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_TP_FLAGS], lmp_subtree[LMP_TREE_SERVICE_CONFIG_CPSA_TP_FLAGS], tp_flags, ENC_NA);
1593 l = tvb_get_uint8(tvb, offset2+2);
1594 proto_item_append_text(ti2, ": %s%s%s",
1595 (l & 0x01) ? "Path/VC Overhead Transparency " : "",
1596 (l & 0x02) ? "Line/MS Overhead Transparency " : "",
1597 (l & 0x04) ? "Section/RS Overhead Transparency " : "");
1599 /* Contiguous Concatenation Types */
1600 proto_tree_add_bitmask(lmp_object_tree, tvb, offset2+3, hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_CCT_FLAGS], lmp_subtree[LMP_TREE_SERVICE_CONFIG_CPSA_CCT_FLAGS], cct_flags, ENC_NA);
1602 /* Min and Max NCC */
1603 proto_item_append_text(ti, ": Minimum NCC: %d, Maximum NCC: %d",
1604 tvb_get_ntohs(tvb, offset2+4),
1605 tvb_get_ntohs(tvb, offset2+6));
1607 proto_tree_add_item(lmp_object_tree,
1608 hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_MIN_NCC],
1609 tvb, offset2+4, 2, ENC_BIG_ENDIAN);
1611 proto_tree_add_item(lmp_object_tree,
1612 hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_MAX_NCC],
1613 tvb, offset2+6, 2, ENC_BIG_ENDIAN);
1615 /* Min and Max NVC */
1616 proto_item_append_text(ti, ": Minimum NVC: %d, Maximum NVC: %d",
1617 tvb_get_ntohs(tvb, offset2+8),
1618 tvb_get_ntohs(tvb, offset2+10));
1620 proto_tree_add_item(lmp_object_tree,
1621 hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_MIN_NVC],
1622 tvb, offset2+8, 2, ENC_BIG_ENDIAN);
1624 proto_tree_add_item(lmp_object_tree,
1625 hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_MAX_NVC],
1626 tvb, offset2+10, 2, ENC_BIG_ENDIAN);
1628 /* Local interface ID */
1629 proto_item_append_text(ti, ": Local Interface ID %s",
1630 tvb_ip_to_str(pinfo->pool, tvb, offset2+12));
1632 proto_tree_add_item(lmp_object_tree,
1633 hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_INTERFACE_ID],
1634 tvb, offset2+12, 4, ENC_BIG_ENDIAN);
1636 break;
1638 case 3:
1640 static int * const t_flags[] = {
1641 &hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_TRANSPARENCY_FLAGS_SOH],
1642 &hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_TRANSPARENCY_FLAGS_LOH],
1643 NULL
1646 static int * const tcm_flags[] = {
1647 &hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_TCM_FLAGS_TCM_SUPPORTED],
1648 NULL
1651 /* Network Transparency Support and TCM Monitoring Object */
1653 /* Transparency */
1654 proto_tree_add_bitmask(lmp_object_tree, tvb, offset2, hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_TRANSPARENCY_FLAGS], lmp_subtree[LMP_TREE_SERVICE_CONFIG_NSA_TRANSPARENCY_FLAGS], t_flags, ENC_BIG_ENDIAN);
1655 l = tvb_get_ntohl(tvb, offset2);
1656 proto_item_append_text(ti2, ": %s %s",
1657 (l & 0x01) ? "Standard SOH/RSOH transparency supported " : "",
1658 (l & 0x02) ? "Standard LOH/MSOH transparency supported " : "");
1660 /* TCM Monitoring */
1661 proto_tree_add_bitmask(lmp_object_tree, tvb, offset2+7, hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_TCM_FLAGS], lmp_subtree[LMP_TREE_SERVICE_CONFIG_NSA_TCM_FLAGS], tcm_flags, ENC_BIG_ENDIAN);
1662 l = tvb_get_uint8(tvb, offset2+7);
1663 proto_item_append_text(ti2, ": %s",
1664 (l & 0x01) ? "Transparent Support of TCM available " : "");
1666 break;
1668 case 4:
1670 static int * const diversity_flags[] = {
1671 &hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_NETWORK_DIVERSITY_FLAGS_NODE],
1672 &hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_NETWORK_DIVERSITY_FLAGS_LINK],
1673 &hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_NETWORK_DIVERSITY_FLAGS_SRLG],
1674 NULL
1677 /* Network Diversity Object */
1678 proto_tree_add_bitmask(lmp_object_tree, tvb, offset2+3, hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_NETWORK_DIVERSITY_FLAGS], lmp_subtree[LMP_TREE_SERVICE_CONFIG_NSA_NETWORK_DIVERSITY_FLAGS], diversity_flags, ENC_BIG_ENDIAN);
1679 l = tvb_get_uint8(tvb,offset2+3);
1680 proto_item_append_text(ti2, ": %s%s%s",
1681 (l & 0x01) ? "Node Diversity is supported " : "",
1682 (l & 0x02) ? "Link Diversity is supported " : "",
1683 (l & 0x04) ? "SRLG Diversity is supported " : "");
1686 break;
1688 default:
1689 /* Unknown type in Service Config object */
1690 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
1691 break;
1693 break;
1695 case LMP_CLASS_DA_DCN_ADDRESS:
1696 switch(type) {
1698 case 1:
1699 proto_item_append_text(ti, ": %s", tvb_ip_to_str(pinfo->pool, tvb, offset2));
1700 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[LMPF_VAL_LOCAL_DA_DCN_ADDR], tvb,
1701 offset2, 4, ENC_BIG_ENDIAN);
1702 break;
1704 case 2:
1705 proto_item_append_text(ti, ": %s", tvb_ip_to_str(pinfo->pool, tvb, offset2));
1706 proto_tree_add_item(lmp_object_tree, hf_lmp_filter[LMPF_VAL_REMOTE_DA_DCN_ADDR], tvb,
1707 offset2, 4, ENC_BIG_ENDIAN);
1708 break;
1710 default:
1711 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
1712 break;
1714 break;
1717 case LMP_CLASS_LOCAL_LAD_INFO:
1718 switch(type) {
1719 case 1:
1720 proto_item_append_text(ti, ": IPv4");
1721 proto_tree_add_item(lmp_object_tree,
1722 hf_lmp_filter[LMPF_VAL_LOCAL_LAD_INFO_NODE_ID],
1723 tvb, offset2, 4, ENC_BIG_ENDIAN);
1724 proto_tree_add_item(lmp_object_tree,
1725 hf_lmp_filter[LMPF_VAL_LOCAL_LAD_INFO_AREA_ID],
1726 tvb, offset2+4, 4, ENC_BIG_ENDIAN);
1727 proto_tree_add_item(lmp_object_tree,
1728 hf_lmp_filter[LMPF_VAL_LOCAL_LAD_INFO_TE_LINK_ID],
1729 tvb, offset2+8, 4, ENC_BIG_ENDIAN);
1730 proto_tree_add_item(lmp_object_tree,
1731 hf_lmp_filter[LMPF_VAL_LOCAL_LAD_INFO_COMPONENT_ID],
1732 tvb, offset2+12, 4, ENC_BIG_ENDIAN);
1733 proto_tree_add_item(lmp_object_tree,
1734 hf_lmp_filter[LMPF_VAL_LOCAL_LAD_INFO_SC_PC_ID],
1735 tvb, offset2+16, 4, ENC_BIG_ENDIAN);
1736 proto_tree_add_item(lmp_object_tree,
1737 hf_lmp_filter[LMPF_VAL_LOCAL_LAD_INFO_SC_PC_ADDR],
1738 tvb, offset2+20, 4, ENC_BIG_ENDIAN);
1739 l = 24;
1740 while (l < obj_length - 4) {
1741 mylen = tvb_get_uint8(tvb, offset2+l+1);
1742 ti2 = proto_tree_add_item(lmp_object_tree,
1743 hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ],
1744 tvb, offset2+l, mylen, ENC_NA);
1745 lmp_subobj_tree = proto_item_add_subtree(ti2,
1746 lmp_subtree[LMP_TREE_LAD_INFO_SUBOBJ]);
1747 proto_tree_add_item(lmp_subobj_tree, hf_lmp_subobject_type, tvb, offset2+l, 1, ENC_BIG_ENDIAN);
1749 if (mylen == 0 || l + mylen > obj_length - 4) {
1750 proto_tree_add_uint_format_value(lmp_object_tree, hf_lmp_subobject_length, tvb, offset2+l+1, 1,
1751 mylen, "%d (Invalid)", mylen);
1752 break;
1754 else
1755 proto_tree_add_item(lmp_subobj_tree, hf_lmp_subobject_length, tvb, offset2+l+1, 1, ENC_BIG_ENDIAN);
1757 switch(tvb_get_uint8(tvb, offset2+l)) {
1759 case 250:
1760 proto_item_set_text(ti2, "Primary Routing Controller: "
1761 "Area ID: %s, RC PC ID: %s, "
1762 "RC PC Addr: %s",
1763 tvb_ip_to_str(pinfo->pool, tvb, offset2+l+4),
1764 tvb_ip_to_str(pinfo->pool, tvb, offset2+l+8),
1765 tvb_ip_to_str(pinfo->pool, tvb, offset2+l+12));
1766 proto_tree_add_item(lmp_subobj_tree,
1767 hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_PRI_AREA_ID],
1768 tvb, offset2+l+4, 4, ENC_BIG_ENDIAN);
1769 proto_tree_add_item(lmp_subobj_tree,
1770 hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_PRI_RC_PC_ID],
1771 tvb, offset2+l+8, 4, ENC_BIG_ENDIAN);
1772 proto_tree_add_item(lmp_subobj_tree,
1773 hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_PRI_RC_PC_ADDR],
1774 tvb, offset2+l+12, 4, ENC_BIG_ENDIAN);
1775 break;
1777 case 251:
1778 proto_item_set_text(ti2, "Secondary Routing Controller: "
1779 "Area ID: %s, RC PC ID: %s, "
1780 "RC PC Addr: %s",
1781 tvb_ip_to_str(pinfo->pool, tvb, offset2+l+4),
1782 tvb_ip_to_str(pinfo->pool, tvb, offset2+l+8),
1783 tvb_ip_to_str(pinfo->pool, tvb, offset2+l+12));
1784 proto_tree_add_item(lmp_subobj_tree,
1785 hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_SEC_AREA_ID],
1786 tvb, offset2+l+4, 4, ENC_BIG_ENDIAN);
1787 proto_tree_add_item(lmp_subobj_tree,
1788 hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_SEC_RC_PC_ID],
1789 tvb, offset2+l+8, 4, ENC_BIG_ENDIAN);
1790 proto_tree_add_item(lmp_subobj_tree,
1791 hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_SEC_RC_PC_ADDR],
1792 tvb, offset2+l+12, 4, ENC_BIG_ENDIAN);
1793 break;
1795 case 252:
1796 proto_item_set_text(ti2, "SONET/SDH Layer Capability: "
1797 "Switching Cap: %s, Encoding Type: %s",
1798 rval_to_str(tvb_get_uint8(tvb, offset2+l+4),
1799 gmpls_switching_type_rvals, "Unknown (%d)"),
1800 rval_to_str(tvb_get_uint8(tvb, offset2+l+5),
1801 gmpls_lsp_enc_rvals, "Unknown (%d)"));
1802 proto_tree_add_item(lmp_subobj_tree,
1803 hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_SWITCHING_TYPE],
1804 tvb, offset2+l+4, 1, ENC_BIG_ENDIAN);
1805 proto_tree_add_item(lmp_subobj_tree,
1806 hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_LSP_ENCODING],
1807 tvb, offset2+l+5, 1, ENC_BIG_ENDIAN);
1809 for (j = 0; j < (mylen - 8) / 4; j++) {
1810 proto_tree_add_uint_format(lmp_subobj_tree, hf_lmp_free_timeslots, tvb, offset2+l+8+(j*4), 4,
1811 tvb_get_ntoh24(tvb, offset2+l+9+(j*4)), "%s: %d free timeslots",
1812 val_to_str_ext(tvb_get_uint8(tvb, offset2+l+8+(j*4)),
1813 &gmpls_sonet_signal_type_str_ext,
1814 "Unknown Signal Type (%d)"),
1815 tvb_get_ntoh24(tvb, offset2+l+9+(j*4)));
1817 break;
1819 default:
1820 proto_tree_add_item(lmp_subobj_tree, hf_lmp_data, tvb, offset2+l,
1821 tvb_get_uint8(tvb, offset2+l+1), ENC_NA);
1822 break;
1824 if (tvb_get_uint8(tvb, offset2+l+1) == 0)
1825 break;
1827 l += tvb_get_uint8(tvb, offset2+l+1);
1830 break;
1832 default:
1833 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
1834 break;
1836 break;
1840 default:
1841 proto_tree_add_item(lmp_object_tree, hf_lmp_data, tvb, offset2, mylen, ENC_NA);
1842 break;
1845 offset += obj_length;
1846 len += obj_length;
1848 } /* while */
1849 } /* tree */
1851 return tvb_captured_length(tvb);
1854 static void
1855 register_lmp_prefs (void)
1857 module_t *lmp_module;
1859 lmp_module = prefs_register_protocol(proto_lmp, NULL);
1861 prefs_register_bool_preference(
1862 lmp_module, "checksum", "LMP checksum field",
1863 "Whether LMP contains a checksum which can be checked", &lmp_checksum_config);
1864 prefs_register_obsolete_preference(lmp_module, "version");
1867 void
1868 proto_register_lmp(void)
1870 static int *ett[NUM_LMP_SUBTREES];
1871 int i;
1873 static hf_register_info lmpf_info[] = {
1875 /* Message type number */
1876 {&hf_lmp_filter[LMPF_MSG],
1877 { "Message Type", "lmp.msg", FT_UINT8, BASE_DEC, VALS(message_type_vals), 0x0,
1878 NULL, HFILL }},
1880 /* Message type shorthands */
1881 {&hf_lmp_filter[LMPF_MSG_CONFIG],
1882 { "Config Message", "lmp.msg.config", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1883 NULL, HFILL }},
1885 {&hf_lmp_filter[LMPF_MSG_CONFIG_ACK],
1886 { "ConfigAck Message", "lmp.msg.configack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1887 NULL, HFILL }},
1889 {&hf_lmp_filter[LMPF_MSG_CONFIG_NACK],
1890 { "ConfigNack Message", "lmp.msg.confignack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1891 NULL, HFILL }},
1893 {&hf_lmp_filter[LMPF_MSG_HELLO],
1894 { "HELLO Message", "lmp.msg.hello", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1895 NULL, HFILL }},
1897 {&hf_lmp_filter[LMPF_MSG_BEGIN_VERIFY],
1898 { "BeginVerify Message", "lmp.msg.beginverify", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1899 NULL, HFILL }},
1901 {&hf_lmp_filter[LMPF_MSG_BEGIN_VERIFY_ACK],
1902 { "BeginVerifyAck Message", "lmp.msg.beginverifyack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1903 NULL, HFILL }},
1905 {&hf_lmp_filter[LMPF_MSG_BEGIN_VERIFY_NACK],
1906 { "BeginVerifyNack Message", "lmp.msg.beginverifynack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1907 NULL, HFILL }},
1909 {&hf_lmp_filter[LMPF_MSG_END_VERIFY],
1910 { "EndVerify Message", "lmp.msg.endverify", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1911 NULL, HFILL }},
1913 {&hf_lmp_filter[LMPF_MSG_END_VERIFY_ACK],
1914 { "EndVerifyAck Message", "lmp.msg.endverifyack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1915 NULL, HFILL }},
1917 {&hf_lmp_filter[LMPF_MSG_TEST],
1918 { "Test Message", "lmp.msg.test", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1919 NULL, HFILL }},
1921 {&hf_lmp_filter[LMPF_MSG_TEST_STATUS_SUCCESS],
1922 { "TestStatusSuccess Message", "lmp.msg.teststatussuccess", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1923 NULL, HFILL }},
1925 {&hf_lmp_filter[LMPF_MSG_TEST_STATUS_FAILURE],
1926 { "TestStatusFailure Message", "lmp.msg.teststatusfailure", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1927 NULL, HFILL }},
1929 {&hf_lmp_filter[LMPF_MSG_TEST_STATUS_ACK],
1930 { "TestStatusAck Message", "lmp.msg.teststatusack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1931 NULL, HFILL }},
1933 {&hf_lmp_filter[LMPF_MSG_LINK_SUMMARY],
1934 { "LinkSummary Message", "lmp.msg.linksummary", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1935 NULL, HFILL }},
1937 {&hf_lmp_filter[LMPF_MSG_LINK_SUMMARY_ACK],
1938 { "LinkSummaryAck Message", "lmp.msg.linksummaryack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1939 NULL, HFILL }},
1941 {&hf_lmp_filter[LMPF_MSG_LINK_SUMMARY_NACK],
1942 { "LinkSummaryNack Message", "lmp.msg.linksummarynack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1943 NULL, HFILL }},
1945 {&hf_lmp_filter[LMPF_MSG_CHANNEL_STATUS],
1946 { "ChannelStatus Message", "lmp.msg.channelstatus", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1947 NULL, HFILL }},
1949 {&hf_lmp_filter[LMPF_MSG_CHANNEL_STATUS_ACK],
1950 { "ChannelStatusAck Message", "lmp.msg.channelstatusack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1951 NULL, HFILL }},
1953 {&hf_lmp_filter[LMPF_MSG_CHANNEL_STATUS_REQ],
1954 { "ChannelStatusRequest Message", "lmp.msg.channelstatusrequest", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1955 NULL, HFILL }},
1957 {&hf_lmp_filter[LMPF_MSG_CHANNEL_STATUS_RESP],
1958 { "ChannelStatusResponse Message", "lmp.msg.channelstatusresponse", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1959 NULL, HFILL }},
1961 {&hf_lmp_filter[LMPF_MSG_TRACE_MONITOR],
1962 { "TraceMonitor Message", "lmp.msg.tracemonitor", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1963 NULL, HFILL }},
1965 {&hf_lmp_filter[LMPF_MSG_TRACE_MONITOR_ACK],
1966 { "TraceMonitorAck Message", "lmp.msg.tracemonitorack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1967 NULL, HFILL }},
1969 {&hf_lmp_filter[LMPF_MSG_TRACE_MONITOR_NACK],
1970 { "TraceMonitorNack Message", "lmp.msg.tracemonitornack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1971 NULL, HFILL }},
1973 {&hf_lmp_filter[LMPF_MSG_TRACE_MISMATCH],
1974 { "TraceMismatch Message", "lmp.msg.tracemismatch", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1975 NULL, HFILL }},
1977 {&hf_lmp_filter[LMPF_MSG_TRACE_MISMATCH_ACK],
1978 { "TraceMismatchAck Message", "lmp.msg.tracemismatchack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1979 NULL, HFILL }},
1981 {&hf_lmp_filter[LMPF_MSG_TRACE_REQUEST],
1982 { "TraceRequest Message", "lmp.msg.tracerequest", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1983 NULL, HFILL }},
1985 {&hf_lmp_filter[LMPF_MSG_TRACE_REPORT],
1986 { "TraceReport Message", "lmp.msg.tracereport", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1987 NULL, HFILL }},
1989 {&hf_lmp_filter[LMPF_MSG_TRACE_REQUEST_NACK],
1990 { "TraceRequestNack Message", "lmp.msg.tracerequestnack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1991 NULL, HFILL }},
1993 {&hf_lmp_filter[LMPF_MSG_INSERT_TRACE],
1994 { "InsertTrace Message", "lmp.msg.inserttrace", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1995 NULL, HFILL }},
1997 {&hf_lmp_filter[LMPF_MSG_INSERT_TRACE_ACK],
1998 { "InsertTraceAck Message", "lmp.msg.inserttraceack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
1999 NULL, HFILL }},
2001 {&hf_lmp_filter[LMPF_MSG_INSERT_TRACE_NACK],
2002 { "InsertTraceNack Message", "lmp.msg.inserttracenack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
2003 NULL, HFILL }},
2005 {&hf_lmp_filter[LMPF_MSG_SERVICE_CONFIG],
2006 { "ServiceConfig Message", "lmp.msg.serviceconfig", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
2007 NULL, HFILL }},
2009 {&hf_lmp_filter[LMPF_MSG_SERVICE_CONFIG_ACK],
2010 { "ServiceConfigAck Message", "lmp.msg.serviceconfigack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
2011 NULL, HFILL }},
2013 {&hf_lmp_filter[LMPF_MSG_SERVICE_CONFIG_NACK],
2014 { "ServiceConfigNack Message", "lmp.msg.serviceconfignack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
2015 NULL, HFILL }},
2017 {&hf_lmp_filter[LMPF_MSG_DISCOVERY_RESP],
2018 { "DiscoveryResponse Message", "lmp.msg.discoveryresp", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
2019 NULL, HFILL }},
2021 {&hf_lmp_filter[LMPF_MSG_DISCOVERY_RESP_ACK],
2022 { "DiscoveryResponseAck Message", "lmp.msg.discoveryrespack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
2023 NULL, HFILL }},
2025 {&hf_lmp_filter[LMPF_MSG_DISCOVERY_RESP_NACK],
2026 { "DiscoveryResponseNack Message", "lmp.msg.discoveryrespnack", FT_BOOLEAN, BASE_NONE, NULL, 0x0,
2027 NULL, HFILL }},
2029 /* LMP Message Header Fields ------------------- */
2031 {&hf_lmp_filter[LMPF_HDR_FLAGS],
2032 { "LMP Header - Flags", "lmp.hdr.flags", FT_UINT8, BASE_DEC, NULL, 0x0,
2033 NULL, HFILL }},
2035 {&hf_lmp_filter[LMPF_HDR_FLAGS_CC_DOWN],
2036 { "ControlChannelDown", "lmp.hdr.ccdown", FT_BOOLEAN, 8, NULL, 0x01,
2037 NULL, HFILL }},
2039 {&hf_lmp_filter[LMPF_HDR_FLAGS_REBOOT],
2040 { "Reboot", "lmp.hdr.reboot", FT_BOOLEAN, 8, NULL, 0x02,
2041 NULL, HFILL }},
2043 /* LMP object class filters ------------------------------- */
2045 {&hf_lmp_filter[LMPF_OBJECT],
2046 { "LOCAL_CCID", "lmp.object", FT_UINT8, BASE_DEC, NULL, 0x0,
2047 NULL, HFILL }},
2049 {&hf_lmp_filter[LMPF_CLASS_CCID],
2050 { "CCID", "lmp.obj.ccid", FT_NONE, BASE_NONE, NULL, 0x0,
2051 NULL, HFILL }},
2052 {&hf_lmp_filter[LMPF_CLASS_NODE_ID],
2053 { "NODE_ID", "lmp.obj.Nodeid", FT_NONE, BASE_NONE, NULL, 0x0,
2054 NULL, HFILL }},
2055 {&hf_lmp_filter[LMPF_CLASS_LINK_ID],
2056 { "LINK_ID", "lmp.obj.linkid", FT_NONE, BASE_NONE, NULL, 0x0,
2057 NULL, HFILL }},
2058 {&hf_lmp_filter[LMPF_CLASS_INTERFACE_ID],
2059 { "INTERFACE_ID", "lmp.obj.interfaceid", FT_NONE, BASE_NONE, NULL, 0x0,
2060 NULL, HFILL }},
2061 {&hf_lmp_filter[LMPF_CLASS_MESSAGE_ID],
2062 { "MESSAGE_ID", "lmp.obj.messageid", FT_NONE, BASE_NONE, NULL, 0x0,
2063 NULL, HFILL }},
2064 {&hf_lmp_filter[LMPF_CLASS_CONFIG],
2065 { "CONFIG", "lmp.obj.config", FT_NONE, BASE_NONE, NULL, 0x0,
2066 NULL, HFILL }},
2067 {&hf_lmp_filter[LMPF_CLASS_HELLO],
2068 { "HELLO", "lmp.obj.hello", FT_NONE, BASE_NONE, NULL, 0x0,
2069 NULL, HFILL }},
2070 {&hf_lmp_filter[LMPF_CLASS_BEGIN_VERIFY],
2071 { "BEGIN_VERIFY", "lmp.obj.begin_verify", FT_NONE, BASE_NONE, NULL, 0x0,
2072 NULL, HFILL }},
2073 {&hf_lmp_filter[LMPF_CLASS_BEGIN_VERIFY_ACK],
2074 { "BEGIN_VERIFY_ACK", "lmp.obj.begin_verify_ack", FT_NONE, BASE_NONE, NULL, 0x0,
2075 NULL, HFILL }},
2076 {&hf_lmp_filter[LMPF_CLASS_VERIFY_ID],
2077 { "VERIFY_ID", "lmp.obj.verifyid", FT_NONE, BASE_NONE, NULL, 0x0,
2078 NULL, HFILL }},
2080 {&hf_lmp_filter[LMPF_CLASS_TE_LINK],
2081 { "TE_LINK", "lmp.obj.te_link", FT_NONE, BASE_NONE, NULL, 0x0,
2082 NULL, HFILL }},
2083 {&hf_lmp_filter[LMPF_CLASS_DATA_LINK],
2084 { "DATA_LINK", "lmp.obj.data_link", FT_NONE, BASE_NONE, NULL, 0x0,
2085 NULL, HFILL }},
2087 {&hf_lmp_filter[LMPF_CLASS_CHANNEL_STATUS],
2088 { "CHANNEL_STATUS", "lmp.obj.channel_status", FT_NONE, BASE_NONE, NULL, 0x0,
2089 NULL, HFILL }},
2091 {&hf_lmp_filter[LMPF_CLASS_CHANNEL_STATUS_REQUEST],
2092 { "CHANNEL_STATUS_REQUEST", "lmp.obj.channel_status_request", FT_NONE, BASE_NONE, NULL, 0x0,
2093 NULL, HFILL }},
2095 {&hf_lmp_filter[LMPF_CLASS_ERROR],
2096 { "ERROR", "lmp.obj.error", FT_NONE, BASE_NONE, NULL, 0x0,
2097 NULL, HFILL }},
2099 {&hf_lmp_filter[LMPF_CLASS_TRACE],
2100 { "TRACE", "lmp.obj.trace", FT_NONE, BASE_NONE, NULL, 0x0,
2101 NULL, HFILL }},
2103 {&hf_lmp_filter[LMPF_CLASS_TRACE_REQ],
2104 { "TRACE REQ", "lmp.obj.trace_req", FT_NONE, BASE_NONE, NULL, 0x0,
2105 NULL, HFILL }},
2107 {&hf_lmp_filter[LMPF_CLASS_SERVICE_CONFIG],
2108 { "SERVICE_CONFIG", "lmp.obj.serviceconfig", FT_NONE, BASE_NONE, NULL, 0x0,
2109 NULL, HFILL }},
2111 {&hf_lmp_filter[LMPF_CLASS_DA_DCN_ADDRESS],
2112 { "DA_DCN_ADDRESS", "lmp.obj.dadcnaddr", FT_NONE, BASE_NONE, NULL, 0x0,
2113 NULL, HFILL }},
2115 {&hf_lmp_filter[LMPF_CLASS_LOCAL_LAD_INFO],
2116 { "LOCAL_LAD_INFO", "lmp.obj.localladinfo", FT_NONE, BASE_NONE, NULL, 0x0,
2117 NULL, HFILL }},
2119 /* Other LMP Value Filters ------------------------------ */
2121 {&hf_lmp_filter[LMPF_VAL_CTYPE],
2122 { "Object C-Type", "lmp.obj.ctype", FT_UINT8, BASE_DEC, NULL, 0x0,
2123 NULL, HFILL }},
2125 {&hf_lmp_filter[LMPF_VAL_LOCAL_CCID],
2126 { "Local CCID Value", "lmp.local_ccid", FT_UINT32, BASE_DEC, NULL, 0x0,
2127 NULL, HFILL }},
2128 {&hf_lmp_filter[LMPF_VAL_REMOTE_CCID],
2129 { "Remote CCID Value", "lmp.remote_ccid", FT_UINT32, BASE_DEC, NULL, 0x0,
2130 NULL, HFILL }},
2132 {&hf_lmp_filter[LMPF_VAL_LOCAL_NODE_ID],
2133 { "Local Node ID Value", "lmp.local_nodeid", FT_IPv4, BASE_NONE, NULL, 0x0,
2134 NULL, HFILL }},
2135 {&hf_lmp_filter[LMPF_VAL_REMOTE_NODE_ID],
2136 { "Remote Node ID Value", "lmp.remote_nodeid", FT_IPv4, BASE_NONE, NULL, 0x0,
2137 NULL, HFILL }},
2139 {&hf_lmp_filter[LMPF_VAL_LOCAL_LINK_ID_IPV4],
2140 { "Local Link ID - IPv4", "lmp.local_linkid_ipv4", FT_IPv4, BASE_NONE, NULL, 0x0,
2141 NULL, HFILL }},
2142 {&hf_lmp_filter[LMPF_VAL_LOCAL_LINK_ID_IPV6],
2143 { "Local Link ID - IPv6", "lmp.local_linkid_ipv6", FT_IPv6, BASE_NONE, NULL, 0x0,
2144 NULL, HFILL }},
2145 {&hf_lmp_filter[LMPF_VAL_LOCAL_LINK_ID_UNNUM],
2146 { "Local Link ID - Unnumbered", "lmp.local_linkid_unnum", FT_UINT32, BASE_DEC, NULL, 0x0,
2147 NULL, HFILL }},
2148 {&hf_lmp_filter[LMPF_VAL_REMOTE_LINK_ID_IPV4],
2149 { "Remote Link ID - IPv4", "lmp.remote_linkid_ipv4", FT_IPv4, BASE_NONE, NULL, 0x0,
2150 NULL, HFILL }},
2151 {&hf_lmp_filter[LMPF_VAL_REMOTE_LINK_ID_IPV6],
2152 { "Remote Link ID - IPv6", "lmp.remote_linkid_ipv6", FT_IPv6, BASE_NONE, NULL, 0x0,
2153 NULL, HFILL }},
2154 {&hf_lmp_filter[LMPF_VAL_REMOTE_LINK_ID_UNNUM],
2155 { "Remote Link ID - Unnumbered", "lmp.remote_linkid_unnum", FT_UINT32, BASE_DEC, NULL, 0x0,
2156 NULL, HFILL }},
2158 {&hf_lmp_filter[LMPF_VAL_LOCAL_INTERFACE_ID_IPV4],
2159 { "Local Interface ID - IPv4", "lmp.local_interfaceid_ipv4", FT_IPv4, BASE_NONE, NULL, 0x0,
2160 NULL, HFILL }},
2161 {&hf_lmp_filter[LMPF_VAL_LOCAL_INTERFACE_ID_IPV6],
2162 { "Local Interface ID - IPv6", "lmp.local_interfaceid_ipv6", FT_IPv6, BASE_NONE, NULL, 0x0,
2163 NULL, HFILL }},
2164 {&hf_lmp_filter[LMPF_VAL_LOCAL_INTERFACE_ID_UNNUM],
2165 { "Local Interface ID - Unnumbered", "lmp.local_interfaceid_unnum", FT_UINT32, BASE_DEC, NULL, 0x0,
2166 NULL, HFILL }},
2167 {&hf_lmp_filter[LMPF_VAL_REMOTE_INTERFACE_ID_IPV4],
2168 { "Remote Interface ID - IPv4", "lmp.remote_interfaceid_ipv4", FT_IPv4, BASE_NONE, NULL, 0x0,
2169 NULL, HFILL }},
2170 {&hf_lmp_filter[LMPF_VAL_REMOTE_INTERFACE_ID_IPV6],
2171 { "Remote Interface ID - IPv6", "lmp.remote_interfaceid_ipv6", FT_IPv6, BASE_NONE, NULL, 0x0,
2172 NULL, HFILL }},
2173 {&hf_lmp_filter[LMPF_VAL_REMOTE_INTERFACE_ID_UNNUM],
2174 { "Remote Interface ID - Unnumbered", "lmp.remote_interfaceid_unnum", FT_UINT32, BASE_DEC, NULL, 0x0,
2175 NULL, HFILL }},
2176 {&hf_lmp_filter[LMPF_VAL_CHANNEL_STATUS_INTERFACE_ID_IPV4],
2177 { "Interface ID: IPv4", "lmp.channel_status_interfaceid_ipv4", FT_IPv4, BASE_NONE, NULL, 0x0,
2178 NULL, HFILL }},
2179 {&hf_lmp_filter[LMPF_VAL_CHANNEL_STATUS_INTERFACE_ID_IPV6],
2180 { "Interface ID: IPv6", "lmp.channel_status_interfaceid_ipv6", FT_IPv6, BASE_NONE, NULL, 0x0,
2181 NULL, HFILL }},
2182 {&hf_lmp_filter[LMPF_VAL_CHANNEL_STATUS_INTERFACE_ID_UNNUM],
2183 { "Interface ID: Unnumbered", "lmp.channel_status_interfaceid_unnum", FT_UINT32, BASE_DEC, NULL, 0x0,
2184 NULL, HFILL }},
2185 {&hf_lmp_filter[LMPF_VAL_MESSAGE_ID],
2186 { "Message-ID Value", "lmp.messageid", FT_UINT32, BASE_DEC, NULL, 0x0,
2187 NULL, HFILL }},
2188 {&hf_lmp_filter[LMPF_VAL_MESSAGE_ID_ACK],
2189 { "Message-ID Ack Value", "lmp.messageid_ack", FT_UINT32, BASE_DEC, NULL, 0x0,
2190 NULL, HFILL }},
2192 {&hf_lmp_filter[LMPF_VAL_CONFIG_HELLO],
2193 { "HelloInterval", "lmp.hellointerval", FT_UINT32, BASE_DEC, NULL, 0x0,
2194 NULL, HFILL }},
2195 {&hf_lmp_filter[LMPF_VAL_CONFIG_HELLO_DEAD],
2196 { "HelloDeadInterval", "lmp.hellodeadinterval", FT_UINT32, BASE_DEC, NULL, 0x0,
2197 NULL, HFILL }},
2199 {&hf_lmp_filter[LMPF_VAL_HELLO_TXSEQ],
2200 { "TxSeqNum", "lmp.txseqnum", FT_UINT32, BASE_DEC, NULL, 0x0,
2201 NULL, HFILL }},
2202 {&hf_lmp_filter[LMPF_VAL_HELLO_RXSEQ],
2203 { "RxSeqNum", "lmp.rxseqnum", FT_UINT32, BASE_DEC, NULL, 0x0,
2204 NULL, HFILL }},
2206 {&hf_lmp_filter[LMPF_VAL_BEGIN_VERIFY_FLAGS],
2207 { "Flags", "lmp.begin_verify.flags", FT_UINT16, BASE_HEX, NULL, 0x0,
2208 NULL, HFILL }},
2209 {&hf_lmp_filter[LMPF_VAL_BEGIN_VERIFY_FLAGS_ALL_LINKS],
2210 { "Verify All Links", "lmp.begin_verify.all_links",
2211 FT_BOOLEAN, 8, NULL, 0x01, NULL, HFILL }},
2212 {&hf_lmp_filter[LMPF_VAL_BEGIN_VERIFY_FLAGS_LINK_TYPE],
2213 { "Data Link Type", "lmp.begin_verify.link_type",
2214 FT_BOOLEAN, 8, NULL, 0x02, NULL, HFILL }},
2215 {&hf_lmp_filter[LMPF_VAL_BEGIN_VERIFY_ENCTYPE],
2216 { "Encoding Type", "lmp.begin_verify.enctype",
2217 FT_UINT8, BASE_DEC|BASE_RANGE_STRING, RVALS(gmpls_lsp_enc_rvals), 0x0,
2218 NULL, HFILL }},
2219 {&hf_lmp_filter[LMPF_VAL_VERIFY_ID],
2220 { "Verify-ID", "lmp.verifyid", FT_UINT32, BASE_DEC, NULL, 0x0,
2221 NULL, HFILL }},
2223 {&hf_lmp_filter[LMPF_VAL_TE_LINK_FLAGS],
2224 { "TE-Link Flags", "lmp.te_link_flags", FT_UINT8, BASE_HEX, NULL, 0x0,
2225 NULL, HFILL }},
2226 {&hf_lmp_filter[LMPF_VAL_TE_LINK_FLAGS_FAULT_MGMT],
2227 { "Fault Management Supported", "lmp.te_link.fault_mgmt",
2228 FT_BOOLEAN, 8, NULL, 0x01, NULL, HFILL }},
2229 {&hf_lmp_filter[LMPF_VAL_TE_LINK_FLAGS_LINK_VERIFY],
2230 { "Link Verification Supported", "lmp.te_link.link_verify",
2231 FT_BOOLEAN, 8, NULL, 0x02, NULL, HFILL }},
2232 {&hf_lmp_filter[LMPF_VAL_TE_LINK_LOCAL_IPV4],
2233 { "TE-Link Local ID - IPv4", "lmp.te_link.local_ipv4", FT_IPv4, BASE_NONE, NULL, 0x0,
2234 NULL, HFILL }},
2235 {&hf_lmp_filter[LMPF_VAL_TE_LINK_LOCAL_IPV6],
2236 { "TE-Link Local ID - IPv6", "lmp.te_link.local_ipv6", FT_IPv6, BASE_NONE, NULL, 0x0,
2237 NULL, HFILL }},
2238 {&hf_lmp_filter[LMPF_VAL_TE_LINK_LOCAL_UNNUM],
2239 { "TE-Link Local ID - Unnumbered", "lmp.te_link.local_unnum", FT_UINT32, BASE_DEC, NULL, 0x0,
2240 NULL, HFILL }},
2241 {&hf_lmp_filter[LMPF_VAL_TE_LINK_REMOTE_IPV4],
2242 { "TE-Link Remote ID - IPv4", "lmp.te_link.remote_ipv4", FT_IPv4, BASE_NONE, NULL, 0x0,
2243 NULL, HFILL }},
2244 {&hf_lmp_filter[LMPF_VAL_TE_LINK_REMOTE_IPV6],
2245 { "TE-Link Remote ID - IPv6", "lmp.te_link.remote_ipv6", FT_IPv6, BASE_NONE, NULL, 0x0,
2246 NULL, HFILL }},
2247 {&hf_lmp_filter[LMPF_VAL_TE_LINK_REMOTE_UNNUM],
2248 { "TE-Link Remote ID - Unnumbered", "lmp.te_link.remote_unnum", FT_UINT32, BASE_DEC, NULL, 0x0,
2249 NULL, HFILL }},
2251 {&hf_lmp_filter[LMPF_VAL_DATA_LINK_FLAGS],
2252 { "Data-Link Flags", "lmp.data_link_flags", FT_UINT8, BASE_HEX, NULL, 0x0,
2253 NULL, HFILL }},
2254 {&hf_lmp_filter[LMPF_VAL_DATA_LINK_FLAGS_PORT],
2255 { "Data-Link is Individual Port", "lmp.data_link.port",
2256 FT_BOOLEAN, 8, NULL, 0x01, NULL, HFILL }},
2257 {&hf_lmp_filter[LMPF_VAL_DATA_LINK_FLAGS_ALLOCATED],
2258 { "Data-Link is Allocated", "lmp.data_link.link_verify",
2259 FT_BOOLEAN, 8, NULL, 0x02, NULL, HFILL }},
2260 {&hf_lmp_filter[LMPF_VAL_DATA_LINK_LOCAL_IPV4],
2261 { "Data-Link Local ID - IPv4", "lmp.data_link.local_ipv4", FT_IPv4, BASE_NONE, NULL, 0x0,
2262 NULL, HFILL }},
2263 {&hf_lmp_filter[LMPF_VAL_DATA_LINK_LOCAL_UNNUM],
2264 { "Data-Link Local ID - Unnumbered", "lmp.data_link.local_unnum", FT_UINT32, BASE_DEC, NULL, 0x0,
2265 NULL, HFILL }},
2266 {&hf_lmp_filter[LMPF_VAL_DATA_LINK_REMOTE_IPV4],
2267 { "Data-Link Remote ID - IPv4", "lmp.data_link.remote_ipv4", FT_IPv4, BASE_NONE, NULL, 0x0,
2268 NULL, HFILL }},
2269 {&hf_lmp_filter[LMPF_VAL_DATA_LINK_REMOTE_UNNUM],
2270 { "Data-Link Remote ID - Unnumbered", "lmp.data_link.remote_unnum", FT_UINT32, BASE_DEC, NULL, 0x0,
2271 NULL, HFILL }},
2272 {&hf_lmp_filter[LMPF_VAL_DATA_LINK_SUBOBJ],
2273 { "Subobject", "lmp.data_link_subobj", FT_NONE, BASE_NONE, NULL, 0x0,
2274 NULL, HFILL }},
2275 {&hf_lmp_filter[LMPF_VAL_DATA_LINK_SUBOBJ_SWITCHING_TYPE],
2276 { "Interface Switching Capability", "lmp.data_link_switching", FT_UINT8, BASE_DEC|BASE_RANGE_STRING,
2277 RVALS(gmpls_switching_type_rvals), 0x0, NULL, HFILL }},
2278 {&hf_lmp_filter[LMPF_VAL_DATA_LINK_SUBOBJ_LSP_ENCODING],
2279 { "LSP Encoding Type", "lmp.data_link_encoding", FT_UINT8, BASE_DEC|BASE_RANGE_STRING,
2280 RVALS(gmpls_lsp_enc_rvals), 0x0, NULL, HFILL }},
2282 {&hf_lmp_filter[LMPF_VAL_ERROR],
2283 { "Error Code", "lmp.error", FT_UINT32, BASE_HEX, NULL, 0x0,
2284 NULL, HFILL }},
2286 {&hf_lmp_filter[LMPF_VAL_ERROR_VERIFY_UNSUPPORTED_LINK],
2287 { "Verification - Unsupported for this TE-Link", "lmp.error.verify_unsupported_link",
2288 FT_BOOLEAN, 8, NULL, 0x01, NULL, HFILL }},
2289 {&hf_lmp_filter[LMPF_VAL_ERROR_VERIFY_UNWILLING],
2290 { "Verification - Unwilling to Verify at this time", "lmp.error.verify_unwilling",
2291 FT_BOOLEAN, 8, NULL, 0x02, NULL, HFILL }},
2292 {&hf_lmp_filter[LMPF_VAL_ERROR_VERIFY_TRANSPORT],
2293 { "Verification - Transport Unsupported", "lmp.error.verify_unsupported_transport",
2294 FT_BOOLEAN, 8, NULL, 0x04, NULL, HFILL }},
2295 {&hf_lmp_filter[LMPF_VAL_ERROR_VERIFY_TE_LINK_ID],
2296 { "Verification - TE Link ID Configuration Error", "lmp.error.verify_te_link_id",
2297 FT_BOOLEAN, 8, NULL, 0x08, NULL, HFILL }},
2299 {&hf_lmp_filter[LMPF_VAL_ERROR_VERIFY_UNKNOWN_CTYPE],
2300 { "Verification - Unknown Object C-Type", "lmp.error.verify_unknown_ctype",
2301 FT_BOOLEAN, 8, NULL, 0x08, NULL, HFILL }},
2303 {&hf_lmp_filter[LMPF_VAL_ERROR_SUMMARY_BAD_PARAMETERS],
2304 { "Summary - Unacceptable non-negotiable parameters", "lmp.error.summary_bad_params",
2305 FT_BOOLEAN, 8, NULL, 0x01, NULL, HFILL }},
2306 {&hf_lmp_filter[LMPF_VAL_ERROR_SUMMARY_RENEGOTIATE],
2307 { "Summary - Renegotiate Parameter", "lmp.error.summary_renegotiate",
2308 FT_BOOLEAN, 8, NULL, 0x02, NULL, HFILL }},
2309 {&hf_lmp_filter[LMPF_VAL_ERROR_SUMMARY_BAD_TE_LINK],
2310 { "Summary - Bad TE Link Object", "lmp.error.summary_bad_te_link",
2311 FT_BOOLEAN, 8, NULL, 0x08, NULL, HFILL }},
2312 {&hf_lmp_filter[LMPF_VAL_ERROR_SUMMARY_BAD_DATA_LINK],
2313 { "Summary - Bad Data Link Object", "lmp.error.summary_bad_data_link",
2314 FT_BOOLEAN, 8, NULL, 0x10, NULL, HFILL }},
2315 {&hf_lmp_filter[LMPF_VAL_ERROR_SUMMARY_UNKNOWN_TEL_CTYPE],
2316 { "Summary - Bad TE Link C-Type", "lmp.error.summary_unknown_tel_ctype",
2317 FT_BOOLEAN, 8, NULL, 0x04, NULL, HFILL }},
2318 {&hf_lmp_filter[LMPF_VAL_ERROR_SUMMARY_UNKNOWN_DL_CTYPE],
2319 { "Summary - Bad Data Link C-Type", "lmp.error.summary_unknown_dl_ctype",
2320 FT_BOOLEAN, 8, NULL, 0x04, NULL, HFILL }},
2321 {&hf_lmp_filter[LMPF_VAL_ERROR_SUMMARY_BAD_REMOTE_LINK_ID],
2322 { "Summary - Bad Remote Link ID", "lmp.error.summary_bad_remote_link_id",
2323 FT_BOOLEAN, 8, NULL, 0x04, NULL, HFILL }},
2324 {&hf_lmp_filter[LMPF_VAL_ERROR_CONFIG_BAD_PARAMETERS],
2325 { "Config - Unacceptable non-negotiable parameters", "lmp.error.config_bad_params",
2326 FT_BOOLEAN, 8, NULL, 0x01, NULL, HFILL }},
2327 {&hf_lmp_filter[LMPF_VAL_ERROR_CONFIG_RENEGOTIATE],
2328 { "Config - Renegotiate Parameter", "lmp.error.config_renegotiate",
2329 FT_BOOLEAN, 8, NULL, 0x02, NULL, HFILL }},
2330 {&hf_lmp_filter[LMPF_VAL_ERROR_CONFIG_BAD_CCID],
2331 { "Config - Bad CC ID", "lmp.error.config_bad_ccid",
2332 FT_BOOLEAN, 8, NULL, 0x04, NULL, HFILL }},
2333 {&hf_lmp_filter[LMPF_VAL_ERROR_TRACE_UNSUPPORTED_TYPE],
2334 { "Trace - Unsupported trace type", "lmp.error.trace_unsupported_type",
2335 FT_BOOLEAN, 8, NULL, 0x01, NULL, HFILL }},
2336 {&hf_lmp_filter[LMPF_VAL_ERROR_TRACE_INVALID_MSG],
2337 { "Trace - Invalid Trace Message", "lmp.error.trace_invalid_msg",
2338 FT_BOOLEAN, 8, NULL, 0x02, NULL, HFILL }},
2339 {&hf_lmp_filter[LMPF_VAL_ERROR_TRACE_UNKNOWN_CTYPE],
2340 { "Trace - Unknown Object C-Type", "lmp.error.trace_unknown_ctype",
2341 FT_BOOLEAN, 8, NULL, 0x10, NULL, HFILL }},
2342 {&hf_lmp_filter[LMPF_VAL_ERROR_LAD_AREA_ID_MISMATCH],
2343 { "LAD - Domain Routing Area ID Mismatch detected", "lmp.error.lad_area_id_mismatch",
2344 FT_BOOLEAN, 8, NULL, 0x01, NULL, HFILL }},
2345 {&hf_lmp_filter[LMPF_VAL_ERROR_LAD_TCP_ID_MISMATCH],
2346 { "LAD - TCP ID Mismatch detected", "lmp.error.lad_tcp_id_mismatch",
2347 FT_BOOLEAN, 8, NULL, 0x02, NULL, HFILL }},
2348 {&hf_lmp_filter[LMPF_VAL_ERROR_LAD_DA_DCN_MISMATCH],
2349 { "LAD - DA DCN Mismatch detected", "lmp.error.lad_da_dcn_mismatch",
2350 FT_BOOLEAN, 8, NULL, 0x04, NULL, HFILL }},
2351 {&hf_lmp_filter[LMPF_VAL_ERROR_LAD_CAPABILITY_MISMATCH],
2352 { "LAD - Capability Mismatch detected", "lmp.error.lad_capability_mismatch",
2353 FT_BOOLEAN, 8, NULL, 0x08, NULL, HFILL }},
2354 {&hf_lmp_filter[LMPF_VAL_ERROR_LAD_UNKNOWN_CTYPE],
2355 { "LAD - Unknown Object C-Type", "lmp.error.lad_unknown_ctype",
2356 FT_BOOLEAN, 8, NULL, 0x10, NULL, HFILL }},
2358 {&hf_lmp_filter[LMPF_VAL_TRACE_LOCAL_TYPE],
2359 { "Local Trace Type", "lmp.trace.local_type", FT_UINT16, BASE_DEC,
2360 VALS(lmp_trace_type_str), 0x0, NULL, HFILL }},
2361 {&hf_lmp_filter[LMPF_VAL_TRACE_LOCAL_LEN],
2362 { "Local Trace Length", "lmp.trace.local_length", FT_UINT16, BASE_DEC,
2363 NULL, 0x0, NULL, HFILL }},
2364 {&hf_lmp_filter[LMPF_VAL_TRACE_LOCAL_MSG],
2365 { "Local Trace Message", "lmp.trace.local_msg", FT_STRING, BASE_NONE,
2366 NULL, 0x0, NULL, HFILL }},
2367 {&hf_lmp_filter[LMPF_VAL_TRACE_REMOTE_TYPE],
2368 { "Remote Trace Type", "lmp.trace.remote_type", FT_UINT16, BASE_DEC,
2369 VALS(lmp_trace_type_str), 0x0, NULL, HFILL }},
2370 {&hf_lmp_filter[LMPF_VAL_TRACE_REMOTE_LEN],
2371 { "Remote Trace Length", "lmp.trace.remote_length", FT_UINT16, BASE_DEC,
2372 NULL, 0x0, NULL, HFILL }},
2373 {&hf_lmp_filter[LMPF_VAL_TRACE_REMOTE_MSG],
2374 { "Remote Trace Message", "lmp.trace.remote_msg", FT_STRING, BASE_NONE,
2375 NULL, 0x0, NULL, HFILL }},
2377 {&hf_lmp_filter[LMPF_VAL_TRACE_REQ_TYPE],
2378 { "Trace Type", "lmp.trace_req.type", FT_UINT16, BASE_DEC,
2379 VALS(lmp_trace_type_str), 0x0, NULL, HFILL }},
2381 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_SP_FLAGS],
2382 { "Service Config - Supported Signalling Protocols",
2383 "lmp.service_config.sp", FT_UINT8, BASE_HEX, NULL, 0x0, NULL, HFILL}},
2385 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_SP_FLAGS_RSVP],
2386 { "RSVP is supported", "lmp.service_config.sp.rsvp",
2387 FT_BOOLEAN, 8, NULL, 0x01, NULL, HFILL}},
2389 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_SP_FLAGS_LDP],
2390 { "LDP is supported", "lmp.service_config.sp.ldp",
2391 FT_BOOLEAN, 8, NULL, 0x02, NULL, HFILL}},
2393 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_TP_FLAGS],
2394 { "Client Port Service Attributes", "lmp.service_config.cpsa",
2395 FT_UINT8, BASE_HEX, NULL, 0x0, NULL, HFILL}},
2397 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_TP_FLAGS_PATH_OVERHEAD],
2398 { "Path/VC Overhead Transparency Supported",
2399 "lmp.service_config.cpsa.path_overhead",
2400 FT_BOOLEAN, 8, NULL, 0x01, NULL, HFILL}},
2402 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_TP_FLAGS_LINE_OVERHEAD],
2403 { "Line/MS Overhead Transparency Supported",
2404 "lmp.service_config.cpsa.line_overhead",
2405 FT_BOOLEAN, 8, NULL, 0x02, NULL, HFILL}},
2407 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_TP_FLAGS_SECTION_OVERHEAD],
2408 { "Section/RS Overhead Transparency Supported",
2409 "lmp.service_config.cpsa.section_overhead",
2410 FT_BOOLEAN, 8, NULL, 0x04, NULL, HFILL}},
2412 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_CCT_FLAGS],
2413 { "Contiguous Concatenation Types", "lmp.service_config.cct",
2414 FT_UINT8, BASE_HEX, NULL, 0x0, NULL, HFILL}},
2416 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_CCT_FLAGS_CC_SUPPORTED],
2417 { "Contiguous Concatenation Types Supported",
2418 "lmp.service_config.cpsa.line_overhead",
2419 FT_BOOLEAN, 8, NULL, 0x01, NULL, HFILL}},
2421 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_MIN_NCC],
2422 { "Minimum Number of Contiguously Concatenated Components",
2423 "lmp.service_config.cpsa.min_ncc",
2424 FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL}},
2426 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_MAX_NCC],
2427 { "Maximum Number of Contiguously Concatenated Components",
2428 "lmp.service_config.cpsa.max_ncc",
2429 FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL}},
2431 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_MIN_NVC],
2432 { "Maximum Number of Contiguously Concatenated Components",
2433 "lmp.service_config.cpsa.min_nvc",
2434 FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL}},
2436 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_MAX_NVC],
2437 { "Minimum Number of Virtually Concatenated Components",
2438 "lmp.service_config.cpsa.max_nvc",
2439 FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL}},
2441 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_CPSA_INTERFACE_ID],
2442 { "Local interface id of the client interface referred to",
2443 "lmp.service_config.cpsa.local_ifid",
2444 FT_IPv4, BASE_NONE, NULL, 0x0, NULL, HFILL}},
2446 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_TRANSPARENCY_FLAGS],
2447 { "Network Transparency Flags",
2448 "lmp.service_config.nsa.transparency",
2449 FT_UINT32, BASE_HEX, NULL, 0x0, NULL, HFILL}},
2451 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_TRANSPARENCY_FLAGS_SOH],
2452 { "Standard SOH/RSOH transparency supported",
2453 "lmp.service_config.nsa.transparency.soh",
2454 FT_BOOLEAN, 8, NULL, 0x01, NULL, HFILL}},
2456 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_TRANSPARENCY_FLAGS_LOH],
2457 { "Standard LOH/MSOH transparency supported",
2458 "lmp.service_config.nsa.transparency.loh",
2459 FT_BOOLEAN, 8, NULL, 0x02, NULL, HFILL}},
2461 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_TCM_FLAGS],
2462 { "TCM Monitoring",
2463 "lmp.service_config.nsa.tcm",
2464 FT_UINT8, BASE_HEX, NULL, 0x0, NULL, HFILL}},
2466 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_TCM_FLAGS_TCM_SUPPORTED],
2467 { "TCM Monitoring Supported",
2468 "lmp.service_config.nsa.transparency.tcm",
2469 FT_BOOLEAN, 8, NULL, 0x01, NULL, HFILL}},
2471 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_NETWORK_DIVERSITY_FLAGS],
2472 { "Network Diversity Flags",
2473 "lmp.service_config.nsa.diversity",
2474 FT_UINT8, BASE_HEX, NULL, 0x0, NULL, HFILL}},
2476 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_NETWORK_DIVERSITY_FLAGS_NODE],
2477 { "Node diversity supported",
2478 "lmp.service_config.nsa.diversity.node",
2479 FT_BOOLEAN, 8, NULL, 0x01, NULL, HFILL}},
2481 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_NETWORK_DIVERSITY_FLAGS_LINK],
2482 { "Link diversity supported",
2483 "lmp.service_config.nsa.diversity.link",
2484 FT_BOOLEAN, 8, NULL, 0x02, NULL, HFILL}},
2486 {&hf_lmp_filter[LMPF_VAL_SERVICE_CONFIG_NSA_NETWORK_DIVERSITY_FLAGS_SRLG],
2487 { "SRLG diversity supported",
2488 "lmp.service_config.nsa.diversity.srlg",
2489 FT_BOOLEAN, 8, NULL, 0x04, NULL, HFILL}},
2491 {&hf_lmp_filter[LMPF_VAL_LOCAL_DA_DCN_ADDR],
2492 { "Local DA DCN Address", "lmp.local_da_dcn_addr", FT_IPv4, BASE_NONE, NULL, 0x0,
2493 NULL, HFILL }},
2494 {&hf_lmp_filter[LMPF_VAL_REMOTE_DA_DCN_ADDR],
2495 { "Remote DA DCN Address", "lmp.remote_da_dcn_addr", FT_IPv4, BASE_NONE, NULL, 0x0,
2496 NULL, HFILL }},
2498 {&hf_lmp_filter[LMPF_VAL_LOCAL_LAD_INFO_NODE_ID],
2499 { "Node ID", "lmp.local_lad_node_id", FT_IPv4, BASE_NONE, NULL, 0x0,
2500 NULL, HFILL }},
2501 {&hf_lmp_filter[LMPF_VAL_LOCAL_LAD_INFO_AREA_ID],
2502 { "Area ID", "lmp.local_lad_area_id", FT_IPv4, BASE_NONE, NULL, 0x0,
2503 NULL, HFILL }},
2504 {&hf_lmp_filter[LMPF_VAL_LOCAL_LAD_INFO_TE_LINK_ID],
2505 { "TE Link ID", "lmp.local_lad_telink_id", FT_UINT32, BASE_DEC, NULL, 0x0,
2506 NULL, HFILL }},
2507 {&hf_lmp_filter[LMPF_VAL_LOCAL_LAD_INFO_COMPONENT_ID],
2508 { "Component Link ID", "lmp.local_lad_comp_id", FT_UINT32, BASE_DEC, NULL, 0x0,
2509 NULL, HFILL }},
2510 {&hf_lmp_filter[LMPF_VAL_LOCAL_LAD_INFO_SC_PC_ID],
2511 { "SC PC ID", "lmp.local_lad_sc_pc_id", FT_IPv4, BASE_NONE, NULL, 0x0,
2512 NULL, HFILL }},
2513 {&hf_lmp_filter[LMPF_VAL_LOCAL_LAD_INFO_SC_PC_ADDR],
2514 { "SC PC Address", "lmp.local_lad_sc_pc_addr", FT_IPv4, BASE_NONE, NULL, 0x0,
2515 NULL, HFILL }},
2516 {&hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ],
2517 { "Subobject", "lmp.lad_info_subobj", FT_NONE, BASE_NONE, NULL, 0x0,
2518 NULL, HFILL }},
2519 {&hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_PRI_AREA_ID],
2520 { "SC PC Address", "lmp.lad_pri_area_id", FT_IPv4, BASE_NONE, NULL, 0x0,
2521 NULL, HFILL }},
2522 {&hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_PRI_RC_PC_ID],
2523 { "SC PC Address", "lmp.lad_pri_rc_pc_id", FT_IPv4, BASE_NONE, NULL, 0x0,
2524 NULL, HFILL }},
2525 {&hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_PRI_RC_PC_ADDR],
2526 { "SC PC Address", "lmp.lad_pri_rc_pc_addr", FT_IPv4, BASE_NONE, NULL, 0x0,
2527 NULL, HFILL }},
2528 {&hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_SEC_AREA_ID],
2529 { "SC PC Address", "lmp.lad_sec_area_id", FT_IPv4, BASE_NONE, NULL, 0x0,
2530 NULL, HFILL }},
2531 {&hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_SEC_RC_PC_ID],
2532 { "SC PC Address", "lmp.lad_sec_rc_pc_id", FT_IPv4, BASE_NONE, NULL, 0x0,
2533 NULL, HFILL }},
2534 {&hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_SEC_RC_PC_ADDR],
2535 { "SC PC Address", "lmp.lad_sec_rc_pc_addr", FT_IPv4, BASE_NONE, NULL, 0x0,
2536 NULL, HFILL }},
2537 {&hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_SWITCHING_TYPE],
2538 { "Interface Switching Capability", "lmp.lad_switching", FT_UINT8, BASE_DEC|BASE_RANGE_STRING,
2539 RVALS(gmpls_switching_type_rvals), 0x0, NULL, HFILL }},
2540 {&hf_lmp_filter[LMPF_VAL_LAD_INFO_SUBOBJ_LSP_ENCODING],
2541 { "LSP Encoding Type", "lmp.lad_encoding", FT_UINT8, BASE_DEC|BASE_RANGE_STRING,
2542 RVALS(gmpls_lsp_enc_rvals), 0x0, NULL, HFILL }},
2543 {&hf_lmp_filter[LMPF_CHECKSUM],
2544 { "Message Checksum", "lmp.checksum", FT_UINT16, BASE_HEX, NULL, 0x0,
2545 NULL, HFILL }},
2546 {&hf_lmp_filter[LMPF_CHECKSUM_STATUS],
2547 { "Checksum Status", "lmp.checksum.status", FT_UINT8, BASE_NONE, VALS(proto_checksum_vals), 0x0,
2548 NULL, HFILL }},
2549 {&hf_lmp_data,
2550 { "Data", "lmp.data", FT_BYTES, BASE_NONE, NULL, 0x0,
2551 NULL, HFILL }},
2553 /* Generated from convert_proto_tree_add_text.pl */
2554 { &hf_lmp_version, { "LMP Version", "lmp.version", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
2555 { &hf_lmp_header_flags, { "Flags", "lmp.header_flags", FT_UINT8, BASE_HEX, NULL, 0x0, NULL, HFILL }},
2556 { &hf_lmp_header_length, { "Length", "lmp.header_length", FT_UINT16, BASE_DEC|BASE_UNIT_STRING, UNS(&units_byte_bytes), 0x0, NULL, HFILL }},
2557 { &hf_lmp_negotiable, { "Negotiable", "lmp.negotiable", FT_BOOLEAN, 8, TFS(&tfs_yes_no), 0x80, NULL, HFILL }},
2558 { &hf_lmp_object_length, { "Length", "lmp.object_length", FT_UINT16, BASE_DEC, NULL, 0x0, NULL, HFILL }},
2559 { &hf_lmp_object_class, { "Object Class", "lmp.object_class", FT_UINT8, BASE_DEC, VALS(lmp_class_vals), 0x0, NULL, HFILL }},
2560 { &hf_lmp_verify_interval, { "Verify Interval", "lmp.verify_interval", FT_UINT16, BASE_DEC|BASE_UNIT_STRING, UNS(&units_milliseconds), 0x0, NULL, HFILL }},
2561 { &hf_lmp_number_of_data_links, { "Number of Data Links", "lmp.number_of_data_links", FT_UINT32, BASE_DEC, NULL, 0x0, NULL, HFILL }},
2562 { &hf_lmp_verify_transport_mechanism, { "Verify Transport Mechanism", "lmp.verify_transport_mechanism", FT_UINT16, BASE_HEX, NULL, 0x0, NULL, HFILL }},
2563 { &hf_lmp_transmission_rate, { "Transmission Rate", "lmp.transmission_rate", FT_FLOAT, BASE_NONE, NULL, 0x0, NULL, HFILL }},
2564 { &hf_lmp_wavelength, { "Wavelength", "lmp.wavelength", FT_UINT32, BASE_DEC, NULL, 0x0, NULL, HFILL }},
2565 { &hf_lmp_verifydeadinterval, { "VerifyDeadInterval", "lmp.verifydeadinterval", FT_UINT16, BASE_DEC|BASE_UNIT_STRING, UNS(&units_milliseconds), 0x0, NULL, HFILL }},
2566 { &hf_lmp_verify_transport_response, { "Verify Transport Response", "lmp.verify_transport_response", FT_UINT16, BASE_HEX, NULL, 0x0, NULL, HFILL }},
2567 { &hf_lmp_data_link_local_id_ipv6, { "Data-Link Local ID - IPv6", "lmp.data_link.local_ipv6", FT_IPv6, BASE_NONE, NULL, 0x0, NULL, HFILL }},
2568 { &hf_lmp_data_link_remote_id_ipv6, { "Data-Link Remote ID - IPv6", "lmp.data_link.remote_ipv6", FT_IPv6, BASE_NONE, NULL, 0x0, NULL, HFILL }},
2569 { &hf_lmp_subobject_type, { "Subobject Type", "lmp.subobject_type", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
2570 { &hf_lmp_subobject_length, { "Subobject Length", "lmp.subobject_length", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
2571 { &hf_lmp_minimum_reservable_bandwidth, { "Minimum Reservable Bandwidth", "lmp.minimum_reservable_bandwidth", FT_FLOAT, BASE_NONE, NULL, 0x0, NULL, HFILL }},
2572 { &hf_lmp_maximum_reservable_bandwidth, { "Maximum Reservable Bandwidth", "lmp.maximum_reservable_bandwidth", FT_FLOAT, BASE_NONE, NULL, 0x0, NULL, HFILL }},
2573 { &hf_lmp_interface_id_ipv4, { "Interface ID - IPv4", "lmp.interface_id.ipv4", FT_IPv4, BASE_NONE, NULL, 0x0, NULL, HFILL }},
2574 { &hf_lmp_interface_id_ipv6, { "Interface ID - IPv6", "lmp.interface_id.ipv6", FT_IPv6, BASE_NONE, NULL, 0x0, NULL, HFILL }},
2575 { &hf_lmp_interface_id_unnumbered, { "Interface ID - Unnumbered", "lmp.interface_id.id_unnumbered", FT_UINT32, BASE_DEC, NULL, 0x0, NULL, HFILL }},
2576 { &hf_lmp_link, { "Link", "lmp.link", FT_BOOLEAN, 32, TFS(&tfs_active_monitoring_not_allocated), 0x80000000, NULL, HFILL }},
2577 { &hf_lmp_channel_status, { "Channel Status", "lmp.channel_status", FT_UINT32, BASE_DEC, VALS(channel_status_str), 0x7fffffff, NULL, HFILL }},
2578 { &hf_lmp_uni_version, { "UNI Version", "lmp.uni_version", FT_UINT8, BASE_DEC, NULL, 0x0, NULL, HFILL }},
2579 { &hf_lmp_link_type, { "Link Type", "lmp.link_type", FT_UINT8, BASE_DEC, VALS(service_attribute_link_type_str), 0x0, NULL, HFILL }},
2580 { &hf_lmp_signal_types_sdh, { "Signal Types", "lmp.signal_types", FT_UINT8, BASE_DEC, VALS(service_attribute_signal_types_sdh_str), 0x0, NULL, HFILL }},
2581 { &hf_lmp_signal_types_sonet, { "Signal Types", "lmp.signal_types", FT_UINT8, BASE_DEC, VALS(service_attribute_signal_types_sonet_str), 0x0, NULL, HFILL }},
2582 { &hf_lmp_free_timeslots, { "Free timeslots", "lmp.free_timeslots", FT_UINT24, BASE_DEC, NULL, 0x0, NULL, HFILL }},
2585 static ei_register_info ei[] = {
2586 { &ei_lmp_checksum_incorrect, { "lmp.checksum.incorrect", PI_PROTOCOL, PI_WARN, "Incorrect checksum", EXPFILL }},
2587 { &ei_lmp_invalid_msg_type, { "lmp.invalid_msg_type", PI_PROTOCOL, PI_WARN, "Invalid message type", EXPFILL }},
2588 { &ei_lmp_invalid_class, { "lmp.invalid_class", PI_PROTOCOL, PI_WARN, "Invalid class", EXPFILL }},
2589 { &ei_lmp_trace_len, { "lmp.trace.len_invalid", PI_PROTOCOL, PI_WARN, "Invalid Trace Length", EXPFILL }},
2590 { &ei_lmp_obj_len, { "lmp.obj.len_invalid", PI_PROTOCOL, PI_WARN, "Invalid Object Length", EXPFILL }}
2593 expert_module_t* expert_lmp;
2595 for (i=0; i<NUM_LMP_SUBTREES; i++) {
2596 ett[i] = &lmp_subtree[i];
2600 proto_lmp = proto_register_protocol("Link Management Protocol (LMP)", "LMP", "lmp");
2602 expert_lmp = expert_register_protocol(proto_lmp);
2603 expert_register_field_array(expert_lmp, ei, array_length(ei));
2605 proto_register_field_array(proto_lmp, lmpf_info, array_length(lmpf_info));
2606 proto_register_subtree_array(ett, array_length(ett));
2608 lmp_handle = register_dissector("lmp", dissect_lmp, proto_lmp);
2610 register_lmp_prefs();
2613 void
2614 proto_reg_handoff_lmp(void)
2616 dissector_add_uint_with_preference("udp.port", UDP_PORT_LMP_DEFAULT, lmp_handle);
2620 * Editor modelines - https://www.wireshark.org/tools/modelines.html
2622 * Local variables:
2623 * c-basic-offset: 4
2624 * tab-width: 8
2625 * indent-tabs-mode: nil
2626 * End:
2628 * vi: set shiftwidth=4 tabstop=8 expandtab:
2629 * :indentSize=4:tabSize=8:noTabs=true: