gprs-llc: Don't attempt to decode Dummy UI Command

As explained by 3GPP TS 44.064 Section 6.4.2.2 there are Dummy UI
Commands which are never generated by a LLC entity, but nevertheless
received by a LLC entity.  They are generated by the underlying
network-side RLC/MAC entity a as a means to artificially delay the
release of a downlink TBF.

We introduce a new "llcgprs.dummy_ui" boolean field on which the user
can match to filter our such messages, if needed.

Change-Id: Ie8fcb42cbd66a7e5b77849f0bc5a3630d0d54a9c
Reviewed-on: https://code.wireshark.org/review/22862
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
This commit is contained in:
Harald Welte 2017-07-28 19:23:15 +02:00 committed by Michael Mann
parent c9cb01adbb
commit 38b7660eed
1 changed files with 13 additions and 0 deletions

View File

@ -95,6 +95,7 @@ static int hf_llcgprs_tom_rl = -1;
static int hf_llcgprs_tom_pd = -1;
static int hf_llcgprs_tom_header = -1;
static int hf_llcgprs_tom_data = -1;
static int hf_llcgprs_dummy_ui = -1;
/* Unnumbered Commands and Responses (U Frames) */
#define U_DM 0x01
@ -451,6 +452,8 @@ llc_gprs_dissect_xid(tvbuff_t *tvb, packet_info *pinfo, proto_item *llcgprs_tree
}
}
/* shortest dummy UI command as per TS 44.064 Section 6.4.2.2 */
static const guint8 dummy_ui_cmd[] = { 0x43, 0xc0, 0x01, 0x2b, 0x2b, 0x2b };
static int
dissect_llcgprs(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data _U_)
@ -474,6 +477,12 @@ dissect_llcgprs(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void* data
proto_tree *uinfo_tree = NULL;
gboolean ciphered_ui_frame = FALSE;
if (!tvb_memeql(tvb, 0, dummy_ui_cmd, sizeof(dummy_ui_cmd))) {
proto_tree_add_boolean(tree, hf_llcgprs_dummy_ui, tvb, offset,
tvb_captured_length(tvb), TRUE);
return tvb_captured_length(tvb);
}
col_set_str(pinfo->cinfo, COL_PROTOCOL, "GPRS-LLC");
/* llc_data_length includes the header and the payload */
@ -1305,6 +1314,10 @@ proto_register_llcgprs(void)
{ &hf_llcgprs_tom_data,
{ "TOM Message Capsule Byte", "llcgprs.tomdata", FT_UINT8, BASE_HEX,
NULL, 0xFF, "tdb", HFILL }},
{ &hf_llcgprs_dummy_ui,
{ "Dummy UI Command", "llcgprs.dummy_ui", FT_BOOLEAN, BASE_NONE,
NULL, 0x00, NULL, HFILL }},
};
/* Setup protocol subtree array */