aboutsummaryrefslogtreecommitdiffstats
path: root/openbsc/src
AgeCommit message (Collapse)AuthorFilesLines
2016-04-20cscn: enable SMS queue (by removing an '#if 0')Neels Hofmeyr1-2/+0
2016-04-20cscn: enable 'subscriber' vty commands for libmscNeels Hofmeyr2-1/+1
This involves removing the openbsc_vty_print_statistics() from vty_interface_layer3.c, as this would link across the MSC/BSC border.
2016-04-20cn_ranap_handle_co: add error rc and logging for PR OutcomeNeels Hofmeyr1-0/+5
2016-04-20cosmetic: debug and error logging, comment tweaksNeels Hofmeyr5-4/+38
2016-04-20cscn: don't redefine talloc_asn1_ctx from iu.cNeels Hofmeyr1-2/+0
2016-04-20IuCS: more detailed debug log upon IuCS rxNeels Hofmeyr1-2/+9
2016-04-20Add Iu pagingNeels Hofmeyr2-3/+89
Add iu_page_cs() and iu_page_ps() API, also add to libiudummy for linking in tests. Implement msc_paging_request() by calling iu_page_cs().
2016-04-20iu.c: add registry of RNC-Ids in LACsNeels Hofmeyr2-2/+129
Introduce struct gsm_rnc, stored in a global list, static to iu.c. (This list is not part of gsm_network so that the code can be used from both MSC and GPRS code, i.e. both for CS and PS.) Parse RANAP Global RNC Id, add GSM flags to build for gsm48_mcc_mnc_from_bcd() to decode the PLMN Id. Upon every Initial UE message, record/verify RNC Id and LAC for that connection. In case of mismatch, so far just log an error.
2016-04-19iu.c: introduce talloc_iu_ctxNeels Hofmeyr1-3/+6
Introduce talloc_iu_ctx, setup during iu_init() as child of the talloc_ctx passed in by the caller. Allocate ue_conn_ctx from talloc_iu_ctx, used to be from NULL. Allocate osmo_sua_user and talloc_asn1_ctx from talloc_iu_ctx, used to be from the ctx passed in by iu_init() caller.
2016-04-19cosmetic: comment, whitespaceNeels Hofmeyr1-2/+1
2016-04-19iu.h: add iu_link_del()Neels Hofmeyr1-0/+15
2016-04-19Iu RANAP event: add IU_EVENT_LINK_INVALIDATEDNeels Hofmeyr2-2/+3
See in-code comment...
2016-04-19libmsc: Pass KeyStatus to iu_tx_sec_mode_cmdDaniel Willmann1-1/+1
2016-04-19gprs: Activate RABs from RoutingArea update request as wellDaniel Willmann1-8/+9
2016-04-19gprs: Keep track of key negotiation and set the key status flag in sec_mod_cmdDaniel Willmann3-32/+9
2016-04-12gprs: Change auth key for every new Iu connectionDaniel Willmann1-9/+57
2016-04-11cscn: record and use LAC on incoming InitialUE msgNeels Hofmeyr2-7/+31
Add lac argument to gsm0408_rcvmsg_iucs(), to record the LAC in newly allocated gsm_subscriber_connections. In effect, fix the LAC sent to UE during Location Updating Accept message. Before, 0 was stored as LAC and sent to the UE, regardless of the actual LAC in use.
2016-04-11iu.c: check return value of ranap_parse_lai()Neels Hofmeyr1-2/+8
2016-04-08sgsn: Reset mm ctx state in service request and after authorizationDaniel Willmann1-0/+4
2016-04-08sgsn: Don't send the pdp context accept every time the RAB activatesDaniel Willmann1-1/+4
2016-04-08gprs: Save integrity protection status inside ue ctx, not mm ctxDaniel Willmann1-3/+2
2016-04-08gprs: Use different RAB IDs for activationDaniel Willmann3-9/+27
2016-04-08sgsn: Pass RAB ID to iu_rab_act_ps() functionDaniel Willmann3-5/+4
2016-04-05vty l3 help: fix typo 'comamnds'; fix english s/his//Neels Hofmeyr1-5/+5
2016-03-31cosmetic: comments, debug log, msgb alloc nameNeels Hofmeyr1-3/+3
2016-03-31mscsplit: rewire MSC gsm0808_submit_dtap() to msc_tx_dtap()Neels Hofmeyr4-19/+15
2016-03-31Merge branch 'master' into sysmocom/iuNeels Hofmeyr5-25/+35
Conflicts: openbsc/src/libmsc/auth.c openbsc/src/libmsc/gsm_04_08.c openbsc/src/osmo-bsc/osmo_bsc_vty.c openbsc/tests/Makefile.am
2016-03-31Fix MM Auth: zero-initialize auth tuple before first useNeels Hofmeyr1-1/+10
Make sure a new auth tuple is initialized after db_get_lastauthtuple_for_subscr() returns an error, i.e. if no tuple is present for the subscriber yet. Before this patch, the first key_seq depended on the typically uninitialized value that was present in auth tuple's key_seq upon calling auth_get_tuple_for_subscr(). The very first key_seq used for a new subscriber will now always be 0. Before, it used to be mostly 1 ("(0 + 1) % 7"), but depended on whether the key_seq was indeed initialized with 0, actually by random.
2016-03-31Fix MM Auth: disallow key_seq mismatchNeels Hofmeyr1-0/+1
In auth_get_tuple_for_subscr(), add missing condition to match incoming key_seq with stored key_seq, so that re-authentication is requested for mismatching key_seqs. Add test for this issue.
2016-03-31MM Auth: return AUTH_NOT_AVAIL instead of hardcoded zeroNeels Hofmeyr1-4/+4
AUTH_NOT_AVAIL == 0, so this is no functional change.
2016-03-31MM Auth: introduce AUTH_ERROR constant.Neels Hofmeyr1-3/+3
Instead of using hardcoded -1 for errors, include -1 in the enum auth_action type; apply its use. In the mm_auth test, the string output changes from '(internal error)' to 'AUTH_ERROR', since now the proper enum value is used in auth_action_names[].
2016-03-31Add MM Auth test; add auth_action_str() functionNeels Hofmeyr1-0/+9
Add basic MM Authentication test setup, with fake DB access and RAND_bytes(). So far implement simple tests for IO error during DB access and missing auth entry. To print the auth action during tests, add struct auth_action_names and auth_action_str() inline function in auth.[hc].
2016-03-27osmo-bsc: fix compiler warning: store struct in vty->indexNeels Hofmeyr1-2/+2
Don't store an MSC index number in the vty->index void* value. Instead, store the osmo_msc_data struct directly. Thus avoid warnings about differences in int vs void* sizes, and save some index lookups.
2016-03-22comments about incomplete MM cipheringNeels Hofmeyr1-0/+5
2016-03-22cscn: implement integrity protectionNeels Hofmeyr6-9/+152
Upon authentication response, initiate integrity protection for Iu by sending a Security Mode Command (IK), with hardcoded auth tuple so far. Implement RANAP event handling to receive Security Mode Complete message, adding stubs for the other events; in new files osmo-cscn/iucs_ranap.[hc] to keep RANAP dependencies separate, and particularly out of libmsc. Upon receiving Security Mode Complete, call the security operation callback (conn->sec_operation->cb) to complete the Location Update. Introduce enum integrity_protection_state constants to indicate integrity protection, record in gsm_subscriber_conn.iu.integrity_protection. Make subscr_conn_lookup_iu() non-static and declare in iu_cs.h to be able to call from iucs_ranap.c's Security Mode Complete event. Implement dummy iu_tx_sec_mode_cmd() to allow tests to build without RANAP dependencies. In cscn_main.c, call iucs_rx_ranap_event(), to populate the struct gsm_network struct with cscn_network explicitly (don't share cscn_network across compilation scopes because it's ugly).
2016-03-22in gsm8_rx_mm_auth_resp(): call sec_operation.cb() instead of finish_lu() ↵Neels Hofmeyr1-9/+7
directly
2016-03-22fix various compiler warningsNeels Hofmeyr3-2/+5
sgsn_libgtp.c: missing include, for asn1str_to_u32() iu_cs.c: missing include, for subscr_name() osmo_bsc_vty.c: int/pointer conversions (note: this was discussed on the list to be solved by passing a pointer instead. Until then...) iudummy.c: opaque struct declarations
2016-03-22gsm0408_authorize(): remove unused msgb arg, make non-staticNeels Hofmeyr1-3/+3
Prepares for calling from IuCS RANAP events.
2016-03-22iu_tx_sec_mode_cmd(): add send_ck flag parameterNeels Hofmeyr2-7/+10
In this way the caller can distinguish between sending an IK or an IK+CK Security Mode Command.
2016-03-22cosmetic: whitespace, comment, rename static func rx_iu_event()Neels Hofmeyr4-6/+6
2016-03-22fix build: match Iu event cb enum argument type from declarationNeels Hofmeyr3-3/+3
2016-03-21debug log fixesNeels Hofmeyr2-2/+3
gprs_gmm.c: remove extraneous debug print arg. iu_cs.c: increment should not be in debug statement. Fixes at least one coverity warning.
2016-03-18debug: log list of subscribers upon lookupNeels Hofmeyr1-0/+36
2016-03-18iu.c: log conn_id on outgoing messagesNeels Hofmeyr1-1/+2
2016-03-18logging: add DSUA to default_categories[]Neels Hofmeyr1-0/+5
2016-03-18logging: add DRANAP to default_categoriesNeels Hofmeyr1-0/+5
2016-03-18IuCS: fix logical flip in same_ue_conn()Neels Hofmeyr1-1/+1
2016-03-18gprs_gmm: Call gsm48_gmm_authorize from RA upd requestDaniel Willmann1-1/+8
In Iu mode the RA upd request can be called from a new Iu connection so we might need to reauthenticate the connection as well as turn on integrity protection.
2016-03-18cscn: Follow libiu move to generic event handlerDaniel Willmann1-4/+4
2016-03-18libiu: Change gprs_transp_upd_key to be useful for CS as wellDaniel Willmann2-39/+35
gprs_transp_upd_key only sends a security mode command which is needed for CS as well so change it. Make sure it is called after the UE is authenticated in Iu mode.