Loading captures/TC_NGAP_AMF_PDU_02.pcap +11.4 KiB (16.5 KiB) File changed.No diff preview for this file type. View original file View changed file captures/TC_NGAP_AMF_PDU_02_2.pcap +9.17 KiB (16.3 KiB) File changed.No diff preview for this file type. View original file View changed file ttcn/AtsNGAP/NGAP_Steps.ttcn +35 −9 Changes for ttcn/AtsNGAP/NGAP_Steps.ttcn: 35 added lines, 9 removed lines. Original line number Diff line number Diff line Loading @@ -729,10 +729,13 @@ module NGAP_Steps { // TODO FSCOM f_xxx_UE_SecurityMode to be mmoved into NAG_NG * (test system = gNB and UE, PICS_USE_GTPU). * @details The test system sends ICMP echo requests from the UE (vc_ueIpv4Address) to PX_DN_PING_HOST in G-PDUs on * the UL tunnel of the UPF (vc_ulGtpTunnel, QoS flow PX_QOS_FLOW_IDENTIFIER), and awaits, for up to * PX_TNOAC, the echo replies in G-PDUs on the DL tunnel it gave in the PDU SESSION RESOURCE SETUP RESPONSE * PX_TNOAC after the last one, the echo replies in G-PDUs on the DL tunnel it gave in the PDU SESSION RESOURCE SETUP RESPONSE * (PX_GTP_TEID), or moved to afterwards (p_dlTeid, e.g. by a PDU SESSION RESOURCE MODIFY INDICATION). A reply on * that tunnel shows that the tunnel reached the UPF (AMF, then SMF). The G-PDUs go to the UDP destination of * the N3 port configuration, which should be the address of the UL tunnel. * the N3 port configuration, which should be the address of the UL tunnel. The requests are spaced by * c_echoInterval, as ping does: the 5GC may install the DL tunnel in the UPF only after the PDU SESSION * RESOURCE SETUP RESPONSE (e.g. free5GC, PFCP session modification), so replies to the first requests can be * lost. The check ends with the reply to the last request. * @param p_count The number of echo requests. * @param p_dlTeid The DL tunnel TEID of the gNB where the replies are awaited. * @return true if at least one echo reply came back on the DL tunnel, or if the check is not configured Loading @@ -744,7 +747,11 @@ module NGAP_Steps { // TODO FSCOM f_xxx_UE_SecurityMode to be mmoved into NAG_NG var octetstring v_source, v_destination, v_icmp; var integer v_protocol; var integer v_replies := 0; var integer v_sent := 0; var integer v_seq; const float c_echoInterval := 1.0; // Seconds between two echo requests timer t_reply := PX_TNOAC; timer t_next := c_echoInterval; if (not PICS_USE_GTPU or (PX_DN_PING_HOST == "")) { log("*** " & __SCOPE__ & ": INFO: no user plane check (PICS_USE_GTPU false or no PX_DN_PING_HOST) ***"); Loading @@ -758,25 +765,44 @@ module NGAP_Steps { // TODO FSCOM f_xxx_UE_SecurityMode to be mmoved into NAG_NG log("f_NGAP_amf_check_user_plane: ", p_count, " echo request(s) from ", f_ipv4_toString(vc_ueIpv4Address), " to ", PX_DN_PING_HOST, " on the UL tunnel ", f_ipv4_toString(bit2oct(vc_ulGtpTunnel.transportLayerAddress)), "/", vc_ulGtpTunnel.gTP_TEID, ", replies awaited on the DL tunnel ", f_ipv4_toString(bit2oct(PX_TRANSPORT_LAYER_ADDRESS)), "/", p_dlTeid); for (var integer i := 1; i <= p_count; i := i + 1) { // First echo request; the next ones every c_echoInterval (t_next), then PX_TNOAC for the last replies (t_reply) N3_P.send(m_gtpu_gPdu_ul(vc_ulGtpTunnel.gTP_TEID, PX_QOS_FLOW_IDENTIFIER, f_ipv4_icmpEchoRequest(vc_ueIpv4Address, v_host, 21588 /* 'TT' */, i))); } f_ipv4_icmpEchoRequest(vc_ueIpv4Address, v_host, 21588 /* 'TT' */, 1))); v_sent := 1; if (v_sent < p_count) { t_next.start; } else { t_reply.start; } alt { [] N3_P.receive(mw_gtpu_gPdu(p_dlTeid)) -> value v_gtpu { if (f_ipv4_getHeader(v_gtpu.payload, v_source, v_destination, v_protocol, v_icmp) and (v_protocol == 1) and (lengthof(v_icmp) >= 8) and (v_icmp[0] == '00'O) and (v_source == v_host) and (v_destination == vc_ueIpv4Address)) { v_replies := v_replies + 1; log("f_NGAP_amf_check_user_plane: echo reply ", oct2int(substr(v_icmp, 6, 2)), " on the DL tunnel"); v_seq := oct2int(substr(v_icmp, 6, 2)); log("f_NGAP_amf_check_user_plane: echo reply ", v_seq, " on the DL tunnel"); if (v_seq == p_count) { // The reply to the last request: done t_next.stop; t_reply.stop; } else { log("f_NGAP_amf_check_user_plane: other G-PDU on the DL tunnel: ", v_gtpu); repeat; } if (v_replies < p_count) { } else { log("f_NGAP_amf_check_user_plane: other G-PDU on the DL tunnel: ", v_gtpu); repeat; } t_reply.stop; } [] t_next.timeout { v_sent := v_sent + 1; N3_P.send(m_gtpu_gPdu_ul(vc_ulGtpTunnel.gTP_TEID, PX_QOS_FLOW_IDENTIFIER, f_ipv4_icmpEchoRequest(vc_ueIpv4Address, v_host, 21588 /* 'TT' */, v_sent))); if (v_sent < p_count) { t_next.start; } else { t_reply.start; } repeat; } [] N3_P.receive(mw_gtpu_any) -> value v_gtpu { log("f_NGAP_amf_check_user_plane: other GTP-U message: ", v_gtpu); Loading Loading
captures/TC_NGAP_AMF_PDU_02.pcap +11.4 KiB (16.5 KiB) File changed.No diff preview for this file type. View original file View changed file
captures/TC_NGAP_AMF_PDU_02_2.pcap +9.17 KiB (16.3 KiB) File changed.No diff preview for this file type. View original file View changed file
ttcn/AtsNGAP/NGAP_Steps.ttcn +35 −9 Changes for ttcn/AtsNGAP/NGAP_Steps.ttcn: 35 added lines, 9 removed lines. Original line number Diff line number Diff line Loading @@ -729,10 +729,13 @@ module NGAP_Steps { // TODO FSCOM f_xxx_UE_SecurityMode to be mmoved into NAG_NG * (test system = gNB and UE, PICS_USE_GTPU). * @details The test system sends ICMP echo requests from the UE (vc_ueIpv4Address) to PX_DN_PING_HOST in G-PDUs on * the UL tunnel of the UPF (vc_ulGtpTunnel, QoS flow PX_QOS_FLOW_IDENTIFIER), and awaits, for up to * PX_TNOAC, the echo replies in G-PDUs on the DL tunnel it gave in the PDU SESSION RESOURCE SETUP RESPONSE * PX_TNOAC after the last one, the echo replies in G-PDUs on the DL tunnel it gave in the PDU SESSION RESOURCE SETUP RESPONSE * (PX_GTP_TEID), or moved to afterwards (p_dlTeid, e.g. by a PDU SESSION RESOURCE MODIFY INDICATION). A reply on * that tunnel shows that the tunnel reached the UPF (AMF, then SMF). The G-PDUs go to the UDP destination of * the N3 port configuration, which should be the address of the UL tunnel. * the N3 port configuration, which should be the address of the UL tunnel. The requests are spaced by * c_echoInterval, as ping does: the 5GC may install the DL tunnel in the UPF only after the PDU SESSION * RESOURCE SETUP RESPONSE (e.g. free5GC, PFCP session modification), so replies to the first requests can be * lost. The check ends with the reply to the last request. * @param p_count The number of echo requests. * @param p_dlTeid The DL tunnel TEID of the gNB where the replies are awaited. * @return true if at least one echo reply came back on the DL tunnel, or if the check is not configured Loading @@ -744,7 +747,11 @@ module NGAP_Steps { // TODO FSCOM f_xxx_UE_SecurityMode to be mmoved into NAG_NG var octetstring v_source, v_destination, v_icmp; var integer v_protocol; var integer v_replies := 0; var integer v_sent := 0; var integer v_seq; const float c_echoInterval := 1.0; // Seconds between two echo requests timer t_reply := PX_TNOAC; timer t_next := c_echoInterval; if (not PICS_USE_GTPU or (PX_DN_PING_HOST == "")) { log("*** " & __SCOPE__ & ": INFO: no user plane check (PICS_USE_GTPU false or no PX_DN_PING_HOST) ***"); Loading @@ -758,25 +765,44 @@ module NGAP_Steps { // TODO FSCOM f_xxx_UE_SecurityMode to be mmoved into NAG_NG log("f_NGAP_amf_check_user_plane: ", p_count, " echo request(s) from ", f_ipv4_toString(vc_ueIpv4Address), " to ", PX_DN_PING_HOST, " on the UL tunnel ", f_ipv4_toString(bit2oct(vc_ulGtpTunnel.transportLayerAddress)), "/", vc_ulGtpTunnel.gTP_TEID, ", replies awaited on the DL tunnel ", f_ipv4_toString(bit2oct(PX_TRANSPORT_LAYER_ADDRESS)), "/", p_dlTeid); for (var integer i := 1; i <= p_count; i := i + 1) { // First echo request; the next ones every c_echoInterval (t_next), then PX_TNOAC for the last replies (t_reply) N3_P.send(m_gtpu_gPdu_ul(vc_ulGtpTunnel.gTP_TEID, PX_QOS_FLOW_IDENTIFIER, f_ipv4_icmpEchoRequest(vc_ueIpv4Address, v_host, 21588 /* 'TT' */, i))); } f_ipv4_icmpEchoRequest(vc_ueIpv4Address, v_host, 21588 /* 'TT' */, 1))); v_sent := 1; if (v_sent < p_count) { t_next.start; } else { t_reply.start; } alt { [] N3_P.receive(mw_gtpu_gPdu(p_dlTeid)) -> value v_gtpu { if (f_ipv4_getHeader(v_gtpu.payload, v_source, v_destination, v_protocol, v_icmp) and (v_protocol == 1) and (lengthof(v_icmp) >= 8) and (v_icmp[0] == '00'O) and (v_source == v_host) and (v_destination == vc_ueIpv4Address)) { v_replies := v_replies + 1; log("f_NGAP_amf_check_user_plane: echo reply ", oct2int(substr(v_icmp, 6, 2)), " on the DL tunnel"); v_seq := oct2int(substr(v_icmp, 6, 2)); log("f_NGAP_amf_check_user_plane: echo reply ", v_seq, " on the DL tunnel"); if (v_seq == p_count) { // The reply to the last request: done t_next.stop; t_reply.stop; } else { log("f_NGAP_amf_check_user_plane: other G-PDU on the DL tunnel: ", v_gtpu); repeat; } if (v_replies < p_count) { } else { log("f_NGAP_amf_check_user_plane: other G-PDU on the DL tunnel: ", v_gtpu); repeat; } t_reply.stop; } [] t_next.timeout { v_sent := v_sent + 1; N3_P.send(m_gtpu_gPdu_ul(vc_ulGtpTunnel.gTP_TEID, PX_QOS_FLOW_IDENTIFIER, f_ipv4_icmpEchoRequest(vc_ueIpv4Address, v_host, 21588 /* 'TT' */, v_sent))); if (v_sent < p_count) { t_next.start; } else { t_reply.start; } repeat; } [] N3_P.receive(mw_gtpu_any) -> value v_gtpu { log("f_NGAP_amf_check_user_plane: other GTP-U message: ", v_gtpu); Loading