aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc
AgeCommit message (Collapse)AuthorFilesLines
2013-01-15bsc: Auto RF Off in case of missing MSC connectionHolger Hans Peter Freyther5-2/+84
For short IP failures we want the RF to stay up and wait for the re-connect but in case the A-link is gone too long it is good to switch off the RF and wait for commands to enable it again.
2013-01-15nat: Fail if the control interface can not be initializedHolger Hans Peter Freyther1-0/+4
2013-01-15bsc: Create a better error message for when RF commands are rejectedHolger Hans Peter Freyther1-1/+1
Provide an error message that makes it more clear that the command is rejected because RF handling is not enabled in the BSC.
2013-01-15bsc: Simplify the trap sending by using the location state methodHolger Hans Peter Freyther1-17/+2
2013-01-15bsc: Send a TRAP with the locations on a MSC connectionHolger Hans Peter Freyther1-0/+41
Send the current position when the MSC connection is established.
2013-01-15bsc: Use the BSC RF CTRL to change the RF state of the TRXsHolger Hans Peter Freyther3-9/+14
Use the delayed scheduling feature of the osmo_bsc_rf class to avoid crashing the site controller of the nanoBTS.
2013-01-15bsc: Do not re-start the grace timer when we are in the grace periodHolger Hans Peter Freyther1-0/+5
2013-01-15bsc: Introduce an authenticated signal for the MSC connectionHolger Hans Peter Freyther2-0/+5
Send the signal whenever a MSC appears to be authenticated.
2013-01-13sms: Avoid infinite CP-ERROR/CP-ACK loop with sms.Holger Hans Peter Freyther1-0/+12
The issue can be reproduced by typing the following 9 or more times. OpenBSC> subscriber id 2 sms sender id 2 send bla For some unknown reason the phone sends us a CP-ERROR for a transaction identifier we have allocated and used but don't remember. Due the way we use the SMC/SMR we 'establish' the machine and this results in a CP-ACK being sent out. But the CP-ERROR is not having the content we want for an establish so we send out a RP-ERROR. This will result in a CP-ERROR because the phone does not know the transaction... Avoid the issue by checking the direction of the transaction. If we do not know the transaction and it is supposed to be allocated by us then just ignore it and do not create a new transaction.
2013-01-11debug: Fix typo in the debug categoryHolger Hans Peter Freyther1-1/+1
2013-01-11ctrl: Work on the cmd->node instead of the data pointer passedHolger Hans Peter Freyther1-9/+9
Make the macros use the cmd->node instead of the data pointer. The naming of the variable inside the macro already indicates that it should use the nodes data structure.
2013-01-11ctrl: Fix the signature of the string control commandsHolger Hans Peter Freyther1-2/+7
Like with all type unsafe callbacks we will need to cast from void to the dtype. This addresses some compiler warnings. Make it possible to only include the control_cmd.h to use the macros defined in this file.
2013-01-08si: Do not schedule SI1 to SI4 on the second TRXAndreas Eversberg1-3/+5
2013-01-08abis: Fix the verification of BCCH/SDCCH8 on TRX != 0 for the BS11Holger Hans Peter Freyther1-1/+1
The SDCCH8 is only allowed on trx 0 if there is no BCCH/SDCCH4 on it.
2013-01-07audio: Make AMR multirate configurable for the osmo-bscHolger Hans Peter Freyther1-0/+51
Provide VTY options to allow/forbid the usage of a specific multirate option.
2013-01-07audio: Make the BSC handle the new mr_config request of the BSC APIHolger Hans Peter Freyther5-0/+47
Handle the mr_config request and set the AMR multirate config for the given MSC. Initialize the mr_config with the AMR5.9 default we have been using until now.
2013-01-07bsc: Blind fix to deal with phones sending a dialplan of 0Holger Hans Peter Freyther1-2/+2
2013-01-07bsc: Fix crash when the new route is not availableHolger Hans Peter Freyther1-1/+1
When we are asked to route calls on a local link and the link is not available we would crash when trying to send a packet over a deadline. When we have decided to move a connection it is guranteed that the current SCCP connection will vanish, we either migrate to another MSC or the RSL/subscriber connection will be closed.
2013-01-07bsc: Add VTY code for the local area prefixHolger Hans Peter Freyther1-0/+20
2013-01-07bsc: Inspect a CC Setup message and attempt to reroute the trafficHolger Hans Peter Freyther2-3/+120
Inspect the CC Setup messages and if the dialed number is matching the regexp of the local MSC the connection will be rerouted. The original MSC will get a GSM0808 CLEAR REQUEST, a new connection with a CC Setup message will be opened.
2013-01-07nat: Send a CM Service Reject for NAT_CON_TYPE_SSA as wellHolger Hans Peter Freyther1-1/+1
For USSD we remember that it is a supplementary service but this means we sent no CM Service Reject down to the subscriber. Treat NAT_CON_TYPE_CM_SERV_REQ and NAT_CON_TYPE_SSA the same and send a cm service reject.
2013-01-07nat: Introduce a global IMSI barr list using red-black treesHolger Hans Peter Freyther9-16/+288
2013-01-07nat: Simplify the code and call auth_imsi from the main methodHolger Hans Peter Freyther1-24/+29
Do the auth check in bsc_nat_filter_sccp_cr, remove the cause from the signature again. For the bsc_nat_filter_dt restructure the flow but leave the auth inside the id response message. Return 1 when the IMSI has been extracted as indicator for running the auth check. 1 has not been used before and is safe to be used as this indicator.
2013-01-07nat: Get the cause into the imsi_auth method in preparationHolger Hans Peter Freyther1-13/+19
For the new barr feature get the cause struct down to the imsi_auth code so we can add the blacklist there.
2013-01-07nat: Allow the filter to select the reject causeHolger Hans Peter Freyther4-23/+49
In preparation for another kind of black-list allow the filter code to decide how the connection should be rejected. Introduce a new struct that will carry the reject causes for certain operations.
2013-01-07nat: Move the IMSI/TMSI filtering to a new and dedicated fileHolger Hans Peter Freyther4-282/+323
Move all routines related to filtering to a separate file.
2013-01-07nat: Fix a typo in the log message for out of memoryHolger Hans Peter Freyther1-1/+1
2013-01-07nat: Extract the message re-writing from the utils to a dedicated fileHolger Hans Peter Freyther4-590/+630
Move the code around to make it more clear what the routines should do.
2013-01-01Revert "libbsc: With the new SAPI states we don't need sacch_deact anymore"Holger Hans Peter Freyther1-0/+1
For now we need to keep the sacch_deact in OpenBSC as we couldn't get the new activation/de-activation code working. This reverts commit 0c282f52684ac033e20ab411ab206e8559d564c9.
2013-01-01osmo-nitb: Add a timer to regularly expireJan Luebbe1-0/+12
2013-01-01libmsc: Track and update the location update expiryJan Luebbe5-6/+138
Set the subscriber expiry timeout to twice the duration of the location update period and provide functions subscr_expire() and db_subscriber_expire() to mark subscribers offline that have missed two location update periods. This patch increases the DB revision to 3, so the hlr will be incompatible with prior versions. We should allow 0 for T3212 as well to disable the location update period. In that case we will need a way to indicate that in the database.
2013-01-01Stricter limits for T3212 (location update period)Daniel Willmann2-4/+4
libcommon: Default to 30min location update period libbsc: Limit VTY value for periodic update and disallow the value 0 According to GSM 04.08 Table 10.5.33 "The value 0 is used for infinite timeout value i.e. periodic updating shall not be used within the cell." This was the default value until now, but the code that deals with expiring inactive subscribers in the next commit can't handle that case so this remains a TODO for now.
2013-01-01misc: Do not use else when using return in the previous branchHolger Hans Peter Freyther1-1/+1
2013-01-01libbsc: Make argument optional in some 'show' commandsSylvain Munaut1-6/+6
The actual command implementation was already for this, but some bad vty parsing prevented optional range arguments from working properly. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2013-01-01libmsc: Allow to set sender id when sending SMS from the VTYSylvain Munaut4-17/+55
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2013-01-01libmsc: Refuse service to anyone not attachedSylvain Munaut1-0/+4
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2012-12-29gsm_04_08: Display debug message correctly on DETACH INDICATIONdaniel/channel-ho-wipDaniel Willmann1-3/+5
Log messages would get mangled before if we receive detach by TMSI or IMSI.
2012-12-29libbsc: With the new SAPI states we don't need sacch_deact anymoreDaniel Willmann2-2/+0
2012-12-29gsm_data_shared.h: Keep a list of SAPI states per lchanDaniel Willmann1-0/+13
2012-12-26libmsc: One of assign_compl and assign_fail will always be calledHolger Hans Peter Freyther1-12/+0
Remove the log messages and comments as they are wrong for now. Even for the mode modify we will get the assign complete call.
2012-12-26tests: Don't delete atconfig in cleanDaniel Willmann1-1/+1
This file is created in ./configure so we shouldn't remove it with make. Otherwise ./configure && make clean && make check fails with: make[3]: *** No rule to make target `atconfig', needed by `check-local'. Stop.
2012-12-26abis_test: Fix the test case and calculate the right offsetHolger Hans Peter Freyther2-4/+4
We parse the load_config, take the ptrdiff_t from start and load_config and from the previous array as the alignment can differ on different ABIs. This was found by Daniel when executing the tests on a 64 bit userspace.
2012-12-26handover: Fix the handover signalling for IP based BTSesHolger Hans Peter Freyther5-49/+36
This was reported by Kevin when he was testing handover. The problem is the order of the signal handlers for S_ABISIP_CRCX_ACK. Right now the handover signal handler is called before the one inside the libmsc gsm_04_08.c. This means S_HANDOVER_ACK is signalled _before_ there is a rtp socket created for the channel. The result is that the MDCX will never be sent and the called will not be properly switched _after_ the handover detection. I do not want to play with the order of signal handlers, remove the CRCX ack handling from the handover_logic.c and force the NITB (and later the BSC) to check if the lchan is involved with a handover and do the switching in there. This means right now we do what two signal handlers did in one. Reproduced and tested with the FakeBTS Handover test. Log message: <0004> abis_rsl.c:1954 (bts=1,trx=0,ts=3,ss=0) IPAC_CRCX_ACK ... <000c> gsm_04_08.c:1400 no RTP socket for new_lchan <001a> rtp_proxy.c:533 rtp_socket_create(): success <001a> rtp_proxy.c:615 rtp_socket_bind(rs=0x48703c8, IP=0.0.0.0): ...
2012-12-26gsm: Do not attempt to release SAPI=0 if it was never allocatedHolger Hans Peter Freyther3-0/+26
In case of handover (but probably on RACH) we would send a RLL for SAPI=0 even if this SAPI was never established. After we have released all SAPI>0 locally check that SAPI=0 is established and if not release the rf channel directly.
2012-12-26libbsc: Fix DL QUAL decoding from measurement reportsSylvain Munaut1-2/+2
Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
2012-12-25gsm_subscriber: change subscr_bsc_active_subscriber to pluralJan Luebbe2-10/+10
This was requested by Holger Freyther <zecke@selfish.org>.
2012-12-25nitb: Add a VTY command to initiate a handover to another BTSHolger Hans Peter Freyther1-0/+53
2012-12-23lchan: Introduce T3109 handling for the release procedureHolger Hans Peter Freyther12-24/+63
T3109 is started when the SACCH is deactivated. It is stopped when the phones sends the DISC/UA/UM on LAPDm for the main signalling link. In case of timeout the abnormal release procedure will be initiated. Make sure to not issue the SACCH Deactivate twice to avoid confusing the equipment. This is still not fully spec compliant. In case of a timeout the abnormal release handling will be started which involves starting T3111+2. The error handling should be split out of the rf channel release method, e.g. lchan_release should be called and check if the channel release was already initiated.
2012-12-23lchan: Introduce a BROKEN state for the lchanHolger Hans Peter Freyther3-4/+6
If the CHAN ACTIV is NACKED we set the state backto NONE. This is problematic as our channel allocator will allocate from the front or from the back and if the channel is early in the list it might cause permanent failures. Introduce a BROKEN state and use it when the channel activation is failing for an unknown reason. Copy the cause so it can be inspected later.
2012-12-23lchan: Document the behavior/quirks for abnormal channel releaseHolger Hans Peter Freyther1-5/+29
Deactivate the SACCH and release all SAPIs locally as of GSM 04.08. Add documentation to the code and explain what will happen as part of the release process.