aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHarald Welte <laforge@osmocom.org>2020-08-20 21:45:09 +0200
committerAnders Broman <a.broman58@gmail.com>2020-08-21 05:11:34 +0000
commite7116cca75937d96d5795340388a519ee8e6f882 (patch)
treee4eaae471f3721ae36c8e9ed70983009d63d7eb5
parent217a92981b04de74051b243ac6c8eea32f44b848 (diff)
packet-fr: Treat DLCI=0 as Q.933 LMI if GPRS-NS is selected
3GPP TS 48.016 specifies GPRS-NS over Frame Reley. In Section 6.1.1 it explicitly states that ITU-T Q.933 Annex A for FR PVC must be supported. In real-world Gb-over-FR protocol traces I also see related LMI messages on DLCI=0. Hence, let's not dispatch DLCI=0 messages to the GPRS-NS dissector, where they are all detected wrongly. Only non-zero DLCI are NS-VC. Change-Id: I6ce3557cda0da31323a851008bf648047ba1f926 Reviewed-on: https://code.wireshark.org/review/38211 Petri-Dish: Anders Broman <a.broman58@gmail.com> Tested-by: Petri Dish Buildbot Reviewed-by: Anders Broman <a.broman58@gmail.com>
-rw-r--r--epan/dissectors/packet-fr.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/epan/dissectors/packet-fr.c b/epan/dissectors/packet-fr.c
index b4ed470202..6a1768ca45 100644
--- a/epan/dissectors/packet-fr.c
+++ b/epan/dissectors/packet-fr.c
@@ -680,8 +680,18 @@ dissect_fr_common(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree,
break;
case GPRS_NS:
- next_tvb = tvb_new_subset_remaining(tvb, offset);
- call_dissector(gprs_ns_handle, next_tvb, pinfo, tree);
+ if (addr == 0) {
+ fr_ctrl = tvb_get_guint8(tvb, offset);
+ control = dissect_xdlc_control(tvb, offset, pinfo, fr_tree,
+ hf_fr_control, ett_fr_control,
+ &fr_cf_items, &fr_cf_items_ext,
+ NULL, NULL, is_response, TRUE, TRUE);
+ offset += XDLC_CONTROL_LEN(control, TRUE);
+ dissect_fr_nlpid(tvb, offset, pinfo, tree, ti, fr_tree, fr_ctrl);
+ } else {
+ next_tvb = tvb_new_subset_remaining(tvb, offset);
+ call_dissector(gprs_ns_handle, next_tvb, pinfo, tree);
+ }
break;
case RAW_ETHER: