Commit 31fe819c authored by Raymond Knopp's avatar Raymond Knopp

extra logging

parent f2c5c0f7
...@@ -235,8 +235,8 @@ pdcp_validate_security( ...@@ -235,8 +235,8 @@ pdcp_validate_security(
" Security: failed MAC-I Algo %X UE %"PRIx16" ", " Security: failed MAC-I Algo %X UE %"PRIx16" ",
pdcp_pP->integrityProtAlgorithm, pdcp_pP->integrityProtAlgorithm,
ctxt_pP->rnti); ctxt_pP->rnti);
LOG_E(PDCP, "[OSA][RB %d] %s failed to validate MAC-I of incoming PDU\n", LOG_E(PDCP, "[OSA][RB %d] %s failed to validate MAC-I (key %llx) of incoming PDU\n",
rb_id, (pdcp_pP->is_ue != 0) ? "UE" : "eNB"); rb_id, (pdcp_pP->is_ue != 0) ? "UE" : "eNB",((long long unsigned int*)decrypt_params.key)[0]);
VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_PDCP_VALIDATE_SECURITY, VCD_FUNCTION_OUT); VCD_SIGNAL_DUMPER_DUMP_FUNCTION_BY_NAME(VCD_SIGNAL_DUMPER_FUNCTIONS_PDCP_VALIDATE_SECURITY, VCD_FUNCTION_OUT);
return -1; return -1;
} }
......
...@@ -188,7 +188,7 @@ boolean_t pdcp_is_rx_seq_number_valid(uint16_t seq_num, pdcp_t* pdcp_entity,srb_ ...@@ -188,7 +188,7 @@ boolean_t pdcp_is_rx_seq_number_valid(uint16_t seq_num, pdcp_t* pdcp_entity,srb_
pdcp_entity->next_pdcp_rx_sn_before_integrity = pdcp_entity->next_pdcp_rx_sn; pdcp_entity->next_pdcp_rx_sn_before_integrity = pdcp_entity->next_pdcp_rx_sn;
if (seq_num != pdcp_entity->next_pdcp_rx_sn) { if (seq_num != pdcp_entity->next_pdcp_rx_sn) {
LOG_D(PDCP,"Re-adjusting the sequence number to %d\n", seq_num); LOG_D(PDCP,"Re-adjusting the sequence number to %d from %d\n", seq_num,pdcp_entity->next_pdcp_rx_sn);
} }
//set Next_PDCP_RX_SN to the received PDCP SN +1 ; //set Next_PDCP_RX_SN to the received PDCP SN +1 ;
......
...@@ -176,26 +176,33 @@ int s1ap_eNB_encode_successfull_outcome(S1AP_S1AP_PDU_t *pdu, ...@@ -176,26 +176,33 @@ int s1ap_eNB_encode_successfull_outcome(S1AP_S1AP_PDU_t *pdu,
switch(pdu->choice.successfulOutcome.procedureCode) { switch(pdu->choice.successfulOutcome.procedureCode) {
case S1AP_ProcedureCode_id_InitialContextSetup: case S1AP_ProcedureCode_id_InitialContextSetup:
res = asn_encode_to_new_buffer(NULL, ATS_CANONICAL_XER, &asn_DEF_S1AP_S1AP_PDU, pdu); res = asn_encode_to_new_buffer(NULL, ATS_CANONICAL_XER, &asn_DEF_S1AP_S1AP_PDU, pdu);
message_id = S1AP_INITIAL_CONTEXT_SETUP_LOG; if (res.result.encoded<=0) LOG_E(RRC,"S1AP_ProcedureCode_id_InitialContextSetup: res.result.encoded<=0\n");
message_p = itti_alloc_new_message_sized(TASK_S1AP, message_id, res.result.encoded + sizeof (IttiMsgText)); else {
message_p->ittiMsg.s1ap_initial_context_setup_log.size = res.result.encoded; message_id = S1AP_INITIAL_CONTEXT_SETUP_LOG;
memcpy(&message_p->ittiMsg.s1ap_initial_context_setup_log.text, res.buffer, res.result.encoded); message_p = itti_alloc_new_message_sized(TASK_S1AP, message_id, res.result.encoded + sizeof (IttiMsgText));
itti_send_msg_to_task(TASK_UNKNOWN, INSTANCE_DEFAULT, message_p); message_p->ittiMsg.s1ap_initial_context_setup_log.size = res.result.encoded;
free(res.buffer); memcpy(&message_p->ittiMsg.s1ap_initial_context_setup_log.text, res.buffer, res.result.encoded);
itti_send_msg_to_task(TASK_UNKNOWN, INSTANCE_DEFAULT, message_p);
free(res.buffer);
}
break; break;
case S1AP_ProcedureCode_id_UEContextRelease: case S1AP_ProcedureCode_id_UEContextRelease:
res = asn_encode_to_new_buffer(NULL, ATS_CANONICAL_XER, &asn_DEF_S1AP_S1AP_PDU, pdu); res = asn_encode_to_new_buffer(NULL, ATS_CANONICAL_XER, &asn_DEF_S1AP_S1AP_PDU, pdu);
message_id = S1AP_UE_CONTEXT_RELEASE_COMPLETE_LOG; if (res.result.encoded<=0) LOG_E(RRC,"S1AP_ProcedureCode_id_UEContextRelease: res.result.encoded<=0\n");
message_p = itti_alloc_new_message_sized(TASK_S1AP, message_id, res.result.encoded + sizeof (IttiMsgText)); else {
message_p->ittiMsg.s1ap_ue_context_release_complete_log.size = res.result.encoded; message_id = S1AP_UE_CONTEXT_RELEASE_COMPLETE_LOG;
memcpy(&message_p->ittiMsg.s1ap_ue_context_release_complete_log.text, res.buffer, res.result.encoded); message_p = itti_alloc_new_message_sized(TASK_S1AP, message_id, res.result.encoded + sizeof (IttiMsgText));
itti_send_msg_to_task(TASK_UNKNOWN, INSTANCE_DEFAULT, message_p); message_p->ittiMsg.s1ap_ue_context_release_complete_log.size = res.result.encoded;
free(res.buffer); memcpy(&message_p->ittiMsg.s1ap_ue_context_release_complete_log.text, res.buffer, res.result.encoded);
itti_send_msg_to_task(TASK_UNKNOWN, INSTANCE_DEFAULT, message_p);
free(res.buffer);
}
break; break;
case S1AP_ProcedureCode_id_E_RABSetup: case S1AP_ProcedureCode_id_E_RABSetup:
res = asn_encode_to_new_buffer(NULL, ATS_CANONICAL_XER, &asn_DEF_S1AP_S1AP_PDU, pdu); res = asn_encode_to_new_buffer(NULL, ATS_CANONICAL_XER, &asn_DEF_S1AP_S1AP_PDU, pdu);
AssertFatal(res.result.encoded>0,"res.result.encoded<=0\n");
message_id = S1AP_E_RAB_SETUP_RESPONSE_LOG; message_id = S1AP_E_RAB_SETUP_RESPONSE_LOG;
message_p = itti_alloc_new_message_sized(TASK_S1AP, message_id, res.result.encoded + sizeof (IttiMsgText)); message_p = itti_alloc_new_message_sized(TASK_S1AP, message_id, res.result.encoded + sizeof (IttiMsgText));
message_p->ittiMsg.s1ap_e_rab_setup_response_log.size = res.result.encoded; message_p->ittiMsg.s1ap_e_rab_setup_response_log.size = res.result.encoded;
...@@ -207,24 +214,30 @@ int s1ap_eNB_encode_successfull_outcome(S1AP_S1AP_PDU_t *pdu, ...@@ -207,24 +214,30 @@ int s1ap_eNB_encode_successfull_outcome(S1AP_S1AP_PDU_t *pdu,
case S1AP_ProcedureCode_id_E_RABModify: case S1AP_ProcedureCode_id_E_RABModify:
res = asn_encode_to_new_buffer(NULL, ATS_CANONICAL_XER, &asn_DEF_S1AP_S1AP_PDU, pdu); res = asn_encode_to_new_buffer(NULL, ATS_CANONICAL_XER, &asn_DEF_S1AP_S1AP_PDU, pdu);
message_id = S1AP_E_RAB_MODIFY_RESPONSE_LOG; if (res.result.encoded<=0) LOG_E(RRC,"S1AP_ProcedureCode_id_E_RABModify: res.result.encoded<=0\n");
message_p = itti_alloc_new_message_sized(TASK_S1AP, message_id, res.result.encoded + sizeof (IttiMsgText)); else {
message_p->ittiMsg.s1ap_e_rab_modify_response_log.size = res.result.encoded; message_id = S1AP_E_RAB_MODIFY_RESPONSE_LOG;
memcpy(&message_p->ittiMsg.s1ap_e_rab_modify_response_log.text, res.buffer, res.result.encoded); message_p = itti_alloc_new_message_sized(TASK_S1AP, message_id, res.result.encoded + sizeof (IttiMsgText));
itti_send_msg_to_task(TASK_UNKNOWN, INSTANCE_DEFAULT, message_p); message_p->ittiMsg.s1ap_e_rab_modify_response_log.size = res.result.encoded;
free(res.buffer); memcpy(&message_p->ittiMsg.s1ap_e_rab_modify_response_log.text, res.buffer, res.result.encoded);
S1AP_INFO("E_RABModify successful message\n"); itti_send_msg_to_task(TASK_UNKNOWN, INSTANCE_DEFAULT, message_p);
free(res.buffer);
S1AP_INFO("E_RABModify successful message\n");
}
break; break;
case S1AP_ProcedureCode_id_E_RABRelease: case S1AP_ProcedureCode_id_E_RABRelease:
res = asn_encode_to_new_buffer(NULL, ATS_CANONICAL_XER, &asn_DEF_S1AP_S1AP_PDU, pdu); res = asn_encode_to_new_buffer(NULL, ATS_CANONICAL_XER, &asn_DEF_S1AP_S1AP_PDU, pdu);
message_id = S1AP_E_RAB_RELEASE_RESPONSE_LOG; if (res.result.encoded<=0) LOG_E(RRC,"S1AP_ProcedureCode_id_E_RABRelease: res.result.encoded<=0\n");
message_p = itti_alloc_new_message_sized(TASK_S1AP, message_id, res.result.encoded + sizeof (IttiMsgText)); else {
message_p->ittiMsg.s1ap_e_rab_release_response_log.size = res.result.encoded; message_id = S1AP_E_RAB_RELEASE_RESPONSE_LOG;
memcpy(&message_p->ittiMsg.s1ap_e_rab_release_response_log.text, res.buffer, res.result.encoded); message_p = itti_alloc_new_message_sized(TASK_S1AP, message_id, res.result.encoded + sizeof (IttiMsgText));
itti_send_msg_to_task(TASK_UNKNOWN, INSTANCE_DEFAULT, message_p); message_p->ittiMsg.s1ap_e_rab_release_response_log.size = res.result.encoded;
free(res.buffer); memcpy(&message_p->ittiMsg.s1ap_e_rab_release_response_log.text, res.buffer, res.result.encoded);
S1AP_INFO("E_RAB Release successful message\n"); itti_send_msg_to_task(TASK_UNKNOWN, INSTANCE_DEFAULT, message_p);
free(res.buffer);
S1AP_INFO("E_RAB Release successful message\n");
}
break; break;
default: default:
......
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