diff --git a/ttcn/AtsImsIot/AtsImsIot_Emergency.ttcn b/ttcn/AtsImsIot/AtsImsIot_Emergency.ttcn index 81f1e26e7d1a00c7ebddc7e2226dce8c722ebe99..48d192a03ff27a5a9d46be3cac717ded327f6b50 100644 --- a/ttcn/AtsImsIot/AtsImsIot_Emergency.ttcn +++ b/ttcn/AtsImsIot/AtsImsIot_Emergency.ttcn @@ -181,18 +181,18 @@ module AtsImsIot_Emergency { f_mtc_userRadioEnabled ( v_ueA, true, true ); // UA-A trigger an initial network_attachment by enabling radio interface of its mobile // Test body - f_mtc_check_TP_GM_PCSCF_REGISTER_01(vc_vxlte_monitor_components.gmA); // Events 1, 12 - f_mtc_check_TP_MW_PCSCF_REGISTER_01(vc_vxlte_monitor_components.mwPI); // Event 4, 11 - f_mtc_check_TP_MW_ICSCF_REGISTER_01(vc_vxlte_monitor_components.mwIS, true); // Event 7, 10 + f_mtc_check_TP_GM_PCSCF_ECO_REGISTER_01(vc_vxlte_monitor_components.gmA); // Events 1, 12 + f_mtc_check_TP_MW_PCSCF_ECO_REGISTER_01(vc_vxlte_monitor_components.mwPI); // Event 4, 11 + f_mtc_check_TP_MW_ICSCF_ECO_REGISTER_01(vc_vxlte_monitor_components.mwIS, true); // Event 7, 10 - f_mtc_check_TP_CX_HSS_UAA_01(f_getCxInterface(PX_DIAMETER_CX_SINGLE_INTERFACE));// Event 5, 6 + f_mtc_check_TP_CX_HSS_ECO_UAA_01(f_getCxInterface(PX_DIAMETER_CX_SINGLE_INTERFACE));// Event 5, 6 f_mtc_check_TP_CX_HSS_MAA_01(vc_vxlte_monitor_components.cxSH);// Event 8, 9 - f_mtc_check_TP_GM_PCSCF_REGISTER_02(vc_vxlte_monitor_components.gmA); // Events 13, 22 - f_mtc_check_TP_MW_PCSCF_REGISTER_02(vc_vxlte_monitor_components.mwPI); // Events 14, 21 - f_mtc_check_TP_MW_ICSCF_REGISTER_02(vc_vxlte_monitor_components.mwIS, true); // Event 17, 20 + f_mtc_check_TP_GM_PCSCF_ECO_REGISTER_02(vc_vxlte_monitor_components.gmA); // Events 13, 22 + f_mtc_check_TP_MW_PCSCF_ECO_REGISTER_02(vc_vxlte_monitor_components.mwPI); // Events 14, 21 + f_mtc_check_TP_MW_ICSCF_ECO_REGISTER_02(vc_vxlte_monitor_components.mwIS, true); // Event 17, 20 - f_mtc_check_TP_CX_HSS_UAA_02(f_getCxInterface(PX_DIAMETER_CX_SINGLE_INTERFACE));// Event 15, 16 + f_mtc_check_TP_CX_HSS_ECO_UAA_02(f_getCxInterface(PX_DIAMETER_CX_SINGLE_INTERFACE));// Event 15, 16 f_mtc_check_TP_CX_HSS_SAA_01(vc_vxlte_monitor_components.cxSH);// Event 18, 19 // postamble @@ -239,16 +239,18 @@ module AtsImsIot_Emergency { f_mtc_userRadioEnabled ( v_ueA, true, true ); // UA-A trigger an initial network_attachment by enabling radio interface of its mobile // Test body - f_mtc_check_TP_GM_PCSCF_REGISTER_01(vc_vxlte_monitor_components.gmA); // Events 1, 12 - f_mtc_check_TP_MW_PCSCF_REGISTER_01(vc_vxlte_monitor_components.mwPI); // Event 4, 11 - f_mtc_check_TP_MW_ICSCF_REGISTER_01(vc_vxlte_monitor_components.mwIS, true); // Event 7, 10 + f_mtc_check_TP_GM_PCSCF_ECO_REGISTER_01(vc_vxlte_monitor_components.gmA); // Events 1, 12 + f_mtc_check_TP_MW_PCSCF_ECO_REGISTER_01(vc_vxlte_monitor_components.mwPI); // Event 4, 11 + f_mtc_check_TP_MW_ICSCF_ECO_REGISTER_01(vc_vxlte_monitor_components.mwIS, true); // Event 7, 10 - f_mtc_check_TP_CX_HSS_UAA_01(f_getCxInterface(PX_DIAMETER_CX_SINGLE_INTERFACE));// Event 5, 6 + f_mtc_check_TP_CX_HSS_ECO_UAA_01(f_getCxInterface(PX_DIAMETER_CX_SINGLE_INTERFACE));// Event 5, 6 f_mtc_check_TP_CX_HSS_MAA_01(vc_vxlte_monitor_components.cxSH);// Event 8, 9 - f_mtc_check_TP_GM_PCSCF_REGISTER_05(vc_vxlte_monitor_components.gmA); // Events 13, 22 - f_mtc_check_TP_MW_PCSCF_REGISTER_05(vc_vxlte_monitor_components.mwPI); // Events 14, 21 - f_mtc_check_TP_MW_ICSCF_REGISTER_05(vc_vxlte_monitor_components.mwIS, true); // Event 17, 20 + f_mtc_check_TP_GM_PCSCF_ECO_REGISTER_03(vc_vxlte_monitor_components.gmA); // Events 13, 22 + f_mtc_check_TP_MW_PCSCF_ECO_REGISTER_03(vc_vxlte_monitor_components.mwPI); // Events 14, 21 + f_mtc_check_TP_MW_ICSCF_REGISTER_03(vc_vxlte_monitor_components.mwIS, true); // Event 17, 20 + + f_mtc_check_TP_CX_HSS_ECO_ECO_UAA_02(f_getCxInterface(PX_DIAMETER_CX_SINGLE_INTERFACE));// Event 15, 16 f_mtc_check_TP_CX_HSS_SAA_01(vc_vxlte_monitor_components.cxSH);// Event 18, 19 // postamble diff --git a/ttcn/AtsImsIot/AtsImsIot_TP_behavior_CX.ttcn b/ttcn/AtsImsIot/AtsImsIot_TP_behavior_CX.ttcn index 55300d3592d5192377b99394245d3ecb8497edba..3d3f7a4547c772fc6e36a0227d3dd83c6a6485cc 100644 --- a/ttcn/AtsImsIot/AtsImsIot_TP_behavior_CX.ttcn +++ b/ttcn/AtsImsIot/AtsImsIot_TP_behavior_CX.ttcn @@ -501,6 +501,103 @@ group g_HSS { } } // End of function f_mtc_check_TP_CX_HSS_UAA_01 + /** + * Starts monitor component behavior for f_mtc_check_TP_CX_HSS_ECO_UAA_01 + * @param p_monitorCompRef Reference to monitor component + * <pre> + * Test objective "IUT successfully processes all mandatory AVPs in a UA-Request received due to first UE initial registration and sends UA-Answer." + * + * <pre> + * + * Config Id CF_VxLTE_INT + * + * Initial conditions with { + * the UE_A entity isNotRegisteredTo the IMS_A + * } + * + * ensure that { + * when { + * the IMS_I_CSCF_A entity sends a UAR containing + * Session_ID_AVP + * Vendor_Specific_Application_Id_AVP + * Auth_Session_State_AVP + * indicating value NO_STATE_MAINTAINED, + * Origin_Host_AVP + * Origin_Realm_AVP + * Public_Identity_AVP + * Visited_Network_Identifier_AVP + * User_Authorization_Type_AVP + * indicating value REGISTRATION, + * User_Name_AVP + * Destination_Host_AVP + * Destination_Realm_AVP + * UAR_Flags_AVP + * indicating value IMS_Emergency_Registration_bit_not_set + * ; + * to the IMS_HSS_A entity + * } + * then { + * the IMS_HSS_A entity sends the UAA containing + * Session_ID_AVP + * Vendor_Specific_Application_Id_AVP + * Auth_Session_State_AVP + * Origin_Host_AVP + * Origin_Realm_AVP + * not Result_Code_AVP + * Experimental_Result_AVP containing + * Experimental_Result_Code_AVP + * indicating value DIAMETER_FIRST_REGISTRATION + * ; + * ; + * to the IMS_I_CSCF_A entity + * } + * } + * </pre> + * @see TS 103 653-1 clause 7.4 + */ + function f_mtc_check_TP_CX_HSS_ECO_UAA_01( + DiameterInterfaceMonitor p_monitorCompRef, + in boolean p_checkMessage := false, + in boolean p_forward_to_mtc := false + ) runs on ImsTestCoordinator { + if (isvalue(p_monitorCompRef)){ + var ImsUserInfo v_userInfoA := f_getSipUserId(PX_EUT_A); + var charstring v_publicIdentity := "sip:"&v_userInfoA.publicId&"@"&v_userInfoA.domain; + //"sip:"&v_userInfoA.publicId&@&v_userInfoA.domain + p_monitorCompRef.start ( + f_Iot_Diameter_receive( + { + DIAMETER_MSG:{uAR_MSG := mw_UAR_Registration(mw_publicIdentity(v_publicIdentity))} + }, + { + DIAMETER_MSG:{uAR_MSG := mw_UAR_basic} + }, + {0, omit}, + "TP_CX_HSS_UAA_01 - UAR", + p_forward_to_mtc, + p_checkMessage + ) + ); + p_monitorCompRef.done; + + p_monitorCompRef.start ( + f_Iot_Diameter_receive( + { + DIAMETER_MSG:{uAA_MSG := mw_UAA_diamFirstRegistration} + }, + { + DIAMETER_MSG:{uAA_MSG := mw_UAA_basic} + }, + {0, omit}, + "TP_CX_HSS_UAA_01 - UAA", + p_forward_to_mtc, + p_checkMessage + ) + ); + p_monitorCompRef.done; + } + } // End of function f_mtc_check_TP_CX_HSS_ECO_UAA_01 + /** * Starts monitor component behavior for TP_CX_HSS_UAA_02 * @param p_monitorCompRef Reference to monitor component diff --git a/ttcn/AtsImsIot/AtsImsIot_TP_behavior_GM.ttcn b/ttcn/AtsImsIot/AtsImsIot_TP_behavior_GM.ttcn index cec6cb6aaee05febe453544f7d2187da7a9c8208..e51ee8cf49d98032d2afd553946deb14492288d3 100644 --- a/ttcn/AtsImsIot/AtsImsIot_TP_behavior_GM.ttcn +++ b/ttcn/AtsImsIot/AtsImsIot_TP_behavior_GM.ttcn @@ -220,6 +220,117 @@ module AtsImsIot_TP_behavior_GM { } } // End of function f_mtc_check_TP_GM_PCSCF_REGISTER_01 + /** + * @desc Verify that the P-CSCF successfully processes a first registration (Successful) + * Initial conditions with { + * the UE_A entity isAttachedTo the EPC_A and + * the UE_A entity isNotRegisteredTo the IMS_A and + * the UE_B entity isNotRegisteredTo the IMS_B + * } + * + * Expected behaviour + * ensure that { + * when { + * the UE_A entity isTriggeredToStart + * } + * then { + * the UE_A entity sends a REGISTER containing + * From indicating value PX_UE_A_SIP_URI, + * To indicating value PX_UE_A_SIP_URI, + * CallId indicating value PX_UE_A_CALLID, + * Via indicating value PX_UE_A_VIA, + * Authorization containing + * Authentication_Schema indicating value PX_TO_BE_DEFINED, + * Authentication_URI indicating value PX_TO_BE_DEFINED, + * Username indicating value PX_UE_A_USERNAME, + * Realm indicating value PX_UE_A_REALM, + * Algorithm indicating value PX_UE_A_AUTH_ALG, + * Nonce indicating value "", + * not term_ioi, + * not SecurityClient + * ;; + * to the IMS_P_CSCF_A entity + * and the UE_A entity receives an 401_Unauthorized containing + * From indicating value PX_UE_A_SIP_URI, + * To indicating value PX_UE_A_SIP_URI, + * CallId indicating value PX_UE_A_CALLID, + * Via indicating value PX_UE_A_VIA, + * Path, + * Warning, + * PAccessNetworkInfo, + * WwwAuthenticate containing + * Digest, + * Realm indicating value PX_UE_A_REALM, + * Algorithm indicating value PX_UE_A_AUTH_ALG, + * Nonce indicating value "not empty", + * qop indicating value "auth" + * ;, + * Contact indicating value "sos" + * ; + * from the IMS_P_CSCF_A entity + * } + * } + */ + function f_mtc_check_TP_GM_PCSCF_ECO_REGISTER_01( + in SipInterfaceMonitor p_monitorCompRef, + in boolean p_checkMessage := false + ) runs on ImsTestCoordinator { + if (isvalue(p_monitorCompRef)) { + var ImsUserInfo v_userInfoA := f_getSipUserId(PX_EUT_A); + var SipMessage v_sip; + + // Check the first REGISTER + p_monitorCompRef.start( + f_Iot_Sip_receive( + { + mw_SipRequest( + mw_TP_GM_PCSCF_ECO_REGISTER_01( // FIXME Add CallId... + mw_From_AddrUnion_SipUrl(omit, v_userInfoA.publicId, v_userInfoA.domain), + mw_To_AddrUnion_SipUrl(omit, v_userInfoA.publicId, v_userInfoA.domain), + mw_Authorization_other, + -, -, + mw_contact(mw_ContactAddress) + ) + ) + }, + { + mw_SipRequest(mw_REGISTER_Request_Base) + }, + {0, omit}, + "TP_GM_PCSCF_REGISTER_01 - First request", + true, + p_checkMessage + ) + ); + p_monitorCompRef.done; + // Retrieve messge + f_getSipMsgFromMonitor(p_monitorCompRef, v_sip); + if (not(isbound(v_sip))) { + return; + } + // Check REGISTER 401 Unauthorized response + p_monitorCompRef.start( + f_Iot_Sip_receive( + { + mw_SipResponse(mw_401Unauthorized(v_sip.request.msgHeader.cSeq, mw_WwwAuthenticate)) + }, + { + mw_SipResponse(mw_401Unauthorized_Base), + mw_SipResponse(mw_Response_4xx_Base( + v_sip.request.msgHeader.callId, + v_sip.request.msgHeader.cSeq + )) + }, + {0, omit}, + "TP_GM_PCSCF_REGISTER_01 - 401 Unauthorized", + false, + p_checkMessage + ) + ); + p_monitorCompRef.done; + } + } // End of function f_mtc_check_TP_GM_PCSCF_ECO_REGISTER_01 + /** * @desc Verify that the P-CSCF successfully processes a first registration (Successful) * Initial conditions with { @@ -424,6 +535,104 @@ module AtsImsIot_TP_behavior_GM { } } // End of function f_mtc_check_TP_GM_PCSCF_REGISTER_03 + /** + * @desc Verify that the P-CSCF successfully processes an invalid first registration (Unsuccessful). + * Initial conditions with { + * the UE_A entity isAttachedTo the EPC_A and + * the UE_A entity isNotRegisteredTo the IMS_A and + * the UE_B entity isNotRegisteredTo the IMS_B + * } + * + * Expected behaviour + * ensure that { + * when { + * the UE_A entity isTriggeredToStart + * } + * then { + * the IMS_P_CSCF_A entity receives a REGISTER containing + * From indicating value PX_UE_A_SIP_URI, + * To indicating value PX_UE_A_SIP_URI, + * CallId indicating value PX_UE_A_CALLID, + * Via indicating value PX_UE_A_VIA, + * Authorization containing + * Authentication_Schema indicating value PX_TO_BE_DEFINED, + * Authentication_URI indicating value PX_TO_BE_DEFINED, + * Username indicating value PX_UE_A_INVALID_USERNAME, + * Realm indicating value PX_UE_A_REALM, + * Algorithm indicating value PX_UE_A_AUTH_ALG, + * Nonce indicating value "" + * ;; + * from the UE_A entity + * and the IMS_P_CSCF_A entity sends an 404_NotFound containing + * From indicating value PX_UE_A_SIP_URI, + * To indicating value PX_UE_A_SIP_URI, + * CallId indicating value PX_UE_A_CALLID + * ; + * to the UE_A entity + * } + * } + */ + function f_mtc_check_TP_GM_PCSCF_ECO_REGISTER_03( + in SipInterfaceMonitor p_monitorCompRef, + in boolean p_checkMessage := false + ) runs on ImsTestCoordinator { + if (isvalue(p_monitorCompRef)) { + var ImsUserInfo v_userInfoA := f_getSipUserId(PX_EUT_A); // User removed from HSS + var SipMessage v_sip; + + // Check the first REGISTER + p_monitorCompRef.start( + f_Iot_Sip_receive( + { + mw_SipRequest( + mw_TP_GM_PCSCF_ECO_REGISTER_03( + mw_From_AddrUnion_SipUrl(omit, v_userInfoA.publicId, v_userInfoA.domain), + mw_To_AddrUnion_SipUrl(omit, v_userInfoA.publicId, v_userInfoA.domain), + mw_Authorization_other, + -, -, + mw_contact(mw_ContactAddress) + ) + ) + }, + { + mw_SipRequest(mw_REGISTER_Request_Base) + }, + {0, omit}, + "TP_GM_PCSCF_REGISTER_03 - First request", + true, + p_checkMessage + ) + ); + p_monitorCompRef.done; + // Retrieve messge + f_getSipMsgFromMonitor(p_monitorCompRef, v_sip); + if (not(isbound(v_sip))) { + return; + } + log("v_sip", v_sip); + // Check REGISTER 404 Not Found response + p_monitorCompRef.start( + f_Iot_Sip_receive( + { + mw_SipResponse(mw_404NotFound(v_sip.request.msgHeader.cSeq/*, mw_WwwAuthenticate*/)), + mw_SipResponse(mw_480TemporaryUnavailable(-, v_sip.request.msgHeader.cSeq/*, mw_WwwAuthenticate*/)) + }, + { + mw_SipResponse(mw_Response_4xx_Base( + v_sip.request.msgHeader.callId, + v_sip.request.msgHeader.cSeq + )) + }, + {0, omit}, + "TP_GM_PCSCF_REGISTER_03 - 404 Not Found", + false, + p_checkMessage + ) + ); + p_monitorCompRef.done; + } + } // End of function f_mtc_check_TP_GM_PCSCF_ECO_REGISTER_03 + function f_mtc_check_TP_GM_PCSCF_REGISTER_04( // FIXME RMI To be reviewed in SipInterfaceMonitor p_monitorCompRef, in boolean p_checkMessage := false diff --git a/ttcn/AtsImsIot/AtsImsIot_TP_behavior_MW_IS.ttcn b/ttcn/AtsImsIot/AtsImsIot_TP_behavior_MW_IS.ttcn index 21076ef9a2207c352d39fc2ae51efc3189860372..14428e20fa296038bbee4135ac3afe5a58725a07 100644 --- a/ttcn/AtsImsIot/AtsImsIot_TP_behavior_MW_IS.ttcn +++ b/ttcn/AtsImsIot/AtsImsIot_TP_behavior_MW_IS.ttcn @@ -190,6 +190,107 @@ module AtsImsIot_TP_behavior_MW_IS { } } // End of function f_mtc_check_TP_MW_ICSCF_REGISTER_01 + /** + * @desc Verify that the I-CSCF successfully processes a first registration (Successful). + * Initial conditions with { + * the UE_A entity isAttachedTo the EPC_A and + * the UE_A entity isNotRegisteredTo the IMS_A and + * the UE_B entity isNotRegisteredTo the IMS_B + * } + * + * Expected behaviour + * ensure that { + * when { + * the IMS_I_CSCF_A entity receives a REGISTER containing + * From indicating value PX_UE_A_SIP_URI, + * To indicating value PX_UE_A_SIP_URI, + * CallId indicating value PX_UE_A_CALLID, + * Via indicating value PX_UE_A_VIA, + * ; + * from the IMS_P_CSCF_A entity + * } + * then { + * the IMS_I_CSCF_A entity sends an 401_Unauthorized containing + * From indicating value PX_UE_A_SIP_URI, + * To indicating value PX_UE_A_SIP_URI, + * CallId indicating value PX_UE_A_CALLID, + * Via indicating value PX_UE_A_VIA, + * Path, + * Warning, + * PAccessNetworkInfo, + * WwwAuthenticate containing + * Digest, + * Realm indicating value PX_UE_A_REALM, + * Algorithm indicating value PX_UE_A_AUTH_ALG, + * Nonce indicating value "not empty", + * qop indicating value "auth" + * ;, + * Contact indicating value "sos" + * ; + * to the IMS_S_CSCF_A entity + * } + * } + */ + function f_mtc_check_TP_MW_ICSCF_ECO_REGISTER_01( + in SipInterfaceMonitor p_monitorCompRef, + in boolean p_checkMessage := false + ) runs on ImsTestCoordinator { + if (isvalue(p_monitorCompRef)){ + var ImsUserInfo v_userInfoA := f_getSipUserId(PX_EUT_A); + var SipMessage v_sip; + + // Check the first REGISTER + p_monitorCompRef.start( + f_Iot_Sip_receive( + { + mw_SipRequest( + mw_TP_MW_ICSCF_ECO_REGISTER_01( + mw_From_AddrUnion_SipUrl(omit, v_userInfoA.publicId, v_userInfoA.domain), + mw_To_AddrUnion_SipUrl(omit, v_userInfoA.publicId, v_userInfoA.domain), + mw_Authorization_other,/*(mw_credentialIntegrityYes)*/ + -, -, -, + mw_contact(mw_ContactAddress) + ) + ) + }, + { + mw_SipRequest(mw_REGISTER_Request_Base) + }, + {0, omit}, + "TP_MW_ICSCF_REGISTER_01 - First request", + true, + p_checkMessage + ) + ); + p_monitorCompRef.done; + // Retrieve messge + f_getSipMsgFromMonitor(p_monitorCompRef, v_sip); + if (not(isbound(v_sip))) { + return; + } + // Check REGISTER 401 Unauthorized response + p_monitorCompRef.start( + f_Iot_Sip_receive( + { + mw_SipResponse(mw_401Unauthorized(v_sip.request.msgHeader.cSeq, mw_WwwAuthenticate)) + }, + { + mw_SipResponse(mw_401Unauthorized_Base), + mw_SipResponse(mw_Response_4xx_Base( + v_sip.request.msgHeader.callId, + v_sip.request.msgHeader.cSeq + )) + }, + {0, omit}, + "TP_MW_ICSCF_REGISTER_01 - 401 Unauthorized", + false, + p_checkMessage + ) + ); + p_monitorCompRef.done; + } + } // End of function f_mtc_check_TP_MW_ICSCF_ECO_REGISTER_01 + /** * @desc Verify that the I-CSCF successfully processes a full registration (Successful). * Initial conditions with { @@ -395,6 +496,102 @@ module AtsImsIot_TP_behavior_MW_IS { } } // End of function f_mtc_check_TP_MW_ICSCF_REGISTER_03 + /** + * @desc Verify that the I-CSCF successfully processes a invalid first registration (Unsuccessful). + * Initial conditions with { + * the UE_A entity isAttachedTo the EPC_A and + * the UE_A entity isNotRegisteredTo the IMS_A and + * the UE_B entity isNotRegisteredTo the IMS_B + * } + * + * Expected behaviour + * ensure that { + * when { + * the IMS_I_CSCF_A entity receives a REGISTER containing + * From indicating value PX_UE_A_SIP_URI, + * To indicating value PX_UE_A_SIP_URI, + * CallId indicating value PX_UE_A_CALLID, + * Via indicating value PX_UE_A_VIA, + * Authorization containing + * Authentication_Schema indicating value PX_TO_BE_DEFINED, + * Authentication_URI indicating value PX_TO_BE_DEFINED, + * Username indicating value PX_UE_A_INVALID_USERNAME, + * Realm indicating value PX_UE_A_REALM, + * Algorithm indicating value PX_UE_A_AUTH_ALG, + * Nonce indicating value "not empty", + * qop indicating value "auth", + * not SecurityClient + * ;; + * from the IMS_P_CSCF_A entity + * } + * then { + * the IMS_I_CSCF_A entity sends an 404_NotFound containing + * From indicating value PX_UE_A_SIP_URI, + * To indicating value PX_UE_A_SIP_URI, + * CallId indicating value PX_UE_A_CALLID + * ; + * to the IMS_P_CSCF_A entity + * } + * } + */ + function f_mtc_check_TP_MW_ICSCF_ECO_REGISTER_03( + in SipInterfaceMonitor p_monitorCompRef, + in boolean p_checkMessage := true + ) runs on ImsTestCoordinator { + if (isvalue(p_monitorCompRef)){ + var ImsUserInfo v_userInfoA := f_getSipUserId(PX_EUT_A); // User removed from HSS + var SipMessage v_sip; + + // Check the first REGISTER + p_monitorCompRef.start( + f_Iot_Sip_receive( + { + mw_SipRequest( + mw_TP_MW_ICSCF_ECO_REGISTER_03( + mw_From_AddrUnion_SipUrl(omit, v_userInfoA.publicId, v_userInfoA.domain), + mw_To_AddrUnion_SipUrl(omit, v_userInfoA.publicId, v_userInfoA.domain), + mw_Authorization_other/*(mw_credentialIntegrityYes)*/ + ) + ) + }, + { + mw_SipRequest(mw_REGISTER_Request_Base) + }, + {0, omit}, + "TP_MW_ICSCF_REGISTER_03 - First request", + true, + p_checkMessage + ) + ); + p_monitorCompRef.done; + // Retrieve messge + f_getSipMsgFromMonitor(p_monitorCompRef, v_sip); + if (not(isbound(v_sip))) { + return; + } + // Check REGISTER 404 Not Found response + p_monitorCompRef.start( + f_Iot_Sip_receive( + { + mw_SipResponse(mw_404NotFound(v_sip.request.msgHeader.cSeq, mw_WwwAuthenticate)), + mw_SipResponse(mw_480TemporaryUnavailable(-, v_sip.request.msgHeader.cSeq, mw_WwwAuthenticate)) + }, + { + mw_SipResponse(mw_Response_4xx_Base( + v_sip.request.msgHeader.callId, + v_sip.request.msgHeader.cSeq + )) + }, + {0, omit}, + "TP_MW_ICSCF_REGISTER_03 - 404 Not Found", + false, + p_checkMessage + ) + ); + p_monitorCompRef.done; + } + } // End of function f_mtc_check_TP_MW_ICSCF_ECO_REGISTER_03 + function f_mtc_check_TP_MW_ICSCF_REGISTER_04( // FIXME RMI To be reviewed in SipInterfaceMonitor p_monitorCompRef, in boolean p_checkMessage := true diff --git a/ttcn/AtsImsIot/AtsImsIot_TP_behavior_MW_PS.ttcn b/ttcn/AtsImsIot/AtsImsIot_TP_behavior_MW_PS.ttcn index c6aaded8d4ba8de6bfaf61368c3f3fd0f97b9ff4..f46dad41ef0ae4a2e601a9aec334b4c37ee211fd 100644 --- a/ttcn/AtsImsIot/AtsImsIot_TP_behavior_MW_PS.ttcn +++ b/ttcn/AtsImsIot/AtsImsIot_TP_behavior_MW_PS.ttcn @@ -215,6 +215,119 @@ module AtsImsIot_TP_behavior_MW_PS { } } // End of function f_mtc_check_TP_MW_PCSCF_REGISTER_01 + /** + * @desc Verify that the P-CSCF successfully processes a first registration (Successful). + * Initial conditions with { + * the UE_A entity isAttachedTo the EPC_A and + * the UE_A entity isNotRegisteredTo the IMS_A and + * the UE_B entity isNotRegisteredTo the IMS_B + * } + * + * Expected behaviour + * ensure that { + * when { + * the IMS_P_CSCF_A entity receives a REGISTER containing + * From indicating value PX_UE_A_SIP_URI, + * To indicating value PX_UE_A_SIP_URI, + * CallId indicating value PX_UE_A_CALLID, + * Via indicating value PX_UE_A_VIA, + * ; + * from the UE_A entity + * } + * then { + * the IMS_P_CSCF_A entity sends a REGISTER containing + * From indicating value PX_UE_A_SIP_URI, + * To indicating value PX_UE_A_SIP_URI, + * CallId indicating value PX_UE_A_CALLID, + * Via indicating value PX_UE_A_VIA, + * PChargingVector containing + * icid indicating value PX_TO_BE_DEFINED, + * PVisitedNetworkID indicating value PX_TO_BE_DEFINED, + * Require_HDR indicating value "path", + * Supported indicating value "path" + * ;; + * to the IMS_I_CSCF_A entity + * and the IMS_P_CSCF_A entity sends an 401_Unauthorized containing + * From indicating value PX_UE_A_SIP_URI, + * To indicating value PX_UE_A_SIP_URI, + * CallId indicating value PX_UE_A_CALLID, + * Via indicating value PX_UE_A_VIA, + * Path, + * Warning, + * PAccessNetworkInfo, + * WwwAuthenticate containing + * Digest, + * Realm indicating value PX_UE_A_REALM, + * Algorithm indicating value PX_UE_A_AUTH_ALG, + * Nonce indicating value "not empty", + * qop indicating value "auth" + * ;, + * Contact indicating value "sos" + * ; + * to the UE_A entity + * } + * } + */ + function f_mtc_check_TP_MW_PCSCF_ECO_REGISTER_01( + in SipInterfaceMonitor p_monitorCompRef, + in boolean p_checkMessage := false + ) runs on ImsTestCoordinator { + if (isvalue(p_monitorCompRef)) { + var ImsUserInfo v_userInfoA := f_getSipUserId(PX_EUT_A); + var SipMessage v_sip; + + // Check first REGISTER request + p_monitorCompRef.start( + f_Iot_Sip_receive( + { + mw_SipRequest( + mw_TP_MW_PCSCF_ECO_REGISTER_01( // FIXME Add CallId... + mw_From_AddrUnion_SipUrl(omit, v_userInfoA.publicId, v_userInfoA.domain), + mw_To_AddrUnion_SipUrl(omit, v_userInfoA.publicId, v_userInfoA.domain), + mw_Authorization_other,/*(mw_credentialIntegrityYes)*/ + -, -, + mw_contact(mw_ContactAddress) + ) + ) + }, + { + mw_SipRequest(mw_REGISTER_Request_Base) + }, + {0, omit}, + "TP_MW_PCSCF_REGISTER_01 - First request", + true, + p_checkMessage + ) + ); + p_monitorCompRef.done; + // Retrieve messge + f_getSipMsgFromMonitor(p_monitorCompRef, v_sip); + if (not(isbound(v_sip))) { + return; + } + // Check REGISTER 401 Unauthorized response + p_monitorCompRef.start( + f_Iot_Sip_receive( + { + mw_SipResponse(mw_401Unauthorized(v_sip.request.msgHeader.cSeq, mw_WwwAuthenticate)) + }, + { + mw_SipResponse(mw_401Unauthorized_Base), + mw_SipResponse(mw_Response_4xx_Base( + v_sip.request.msgHeader.callId, + v_sip.request.msgHeader.cSeq + )) + }, + {0, omit}, + "TP_MW_PCSCF_REGISTER_01 - 401 Unauthorized", + false, + p_checkMessage + ) + ); + p_monitorCompRef.done; + } + } // End of function f_mtc_check_TP_MW_PCSCF_ECO_REGISTER_01 + /** * @desc Verify that the P-CSCF successfully processes a full registration (Successful). * Initial conditions with { @@ -447,6 +560,115 @@ module AtsImsIot_TP_behavior_MW_PS { } } // End of function f_mtc_check_TP_MW_PCSCF_REGISTER_03 + /** + * @desc Verify that the P-CSCF successfully processes a invalid first registration (Unsuccessful). + * Initial conditions with { + * the UE_A entity isAttachedTo the EPC_A and + * the UE_A entity isNotRegisteredTo the IMS_A and + * the UE_B entity isNotRegisteredTo the IMS_B + * } + * + * Expected behaviour + * ensure that { + * when { + * the IMS_P_CSCF_A entity receives a REGISTER containing + * From indicating value PX_UE_A_SIP_URI, + * To indicating value PX_UE_A_SIP_URI, + * CallId indicating value PX_UE_A_CALLID, + * Via indicating value PX_UE_A_VIA, + * Authorization containing + * Authentication_Schema indicating value PX_TO_BE_DEFINED, + * Authentication_URI indicating value PX_TO_BE_DEFINED, + * Username indicating value PX_UE_A_INVALID_USERNAME, + * Realm indicating value PX_UE_A_REALM, + * Algorithm indicating value PX_UE_A_AUTH_ALG, + * Nonce indicating value "" + * ;; + * from the UE_A entity + * } + * then { + * the IMS_P_CSCF_A entity sends a REGISTER containing + * From indicating value PX_UE_A_SIP_URI, + * To indicating value PX_UE_A_SIP_URI, + * CallId indicating value PX_UE_A_CALLID, + * Via indicating value PX_UE_A_VIA, + * Authorization containing + * Authentication_Schema indicating value PX_TO_BE_DEFINED, + * Authentication_URI indicating value PX_TO_BE_DEFINED, + * Username indicating value PX_UE_A_INVALID_USERNAME, + * Realm indicating value PX_UE_A_REALM, + * Algorithm indicating value PX_UE_A_AUTH_ALG, + * Nonce indicating value "" + * ;; + * to the IMS_I_CSCF_A entity + * and the IMS_I_CSCF_A entity sends an 404_NotFound containing + * From indicating value PX_UE_A_SIP_URI, + * To indicating value PX_UE_A_SIP_URI, + * CallId indicating value PX_UE_A_CALLID, + * Via indicating value PX_UE_A_VIA, + * ; + * to the IMS_P_CSCF_A entity + * } + * } + */ + function f_mtc_check_TP_MW_PCSCF_ECO_REGISTER_03( + in SipInterfaceMonitor p_monitorCompRef, + in boolean p_checkMessage := false + ) runs on ImsTestCoordinator { + if (isvalue(p_monitorCompRef)) { + var ImsUserInfo v_userInfoA := f_getSipUserId(PX_EUT_A); // User removed from HSS + var SipMessage v_sip; + + // Check the first REGISTER + p_monitorCompRef.start( + f_Iot_Sip_receive( + { + mw_SipRequest( + mw_TP_MW_PCSCF_ECO_REGISTER_01( + mw_From_AddrUnion_SipUrl(omit, v_userInfoA.publicId, v_userInfoA.domain), + mw_To_AddrUnion_SipUrl(omit, v_userInfoA.publicId, v_userInfoA.domain), + mw_Authorization_other, + -, -, + mw_contact(mw_ContactAddress) + ) + ) + }, + { mw_SipRequest(mw_REGISTER_Request_Base) }, + {0, omit}, + "TP_MW_PCSCF_REGISTER_03 - First request", + true, + p_checkMessage + ) + ); + p_monitorCompRef.done; + // Retrieve messge + f_getSipMsgFromMonitor(p_monitorCompRef, v_sip); + if (not(isbound(v_sip))) { + return; + } + // Check REGISTER 404 Not Found response + p_monitorCompRef.start( + f_Iot_Sip_receive( + { + mw_SipResponse(mw_404NotFound(v_sip.request.msgHeader.cSeq/*, mw_WwwAuthenticate*/)), + mw_SipResponse(mw_480TemporaryUnavailable(-, v_sip.request.msgHeader.cSeq/*, mw_WwwAuthenticate*/)) + }, + { + mw_SipResponse(mw_Response_4xx_Base( + v_sip.request.msgHeader.callId, + v_sip.request.msgHeader.cSeq + )) + }, + {0, omit}, + "TP_MW_PCSCF_REGISTER_03 - 404 Not Found", + false, + p_checkMessage + ) + ); + p_monitorCompRef.done; + } + } // End of function f_mtc_check_TP_MW_PCSCF_ECO_REGISTER_03 + function f_mtc_check_TP_MW_PCSCF_REGISTER_04( // FIXME RMI To be reviewed in SipInterfaceMonitor p_monitorCompRef, in boolean p_checkMessage := true diff --git a/ttcn/AtsImsIot/AtsImsIot_Templates_GM.ttcn b/ttcn/AtsImsIot/AtsImsIot_Templates_GM.ttcn index ce18a371d79cd7c25531969f7ede57b2761eff34..6f8599a1ad15480870079d03ee9a631e4f813164 100644 --- a/ttcn/AtsImsIot/AtsImsIot_Templates_GM.ttcn +++ b/ttcn/AtsImsIot/AtsImsIot_Templates_GM.ttcn @@ -215,6 +215,19 @@ module AtsImsIot_Templates_GM { } } // End of template mw_TP_GM_PCSCF_REGISTER_01 + template(present) REGISTER_Request mw_TP_GM_PCSCF_ECO_REGISTER_01( + template (present) From p_from := ?, + template (present) To p_to := ?, + template (present) Authorization p_authorization := ?, + template PChargingVector p_pChargingVector := *, + template PVisitedNetworkID p_pVisitedNetworkID := *, + template (present) Contact p_contact := ?, + ) modifies mw_TP_GM_PCSCF_REGISTER_01 := { + msgHeader := { + contact := p_contact + } + } // End of template mw_TP_GM_PCSCF_ECO_REGISTER_01 + template(present) REGISTER_Request mw_TP_GM_PCSCF_REGISTER_02( template (present) From p_from := ?, template (present) To p_to := ?, @@ -233,6 +246,15 @@ module AtsImsIot_Templates_GM { ) modifies mw_TP_GM_PCSCF_REGISTER_01 := { } // End of template mw_TP_GM_PCSCF_REGISTER_03 + template(present) REGISTER_Request mw_TP_GM_PCSCF_ECO_REGISTER_03( + template (present) From p_from := ?, + template (present) To p_to := ?, + template (present) Authorization p_authorization := ?, + template PChargingVector p_pChargingVector := *, + template PVisitedNetworkID p_pVisitedNetworkID := * + ) modifies mw_TP_GM_PCSCF_ECO_REGISTER_01 := { + } // End of template mw_TP_GM_PCSCF_ECO_REGISTER_03 + template(present) REGISTER_Request mw_TP_GM_PCSCF_REGISTER_04( template (present) From p_from := ?, template (present) To p_to := ?, diff --git a/ttcn/AtsImsIot/AtsImsIot_Templates_MW.ttcn b/ttcn/AtsImsIot/AtsImsIot_Templates_MW.ttcn index c03827e17930ed28967240fc232f93ef2474e298..a7fefb5363c13aba4e9bd49762eb7bb978058a93 100644 --- a/ttcn/AtsImsIot/AtsImsIot_Templates_MW.ttcn +++ b/ttcn/AtsImsIot/AtsImsIot_Templates_MW.ttcn @@ -223,6 +223,19 @@ module AtsImsIot_Templates_MW { } } // End of template mw_TP_MW_PCSCF_REGISTER_01 + template(present) REGISTER_Request mw_TP_MW_PCSCF_ECO_REGISTER_01( + template (present) From p_from := ?, + template (present) To p_to := ?, + template (present) Authorization p_authorization := ?, + template PChargingVector p_pChargingVector := *, + template PVisitedNetworkID p_pVisitedNetworkID := *, + template (present) Contact p_contact := ?, + ) modifies mw_REGISTER_authorizedRequest_wo_securityheaders_IMS := { + msgHeader := { + contact := p_contact + } + } // End of template mw_TP_MW_PCSCF_REGISTER_01 + template(present) REGISTER_Request mw_TP_MW_PCSCF_REGISTER_02( template (present) From p_from := ?, template (present) To p_to := ?, @@ -789,6 +802,20 @@ module AtsImsIot_Templates_MW { } } // End of template mw_TP_MW_ICSCF_REGISTER_01 + template(present) REGISTER_Request mw_TP_MW_ICSCF_ECO_REGISTER_01( + template (present) From p_from := ?, + template (present) To p_to := ?, + template (present) Authorization p_authorization := ?, + template (present) Path p_Path := ?, + template (present) PChargingVector p_pChargingVector := ?, + template (present) PVisitedNetworkID p_pVisitedNetworkID := ?, + template (present) Contact p_contact := ? + ) modifies mw_TP_MW_ICSCF_REGISTER_01 := { + msgHeader := { + contact := p_contact + } + } // End of template mw_TP_MW_ICSCF_ECO_REGISTER_01 + template(present) REGISTER_Request mw_TP_MW_ICSCF_REGISTER_02( template (present) From p_from := ?, template (present) To p_to := ?, @@ -829,7 +856,18 @@ module AtsImsIot_Templates_MW { } } // End of template mw_TP_MW_ICSCF_REGISTER_03 - template(present) REGISTER_Request mw_TP_MW_ICSCF_REGISTER_04( + template(present) REGISTER_Request mw_TP_MW_ICSCF_ECO_REGISTER_03( + template (present) From p_from := ?, + template (present) To p_to := ?, + template (present) Authorization p_authorization := ?, + template (present) Path p_Path := ?, + template (present) PChargingVector p_pChargingVector := ?, + template (present) PVisitedNetworkID p_pVisitedNetworkID := ?, + template (present) Contact p_contact := ? + ) modifies mw_TP_MW_ICSCF_ECO_REGISTER_01 := { + } // End of template mw_TP_MW_ICSCF_ECO_REGISTER_03 + + template(present) REGISTER_Request mw_TP_MW_ICSCF_REGISTER_04( template (present) From p_from := ?, template (present) To p_to := ?, template (present) Authorization p_authorization := ?,