https://projects.osmocom.org/https://projects.osmocom.org/favicon.ico?16647414092022-04-26T17:42:36ZOpen Source Mobile CommunicationsOsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=240122022-04-26T17:42:36Zlaforge
<ul></ul><p>See also <a class="external" href="https://github.com/open5gs/open5gs/issues/824">https://github.com/open5gs/open5gs/issues/824</a> for a discussion regarding SBcAP in open5gs</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=241822022-06-14T12:15:37Zpespin
<ul><li><strong>Assignee</strong> changed from <i>laforge</i> to <i>pespin</i></li></ul> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=241872022-06-15T13:08:43Zpespin
<ul></ul><p>AFAICT laforge/cbps several commits where squashed and merged to master in osmo-ttcn3-hacks.git 08332307eac13ae2049d3e8135b34401ad69334e.</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=241882022-06-15T13:12:27Zpespin
<ul></ul><p>Last commit containing SBCAP support (c679d6aed0b50b481b56f49fd5a8836b8fe42417) in laforge/sbcap was not merged at the time. I cherry-picked it on top of current master in pespin/sbcap.</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=241892022-06-15T15:58:52Zpespin
<ul><li><strong>Spec Reference</strong> set to <i>3GPP TS 29.169</i></li></ul><p>The SBcAP seems to be defined in TS 29.169: <a class="external" href="https://www.etsi.org/deliver/etsi_ts/129100_129199/129168/16.00.00_60/ts_129168v160000p.pdf">https://www.etsi.org/deliver/etsi_ts/129100_129199/129168/16.00.00_60/ts_129168v160000p.pdf</a></p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=241902022-06-15T16:45:41Zpespin
<ul></ul><p>I continued adding SBcAP support in TTCN3 in branch osmo-ttcn3-hacks.git "pespin/sbcap".</p>
<p>Similarly, I started working on osmo-cbc SBcAP support in osmo-cbc.git branch "pespin/sbcap".</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=241912022-06-15T17:20:18Zpespin
<ul></ul><p><a class="user active" href="https://projects.osmocom.org/users/7">laforge</a> what is this "ECBE" stuff I see in osmo-cbc?</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=241922022-06-15T17:24:23Zpespin
<ul></ul><p>Is that ECBE the naming you use for the REST interface? I wonder whether I can totally reuse the existing one, I have to modify/extend it or create a whole new one.</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=241932022-06-15T17:53:12Zlaforge
<ul></ul><p>External CBSP Entity (like our naming ESME for SMS or EUSE for USSD)</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=241942022-06-15T17:53:32Zlaforge
<ul></ul><p>Same REST interface, no needfor anything new IMHO</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=241992022-06-16T14:53:54Zpespin
<ul></ul><p>SBc-AP uses ASN.1 APER encoding, which current asn1c we use in other projects such as libosmo-sccp doesn't support.<br />However, that encoding is probably supported in a recent version of as1nc, so the idea is to try to use that one.<br />There's no need to put SBc-AP in some separate lib since we don't plan to use it anywhere else, so it can be put directly in osmo-cbc.git.</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=242332022-06-23T17:25:54Zpespin
<ul><li><strong>Status</strong> changed from <i>New</i> to <i>In Progress</i></li></ul><p>I started adding an internal libosmo-sbcap in osmo-cbc.git (similar to the ones in osmo-iuh.git).</p>
<p>Parsing the SBc-AP spec ASN files fails with asn1c latest release (v0.9.28), but works with asn1c master (9925dbbda86b436896108439ea3e0a31280a6065).</p>
<p>However, it seems asn1c master in upstream (<a class="external" href="https://github.com/vlm/asn1c">https://github.com/vlm/asn1c</a>) still doesn't support APER, which we need for SBc-AP. Fortunately there's a fork of asn1c from one of the big contributors which does support APER:<br /><a class="external" href="https://github.com/vlm/asn1c/issues/452">https://github.com/vlm/asn1c/issues/452</a><br /><a class="external" href="https://github.com/mouse07410/asn1c">https://github.com/mouse07410/asn1c</a><br />That fork should be rebased on top of current master and it seems to receive fixes even in 2022.</p>
<p>So far I'm doing the build with usptream master asn1c with --gen-PER, but we should move to that fork and user APER.</p>
<p>Also another issue:<br />It seems for our old build of asn1c we use for osmo-iuh.git we have a split libasn1c.git containing a runtime library. AFAICT that's done by ourselves and asn1c master doesn't contain that library. Hence, however wants to build osmo-cbc will require asn1c master available, since the skeleton files found in /usr/share/asn1c are required during compilation time of the generated code (asn_ioc.h, asn_application.h, etc.)<br />Not sure what do we want to do here.</p>
<p>WIP available in osmo-cbc.git branch "pespin/sbcap".</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=242342022-06-23T19:10:10Zlaforge
<ul></ul><p>On Thu, Jun 23, 2022 at 05:25:54PM +0000, pespin wrote:</p>
<blockquote>
<p><a class="external" href="https://github.com/mouse07410/asn1c">https://github.com/mouse07410/asn1c</a><br />That fork should be rebased on top of current master and it seems to receive fixes even in 2022.</p>
</blockquote>
<p>I think the mouse07410 only misses 2-3 commits, not sure if it's worth to rebase. I'd try it as-is</p>
<blockquote>
<p>So far I'm doing the build with usptream master asn1c with --gen-PER, but we should move to that fork and user APER.</p>
</blockquote>
<blockquote>
<p>Also another issue:<br />It seems for our old build of asn1c we use for osmo-iuh.git we have a split libasn1c.git containing a runtime library. AFAICT that's done by ourselves and asn1c master doesn't contain that library. Hence, however wants to build osmo-cbc will require asn1c master available, since the skeleton files found in /usr/share/asn1c are required during compilation time of the generated code (asn_ioc.h, asn_application.h, etc.)<br />Not sure what do we want to do here.</p>
</blockquote>
<p>Have the newly generated skeleton files for SBcAP inside a shared library that hides all the symbol to avoid<br />clashes? The shlib should be inside some omso-cbc subdirectory, IMHO.</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=243162022-07-01T15:41:58Zpespin
<ul></ul><p>Status update: In osmo-cbc.git "pespin/sbcap" branch I have a running osmo-cbc linked properly towards SBcAP library with code generated from asn1c master. The asn1c code generation into C code and the C compilation steps are decoupled.<br />The first step requires asn1c and can be re-run using "make -C src/ regen", which copies over all the required C autogenerated files and headers, towards with asn1c support/skeleton files.<br />All those files are included in to the git repository, so that second step (regular "./configure && make") doesn't require asn1c at all.</p>
<p>Next thing to do now is to regen the C files using "make -C src/ regen" with an asn1c compiler built from mouse07410 repo instead of upstream, in order to get APER generation code.</p>
<p>Once that's done, I can continue with the TTCN3 tests by validating RESET/RESTART stuff is being sent in tests.</p>
<p>laforge wrote in <a href="#note-13">#note-13</a>:</p>
<blockquote><blockquote>
<p><a class="external" href="https://github.com/mouse07410/asn1c">https://github.com/mouse07410/asn1c</a><br />That fork should be rebased on top of current master and it seems to receive fixes even in 2022.</p>
</blockquote>
<p>I think the mouse07410 only misses 2-3 commits, not sure if it's worth to rebase. I'd try it as-is</p>
</blockquote>
<p>Agree, I meant something more like "should already be rebased on top of current master" in here :)</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=243232022-07-04T10:48:37Zpespin
<ul><li><strong>Spec Reference</strong> changed from <i>3GPP TS 29.169</i> to <i>3GPP TS 29.168</i></li></ul> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=243242022-07-05T15:27:00Zpespin
<ul></ul><p>I already have generated code from mouse07410 GH repo imported into osmo-cbc. I started doing some tests encoding a SBcAP message but the encoder crashes the process. After debugging for a while I found a bug in the asn1c code generator and submitted a PR here, which fixes the crash:<br /><a class="external" href="https://github.com/mouse07410/asn1c/pull/92">https://github.com/mouse07410/asn1c/pull/92</a></p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=243662022-07-12T19:27:36Zpespin
<ul><li><strong>% Done</strong> changed from <i>20</i> to <i>50</i></li></ul><p>Status update:<br />I have everything in osmo-ttcn3-hacks.git, osmo-cbc.git branch "pespin/sbcap". With what I have there, I already have some TTCN3 CBC_Tests tests passing. I still need to check some IEs in Write-replace-Request</p>
<p>I also submitted a fix for osmo-cbc which I detected while working on SBc-AP with TTCN3, but I think it should also affect CBSP:<br /><a class="external" href="https://gerrit.osmocom.org/c/osmo-cbc/+/28586">https://gerrit.osmocom.org/c/osmo-cbc/+/28586</a></p>
<p>I investigated a couple more bugs in the asn1c APER encoder and submitted here:<br /><a class="external" href="https://github.com/mouse07410/asn1c/pull/96">https://github.com/mouse07410/asn1c/pull/96</a><br /><a class="external" href="https://github.com/mouse07410/asn1c/pull/97">https://github.com/mouse07410/asn1c/pull/97</a></p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=243822022-07-14T16:36:35Zpespin
<ul><li><strong>% Done</strong> changed from <i>50</i> to <i>60</i></li></ul><p>I submitted a bunch of patches for osmo-cbc, osmo-ttcn3-hacks and docker-playground, adding similar level of support for 4G to what we currently have for 2G.</p>
<p>Further requested features can be implemented on top of that work separately.</p>
<p><a class="external" href="https://gerrit.osmocom.org/c/osmo-cbc/+/28600">https://gerrit.osmocom.org/c/osmo-cbc/+/28600</a><br /><a class="external" href="https://gerrit.osmocom.org/c/osmo-cbc/+/28601">https://gerrit.osmocom.org/c/osmo-cbc/+/28601</a><br /><a class="external" href="https://gerrit.osmocom.org/c/osmo-cbc/+/28602">https://gerrit.osmocom.org/c/osmo-cbc/+/28602</a><br /><a class="external" href="https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/28603">https://gerrit.osmocom.org/c/osmo-ttcn3-hacks/+/28603</a><br /><a class="external" href="https://gerrit.osmocom.org/c/docker-playground/+/28604">https://gerrit.osmocom.org/c/docker-playground/+/28604</a></p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=243972022-07-18T12:18:13Zosmith
<ul></ul><p>Packaging related patches for libosmo-sbcap: <a class="external" href="https://gerrit.osmocom.org/q/topic:sbcap-packaging">https://gerrit.osmocom.org/q/topic:sbcap-packaging</a></p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=243982022-07-18T12:19:58Zosmith
<ul></ul><p>Note that the testsuite is currently failing on arm:</p>
<blockquote>
<p>[ 509s] 1. testsuite.at:4: 1. sbcap (testsuite.at:4): FAILED (testsuite.at:7)</p>
</blockquote>
<p><a class="external" href="https://obs.osmocom.org/package/live_build_log/osmocom:nightly/osmo-cbc/Raspbian_10/armv7l">https://obs.osmocom.org/package/live_build_log/osmocom:nightly/osmo-cbc/Raspbian_10/armv7l</a></p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=244002022-07-18T15:42:46Zpespin
<ul></ul><p>osmith wrote in <a href="#note-20">#note-20</a>:</p>
<blockquote>
<p>Note that the testsuite is currently failing on arm:</p>
<blockquote>
<p>[ 509s] 1. testsuite.at:4: 1. sbcap (testsuite.at:4): FAILED (testsuite.at:7)</p>
</blockquote>
<p><a class="external" href="https://obs.osmocom.org/package/live_build_log/osmocom:nightly/osmo-cbc/Raspbian_10/armv7l">https://obs.osmocom.org/package/live_build_log/osmocom:nightly/osmo-cbc/Raspbian_10/armv7l</a></p>
</blockquote>
<p>I'm currently trying to reproduce this building and running manually in rpi4-3 (10.9.25.70), but I couldn't so far.</p>
<p>I submitted a PR fixing tons of formatting errors in 32bit archs (armv7):<br /><a class="external" href="https://github.com/mouse07410/asn1c/pull/101">https://github.com/mouse07410/asn1c/pull/101</a></p>
<p>I also fixed a small issue with printf formats in osmo-cbc itself:<br /><a class="external" href="https://gerrit.osmocom.org/c/osmo-cbc/+/28645">https://gerrit.osmocom.org/c/osmo-cbc/+/28645</a> Fix printf format in 32bit arch</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=244082022-07-19T15:08:40Zpespin
<ul></ul><p>I fixed a regression just introduced by the APER maintainer, which makes the osmo-cbc unit test fail:<br /><a class="external" href="https://github.com/mouse07410/asn1c/pull/104">https://github.com/mouse07410/asn1c/pull/104</a></p>
<p>Once it gets merged, I'll update the asn1c skeleton files in osmo-cbc.git, which should then also contain the 32bit printf format errors. Having these in place will hopefully fix the crashes we see running the unit test in raspbian 10 in OBS.</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=244092022-07-19T15:09:32Zpespin
<ul><li><b>Checklist item</b> <input type='checkbox' class='checklist-checkbox' checked disabled> <i>SBcAP teste cases in TTCN3</i> set to Done</li><li><b>Checklist item</b> <input type='checkbox' class='checklist-checkbox' checked disabled> <i>SBcAP message handling / logic in OsmoCBC</i> set to Done</li></ul> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=244102022-07-19T15:10:34Zpespin
<ul></ul><p>Initial support for SBc-AP has just been merged in osmo-cbc, as well as related TTCN3 improvements to test it.</p>
<p>Next step: Testing osmo-cbc SBc-AP against Amarisoft network.</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=244112022-07-19T15:24:31Zpespin
<ul><li><strong>Status</strong> changed from <i>In Progress</i> to <i>Feedback</i></li><li><strong>Assignee</strong> changed from <i>pespin</i> to <i>laforge</i></li></ul><p>I have been working on running amarisoft network + enodeB (b200) on a debian9 LXC container. I documented the steps here:<br /><a class="external" href="https://projects.sysmocom.de/projects/miscprojects/wiki/Amarisoft_LTE#section-6">https://projects.sysmocom.de/projects/miscprojects/wiki/Amarisoft_LTE#section-6</a></p>
<p>I tried using the newest Amarisoft release available under <em>software-lab</em> shared volume (2021-12-17), but apparently the <em>dongle</em> available contains a license restricting to older versions:<br /><pre>
Your license is too old for this version.
Support and software update available until 2020-03-19.
</pre></p>
<p>So I went on with the newest version supported by the license (2020-01-23). With that, I am at a point where I have the network running and a phone attaching and using 4G data successfully.</p>
<p>Unfortunately, it seems the CBC functionality in amarisoft is not available in 2020-01-23 I'm using. It seems to be available in the latest 2021-12-17 though.</p>
<p>I see "CBC"/"sbc" text in pdf documentation of 2021-12-17 (2021-12-17/ltemme-linux-2021-12-17/doc/ltemme.pdf), it also states there's a "sbc" command in ltemme terminal. But in documentation of 2020-01-23 there's nothing "CBC"/"sbc" related, no "sbc" command in the terminal (just tried), and "ss -lnp" shows nothing on default Sbc-AP port 29168:</p>
<pre>
sbc
Get list of CBC connections.
Response definition:
cbc_list
Array of object. Each object represents a CBC connection:
address
lcs
String. CBC address and port.
</pre>
<pre>
(mme) sbc
Unknown command: sbc
</pre>
<pre>
# ss -lnp | grep ltemme
udp UNCONN 0 0 127.0.1.100:2152 0.0.0.0:* users:(("ltemme",pid=1750,fd=7))
tcp LISTEN 0 5 0.0.0.0:9000 0.0.0.0:* users:(("ltemme",pid=1750,fd=13))
sctp LISTEN 0 5 127.0.1.100:36412 0.0.0.0:* users:(("ltemme",pid=1750,fd=6))
sctp LISTEN 0 5 127.0.1.100:29118 0.0.0.0:* users:(("ltemme",pid=1750,fd=11))
sctp LISTEN 0 5 127.0.1.100:3868 0.0.0.0:* users:(("ltemme",pid=1750,fd=8))
</pre>
<p>BTW, according to config it seems amarisoft sets up SBc-AP as an SCTP server, which means we'll need to configure osmo-cbc as an SCTP client. That should be supported in current code but probably not yet tested.</p>
<p>Assigning to <a class="user active" href="https://projects.osmocom.org/users/7">laforge</a> for him to generate a new dongle with an up to date license.</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=244492022-07-22T15:51:42Zpespin
<ul><li><strong>File</strong> <a href="/attachments/5260">sbcap_osmo-cbc_amarisoft_1st.pcap</a> <a class="icon-only icon-download" title="Download" href="/attachments/download/5260/sbcap_osmo-cbc_amarisoft_1st.pcap">sbcap_osmo-cbc_amarisoft_1st.pcap</a> added</li></ul><p>I have CBSP and SBc-AP TCP/SCTP client mode implemented in osmo-cbc.git branch "pespin/sbcap".</p>
<p>I am currently testing it against an Amarisoft 2022-06-18 ltemme+lteenb.</p>
<p>I used this command to generate a sample CBS message:<br /><pre>
./cbc-apitool.py -H 10.0.3.40 -p 12345 -v create-cbs --msg-id 3 --payload-data-utf8 12345
</pre></p>
<p>I attach the resulting pcap file containing SBc-AP between osmo-cbc and ltemme, and S1AP between ltemme and lteenb.<br />According to ltemme and lteenb everything seems to look good (cause=accepted), but I don't get any notification in the UE attached to the network, I still need to investigate why.</p>
<p>PS: amarisoft ltemme seems to crash everytime I kill the SCTP SBc-AP connection (kill osmo-cbc).</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=244502022-07-22T16:42:26Zpespin
<ul><li><strong>File</strong> <a href="/attachments/5261">sbcap_osmo-cbc_amarisoft_stop.pcap</a> <a class="icon-only icon-download" title="Download" href="/attachments/download/5261/sbcap_osmo-cbc_amarisoft_stop.pcap">sbcap_osmo-cbc_amarisoft_stop.pcap</a> added</li></ul><p>Here's attached an SBc-AP Stop-Warning-Request and its counterpart accepted response osmo-cbc<->ltemme from an ETWS message which was previously generated (not in the pcap).</p>
<p>The Stop-Warning-Request was generated with:<br /><pre>
./cbc-apitool.py -H 10.0.3.40 -p 12345 -v delete --msg-id 4
DELETE http://10.0.3.40:12345/api/ecbe/v1/message/4 (None)
-> <Response [200]>
</pre></p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=244512022-07-22T17:40:12Zpespin
<ul><li><strong>File</strong> <a href="/attachments/5262">sbcap_osmo-cbc_amarisoft_etws_earthquake.pcap</a> <a class="icon-only icon-download" title="Download" href="/attachments/download/5262/sbcap_osmo-cbc_amarisoft_etws_earthquake.pcap">sbcap_osmo-cbc_amarisoft_etws_earthquake.pcap</a> added</li></ul><p>I got the first ETWS Earthquake alert on my phone after some encoding fixes to the Warning-Type IE.</p>
<pre>
$ ./cbc-apitool.py -H 10.0.3.40 -p 12345 -v create-etws --msg-id 4352
POST http://10.0.3.40:12345/api/ecbe/v1/message ({'cbe_name': 'cbc_apitool', 'category': 'normal', 'repetition_period': 5, 'num_of_bcast': 999, 'scope': {'scope_plmn': {}}, 'smscb_message': {'message_id': 4352, 'serial_nr': {'serial_nr_decoded': {'geo_scope': 'plmn_wide', 'msg_code': 768, 'update_nr': 0}}, 'payload': {'payload_etws': {'warning_type': {'warning_type_decoded': 'earthquake'}, 'emergency_user_alert': True, 'popup_on_display': True}}}})
-> <Response [201]>
$ ./cbc-apitool.py -H 10.0.3.40 -p 12345 -v delete --msg-id 4352
DELETE http://10.0.3.40:12345/api/ecbe/v1/message/4352 (None)
-> <Response [200]>
</pre>
<p>TODO: It seems the messages are not deleted properly after I do cbc-apitool delete. It seems to delete properly towards the MME, but I can see them still showing up in vty "show messages" afterwards:<br /><pre>
OsmoCBC# show messages etws
|MsgId|SerNo| CBE Name | Category |Period|E|Warning Type|
|-----|-----|--------------------|-------------|------|-|------------|
| 1100| 7000|cbc_apitool |Normal | 5 |N| 0000|
</pre></p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=244962022-07-25T17:36:17Zpespin
<ul></ul><p>I submitted some patches to gerrit to improve a bit the managament of smscb messages in osmo-cbc VTY.</p>
<p>I did some testing against ltemme+ltemme + android phone and I'd say minimal ETWS functionality to have alerts transmitted is working fine.<br />I'm not sure what's the expected behavior for CBS messages though, I still need to investigate that. Some insight on what/how to test those would be welcome, since I didn't play much with CBS and CBSP yet.</p>
Nexts steps I'd propose would be:
<ul>
<li>Implement the indication flags in Write-Replace Request so that the MME sends us back indications of which ENBs/cells received successfully the message, and handle that in osmo-cbc so that it can be seen in the rows already present in VTY "show message id". ltemme seems to have some configuration options regarding the indication list which may need tweaking, they are listed in the user manhual pdf.</li>
<li>Implement the minimal subset in open5gs-mme to handle SBc-AP and fill in the open5gs structures. From then on, the S1AP part is already implemented AFAICT.</li>
<li>Figure out how the Replace stuff is supposed to work and find out whether it's properly implemented. AFAIU using "--update-nr 1" in cbc-apitool would trigger a different serial_nr which would cause replace of the existing mesage? But it's not working right now:<br /><pre>
20220725173933432 DREST DEBUG /message POST: {"cbe_name": "cbc_apitool", "category": "normal", "repetition_period": 5, "num_of_bcast": 999, "scope": {"scope_plmn": {}}, "smscb_message": {"message_id": 4352, "serial_nr": {"serial_nr_decoded": {"geo_scope": "plmn_wide", "msg_code": 768, "update_nr": 1}}, "payload": {"payload_etws": {"warning_type": {"warning_type_decoded": "earthquake"}, "emergency_user_alert": true, "popup_on_display": true}}}} (/osmo-cbc/src/rest_api.c:571)
...
20220725173933432 DCBSP ERROR Cannot create message_id 4352 (already exists) (/osmo-cbc/src/smscb_message_fsm.c:353)
20220725173933432 DREST DEBUG rest_it_op_complete(op=0x7fb090001730) complete (/osmo-cbc/src/rest_it_op.c:131)
20220725173933432 DREST DEBUG rest_it_op completed with 0 (HTTP 409) (/osmo-cbc/src/rest_it_op.c:71)
20220725173933432 DREST DEBUG /message POST -> 409 (Could not allocate) (/osmo-cbc/src/rest_api.c:589)
</pre></li>
</ul> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=245112022-07-27T15:14:16Zpespin
<ul><li><strong>File</strong> <a href="/attachments/5274">sbcap_osmo-cbc_amarisoft_etws_earthquake_with_indication.pcap</a> <a class="icon-only icon-download" title="Download" href="/attachments/download/5274/sbcap_osmo-cbc_amarisoft_etws_earthquake_with_indication.pcap">sbcap_osmo-cbc_amarisoft_etws_earthquake_with_indication.pcap</a> added</li></ul><p>The crash in ltemme when SBcAP ScTP conn is closed has been fixed in amarisoft release 2022-07-26.</p>
<p>I'm currently testing the Write-Replace-Warning-Indication feature against Amarisoft. I attach a pcap showing the procedure.</p>
<p>The reported cell shows up correctly in VTY:<br /><pre>
OsmoCBC# show messages etws
|MsgId|SerNo| CBE Name | Category |Period|E|Warning Type| Created | Expired |
|-----|-----|--------------------|-------------|------|-|------------|--------------------|--------------------|
| 1100| 7001|cbc_apitool |Normal | 5 |N| 0000|2022-07-27T15:07:46Z|2022-07-27T15:07:57Z|
OsmoCBC# show message id 4352
Message ID 1100, Serial Number 7001, State: DELETED
Created by CBE 'cbc_apitool' at Wed Jul 27 15:07:46 2022
Repetition Period: 5 ( 9.41s), Number of broadcasts: 999
ETWS Warning Type Value: 0x00, User Alert: On, Popup: On
Security: 0000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000
Peer: 'mme-amarisoft', State: DELETED
Cells Installed:
Cells Failed:
Number of Broadcasts Completed:
ECGI 234-70-1715456 (1/1)
</pre></p>
<p>Only the CI is wrong, I decoded it as being 24 bits instead of 28, I'll fix that soon.</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=245152022-07-27T17:59:33Zpespin
<ul></ul><p>I submitted a bunch of patches adding several improvements and fixes, and adding support for Write-Replace-Warning-Indication, so now we see from VTY which cells successfully received or which failed.</p>
TODO:
<ul>
<li>Split smscb_peer_fsm.c into 2 different FSM implementations with same interface: smscb_peer_cbsp_fsm.c and smscb_peer_sbcap_fsm.c</li>
<li>Figure out testing of CBS messages (non-ETWS), how to run test and what to expect as a user (<a class="user active" href="https://projects.osmocom.org/users/7">laforge</a> may be able to provide some feedback here since he probably tested that for CBSP at the time).</li>
<li>Implement the minimal subset in open5gs-mme to handle SBc-AP</li>
<li>Test against open5gs+srsenb (verify first that srsenb actually supports it).</li>
</ul> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=245162022-07-28T11:30:05Zpespin
<ul><li><b>Checklist item</b> <input type='checkbox' class='checklist-checkbox' checked disabled> <i>manual tests with a MME supporting SBcAP</i> set to Done</li><li><strong>Assignee</strong> changed from <i>laforge</i> to <i>pespin</i></li><li><strong>% Done</strong> changed from <i>60</i> to <i>70</i></li></ul><p>pespin wrote in <a href="#note-31">#note-31</a>:</p>
<blockquote>
TODO:
<ul>
<li>Split smscb_peer_fsm.c into 2 different FSM implementations with same interface: smscb_peer_cbsp_fsm.c and smscb_peer_sbcap_fsm.c</li>
</ul>
</blockquote>
<p>Done: <a class="external" href="https://gerrit.osmocom.org/c/osmo-cbc/+/28828">https://gerrit.osmocom.org/c/osmo-cbc/+/28828</a> Split smscb_peer_fsm into CBSP and SBcAP specific FSMs</p>
<blockquote>
<ul>
<li>Figure out testing of CBS messages (non-ETWS), how to run test and what to expect as a user (<a class="user active" href="https://projects.osmocom.org/users/7">laforge</a> may be able to provide some feedback here since he probably tested that for CBSP at the time).</li>
</ul>
</blockquote>
<p>I was able to test this successfully by using msg id "Presidential Alert" (4370). When using it I successfully see the message "Hellooo" displayed at the phone.<br /><pre>
./cbc-apitool.py -H 10.0.3.40 -p 12345 -v create-cbs --msg-id 4370 --update-nr 1 --payload-data-utf8 "Hellooo"
./cbc-apitool.py -H 10.0.3.40 -p 12345 -v delete --msg-id 4370
</pre></p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=245202022-07-28T17:02:38Zpespin
<ul></ul><p>I'm currently improving the TTCN3 tests.</p>
<p>while doing so I found out that I may be missing to build up a target list in Stop-Warning-Request, based on what it was received in Write-Replace-Warning-Indication.<br />This is similarly done by CBSP code, where the KILL uses whatever list was received during Write-Replace Complete message. SBc-AP doesn't receive a list in Write-Replace-Response, instead it has to rely on Write-Replace-Warning-Indication.</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=245212022-07-28T17:08:17Zpespin
<ul></ul><p>pespin wrote in <a href="#note-33">#note-33</a>:</p>
<blockquote>
<p>while doing so I found out that I may be missing to build up a target list in Stop-Warning-Request, based on what it was received in Write-Replace-Warning-Indication.<br />This is similarly done by CBSP code, where the KILL uses whatever list was received during Write-Replace Complete message. SBc-AP doesn't receive a list in Write-Replace-Response, instead it has to rely on Write-Replace-Warning-Indication.</p>
</blockquote>
<p>Actually that may not be a good behavior, since there could be a race condition between the Stop-Warning-Request being sent and new Write-Replace-Indication containing new cells arriving.<br />Furthermore, I think if the initial scope was "plmn" (aka empty list), then it makes sense to also keep sending an empty list when stopping it.</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=245842022-08-05T17:40:39Zpespin
<ul><li><strong>% Done</strong> changed from <i>70</i> to <i>90</i></li></ul><p>I have been considerably improving the TTCN3 CBC_Tests testsuite with new tests and a new infrastructure which also lets make tests with different scenarios rather easy.<br />During the process, I also improved osmo-cbc support in several places as well as fixed bugs in both CBSP and SBc-AP.</p>
<p>I also spotted a CBC feature which is not yet implemented in CBSP nor in SBc-AP: Reload peers with active messages on cells being reported as "restarted". I created a ticket here to track this topic, since it alone can take some time to think about and implement: <a class="issue tracker-2 status-1 priority-2 priority-default" title="Feature: OsmoCBC doesn't yet support reloading cells becoming operational with active messages (New)" href="https://projects.osmocom.org/issues/5641">#5641</a></p>
<p>Right now I consider SBc-AP support to be on par with existing CBSP one, which allows using osmo-cbc as a basic CBC towards both BSC and MMEs. Specific improvements or bugs can be tracked on newly created specific tickets.</p>
I plan to do the following on Monday to wrap up and finish with this task:
<ul>
<li>Get all pending patches in gerrit merged.</li>
<li>Manual test against amarisoft MME to make sure some of my last improvements/fixes didn't break anything there.</li>
<li>Make a new release of osmo-cbc.</li>
</ul> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=245892022-08-08T09:54:34Zpespin
<ul><li><strong>% Done</strong> changed from <i>90</i> to <i>100</i></li></ul><p>I did a last round of successful interop testing against amarisoft ltemme+lteenb.<br />I made a new release of osmo-cbc which contains all the improvements and fixes to support SBc-AP:<br /><a class="external" href="https://gerrit.osmocom.org/c/osmo-cbc/+/28975">https://gerrit.osmocom.org/c/osmo-cbc/+/28975</a></p>
<p>Once merged and the tag is pushed, the ticket can be closed.</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=245902022-08-08T12:01:16Zpespin
<ul><li><strong>Status</strong> changed from <i>Feedback</i> to <i>Resolved</i></li></ul><p>Tag 0.4.0 pushed, closing ticket.</p> OsmoCBC - Feature #4945: SBc/LTE support in OsmoCBChttps://projects.osmocom.org/issues/4945?journal_id=264242023-03-20T20:02:18Zlaforge
<ul></ul><p>Note: Development of this feature was provided by NLnet foundation, see <a class="external" href="https://nlnet.nl/project/OsmoCBC/">https://nlnet.nl/project/OsmoCBC/</a></p>