aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-rsvp.c
diff options
context:
space:
mode:
authorAnders Broman <anders.broman@ericsson.com>2012-10-30 09:13:13 +0000
committerAnders Broman <anders.broman@ericsson.com>2012-10-30 09:13:13 +0000
commit7ac8c137d9ab1d6ffad8a9e6f63818471e008f09 (patch)
tree3ee4fcfa3302d36100b4ce16f598df2044ff51b9 /epan/dissectors/packet-rsvp.c
parent240789d01dea3e524aaed7a0bea47b8b0a1fad67 (diff)
Fix Incorrect decoding of RSVP RECORD_ROUTE Object.
"in RSVP RESV message there incorrect explanation of field "Flags" of Label subobject is appeared in Packet Details section: value 0x01 of Flags field mistakenly defined as "Local Protection Available" (I guess that this is borrowed from Flags field of IPv4 Address subobject). Flags 0x01 in Label subobject means that particular label is global (RFC 3209, Clause 4.4.1.3)." https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=7876 svn path=/trunk/; revision=45835
Diffstat (limited to 'epan/dissectors/packet-rsvp.c')
-rw-r--r--epan/dissectors/packet-rsvp.c33
1 files changed, 13 insertions, 20 deletions
diff --git a/epan/dissectors/packet-rsvp.c b/epan/dissectors/packet-rsvp.c
index 2c2bc0ad3b..06ccb0ccb1 100644
--- a/epan/dissectors/packet-rsvp.c
+++ b/epan/dissectors/packet-rsvp.c
@@ -171,6 +171,7 @@ static int hf_rsvp_rro_flags_node = -1;
static int hf_rsvp_rro_flags_node_address = -1;
static int hf_rsvp_rro_flags_backup_tunnel_bandwidth = -1;
static int hf_rsvp_rro_flags_backup_tunnel_hop = -1;
+static int hf_rsvp_rro_flags_global_label = -1;
static int hf_rsvp_lsp_attr_e2e = -1;
static int hf_rsvp_lsp_attr_boundary = -1;
static int hf_rsvp_lsp_attr_segment = -1;
@@ -4209,7 +4210,8 @@ dissect_rsvp_session_attribute(proto_item *ti, proto_tree *rsvp_object_tree,
}
/*------------------------------------------------------------------------------
- * EXPLICIT ROUTE AND RECORD ROUTE SUBOBJECTS
+ * EXPLICIT ROUTE AND RECORD ROUTE SUBOBJECTS,
+ * RFC 3209, RFC 3473, RFC 5420, RFC 4873, RFC 5553
*------------------------------------------------------------------------------*/
static void
dissect_rsvp_ero_rro_subobjects(proto_tree *ti, proto_tree *rsvp_object_tree,
@@ -4346,7 +4348,7 @@ dissect_rsvp_ero_rro_subobjects(proto_tree *ti, proto_tree *rsvp_object_tree,
break;
- case 3: /* Label */
+ case 3: /* Label RFC 3477 */
k = tvb_get_guint8(tvb, offset+l) & 0x80;
ti2 = proto_tree_add_text(rsvp_object_tree, tvb,
offset+l, 8,
@@ -4366,22 +4368,13 @@ dissect_rsvp_ero_rro_subobjects(proto_tree *ti, proto_tree *rsvp_object_tree,
tvb_get_guint8(tvb, offset+l+1));
if (rsvp_class == RSVP_CLASS_RECORD_ROUTE) {
flags = tvb_get_guint8(tvb, offset+l+2);
- if (flags&0x01) proto_item_append_text(ti2, ", Local Protection Available");
- if (flags&0x02) proto_item_append_text(ti2, ", Local Protection In Use");
- if (flags&0x04) proto_item_append_text(ti2, ", Backup BW Avail");
- if (flags&0x08) proto_item_append_text(ti2, ", Backup is Next-Next-Hop");
+ if (flags&0x01) proto_item_append_text(ti2, "The label will be understood if received on any interface");
ti2 = proto_tree_add_text(rsvp_ro_subtree, tvb, offset+l+2, 1,
"Flags: 0x%02x", flags);
rsvp_rro_flags_subtree =
proto_item_add_subtree(ti2, TREE(TT_RECORD_ROUTE_SUBOBJ_FLAGS));
- proto_tree_add_item(rsvp_rro_flags_subtree, hf_rsvp_rro_flags_local_avail,
- tvb, offset+l+2, 1, ENC_BIG_ENDIAN);
- proto_tree_add_item(rsvp_rro_flags_subtree, hf_rsvp_rro_flags_local_in_use,
- tvb, offset+l+2, 1, ENC_BIG_ENDIAN);
- proto_tree_add_item(rsvp_rro_flags_subtree, hf_rsvp_rro_flags_backup_tunnel_bandwidth,
- tvb, offset+l+2, 1, ENC_BIG_ENDIAN);
- proto_tree_add_item(rsvp_rro_flags_subtree, hf_rsvp_rro_flags_backup_tunnel_hop,
+ proto_tree_add_item(rsvp_rro_flags_subtree, hf_rsvp_rro_flags_global_label,
tvb, offset+l+2, 1, ENC_BIG_ENDIAN);
}
proto_tree_add_text(rsvp_ro_subtree, tvb, offset+l+3, 1,
@@ -4397,7 +4390,7 @@ dissect_rsvp_ero_rro_subobjects(proto_tree *ti, proto_tree *rsvp_object_tree,
}
break;
- case 4: /* Unnumbered Interface-ID */
+ case 4: /* Unnumbered Interface-ID RFC 3477, RFC 6107*/
k = tvb_get_guint8(tvb, offset+l) & 0x80;
ti2 = proto_tree_add_text(rsvp_object_tree, tvb,
offset+l, 8,
@@ -4420,8 +4413,6 @@ dissect_rsvp_ero_rro_subobjects(proto_tree *ti, proto_tree *rsvp_object_tree,
flags = tvb_get_guint8(tvb, offset+l+2);
if (flags&0x01) proto_item_append_text(ti2, ", Local Protection Available");
if (flags&0x02) proto_item_append_text(ti2, ", Local Protection In Use");
- if (flags&0x04) proto_item_append_text(ti2, ", Backup BW Avail");
- if (flags&0x08) proto_item_append_text(ti2, ", Backup is Next-Next-Hop");
ti2 = proto_tree_add_text(rsvp_ro_subtree, tvb, offset+l+2, 1,
"Flags: 0x%02x", flags);
rsvp_rro_flags_subtree =
@@ -4430,10 +4421,6 @@ dissect_rsvp_ero_rro_subobjects(proto_tree *ti, proto_tree *rsvp_object_tree,
tvb, offset+l+2, 1, ENC_BIG_ENDIAN);
proto_tree_add_item(rsvp_rro_flags_subtree, hf_rsvp_rro_flags_local_in_use,
tvb, offset+l+2, 1, ENC_BIG_ENDIAN);
- proto_tree_add_item(rsvp_rro_flags_subtree, hf_rsvp_rro_flags_backup_tunnel_bandwidth,
- tvb, offset+l+2, 1, ENC_BIG_ENDIAN);
- proto_tree_add_item(rsvp_rro_flags_subtree, hf_rsvp_rro_flags_backup_tunnel_hop,
- tvb, offset+l+2, 1, ENC_BIG_ENDIAN);
}
proto_tree_add_text(rsvp_ro_subtree, tvb, offset+l+4, 4,
"Router-ID: %s",
@@ -7584,6 +7571,12 @@ proto_register_rsvp(void)
NULL, HFILL }
},
+ {&hf_rsvp_rro_flags_global_label,
+ { "Global label", "rsvp.rro.flags.global_label",
+ FT_BOOLEAN, 8, NULL, 0x01,
+ NULL, HFILL }
+ },
+
{&hf_rsvp_lsp_attr_e2e,
{ "E2E re-routing", "rsvp.lsp_attr.e2e",
FT_BOOLEAN, 32, TFS(&tfs_desired_not_desired), 0x01,