USSD: fix handling of ussd-DataCodingScheme != 0x0f

The usual Data Coding Scheme value in the mobile-originated USSD
request (processUnstructuredSS-Request) is 0x0f, which means:

  0000 .... = Coding Group: Coding Group 0 (Language using the GSM 7 bit default alphabet)
  .... 1111 = Language: unspecified

However some modems are known to use a different default value, if
not specified explicitly (AT+CUSD has optional DCS parameter):

  0000 .... = Coding Group: Coding Group 0 (Language using the GSM 7 bit default alphabet)
  .... 0000 = Language: German (0)

In function rx_proc_ss_req(), we should not be using req.ussd_text,
because this field has been deprecated and may contain unexpected
data.  For example, in the abovementioned case it would contain the
7 bit encoded ussd-String 'aa510c061b01'O and osmo-hlr would indeed
fail to find a matching route for a non-ASCII string.

Instead of relaying on gsm0480_parse_facility_ie(), let's check the
Data Coding Scheme value and decode the request string ourselves.
Expect the Coding Group 0, but be more tolerant to the indicated
language: print a warning and treat it as '1111'B (unspecified).

Change-Id: Ib7bac660b1a7942adcfbe7b14f162c95061a25db
Related: OS#6075
1 file changed
tree: 395f7e8d01011c5c4384b852a7da067c1e9b824b
  1. contrib/
  2. debian/
  3. doc/
  4. include/
  5. sql/
  6. src/
  7. tests/
  8. .gitignore
  9. .gitreview
  10. configure.ac
  11. COPYING
  12. git-version-gen
  13. libosmo-gsup-client.pc.in
  14. libosmo-mslookup.pc.in
  15. Makefile.am
  16. README.md
  17. TODO-RELEASE
README.md

osmo-hlr - Osmocom HLR Implementation

This repository contains a C-language implementation of a GSM Home Location Register (HLR). It is part of the Osmocom Open Source Mobile Communications project.

Warning: While the HLR logical functionality is implemented, OsmoHLR does not use the ETSI/3GPP TCAP/MAP protocol stack. Instead, a much simpler custom protocol (GSUP) is used. This means, OsmoHLR is of no use outside the context of an Osmocom core network. You can use it with OsmoMSC, OsmoSGSN etc. - but not with third party components.

Homepage

The official homepage of the project is https://osmocom.org/projects/osmo-hlr/wiki

GIT Repository

You can clone from the official osmo-hlr.git repository using

git clone https://gitea.osmocom.org/cellular-infrastructure/osmo-hlr

There is a web interface at https://gitea.osmocom.org/cellular-infrastructure/osmo-hlr

Documentation

User Manuals and VTY reference manuals are [optionally] built in PDF form as part of the build process.

Pre-rendered PDF version of the current "master" can be found at User Manual as well as the VTY reference manuals

Mailing List

Discussions related to osmo-hlr are happening on the openbsc@lists.osmocom.org mailing list, please see https://lists.osmocom.org/mailman/listinfo/openbsc for subscription options and the list archive.

Please observe the Osmocom Mailing List Rules when posting.

Contributing

Our coding standards are described at https://osmocom.org/projects/cellular-infrastructure/wiki/Coding_standards

We us a gerrit based patch submission/review process for managing contributions. Please see https://osmocom.org/projects/cellular-infrastructure/wiki/Gerrit for more details

The current patch queue for osmo-hlr can be seen at https://gerrit.osmocom.org/#/q/project:osmo-hlr+status:open