fix PDU Sesion Release response: add missing PDUSessionResourceReleaseResponseTransfer IE
The PDUSessionResourceReleaseResponse message was missing the mandatory pDUSessionResourceReleaseResponseTransfer IE in each released PDU session item. This caused Open5GS to send an error indication. Changes: - Add encode_ngap_pdusession_release_response_transfer() function to properly encode the transfer structure (empty since Secondary RAT Usage Information is optional and not used, per 9.3.4.21) - Always include the mandatory PDUSessionResourceReleasedListRelRes IE - Always encode the pDUSessionResourceReleaseResponseTransfer for each PDU session item - Fix Release Command handler to decode and log Cause from command transfer: instead of incorrectly copying command data to response: the 2 transfer IEs in the Command and the Response messages are different and should not be mixed - Split Command/Response struct type definitions - Add missing includes
This commit is contained in:
@@ -348,7 +348,7 @@ static int trigger_ngap_pdu_session_release(char *buf, int debug, telnet_printfu
|
||||
if (sid < 1 || sid > 255) {
|
||||
ERROR_MSG_RET("Invalid pdusession_id(int): %s (must be between 1 and 255)\n", tokens[i]);
|
||||
}
|
||||
msg->pdusession_release_params[nb_sessions++].pdusession_id = sid;
|
||||
msg->pdusession_ids[nb_sessions++] = sid;
|
||||
}
|
||||
|
||||
msg->nb_pdusessions_torelease = nb_sessions;
|
||||
@@ -356,7 +356,7 @@ static int trigger_ngap_pdu_session_release(char *buf, int debug, telnet_printfu
|
||||
if (prnt) {
|
||||
prnt("Triggering NGAP PDU Session Release for gNB_ue_ngap_id=%d: releasing pdusession_id=%d", gNB_ue_ngap_id);
|
||||
for (int i = 0; i < nb_sessions; ++i) {
|
||||
prnt(" %d,", msg->pdusession_release_params[i].pdusession_id);
|
||||
prnt(" %d,", msg->pdusession_ids[i]);
|
||||
}
|
||||
prnt("\n");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user