aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src
AgeCommit message (Collapse)AuthorFilesLines
2013-11-25mgcp/rtp: Add counter for invalid RTP timestamp deltasJacob Erlbeck3-27/+146
This patch modifies the patch_and_count() function to check for RTP timestamp inconsistencies. It basically checks, whether dTS/dSeqNo remains constant. If this fails, the corresponding counter is incremented. There are four counter for this: Incoming and outgoing, each for streams from the BTS and the net. Note that this approach presumes, that the per RTP packet duration (in samples) remains the same throughout the entire stream. Changing the number of speech frames per channel and packet will be detected as error. In addition, the VTY command 'show mgcp' is extended by an optional 'stats' to show the counter values, too. Ticket: OW#964 Sponsored-by: On-Waves ehf
2013-11-22bsc: Add a VTY command to show the paging group for a BSC/IMSIHolger Hans Peter Freyther1-0/+35
2013-11-21rtp: Fixed size check in padded RTP packetsJacob Erlbeck1-1/+1
This patch fixes a corner case (padding 1, payload size incl padding 0) which is not being detected correctly. Sponsored-by: On-Waves ehf
2013-11-15bsc: Use the right string for the notificationHolger Hans Peter Freyther1-1/+1
2013-11-11ipa: Explain that one needs to get the IP address of the BTS as argumentHolger Hans Peter Freyther1-1/+1
2013-11-03gbproxy: The "[stats]" option was not documented, document itHolger Hans Peter Freyther1-1/+1
Documentation error (missing docs): <command id='show gbproxy [stats]'> <param name='[stats]' doc='(null)' />
2013-11-01bsc/ussd: Rename bsc_send_ussd_notification()Jacob Erlbeck1-5/+6
Rename this function to bsc_send_ussd_no_srv() since it's a rather specialised function and not a generic USSD notification function. Sponsored-by: On-Waves ehf
2013-11-01bsc/ussd: Send faked CM Service Accept before sending USSDJacob Erlbeck1-0/+3
The MS do not show the USSD messages yet. This patch modifies the implementation to insert a CM Service Accept to finish the establishment of the MM connection according to 3GPP TS 04.10/3.2.1 before the USSD notification is sent. This fix has been tested with a Blackberry phone that has shown an ussd_grace_txt after rf_locked has been set to '1'. Without this patch, that message wasn't shown. The phone has sent a CC Setup and other messages before processing the channel release message sent by the BSC, but these messages have not been forwarded to the MSC (as expected). Ticket: OW#957 Sponsored-by: On-Waves ehf
2013-11-01bsc: Move gsm48_tx_mm_serv_ack/rej to gsm_04_08_utils.cJacob Erlbeck2-23/+34
These functions are currently located in libmsc/gsm_04_08.c together with other symbols that (transitively) depend on many external symbols (and thus libraries) that aren't otherwise needed by e.g. osmo-bsc. Since gsm48_tx_mm_serv_ack() will be needed by osmo-bsc, these functions are moved to avoid the dependency on gsm_04_08.o. Sponsored-by: On-Waves ehf
2013-10-31Revert "bsc/ussd: Send faked CM Service Accept before sending USSD"Holger Hans Peter Freyther3-17/+10
This reverts commit 61bd965b04e4f00eaf4196eebb4ec6269926d551. No, we should not link to dbi.. and these libraries..
2013-10-31bsc/ussd: Send faked CM Service Accept before sending USSDJacob Erlbeck3-10/+17
The MS do not show the USSD messages yet. This patch modifies the implementation to insert a CM Service Accept before the ussdNotify to finish the establishment of the MM connection according to 3GPP TS 04.10/3.2.1. This fix has been tested with a Blackberry phone that has shown an ussd_grace_txt after rf_locked has been set to '1'. Without this patch, that message wasn't shown. The phone has sent a CC Setup and other messages before processing the channel release message sent by the BSC, but these messages have not been forwarded to the MSC (as expected). Ticket: OW#957 Sponsored-by: On-Waves ehf
2013-10-30vty: Use vty_install_default() instead of bsc_install_default()Jacob Erlbeck11-63/+18
Remove ournode_exit_cmd, ournode_end_cmd, and bsc_install_default() since this functionality is provided by the current libosmocore. Replace calls to bsc_install_default() by call to vty_install_default() with the following semantic patch: @rule1@ expression N; @@ - bsc_install_default(N); + vty_install_default(N); Ticket: OW#952 Sponsored-by: On-Waves ehf
2013-10-24gbproxy: Fix handling of NSEI changesJacob Erlbeck1-3/+6
The gbproxy looses NSEI changes on BVC_RESET and then tries to send later messages to the wrong (not longer existing) destination. This patch fixes this by updating the peer's nsei field on BVC_RESET. Ticket: OW#874 Sponsored-by: On-Waves ehf
2013-10-24gbproxy: Add test for NSEI and NSVCI changesJacob Erlbeck1-0/+11
This checks the behavior of the gbproxy when the BSS peer changes the NSEI and the NSVCI. It also tests BVC_RESET and other UNITDATA messages after these changes between BSS and SGSN and vice versa (via the gbproxy). Ticket: OW#874 Sponsored-by: On-Waves ehf
2013-10-24gbproxy/vty: Enhance delete-gbproxy-peer commandJacob Erlbeck2-23/+115
This adds the option to delete all BVC peers and/or NS_VC with a given NSEI with a single command. Static (configured) NS-VC are not affected. In addition, all connections for this NSEI that can be deleted by this command can be listed without deleting them by appending 'dry-run' to the command. Sponsored-by: On-Waves ehf
2013-10-24gbproxy: Add a command to delete peers from the GBProxyHolger Hans Peter Freyther2-2/+27
This just deletes the peer entry based on NSEI and BVCI. The NS-VC are not touched.
2013-10-24gbproxy: Fix rate counter group leak in peer_free()Jacob Erlbeck1-0/+1
This also frees the counter group pointed to by peer->ctrg when the peer gets freed. Sponsored-by: On-Waves ehf
2013-10-19gbproxy: Reject SGSN UNITDATA messages with an invalid BVCIJacob Erlbeck1-5/+7
Currently such messages lead to a creation of a new peer with the SGSN's NSEI, which results in echoing the message back to the SGSN. This patch modifies this by sending a STATUS response (invalid BVCI) instead back to the SGSN. Sponsored-by: On-Waves ehf
2013-10-19gbproxy: Test invalid BVCI from SGSNJacob Erlbeck1-1/+35
This adds a test with a UNITDATA SGSN message that is addressed to an invalid (unknown) BVCI. The test shows, that the message is echoed to the SGSN. Sponsored-by: On-Waves ehf
2013-10-19gbproxy: Add global and per peer countersJacob Erlbeck1-6/+165
This adds counters that are incremented when errors are detected. It also modifies the VTY command 'show gbproxy' so that 'show gbproxy stats' shows the counters. Sponsored-by: On-Waves ehf
2013-10-19gbproxy: Fix warning and log messageJacob Erlbeck1-1/+2
Add the unused attribute to peer_free() that isn't used currently. Change 'RAC' to 'NSEI' in the log message, since the latter has been examined before the log message is generated. Sponsored-by: On-Waves ehf
2013-10-15gbproxy: Replace NS-VC references by NSEIJacob Erlbeck2-61/+65
Currently in most places in gb_proxy.c a reference to a NS-VC object is used where the peer is meant instead. The patch changes this by using the NSEI instead in these cases. Sponsored-by: On-Waves ehf
2013-10-15gbproxy: Add test program to test gbproxy message handlingJacob Erlbeck1-0/+23
This program tests the gbproxy implementation by passing NS messages to a modified gbproxy that dumps the resulting messages, signals, and state. It focusses on testing abnormal situations like port changes. Ticket: OW#874 Sponsored-by: On-Waves ehf
2013-10-15ussd: Fix test for RELEASE COMPLETEAlexander Huemer1-1/+1
A correcsponding change in libosmocore sets text[0] to '\0'. The test for 0xFF could never have been true.
2013-10-13db: Remove the struct gsm_network from the database layerHolger Hans Peter Freyther4-13/+27
The database code should not know about the network. Move the setting of the network pointer into the subscriber layer.
2013-10-08abis: Consistent usage of LOGP/DEBUGP for "RSL CONNECT NACK"Alexander Chemeris1-2/+2
2013-10-05nitb: Add "subscriber create" VTY command.Alexander Chemeris1-0/+27
It may be useful in production, but it's really required for VTY testing of subscriber related commands.
2013-10-04sms: Possiqble meamleak fix gsm340_rx_tpdu()Alexander Chemeris1-3/+4
Slight clean up of the code in gsm340_rx_tpdu() and a fix for an unlikely, but possible memory leak there.
2013-10-04Fix typo in console output: "PEROIDOC" -> "PERIODIC".Alexander Chemeris1-1/+1
2013-10-04Fix typo ',' -> ';' at the end of a line.Alexander Chemeris1-1/+1
Funny, this is a correct C expression and doesn't change execution, thus it stayed unnoticed for quite a while.
2013-10-01bsc: Add control command to set timezoneJacob Erlbeck1-0/+114
This adds a per BTS control command 'timezone' which expects a value of the format '<hours>,<mins>,<dst>' or 'off' to set the value of bts->tz. It has the same functionality like the existing VTY command 'timezone' in network/bts. Sponsored-by: On-Waves ehf Ticket: OW#978
2013-09-19smpp: Fix the make distcheck for smppHolger Hans Peter Freyther1-0/+1
DISTCHECK_CONFIGURE_FLAGS="--enable-smpp" make distcheck
2013-09-19bsc/mminfo: Patch timezone and DST in MM Info messagesJacob Erlbeck2-3/+100
This adds in-place patching of the time information in the MM INFORMATION message. The timezone in the 'Local time zone' and the 'Universal time and local time zone' information elements and the offset in the 'Network Daylight Saving Time' information element are optionally set. The new values are determined by the 'timezone' vty command in the config_net_bts node. That command is extended by an optional DST offset parameter. Tests are provided for the vty part and for the plain bsc_scan_msc_msg() function. Sponsored-by: On-Waves ehf Ticket: OW#978
2013-09-18bsc: Add vty command for setting Access control classes.Ivan Kluchnikov1-0/+54
2013-09-16ctrl: Set a generic reply when it hasn'n been setJacob Erlbeck1-1/+9
When verification failed and the reply string was not updated, the message "Someone forgot to fill in the reply." was shown instead of the default "Value failed verification." message. This patch changes the default reply handling in ctrl_cmd_handle() by setting the reply to NULL initially and then checking it at the end. If it hasn't been set, a generic message is assigned and an error is logged.
2013-09-16vty: Cosmetic change to the writing of the bts->modelHolger Hans Peter Freyther1-8/+16
Based on the feedback of Peter from the mailinglist, move the writing code to a new method and return early if there is no bts->model.
2013-09-11ctrl: Remember last 'rf_locked' control commandJacob Erlbeck3-3/+20
This stores the last SET rf_locked control command along with a timestamp. The 'show network' vty command is extended to show this information. Ticket: OW#659
2013-09-11vty: Hide unconfigured BTS on 'write'Jacob Erlbeck1-4/+6
This prevents the application from crashing when there is a half configured BTS (e.g. by using the command 'bts 1' when there isn't a BTS 1) and the 'write' command is used.
2013-09-11ussd: Send USSD on call setup on MSC errorsJacob Erlbeck3-9/+136
Send an USSD message to the mobile station requesting a connection for a call or a SMS when the link to the MSC is down or in the grace period. The messages can be set (and this feature activated) by setting bsc/missing-msc-text resp. msc/bsc-grace-text via the vty. The generation of both messages has been tested manually. Ticket: OW#957
2013-09-04bsc_msc: Fix possible null pointer dereferenceHolger Hans Peter Freyther1-3/+1
In case the allocation of con is failing, do not attempt to print con->name as this will be a null pointer dereference. Fixes: Coverity CID 1076318
2013-09-03nat: Remember the original dest local reference in the parsed structHolger Hans Peter Freyther2-1/+4
In case of the RLSD coming from the MSC we are patching the address in-situ but for local calls set con = NULL. We then answered the RLSD with the wrong reference and the MSC kept on trying.
2013-09-03nat: Fix the log message of the code in case of an allocation failureHolger Hans Peter Freyther1-1/+1
This wrong log message appears to be the result of copy and paste
2013-09-03bsc_msc: Stop the re-connect timer in case the msc is lostHolger Hans Peter Freyther1-0/+1
It was possible to cause a crash by enabling and disabling the MSC connection. The enabling lead to scheduling a connection and the second call was not stopping the timer.
2013-09-03bsc_msc: Add a name field to the MSC Connection to differentiate linksHolger Hans Peter Freyther2-20/+43
Assign a static name to a MSC Connection and use it. In case there are multiple connections we can now more easily identify them. This is only used for the NAT right now, the BSC could start to name the various MSC connections too.
2013-09-02vty: Rename 'mgcp-through-msc-ipa' command to 'use-msc-ipa-for-mgcp'Jacob Erlbeck1-5/+5
Currently the 'mgcp' command fails in the 'config-nat' node, because it get confused with 'mgcp-through-msc-ipa' which is executed instead because of the prefix based command selection. Thus the latter command is renamed by this patch to avoid the common prefix. The workaround in the test suite is removed.
2013-09-02vty: Use generic 'end' and 'exit' commandsJacob Erlbeck11-44/+28
Add bsc_install_default() and replace all install_default() This patch adds bsc_install_default() which calls install_default() and add 'exit' and 'end'. All other calls to install_default() are replaced by calls to bsc_install_default(). Since 'exit' and 'end' are now added automatically to each node, the explicit registrations of these commands are removed by this patch, too. The related tests succeed now without work-arounds (except for the 'config' node itself which is part of libosmocore).
2013-09-02vty: Generalize ournode_exit() and ournode_end()Jacob Erlbeck1-104/+36
ournode_exit() duplicates most of bsc_vty_go_parent(). This patch fixes the inconsistencies of both functions within bsc_vty_go_parent() and replaces the implementation of ournode_exit() by a call to it. This makes 'exit' behave exactly like ^D in all openbsc nodes. ournode_end() has been changed to walk through the intermediate nodes until one of the top nodes is reached. This allows for cleanups to be done on the way. Note that in config mode if the tree is searched along the nodes toward the config node and a command is not found this way, a rollback is done by just replacing the vty's node and index member variable by the saved old values which might break the whole thing, when there has been a free() on the way.
2013-09-02SMPP: add missing VTY parameter 'deliver-src-imsi' for ESMEHarald Welte1-0/+24
the parameter was already used in the code and saved from VTY code, but somehow the functions for parsing it didn't make it into master.
2013-09-02nat: Attempt to follow the MODULE_METHOD pattern for methodsHolger Hans Peter Freyther2-5/+5
Rename methods to be like bsc_ussd_ACTION.
2013-09-02nat: Use bsc_nat_msc_is_connected instead of accessing it directlyHolger Hans Peter Freyther1-2/+2