diff options
author | Pau Espin Pedrol <pespin@sysmocom.de> | 2021-03-25 16:35:04 +0100 |
---|---|---|
committer | Pau Espin Pedrol <pespin@sysmocom.de> | 2021-03-25 16:35:07 +0100 |
commit | ce0a0e9beb40540a0d852462172070185d7cb2e6 (patch) | |
tree | e075ee00cb0379ee12bbb841803a411d11f84d45 /src/sgsn/gprs_gmm_attach.c | |
parent | c8ace5a03c60d084735bf14b29f447e30da03924 (diff) |
gmm: Expect E_VLR_ANSWERED when in ST_IU_SECURITY_CMD
GSUP message is sent immediately before moving onto state
ST_IU_SECURITY_CMD, so it's expected to receive a response for it, which
will trigger event E_VLR_ANSWERED being sent.
See following log showing the scenario:
"""
GMM_ATTACH_REQ_FSM(gb_gmm_req)[0x8137b88]{Authenticate}: Received Event E_AUTH_RESP_RECV_SUCCESS
MM(001010123456789/f8bab3dc) Requesting authorization
MM(001010123456789/f8bab3dc) Missing information, requesting subscriber data
MM(001010123456789/f8bab3dc) Requesting subscriber data update
SUBSCR(001010123456789) subscriber data is not available
SUBSCR(001010123456789) Sending GSUP, will send: 04 01 08 00 01 01 21 43 65 60 f3 28 01 01
GMM_ATTACH_REQ_FSM(gb_gmm_req)[0x8137b88]{Authenticate}: state_chg to IuSecurityCommand
SUBSCR(001010123456789) Received GSUP message OSMO_GSUP_MSGT_INSERT_DATA_REQUEST
SUBSCR(001010123456789) Will set PDP info, context id = 1, APN = 01 2a
SUBSCR(001010123456789) Updating subscriber data
MM(001010123456789/f8bab3dc) Subscriber data update
MM(001010123456789/f8bab3dc) Updating authorization (authenticate -> accepted)
MM(001010123456789/f8bab3dc) Got authorization update: state authenticate -> accepted
MM(001010123456789/f8bab3dc) Authorized, continuing procedure, IMSI=001010123456789
GMM_ATTACH_REQ_FSM(gb_gmm_req)[0x8137b88]{IuSecurityCommand}: Received Event E_VLR_ANSWERED
GMM_ATTACH_REQ_FSM(gb_gmm_req)[0x8137b88]{IuSecurityCommand}: Event E_VLR_ANSWERED not permitted
SUBSCR(001010123456789) Sending GSUP, will send: 12 01 08 00 01 01 21 43 65 60 f3 28 01 01
SUBSCR(001010123456789) Received GSUP message OSMO_GSUP_MSGT_UPDATE_LOCATION_RESULT
SUBSCR(001010123456789) Updating subscriber data
MM(001010123456789/f8bab3dc) Subscriber data update
MM(001010123456789/f8bab3dc) Updating authorization (accepted -> accepted)
sccp_sap_up(N-DATA.indication)
N-DATA.ind(2, 20 06 00 08 00 00 01 00 06 00 01 00 )
handle_co(dir=2, proc=6)
Transmitting RANAP CommonID (SCCP conn_id 2)
GMM_ATTACH_REQ_FSM(gb_gmm_req)[0x8137b88]{IuSecurityCommand}: Received Event E_IU_SECURITY_CMD_COMPLETE
GMM_ATTACH_REQ_FSM(gb_gmm_req)[0x8137b88]{IuSecurityCommand}: state_chg to WaitAttachComplete
"""
Related: SYS#5389
Change-Id: If348ff32faa4a709b59ee1b9b043883a7d46cf93
Diffstat (limited to 'src/sgsn/gprs_gmm_attach.c')
-rw-r--r-- | src/sgsn/gprs_gmm_attach.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/sgsn/gprs_gmm_attach.c b/src/sgsn/gprs_gmm_attach.c index c903a016b..629cc53fe 100644 --- a/src/sgsn/gprs_gmm_attach.c +++ b/src/sgsn/gprs_gmm_attach.c @@ -272,6 +272,13 @@ static void st_iu_security_cmd_on_enter(struct osmo_fsm_inst *fi, uint32_t prev_ static void st_iu_security_cmd(struct osmo_fsm_inst *fi, uint32_t event, void *data) { switch(event) { + case E_VLR_ANSWERED: + /* We may receive an event due to rx + * OSMO_GSUP_MSGT_INSERT_DATA_REQUEST here. Do nothing, update of + * subscriber is done by lower layers before event is signalled. + * In this state we simply wait for E_IU_SECURITY_CMD_COMPLETE + */ + break; case E_IU_SECURITY_CMD_COMPLETE: gmm_attach_fsm_state_chg(fi, ST_ACCEPT); break; @@ -308,7 +315,7 @@ static struct osmo_fsm_state gmm_attach_req_fsm_states[] = { .action = st_auth, }, [ST_IU_SECURITY_CMD] = { - .in_event_mask = X(E_IU_SECURITY_CMD_COMPLETE), + .in_event_mask = X(E_IU_SECURITY_CMD_COMPLETE) | X(E_VLR_ANSWERED), .out_state_mask = X(ST_INIT) | X(ST_AUTH) | X(ST_ACCEPT) | X(ST_REJECT), .name = "IuSecurityCommand", .onenter = st_iu_security_cmd_on_enter, |