Loading ttcn/Ats_NG_NAS/NG_NAS_TCFunctions.ttcn +127 −9 Original line number Diff line number Diff line Loading @@ -17,20 +17,22 @@ module NG_NAS_TCFunctions { import from LibCommon_VerdictControl all; import from LibCommon_Time all; // NG_NAS // Lib_NG_NAS import from Lib_NG_NAS_Interface all; import from NG_NAS_TestSystem all; import from Lib_NG_NAS_Templates all; import from LIB_NG_NAS_Functions all; // NG_NAS import from NG_NAS_TypeDefs all; import from NG_NAS_TestSystem all; // Lib3GPP //Lib3GPP import from NG_NAS_MsgContainers {type NG_NAS_DL_Message_Type, NG_NAS_UL_Message_Type}; import from NG_NAS_MsgContainers all; // LibNGAP import from NGAP_IEs language "ASN.1:2002" all; import from NGAP_Constants language "ASN.1:2002" all; import from NGAP_PDU_Descriptions language "ASN.1:2002" all; import from LibNGAP_Pixits all; import from LibNGAP_Templates all; import from LibNGAP_Interface all; Loading Loading @@ -226,12 +228,128 @@ module NG_NAS_TCFunctions { // Preamble f_NGAP_gnb_init(); f_send_NGAP_PDU( m_ngap_initMsg( m_n2_NGSetupRequest( m_globalRANNodeID_globalGNB_ID( m_ie_globalGnbId( PX_PLMN_IDENTITY, PX_GNB_ID,//'0000000000000000000000'B,//in template (value) bitstring p_gnbId, -//in template (omit) GlobalGNB_ID.iE_Extensions p_iE_Extensions := omit )), { m_supportedTAItem( PX_TACode, { m_ie_broadcastPLMNItem( PX_PLMN_IDENTITY,//m_ie_pLMNIdentity('00f110'O), { m_sliceSupportItem( m_s_NSSAI( PX_SST, -,// in template (omit) SD p_sD := omit, -// in template (omit) S_NSSAI.iE_Extensions p_iE_Extensions := omit ), -//in template (omit) SliceSupportItem.iE_Extensions p_iE_Extensions := omit ) } ) },//in template (value) BroadcastPLMNList p_broadcastPLMNList, -//in template (omit) SupportedTAItem.iE_Extensions p_iE_Extensions := omit ) }, PX_PAGING_DRX ))); f_recv_NGAP_PDU( mw_ngap_succMsg( mw_n2_NGSetupResponse( mw_aMFName(PX_AMF_NAME), { *, mw_servedGUAMIItem( mw_gUAMI( PX_PLMN_IDENTITY )), * } ))); vt_NgNasUl_Msg := m_NG_REGISTRATION_REQUEST( {'1'B,'001'B},//in template (value) RegistrationType p_RegistrationType, '000'B,//in template (value) NAS_KsiValue p_KeySetId, '0'B,//in template (value) B1_Type p_Tsc, { // 24.501 cl. 9.11.3.4 iei:=omit, iel:='0002'O, idDigit1:='0000'B, // 1st identitity digit oddEvenInd:='0'B, // Odd/even indicator or Spare typeOfId:='000'B, // Type of identity otherDigits:='00'O// length (1..infinity) optional // Other identity digits, could be any length @sic R5-192389, @sic R5w190307 sic@ sic@ }//in template (value) NG_MobileIdentity p_MobileId, ); vc_sendNAS_PDU := bit2oct(encvalue(valueof(vt_NgNasUl_Msg))); log("===> vc_sendNAS_PDU (1): ", vc_sendNAS_PDU); f_send_NGAP_PDU( m_ngap_initMsg( mw_n2_DownlinkNASTransport( PX_AMF_UE_NGAP_ID, PX_RAN_UE_NGAP_ID, vc_sendNAS_PDU ))); f_recv_NGAP_PDU( mw_ngap_initMsg( mw_n2_DownlinkNASTransport( PX_AMF_UE_NGAP_ID, PX_RAN_UE_NGAP_ID, ? // AuthenticationRequest // vt_NgNasUl_Msg := m_NG_AUTHENTICATION_REQUEST( // '100'B, // { iei := omit, iel : =omit, otherDigits := '0000'O}, // { iei := '00100001'B, randValue := oct2bit('a218b7e415a50b63b4f5afd7db2c9529'O) }, // { iei := '20'O, iel := '1000'B, aUTN := oct2bit('e4ca34194b428000f058119c1778db23'O) } // ); ))); var NG_AUTHENTICATION_REQUEST v_ng_authentication_request; if (f_Check_5GAKA_AuthenticationRequest(vc_recvNGAP_PDU, id_NAS_PDU, v_ng_authentication_request) == false) { setverdict(inconc); log("*** " & __SCOPE__ & ": INCONC: NAS-PDU IE not found. ***"); } f_selfOrClientSyncAndVerdict(c_prDone, f_getVerdict()); log("*** " & __SCOPE__ & ": INFO: Preamble done. ***"); // Body // TODO vt_NgNasUl_Msg := m_NG_AUTHENTICATION_RESPONSE( { iei := '2d'O, iel := '10'O, res := oct2bit('a7c39d021cc8070960775ce133f05be3'O) } ); vc_sendNAS_PDU := bit2oct(encvalue(valueof(vt_NgNasUl_Msg))); log("===> vc_sendNAS_PDU (2): ", vc_sendNAS_PDU); f_send_NGAP_PDU( m_ngap_initMsg( m_n2_UplinkNASTransport( PX_AMF_UE_NGAP_ID, PX_RAN_UE_NGAP_ID, vc_sendNAS_PDU, m_uPTransportLayerInformation_userLocationInformationNR( m_userLocationInformationNR( m_nR_CGI, m_tAI ))))); f_recv_NGAP_PDU( mw_ngap_initMsg( mw_n2_DownlinkNASTransport( PX_AMF_UE_NGAP_ID, PX_RAN_UE_NGAP_ID, ? // SecurityModeCommand ))); var NG_SECURITY_MODE_COMMAND v_ng_security_mode_command; if (f_Check_5GAKA_SecurityModeCommand(vc_recvNGAP_PDU, id_NAS_PDU, v_ng_security_mode_command) == false) { setverdict(inconc); log("*** " & __SCOPE__ & ": INCONC: NAS-PDU IE not found. ***"); } // var NG_AUTHENTICATION_RESPONSE v_ng_authentication_response; // if (f_Check_5GAKA_AuthenticationResponse(vc_recvNGAP_PDU, id_NAS_PDU, v_ng_authentication_response) == false) { // setverdict(inconc); // log("*** " & __SCOPE__ & ": INCONC: NAS-PDU IE not found. ***"); // } f_selfOrClientSyncAndVerdict(c_tbDone, f_getVerdict()); log("*** " & __SCOPE__ & ": INFO: Testbody done. ***"); Loading ttcn/Lib3GPP/NAS/NAS_CommonTypeDefs.ttcn +18 −5 Original line number Diff line number Diff line Loading @@ -762,7 +762,10 @@ type record Non3GPP_NW_ProvidedPolicies { IEI8_Type iei optional, /* present in case of TLV; omit in case of LV */ Type4Length_Type iel, // @sic R5s110420 sic@ B128_Type aUTN /* (as for UMTS) */ }; } with { variant "PRESENCE (iei = '20'O)"; variant (iel) "LENGTHTO (aUTN)" } // ============================================================================= // Structured Type Definition Loading @@ -774,7 +777,10 @@ type record Non3GPP_NW_ProvidedPolicies { // '00110000'B for GMM (30 hex) Type4Length_Type iel, // M 1 octet B112_Type auts // AUTS, 14 octets }; } with { variant "PRESENCE (iei = '30'O)"; variant (iel) "LENGTHTO (auts)" } // ============================================================================= // Structured Type Definition Loading @@ -784,7 +790,9 @@ type record Non3GPP_NW_ProvidedPolicies { type record RAND { IEI8_Type iei optional, // '00100001'B (21 hex) B128_Type randValue // Authentication Parameter RAND value }; } with { variant "PRESENCE (iei = '21'O)" } type record DaylightSavingTime { /* 24.301 cl. 9.9.3.5 -> 24.008 cl. 10.5.3.12 */ IEI8_Type iei optional, /* present in case of TLV; omit in case of LV */ Loading Loading @@ -998,13 +1006,18 @@ type record NBIFOMContainer { IEI8_Type iei optional, /* present in case of TLV; omit in case of LV */ Type4Length_Type iel optional, /* present in case of LV or TLV; omit in case of V */ B32_128_Type res /* 4..16 octets */ }; } with { variant "PRESENCE (iei = '2D'O)"; variant (iel) "LENGTHTO (res)" } type record NAS_KeySetIdentifier { /* 24.301 cl. 9.9.3.21 */ IEI4_Type iei optional, /* present in case of TV; omit in case of V */ B1_Type tsc, // Type of security context: 0 = cached, 1 = mapped NAS_KsiValue nasKeySetId } with{ variant "FIELDLENGTH(4), FIELDORDER(msb), FORCEOMIT(iei)"}; } with { variant "FIELDLENGTH(4), FIELDORDER(msb), FORCEOMIT(iei)" } type record HashMME { /* 24.301 cl. 9.9.3.50 @sic R5s170597 Baseline Moving sic@ */ IEI8_Type iei optional, Loading ttcn/Lib3GPP/NG_NAS/NG_NAS_MsgContainers.ttcn +37 −9 Original line number Diff line number Diff line Loading @@ -56,8 +56,20 @@ module NG_NAS_MsgContainers SET_UAI_RESPONSE set_UAI_Response, SET_UL_MESSAGE_RESPONSE set_UL_Message_Response, UE_TEST_LOOP_NR_SIDELINK_COUNTER_RESPONSE test_Loop_Sidelink_Counter_Response // @sic R5-225291 sic@ } with { variant "TAG( security_Protected_Nas_Message, securityHeaderType = '0001'B; security_Protected_Nas_Message, securityHeaderType = '0010'B; security_Protected_Nas_Message, securityHeaderType = '0011'B; security_Protected_Nas_Message, securityHeaderType = '0100'B; registration_Request, messageType = '01000001'B; registration_Complete, messageType = '01000011'B; authentication_Response, messageType = '01010111'B; security_Mode_Complete, messageType = '01011110'B; ul_Nas_Transport, messageType = '01100111'B; )" }with { variant "TAG(registration_Request, protocolDiscriminator = '01111110'B)"} } type union NG_NAS_DL_Message_Type { /* NAS message with direction 'network to UE' or 'both' */ NG_AUTHENTICATION_REJECT authentication_Reject, Loading Loading @@ -102,8 +114,24 @@ module NG_NAS_MsgContainers UE_TEST_LOOP_NR_SIDELINK_COUNTER_REQUEST test_Loop_Sidelink_Counter_Request, // @sic R5-225291 sic@ UPDATE_UE_LOCATION_INFORMATION update_Ue_Location_Information //@sic R5-213421 sic@ <<<<<<< HEAD } ======= } with { variant "TAG( security_Protected_Nas_Message, securityHeaderType = '0001'B; security_Protected_Nas_Message, securityHeaderType = '0010'B; security_Protected_Nas_Message, securityHeaderType = '0011'B; security_Protected_Nas_Message, securityHeaderType = '0100'B; registration_Accept, messageType = '01000010'B; authentication_Request, messageType = '01010110'B; security_Mode_Command, messageType = '01011101'B; configuration_Update_Command, messageType = '01010100'B; dl_Nas_Transport, messageType = '01101000'B; )" } >>>>>>> 22d86add030cd3da835e95ca682f86332b832143 //**************************************************************************** Loading ttcn/Lib3GPP/NG_NAS/NG_NAS_TypeDefs.ttcn +79 −2 File changed.Preview size limit exceeded, changes collapsed. Show changes ttcn/LibNGAP/lib/LibNGAP_Templates.ttcn +6 −6 Original line number Diff line number Diff line Loading @@ -5863,7 +5863,7 @@ module LibNGAP_Templates { value_ := { NGSetupResponse := { protocolIEs := { permutation( *, { id := id_AMFName, criticality := reject, Loading @@ -5882,9 +5882,9 @@ module LibNGAP_Templates { { id := id_PLMNSupportList, criticality := reject, value_ := { PLMNSupportList := (p_plmnSuppList,*) } },* ) value_ := { PLMNSupportList := p_plmnSuppList } }, * } } } Loading
ttcn/Ats_NG_NAS/NG_NAS_TCFunctions.ttcn +127 −9 Original line number Diff line number Diff line Loading @@ -17,20 +17,22 @@ module NG_NAS_TCFunctions { import from LibCommon_VerdictControl all; import from LibCommon_Time all; // NG_NAS // Lib_NG_NAS import from Lib_NG_NAS_Interface all; import from NG_NAS_TestSystem all; import from Lib_NG_NAS_Templates all; import from LIB_NG_NAS_Functions all; // NG_NAS import from NG_NAS_TypeDefs all; import from NG_NAS_TestSystem all; // Lib3GPP //Lib3GPP import from NG_NAS_MsgContainers {type NG_NAS_DL_Message_Type, NG_NAS_UL_Message_Type}; import from NG_NAS_MsgContainers all; // LibNGAP import from NGAP_IEs language "ASN.1:2002" all; import from NGAP_Constants language "ASN.1:2002" all; import from NGAP_PDU_Descriptions language "ASN.1:2002" all; import from LibNGAP_Pixits all; import from LibNGAP_Templates all; import from LibNGAP_Interface all; Loading Loading @@ -226,12 +228,128 @@ module NG_NAS_TCFunctions { // Preamble f_NGAP_gnb_init(); f_send_NGAP_PDU( m_ngap_initMsg( m_n2_NGSetupRequest( m_globalRANNodeID_globalGNB_ID( m_ie_globalGnbId( PX_PLMN_IDENTITY, PX_GNB_ID,//'0000000000000000000000'B,//in template (value) bitstring p_gnbId, -//in template (omit) GlobalGNB_ID.iE_Extensions p_iE_Extensions := omit )), { m_supportedTAItem( PX_TACode, { m_ie_broadcastPLMNItem( PX_PLMN_IDENTITY,//m_ie_pLMNIdentity('00f110'O), { m_sliceSupportItem( m_s_NSSAI( PX_SST, -,// in template (omit) SD p_sD := omit, -// in template (omit) S_NSSAI.iE_Extensions p_iE_Extensions := omit ), -//in template (omit) SliceSupportItem.iE_Extensions p_iE_Extensions := omit ) } ) },//in template (value) BroadcastPLMNList p_broadcastPLMNList, -//in template (omit) SupportedTAItem.iE_Extensions p_iE_Extensions := omit ) }, PX_PAGING_DRX ))); f_recv_NGAP_PDU( mw_ngap_succMsg( mw_n2_NGSetupResponse( mw_aMFName(PX_AMF_NAME), { *, mw_servedGUAMIItem( mw_gUAMI( PX_PLMN_IDENTITY )), * } ))); vt_NgNasUl_Msg := m_NG_REGISTRATION_REQUEST( {'1'B,'001'B},//in template (value) RegistrationType p_RegistrationType, '000'B,//in template (value) NAS_KsiValue p_KeySetId, '0'B,//in template (value) B1_Type p_Tsc, { // 24.501 cl. 9.11.3.4 iei:=omit, iel:='0002'O, idDigit1:='0000'B, // 1st identitity digit oddEvenInd:='0'B, // Odd/even indicator or Spare typeOfId:='000'B, // Type of identity otherDigits:='00'O// length (1..infinity) optional // Other identity digits, could be any length @sic R5-192389, @sic R5w190307 sic@ sic@ }//in template (value) NG_MobileIdentity p_MobileId, ); vc_sendNAS_PDU := bit2oct(encvalue(valueof(vt_NgNasUl_Msg))); log("===> vc_sendNAS_PDU (1): ", vc_sendNAS_PDU); f_send_NGAP_PDU( m_ngap_initMsg( mw_n2_DownlinkNASTransport( PX_AMF_UE_NGAP_ID, PX_RAN_UE_NGAP_ID, vc_sendNAS_PDU ))); f_recv_NGAP_PDU( mw_ngap_initMsg( mw_n2_DownlinkNASTransport( PX_AMF_UE_NGAP_ID, PX_RAN_UE_NGAP_ID, ? // AuthenticationRequest // vt_NgNasUl_Msg := m_NG_AUTHENTICATION_REQUEST( // '100'B, // { iei := omit, iel : =omit, otherDigits := '0000'O}, // { iei := '00100001'B, randValue := oct2bit('a218b7e415a50b63b4f5afd7db2c9529'O) }, // { iei := '20'O, iel := '1000'B, aUTN := oct2bit('e4ca34194b428000f058119c1778db23'O) } // ); ))); var NG_AUTHENTICATION_REQUEST v_ng_authentication_request; if (f_Check_5GAKA_AuthenticationRequest(vc_recvNGAP_PDU, id_NAS_PDU, v_ng_authentication_request) == false) { setverdict(inconc); log("*** " & __SCOPE__ & ": INCONC: NAS-PDU IE not found. ***"); } f_selfOrClientSyncAndVerdict(c_prDone, f_getVerdict()); log("*** " & __SCOPE__ & ": INFO: Preamble done. ***"); // Body // TODO vt_NgNasUl_Msg := m_NG_AUTHENTICATION_RESPONSE( { iei := '2d'O, iel := '10'O, res := oct2bit('a7c39d021cc8070960775ce133f05be3'O) } ); vc_sendNAS_PDU := bit2oct(encvalue(valueof(vt_NgNasUl_Msg))); log("===> vc_sendNAS_PDU (2): ", vc_sendNAS_PDU); f_send_NGAP_PDU( m_ngap_initMsg( m_n2_UplinkNASTransport( PX_AMF_UE_NGAP_ID, PX_RAN_UE_NGAP_ID, vc_sendNAS_PDU, m_uPTransportLayerInformation_userLocationInformationNR( m_userLocationInformationNR( m_nR_CGI, m_tAI ))))); f_recv_NGAP_PDU( mw_ngap_initMsg( mw_n2_DownlinkNASTransport( PX_AMF_UE_NGAP_ID, PX_RAN_UE_NGAP_ID, ? // SecurityModeCommand ))); var NG_SECURITY_MODE_COMMAND v_ng_security_mode_command; if (f_Check_5GAKA_SecurityModeCommand(vc_recvNGAP_PDU, id_NAS_PDU, v_ng_security_mode_command) == false) { setverdict(inconc); log("*** " & __SCOPE__ & ": INCONC: NAS-PDU IE not found. ***"); } // var NG_AUTHENTICATION_RESPONSE v_ng_authentication_response; // if (f_Check_5GAKA_AuthenticationResponse(vc_recvNGAP_PDU, id_NAS_PDU, v_ng_authentication_response) == false) { // setverdict(inconc); // log("*** " & __SCOPE__ & ": INCONC: NAS-PDU IE not found. ***"); // } f_selfOrClientSyncAndVerdict(c_tbDone, f_getVerdict()); log("*** " & __SCOPE__ & ": INFO: Testbody done. ***"); Loading
ttcn/Lib3GPP/NAS/NAS_CommonTypeDefs.ttcn +18 −5 Original line number Diff line number Diff line Loading @@ -762,7 +762,10 @@ type record Non3GPP_NW_ProvidedPolicies { IEI8_Type iei optional, /* present in case of TLV; omit in case of LV */ Type4Length_Type iel, // @sic R5s110420 sic@ B128_Type aUTN /* (as for UMTS) */ }; } with { variant "PRESENCE (iei = '20'O)"; variant (iel) "LENGTHTO (aUTN)" } // ============================================================================= // Structured Type Definition Loading @@ -774,7 +777,10 @@ type record Non3GPP_NW_ProvidedPolicies { // '00110000'B for GMM (30 hex) Type4Length_Type iel, // M 1 octet B112_Type auts // AUTS, 14 octets }; } with { variant "PRESENCE (iei = '30'O)"; variant (iel) "LENGTHTO (auts)" } // ============================================================================= // Structured Type Definition Loading @@ -784,7 +790,9 @@ type record Non3GPP_NW_ProvidedPolicies { type record RAND { IEI8_Type iei optional, // '00100001'B (21 hex) B128_Type randValue // Authentication Parameter RAND value }; } with { variant "PRESENCE (iei = '21'O)" } type record DaylightSavingTime { /* 24.301 cl. 9.9.3.5 -> 24.008 cl. 10.5.3.12 */ IEI8_Type iei optional, /* present in case of TLV; omit in case of LV */ Loading Loading @@ -998,13 +1006,18 @@ type record NBIFOMContainer { IEI8_Type iei optional, /* present in case of TLV; omit in case of LV */ Type4Length_Type iel optional, /* present in case of LV or TLV; omit in case of V */ B32_128_Type res /* 4..16 octets */ }; } with { variant "PRESENCE (iei = '2D'O)"; variant (iel) "LENGTHTO (res)" } type record NAS_KeySetIdentifier { /* 24.301 cl. 9.9.3.21 */ IEI4_Type iei optional, /* present in case of TV; omit in case of V */ B1_Type tsc, // Type of security context: 0 = cached, 1 = mapped NAS_KsiValue nasKeySetId } with{ variant "FIELDLENGTH(4), FIELDORDER(msb), FORCEOMIT(iei)"}; } with { variant "FIELDLENGTH(4), FIELDORDER(msb), FORCEOMIT(iei)" } type record HashMME { /* 24.301 cl. 9.9.3.50 @sic R5s170597 Baseline Moving sic@ */ IEI8_Type iei optional, Loading
ttcn/Lib3GPP/NG_NAS/NG_NAS_MsgContainers.ttcn +37 −9 Original line number Diff line number Diff line Loading @@ -56,8 +56,20 @@ module NG_NAS_MsgContainers SET_UAI_RESPONSE set_UAI_Response, SET_UL_MESSAGE_RESPONSE set_UL_Message_Response, UE_TEST_LOOP_NR_SIDELINK_COUNTER_RESPONSE test_Loop_Sidelink_Counter_Response // @sic R5-225291 sic@ } with { variant "TAG( security_Protected_Nas_Message, securityHeaderType = '0001'B; security_Protected_Nas_Message, securityHeaderType = '0010'B; security_Protected_Nas_Message, securityHeaderType = '0011'B; security_Protected_Nas_Message, securityHeaderType = '0100'B; registration_Request, messageType = '01000001'B; registration_Complete, messageType = '01000011'B; authentication_Response, messageType = '01010111'B; security_Mode_Complete, messageType = '01011110'B; ul_Nas_Transport, messageType = '01100111'B; )" }with { variant "TAG(registration_Request, protocolDiscriminator = '01111110'B)"} } type union NG_NAS_DL_Message_Type { /* NAS message with direction 'network to UE' or 'both' */ NG_AUTHENTICATION_REJECT authentication_Reject, Loading Loading @@ -102,8 +114,24 @@ module NG_NAS_MsgContainers UE_TEST_LOOP_NR_SIDELINK_COUNTER_REQUEST test_Loop_Sidelink_Counter_Request, // @sic R5-225291 sic@ UPDATE_UE_LOCATION_INFORMATION update_Ue_Location_Information //@sic R5-213421 sic@ <<<<<<< HEAD } ======= } with { variant "TAG( security_Protected_Nas_Message, securityHeaderType = '0001'B; security_Protected_Nas_Message, securityHeaderType = '0010'B; security_Protected_Nas_Message, securityHeaderType = '0011'B; security_Protected_Nas_Message, securityHeaderType = '0100'B; registration_Accept, messageType = '01000010'B; authentication_Request, messageType = '01010110'B; security_Mode_Command, messageType = '01011101'B; configuration_Update_Command, messageType = '01010100'B; dl_Nas_Transport, messageType = '01101000'B; )" } >>>>>>> 22d86add030cd3da835e95ca682f86332b832143 //**************************************************************************** Loading
ttcn/Lib3GPP/NG_NAS/NG_NAS_TypeDefs.ttcn +79 −2 File changed.Preview size limit exceeded, changes collapsed. Show changes
ttcn/LibNGAP/lib/LibNGAP_Templates.ttcn +6 −6 Original line number Diff line number Diff line Loading @@ -5863,7 +5863,7 @@ module LibNGAP_Templates { value_ := { NGSetupResponse := { protocolIEs := { permutation( *, { id := id_AMFName, criticality := reject, Loading @@ -5882,9 +5882,9 @@ module LibNGAP_Templates { { id := id_PLMNSupportList, criticality := reject, value_ := { PLMNSupportList := (p_plmnSuppList,*) } },* ) value_ := { PLMNSupportList := p_plmnSuppList } }, * } } }