Commit 073a1b67 authored by heshanyun's avatar heshanyun

deal with Registration Accept

parent 725bfb23
...@@ -468,6 +468,7 @@ rrc_gNB_process_NGAP_INITIAL_CONTEXT_SETUP_REQ( ...@@ -468,6 +468,7 @@ rrc_gNB_process_NGAP_INITIAL_CONTEXT_SETUP_REQ(
PROTOCOL_CTXT_SET_BY_INSTANCE(&ctxt, instance, GNB_FLAG_YES, ue_context_p->ue_context.rnti, 0, 0); PROTOCOL_CTXT_SET_BY_INSTANCE(&ctxt, instance, GNB_FLAG_YES, ue_context_p->ue_context.rnti, 0, 0);
ue_context_p->ue_context.gNB_ue_ngap_id = NGAP_INITIAL_CONTEXT_SETUP_REQ (msg_p).gNB_ue_ngap_id; ue_context_p->ue_context.gNB_ue_ngap_id = NGAP_INITIAL_CONTEXT_SETUP_REQ (msg_p).gNB_ue_ngap_id;
ue_context_p->ue_context.amf_ue_ngap_id = NGAP_INITIAL_CONTEXT_SETUP_REQ (msg_p).amf_ue_ngap_id; ue_context_p->ue_context.amf_ue_ngap_id = NGAP_INITIAL_CONTEXT_SETUP_REQ (msg_p).amf_ue_ngap_id;
ue_context_p->ue_context.nas_pdu_flag = NGAP_INITIAL_CONTEXT_SETUP_REQ (msg_p).nas_pdu_flag;
/* NAS PDU */ /* NAS PDU */
if (ue_context_p->ue_context.nas_pdu_flag == 1) { if (ue_context_p->ue_context.nas_pdu_flag == 1) {
......
...@@ -2199,6 +2199,29 @@ rrc_ue_process_rrcReconfiguration( ...@@ -2199,6 +2199,29 @@ rrc_ue_process_rrcReconfiguration(
for (list_count = 0; list_count < ie->nonCriticalExtension->dedicatedNAS_MessageList->list.count; list_count++) { for (list_count = 0; list_count < ie->nonCriticalExtension->dedicatedNAS_MessageList->list.count; list_count++) {
pdu_length = ie->nonCriticalExtension->dedicatedNAS_MessageList->list.array[list_count]->size; pdu_length = ie->nonCriticalExtension->dedicatedNAS_MessageList->list.array[list_count]->size;
pdu_buffer = ie->nonCriticalExtension->dedicatedNAS_MessageList->list.array[list_count]->buf; pdu_buffer = ie->nonCriticalExtension->dedicatedNAS_MessageList->list.array[list_count]->buf;
#ifdef ITTI_SIM
uint8_t msg_type = 0;
if((pdu_buffer + 1) != NULL){
if (*(pdu_buffer + 1) > 0 ) {
if(pdu_buffer + 9){
msg_type = *(pdu_buffer + 9);
} else {
LOG_W(NR_RRC, "[UE] Received invalid downlink message\n");
return;
}
} else {
if(pdu_buffer + 2){
msg_type = *(pdu_buffer + 2);
} else {
LOG_W(NR_RRC, "[UE] Received invalid downlink message\n");
return;
}
}
}
if(msg_type == REGISTRATION_ACCEPT){
LOG_I(NR_RRC, "[UE] Received REGISTRATION ACCEPT message\n");
}
#endif
msg_p = itti_alloc_new_message(TASK_RRC_UE, NAS_CONN_ESTABLI_CNF); msg_p = itti_alloc_new_message(TASK_RRC_UE, NAS_CONN_ESTABLI_CNF);
NAS_CONN_ESTABLI_CNF(msg_p).errCode = AS_SUCCESS; NAS_CONN_ESTABLI_CNF(msg_p).errCode = AS_SUCCESS;
NAS_CONN_ESTABLI_CNF(msg_p).nasMsg.length = pdu_length; NAS_CONN_ESTABLI_CNF(msg_p).nasMsg.length = pdu_length;
...@@ -2366,7 +2389,7 @@ nr_rrc_ue_decode_dcch( ...@@ -2366,7 +2389,7 @@ nr_rrc_ue_decode_dcch(
LOG_I(NR_RRC, "[UE %d] Received %s: UEid %u, length %u , buffer %p\n", ctxt_pP->module_id, messages_info[NAS_DOWNLINK_DATA_IND].name, LOG_I(NR_RRC, "[UE %d] Received %s: UEid %u, length %u , buffer %p\n", ctxt_pP->module_id, messages_info[NAS_DOWNLINK_DATA_IND].name,
ctxt_pP->module_id, pdu_length, pdu_buffer); ctxt_pP->module_id, pdu_length, pdu_buffer);
as_nas_info_t initialNasMsg; as_nas_info_t initialNasMsg;
uint8_t msg_type; uint8_t msg_type = 0;
memset(&initialNasMsg, 0, sizeof(as_nas_info_t)); memset(&initialNasMsg, 0, sizeof(as_nas_info_t));
if((pdu_buffer + 1) != NULL){ if((pdu_buffer + 1) != NULL){
if (*(pdu_buffer + 1) > 0 ) { if (*(pdu_buffer + 1) > 0 ) {
......
...@@ -26,6 +26,7 @@ ...@@ -26,6 +26,7 @@
#define INTEGRITY_PROTECTED_AND_CIPHERED_WITH_NEW_SECU_CTX 0b0100 // only for SECURITY MODE COMPLETE #define INTEGRITY_PROTECTED_AND_CIPHERED_WITH_NEW_SECU_CTX 0b0100 // only for SECURITY MODE COMPLETE
#define REGISTRATION_REQUEST 0b01000001 /* 65 = 0x41 */ #define REGISTRATION_REQUEST 0b01000001 /* 65 = 0x41 */
#define REGISTRATION_ACCEPT 0b01000010 /* 66 = 0x42 */
#define REGISTRATION_COMPLETE 0b01000011 /* 67 = 0x43 */ #define REGISTRATION_COMPLETE 0b01000011 /* 67 = 0x43 */
#define FGS_AUTHENTICATION_REQUEST 0b01010110 /* 86 = 0x56 */ #define FGS_AUTHENTICATION_REQUEST 0b01010110 /* 86 = 0x56 */
#define FGS_AUTHENTICATION_RESPONSE 0b01010111 /* 87 = 0x57 */ #define FGS_AUTHENTICATION_RESPONSE 0b01010111 /* 87 = 0x57 */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment