Feature #1846

Implement AoverIP specific procedures, message extensions and information elements

Added by laforge 5 months ago. Updated about 9 hours ago.

In Progress
Start date:
Due date:
% Done:


Spec Reference:


AoIP introduces a variety of new RSL information elements that extend the classic BSS[M]AP messages in several ways, for example to carry RTP IP/port identification rather than TDM circuit identifier codes. Or to indicate MSC/BSC codec capabilities.

We'll need to implement those new information elements (parsing/encoding/testcases) and implement their handling in osmo-bsc (and most likely osmo-msc, too)

notes.txt Magnifier (11.6 KB) dexter, 03/21/2017 10:40 PM

messages_we_use.txt Magnifier (6.5 KB) dexter, 03/24/2017 06:28 PM


#1 Updated by laforge 5 months ago

#2 Updated by neels 2 months ago

  • Description updated (diff)

#3 Updated by laforge about 2 months ago

  • Assignee set to dexter

#4 Updated by laforge about 1 month ago

Background info on 3GPP AoIP

#5 Updated by dexter about 1 month ago

  • File notes.txtMagnifier added
  • Status changed from New to In Progress

I have reviewed the change requests and created an overview to point out where messages had changed. See the attached file. Each line marked with a # indicates that there is a change that directly affects the message type (by adding/changing codings or adding elements).

#6 Updated by dexter about 1 month ago

I have now reviewed the source code. When I get things correct, the following messages types have to be updated:

+ASSIGNMENT REQUEST        (BSS_MAP_MSG_ASSIGMENT_RQST, rx only, osmo_bsc_bssap.c)
+ASSIGNMENT COMPLETE        (BSS_MAP_MSG_ASSIGMENT_COMPLETE, gsm0808_create_assignment_completed())        test exists
+ASSIGNMENT FAILURE        (BSS_MAP_MSG_ASSIGMENT_FAILURE, gsm0808_create_assignment_failure())        test exists
+COMPLETE LAYER 3 INFORMATION    (BSS_MAP_MSG_COMPLETE_LAYER_3, gsm0808_create_layer3())                test exists

(+ means, message needs to be patched)

#7 Updated by dexter about 1 month ago

We have now an encoder / decoder plus tests for "AoIP Transport Layer Address" and an encoder for "Speech Codec Element". (see also libosmocore.git pmaier/aoip)

When I get the osmo-bsc / libosmocore code and the spec right. Then we only need the following additional fields for the BSC case:
AoIP Transport Layer Address (MGW)
Codec List (MSC Preferred)
Call Identifier

Judging by the messages osmo-bsc can unsterstand, we would need generator functions for the following messages:

(I have attached some of my notes with some more details about what is missing)

#8 Updated by dexter about 1 month ago

  • % Done changed from 10 to 20

Finished the implementation and the tests for the Codec List message element. Also started the integration. ASSIGNMENT COMPLETE, ASSIGNMENT FAILURE and COMPLETE LAYER 3 INFORMATION can now handle the Codec List field.

See also branch: pmaier/aoip

#9 Updated by dexter 29 days ago

  • % Done changed from 20 to 30

The create functions of the messages which are relevant in the bsc role are now extended and we should be able to send AoIP messages by now. Also added encoding/decoding for two more elements: gsm0808_channel_type (needed for ASSIGNMENT REQUEST). And gsm0808_encrypt_info (needed for BSS_MAP_MSG_CIPHER_MODE_CMD). The encoding function of these two will be needed to for the create functions that generate the MSC messages. The decoding will replace the hacks in osmo_bsc_bssap.c.

We still lack the GSM0808_IE_CELL_IDENTIFIER_LIST element. Once we have that, we can implement the missing create functions for the MSC role.

#10 Updated by dexter 28 days ago

  • % Done changed from 30 to 40

We can now handle GSM0808_IE_CELL_IDENTIFIER_LIST, to the extend which we need (whole BSS, or by a list of LACs). All other schemes are not yet supported (our BSC can't handle them anyway), but we can upgrade any time, if needed.

We are also now ready to generate BSS_MAP_MSG_PAGING and BSS_MAP_MSG_CIPHER_MODE_CMD messages. We still miss the support for BSS_MAP_MSG_ASSIGMENT_RQST, but I think I will finish this one during the day tomorrow. After that we are ready to make some changes to the BSC code. In my opinion we should first get rid of the decoding hacks, since we now have proper decoding utilities, we should use them.

#11 Updated by dexter 27 days ago

We now also can generate the assignment request. I have sent the patches now into the review process: gsm0808: Add utils for Speech Codec List and Speech Codec gsm0808: Add AoIP specific elements to gsm0808_create_... functions gsm0808: Add utils for Channel Type gsm0808: Add utils for Encryption Information gsm0808: Add utils for Cell Identifier List gsm0808: Add create functions for CIPHER MODE COMMAND gsm0808: Add create functions for BSS_MAP_MSG_PAGING gsm0808: Add create functions for BSS_MAP_MSG_ASSIGMENT_RQST

#12 Updated by dexter 17 days ago

Started the integration of libosmo-sigtran into omso-bsc. To get a starting point I disabled the existing sccp-line code pathes and started to build up the interfaces for libosmo-sigtran next to it. When done, we can remove the no longer needed code.

There are some things where I am not sure if they can be removed, or if they have to work with the new code as well. There is this filter mechanism that seems to filter out unauthenticated connections. I think that will be handled directly by libosmo-sigtran in the future.

We also seem to have this strange feature that the BSC can be simultaniously connected to multipls MSC. To my understanding, this is not 100% standard conform. But since the infrastructure for this is now everywhere in the code. I think its easier when we just keep it.

For osmo-msc, I have started with some dummy MSC code to try out the BSSAP side on the MSC side. So far, the exchange of the RESET command is working fine. I can also make connections and can see the location update passing along together with CC and L3 Complete. It is not yet answered by my code, but It shows that most basic things are working. So we now should move on with integrating the dummy code into osmo-msc and see what happens when we forward the Location update into the MSC.

#13 Updated by dexter 14 days ago

For osmo-bsc the most basic things should be done. We can connect to an msc and we can disconnect again. Connection contexts are created when the connection is opened and freed again when the connection closes. However. The mgcp side needs some attention now, but first some basic things like location update, imsi-detach and paging should work.

Started to integrate AoIP into osmo-msc. I have put my msc-dummy code into a_iface.c. The code does the reset handshake with the MSC and can receive Layer 3 complete messages. The code extracts the cell ID element and the Layer3 data element. I have tried to forward the code into the MSC, but I get a segfault (function bssmap_handle_l3_compl(), line rc = msc_compl_l3(conn, dtap_msg, 0);) here. Probably I am doing it wrong or something is not initialized properly.

Branches in openbsc.git:

#14 Updated by dexter about 9 hours ago

  • % Done changed from 40 to 50

Apart from some AoIP messages that are still missing, the overall message passing between MSC and BSC works fine. Location update (without encryption!) works fine. I can attach phones and detach them again. Also the classmark change is already implemented.

The handling for the following messages is still missing:
BSS_MAP_MSG_CIPHER_MODE_COMPLETE (My guess is that I will have to detect the cipher mode command in the DTAP payload and then encapsulate it accordingly)

Branches in openbsc.git:

Also available in: Atom PDF