PSEA - Slight cosmetic changes

parent 24241e1b
...@@ -27,7 +27,8 @@ ...@@ -27,7 +27,8 @@
extern char *baseNetAddress; extern char *baseNetAddress;
void capture_pdu_session_establishment_accept(uint8_t *buffer, uint32_t msg_length){ void capture_pdu_session_establishment_accept_msg(uint8_t *buffer, uint32_t msg_length)
{
uint8_t offset = 0; uint8_t offset = 0;
security_protected_nas_5gs_msg_t sec_nas_hdr; security_protected_nas_5gs_msg_t sec_nas_hdr;
security_protected_plain_nas_5gs_msg_t sec_nas_msg; security_protected_plain_nas_5gs_msg_t sec_nas_msg;
...@@ -52,8 +53,7 @@ void capture_pdu_session_establishment_accept(uint8_t *buffer, uint32_t msg_leng ...@@ -52,8 +53,7 @@ void capture_pdu_session_establishment_accept(uint8_t *buffer, uint32_t msg_leng
psea_msg.ssc_mode = (*(buffer + (offset++)) & 0xf0) >> 4; psea_msg.ssc_mode = (*(buffer + (offset++)) & 0xf0) >> 4;
psea_msg.qos_rules.length = htons(*(uint16_t *)(buffer + offset)); psea_msg.qos_rules.length = htons(*(uint16_t *)(buffer + offset));
offset+=sizeof(psea_msg.qos_rules.length); offset+=sizeof(psea_msg.qos_rules.length);
/* Supports the capture of only one QoS Rule, /* Supports the capture of only one QoS Rule, it should be changed for multiple QoS Rules */
it should be changed for multiple QoS Rules */
qos_rule_t qos_rule; qos_rule_t qos_rule;
qos_rule.id = *(buffer + (offset++)); qos_rule.id = *(buffer + (offset++));
qos_rule.length = htons(*(uint16_t *)(buffer + offset)); qos_rule.length = htons(*(uint16_t *)(buffer + offset));
...@@ -104,7 +104,7 @@ void capture_pdu_session_establishment_accept(uint8_t *buffer, uint32_t msg_leng ...@@ -104,7 +104,7 @@ void capture_pdu_session_establishment_accept(uint8_t *buffer, uint32_t msg_leng
psea_msg.pdu_addr_ie.pdu_addr_oct4 = *(buffer + offset++); psea_msg.pdu_addr_ie.pdu_addr_oct4 = *(buffer + offset++);
nas_getparams(); nas_getparams();
sprintf(baseNetAddress, "%d.%d", psea_msg.pdu_addr_ie.pdu_addr_oct1, psea_msg.pdu_addr_ie.pdu_addr_oct2); sprintf(baseNetAddress, "%d.%d", psea_msg.pdu_addr_ie.pdu_addr_oct1, psea_msg.pdu_addr_ie.pdu_addr_oct2);
nas_config(1,psea_msg.pdu_addr_ie.pdu_addr_oct3, psea_msg.pdu_addr_ie.pdu_addr_oct4, "oaitun_ue"); nas_config(1, psea_msg.pdu_addr_ie.pdu_addr_oct3, psea_msg.pdu_addr_ie.pdu_addr_oct4, "oaitun_ue");
LOG_T(NAS, "PDU SESSION ESTABLISHMENT ACCEPT - Received UE IP: %d.%d.%d.%d\n", LOG_T(NAS, "PDU SESSION ESTABLISHMENT ACCEPT - Received UE IP: %d.%d.%d.%d\n",
psea_msg.pdu_addr_ie.pdu_addr_oct1, psea_msg.pdu_addr_ie.pdu_addr_oct1,
psea_msg.pdu_addr_ie.pdu_addr_oct2, psea_msg.pdu_addr_ie.pdu_addr_oct2,
......
...@@ -157,6 +157,6 @@ typedef struct security_protected_nas_5gs_msg_s { ...@@ -157,6 +157,6 @@ typedef struct security_protected_nas_5gs_msg_s {
uint8_t sqn; /* Sequence Number */ uint8_t sqn; /* Sequence Number */
} security_protected_nas_5gs_msg_t; /* 24.501 Figure 9.1.1.2 */ } security_protected_nas_5gs_msg_t; /* 24.501 Figure 9.1.1.2 */
void capture_pdu_session_establishment_accept(uint8_t *buffer, uint32_t msg_length); void capture_pdu_session_establishment_accept_msg(uint8_t *buffer, uint32_t msg_length);
#endif #endif
\ No newline at end of file
...@@ -909,7 +909,7 @@ void *nas_nrue_task(void *args_p) ...@@ -909,7 +909,7 @@ void *nas_nrue_task(void *args_p)
LOG_I(NAS, "Send NAS_UPLINK_DATA_REQ message(PduSessionEstablishRequest)\n"); LOG_I(NAS, "Send NAS_UPLINK_DATA_REQ message(PduSessionEstablishRequest)\n");
} }
} else if(msg_type == FGS_PDU_SESSION_ESTABLISHMENT_ACC){ } else if(msg_type == FGS_PDU_SESSION_ESTABLISHMENT_ACC){
capture_pdu_session_establishment_accept(pdu_buffer, NAS_CONN_ESTABLI_CNF (msg_p).nasMsg.length); capture_pdu_session_establishment_accept_msg(pdu_buffer, NAS_CONN_ESTABLI_CNF (msg_p).nasMsg.length);
} }
break; break;
......
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