Age | Commit message (Collapse) | Author | Files | Lines |
|
|
|
Instead of building complex manual byte-wise parsers, we simply use two
strtok_r loops: one iterating over all the lines, the next one
iterating over the invididual space-separated elements in the first line.
The benefit is that we now accept \r, \n or \r\n, or any multiple of
them as line ending. This works around incompliant MGCP implementations
like that of Zynetix MSC.
Addition: mgcp_analyze_header returns 0 when all out parameters have
been set.
Signed-off-by: Holger Hans Peter Freyther <zecke@selfish.org>
|
|
Test parsing some invalid messages and see if we start to crash.
|
|
This code was cleaned up, catch up and rename the method.
|
|
The second test case (CRCX_ZYN) fails as the message is not compliant
with the spec. However, our parer should be more tolerant, just in
case...
|
|
use a data-structure driven approach
|
|
|
|
Internationalize the number like we do it for Call Control. Update
the test result to match this new behavior.
|
|
Introduce number rewriting of SMS-SUBMIT. Introduce a new list,
move code around to help with finding a new number, somehow the
number encoding for TP-DA is borked, 03.40 references 04.11 but
the length appears to be strlen(number) without taken the type
field into account.
|
|
|
|
|
|
gsm_data_shared.h includes e1_input.h of libosmo-abis, add the
LIBOSMOABIS_CFLAGS to Makefile.am, remove AM_LDFLAGS at the same
time as we only build .a archives.
|
|
Match IMSI and destination address against a set of entries, if it
is matching the header will be modified and no sender report will be
requested. Change the test case to request the sender report and then
verify that this bit is reset to 0.
|
|
|
|
SMS went from SAPI=3 to SAPI=0 and nobody notices on the NAT->MSC direction.
|
|
Kill the hacking, use atlocal to remember if the NAT test should
be enabled and then skip the test (exit with 77).
|
|
This reverts commit 41b42c72294d181217bae59e37ddf50c490df17f.
|
|
Paolo says I will need to use atconfig/atlocal, need to read up on
it first though.
|
|
GSM 04.64 8.4.2 asks to ignore UI frames if the DLCI is not known,
or if the "(V(UR)- 32) <= N(U) < V(UR)". E.g. if we want to have
V(UR) == 511 and this frame is dropped, we would ignore N(U)'s
0 to 510. Calculate the delta.
The code is based on Jonathan Santos's "LLC UI window" fix but the
issue was discovered independly.
|
|
The quality of the tests is of different value but it is good to
get started and improve from here.
|
|
|
|
|
|
* Initialize logging
* use a dummy net before calling subcr_put as the keep in ram
option is going to be set.
|
|
* Initialize logging
* The callback expects NULL or a subscriber connection
|
|
|
|
Move the regexp parsing code from the NAT to libcommon as it will
be used by the NAT and BSC code. This also adds the #include <regex.h>
include to gsm_data. This header should be split up.
|
|
This is a big patch that ports openBSC over libosmo-abis.
Sorry, the changes that are included here are all dependent
of libosmo-abis, splitting them into smaller pieces would
leave the repository in some intermediate state, which is
not desired.
The main changes are:
- The directory libabis/ has been removed as it now lives in
libosmo-abis.
- new configuration file format for nanoBTS and HSL femto, we
need to define the virtual e1_line and attach it to the OML
link.
- all the existing BTS drivers (nanoBTS, hsl femto, Nokia site,
BS11 and rbs2000) now use the new libosmo-abis framework.
- use r232 input driver available in libosmo-abis for bs11_config.
- use ipa_msg_recv instead of old ipaccess_read_msg function.
- delete definition of gsm_e1_subslot and input_signal_data.
These structures now lives in libosmo-abis.
Most of this patch are deletions of libabis/ which has been
moved to libosmo-abis.
This patch also modifies openBSC to use all the new definitions
available in libosmocore and libosmo-abis. In order to do that,
we have replaced the following:
- DINP, DMI, DMIB and DMUX by their respective DL* correspondences.
- SS_GLOBAL by SS_L_GLOBAL
- SS_INPUT by SS_L_INPUT
- S_GLOBAL_SHUTDOWN by S_L_GLOBAL_SHUTDOWN
- SS_INPUT by SS_L_INPUT
- S_INP_* by S_L_INP_* sub-signals
- E1INP_NODE by L_E1INP_NODE vty node
This patch has been tested with:
- one nanoBTS
- the HSL femto with the examples available under libosmo-abis
- BS11 with both dahdi and misdn drivers.
|
|
GCC 4.6.0 and LD.BFD 2.21 on ARM somehow fail to resolve
the dbi symbols when we have the library in front of the
static libraries, move them to the back.
Without this patch the tlv_def_patch symbol and the
gsm48_construct_ra.
|
|
GCC 4.6.0 and LD.BFD 2.21 on ARM somehow fail to resolve
the dbi symbols when we have the library in front of the
static libraries, move them to the back.
|
|
Thanks to Konrad Meier
|
|
|
|
Match the used SMSC and the destination of the SMS and change
the SMSC address if both are matched.
|
|
Use the same filtering infrasturcture to patch the SMSC
address in a CP-DATA/RP-DATA message. Add a very simple
testcase for this code.
|
|
Refactor the code to allow having different handlers. The goal
is to be able to patch some SMS messages too.
|
|
The idea that MCC and MNC is enough to classify a subscriber
turns out to be wrong. Certain operatos license a number range
of IMSIs to others. When we see a '^' in the MCC field we treat
it as a regexp. The code now turns the MCC/MNC into a regexp
for the IMSI. It is not using extended POSIX regexp to match
the behavior of the access list.
|
|
Use the libosmocore code to ignore certain signals by
default (e.g. SIGHUP, SIGPIPE) and use the new code to
create a default stderr logging target and initialize
it properly.
|
|
Summary of changes:
s/msg_entry_parse/osmo_config_list_parse/g
s/msg_entry/osmo_config_entry/g
s/msg_entries/osmo_config_list/g
|
|
Summary of changes:
s/bcd2char/osmo_bcd2char/g
s/char2bcd/osmo_char2bcd/g
s/hexparse/osmo_hexparse/g
s/hexdump/osmo_hexdump/g
s/hexdump_nospc/osmo_hexdump_nospc/g
s/ubit_dump/osmo_ubit_dump/g
s/static_assert/osmo_static_assert/g
|
|
Summary of changes:
s/struct bsc_fd/struct osmo_fd/g
s/bsc_register_fd/osmo_fd_register/g
s/bsc_unregister_fd/osmo_fd_unregister/g
s/bsc_select_main/osmo_select_main/g
|
|
The current code tries to find _one_ bsc for a paging message
and then continues. The new code will try to find multiple BSCs
for each LAC. This is done in preparation of having two BSCs
handle the same LAC. This code right now is O(m*n) but it will
be worse once paging groups are landed.
The code to test the function was reduced to just test the lac
lookup code as the other part can not be tested in a standalone
setup anymore.
|
|
This was done with sed on the files.
|
|
If the regexp fails to compile the internal dfa is NULL and a
regexec will crash nicely. Fail and free the string if the regexp
fails to compile.
|
|
In 136f453dd2492b95004461a33c90b11732f33bd8, I forgot to update
the new header path in the test/bsc-nat files (this happened to
me because I forgot to configured openBSC without --enable-nat).
|
|
libosmogsm is a new library that is distributed in the libosmocore.
Now, openbsc depends on it. This patch gets openbsc with this
change.
This patch also rewrites all include path to the new
osmocom/[gsm|core]
Signed-off-by: Pablo Neira Ayuso <pablo@gnumonks.org>
|
|
|
|
|
|
... and make sure tests work again after restructuring
|
|
|
|
|
|
We want to support real trunks in the MGCP code and we need to
have some better book keeping for those. Move the code around.
|