osmith has uploaded this change for review.

View Change

msc: CC SETUP MT speech: verify bearer capabilities

Verify that the MSC sends the bearer capability IE from 3GPP TS 24.008 §
D.1.2 for speech in the network to MS direction, instead of allowing
e.g. what osmo-msc master and latest release currently do:

- Filling out radio channel requirement the same way as the MS to
Network direction, which is wrong for the Network to MS direction:
"Bits 6 and 7 are spare bits. The sending side (i.e. the network)
shall set bit 7 to value 0 and bit 6 to value 1." (3GPP TS 24.008
Table 10.5.102)

- Sending a speech list in the Network to MS direction, which seems to
be allowed in theory and MS are supposed to ignore it (end of Table
10.5.103) but causes bugs in some MS in practice. Therefore it is
better to ensure that osmo-msc does not send it (OS#6656).

Implement this in f_mt_call_complete(), which gets used e.g. by
TC_lu_and_mt_call.

Related: osmo-msc I7046e9244fd9d4301ee2c4df1147a619f753739c
Related: OS#6657, OS#6655, OS#6656
Change-Id: I8fd33cf2f7fb8a1c34851ecf54fccddd2efd0536
---
M library/L3_Templates.ttcn
M msc/BSC_ConnectionHandler.ttcn
2 files changed, 26 insertions(+), 3 deletions(-)

git pull ssh://gerrit.osmocom.org:29418/osmo-ttcn3-hacks refs/changes/44/41044/1
diff --git a/library/L3_Templates.ttcn b/library/L3_Templates.ttcn
index 9551845..49aa2c0 100644
--- a/library/L3_Templates.ttcn
+++ b/library/L3_Templates.ttcn
@@ -1382,6 +1382,24 @@
octet7 := omit
}

+/* TS 3GPP 24.008 § D.1.2 */
+template (value) BearerCapability_TLV ts_Bcap_voice_mt := {
+ elementIdentifier := '04'O,
+ lengthIndicator := 1,
+ octet3 := {
+ informationTransferCapability := '000'B,
+ transferMode := '0'B,
+ codingStandard := '0'B,
+ radioChannelRequirement := '01'B, /* spare */
+ extension_octet_3 := '1'B, /* not ext */
+ speech_aux_3a_3b := omit
+ },
+ octet4 := omit,
+ octet5 := omit,
+ octet6 := omit,
+ octet7 := omit
+}
+
/* TS 3GPP 24.008 § 10.5.4.5 */
template (value) BearerCapability_TLV ts_Bcap_csd := {
elementIdentifier := '04'O,
@@ -1960,7 +1978,6 @@
}
}

-
template PDU_ML3_NW_MS tr_ML3_MT_CC_SETUP(integer tid, template hexstring called := *,
template hexstring calling := *,
template BearerCapability_TLV bcap := *) := {
diff --git a/msc/BSC_ConnectionHandler.ttcn b/msc/BSC_ConnectionHandler.ttcn
index 6acaa20..cfe2d53 100644
--- a/msc/BSC_ConnectionHandler.ttcn
+++ b/msc/BSC_ConnectionHandler.ttcn
@@ -1130,8 +1130,14 @@

cpars.got_osmux_count := 0;

- /* MS <- MSC: Expect CC SETUP */
- BSSAP.receive(tr_PDU_DTAP_MT(tr_ML3_MT_CC_SETUP(cpars.transaction_id, *, cpars.called_party)));
+ /* MS <- MSC: Expect CC SETUP with ts_Bcap_voice_mt (OS#6657) */
+ if (Misc_Helpers.f_osmo_repo_is("nightly")) {
+ BSSAP.receive(tr_PDU_DTAP_MT(tr_ML3_MT_CC_SETUP(cpars.transaction_id, *, cpars.called_party, valueof(ts_Bcap_voice_mt))));
+ } else {
+ /* Remove this latest path after osmo-msc >= 1.14.x is released
+ * with I7046e9244fd9d4301ee2c4df1147a619f753739c */
+ BSSAP.receive(tr_PDU_DTAP_MT(tr_ML3_MT_CC_SETUP(cpars.transaction_id, *, cpars.called_party)));
+ }

/* MS -> MSC: ALERTING */
BSSAP.send(ts_PDU_DTAP_MO(ts_ML3_MO_CC_ALERTING(cpars.transaction_id)));

To view, visit change 41044. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-MessageType: newchange
Gerrit-Project: osmo-ttcn3-hacks
Gerrit-Branch: master
Gerrit-Change-Id: I8fd33cf2f7fb8a1c34851ecf54fccddd2efd0536
Gerrit-Change-Number: 41044
Gerrit-PatchSet: 1
Gerrit-Owner: osmith <osmith@sysmocom.de>