Commit beefd407 authored by pintar's avatar pintar
Browse files

corrections due to validation of STF346 from week 47

parent 81d98bb0
Loading
Loading
Loading
Loading
+34 −23
Original line number Diff line number Diff line
@@ -178,13 +178,22 @@ module LibIms_Steps
		*/
		function f_setHeadersNOTIFY(inout CSeq p_cSeq_s, in integer p_to_user) runs on ImsComponent
		{      
				LibSip_Steps.f_setHeadersNOTIFY(p_cSeq_s);
				
				vc_branch := c_branchCookie & f_getRndTag();
				vc_via:={
					fieldName := VIA_E,
					viaBody 	 := {valueof(m_ViaBody_virtual_XCSCF(vc_branch, vc_userprofile))}
				};
				
				vc_to := f_initToHeader(p_to_user); // init of vc_to using userProfile identifier

				vc_from := f_initFromHeader(vc_userprofile.id, f_getRndTag()); // init of vc_from using userProfile identifier
        
				vc_requestUri := f_initSipUrl(p_to_user); // Request URI of Invite is identical with To header
				
				LibSip_Steps.f_setHeadersNOTIFY(p_cSeq_s);
				//contact header initialization for sending of NOTIFY from CSCF component
				vc_contact := valueof(m_Contact(m_SipUrl_currIpaddr_CSCF(vc_userprofile)));
	  
		}// end f_setHeadersNOTIFY
		
@@ -455,18 +464,18 @@ module LibIms_Steps
			vc_userprofile.registrarDomain := PX_IMS_SUT_UE4_REGISTRAR;
			}
			
			case (c_userProfile_UE1atSUTvisiting) { //variant c_userProfile_UE1atSUTvisiting - UE4 parameters
			vc_userprofile.currPort := PX_IMS_TS_UE4_PORT;
			vc_userprofile.currIpaddr := PX_IMS_TS_UE4_IPADDR;
			vc_userprofile.contactPort := PX_IMS_TS_UE4_PORT;
			vc_userprofile.contactIpaddr := PX_IMS_TS_UE4_IPADDR;
			vc_userprofile.bearerIpaddr := PX_IMS_SUT_UE4_BEARER_IPADDR;	
			vc_userprofile.homeDomain := PX_IMS_SUT_UE4_HOME_DOMAIN;	
			vc_userprofile.publUsername := PX_IMS_SUT_UE4_PUBLIC_USER;
			vc_userprofile.qop := PX_IMS_SUT_UE4_QOP;
			vc_userprofile.privUsername := PX_IMS_SUT_UE4_PRIVAT_USERNAME;	
			vc_userprofile.passwd := PX_IMS_SUT_UE4_PRIVAT_PASSWD;	
			vc_userprofile.registrarDomain := PX_IMS_SUT_UE4_REGISTRAR;
			case (c_userProfile_UE1atSUTvisiting) { //variant c_userProfile_UE1atSUTvisiting - UE3 parameters
			vc_userprofile.currPort := PX_IMS_TS_UE1_PORT;
			vc_userprofile.currIpaddr := PX_IMS_TS_UE1_IPADDR;
			vc_userprofile.contactPort := PX_IMS_TS_UE1_PORT;
			vc_userprofile.contactIpaddr := PX_IMS_TS_UE1_IPADDR;
			vc_userprofile.bearerIpaddr := PX_IMS_SUT_UE3_BEARER_IPADDR;	
			vc_userprofile.homeDomain := PX_IMS_SUT_UE3_HOME_DOMAIN;	
			vc_userprofile.publUsername := PX_IMS_SUT_UE3_PUBLIC_USER;
			vc_userprofile.qop := PX_IMS_SUT_UE3_QOP;
			vc_userprofile.privUsername := PX_IMS_SUT_UE3_PRIVAT_USERNAME;	
			vc_userprofile.passwd := PX_IMS_SUT_UE3_PRIVAT_PASSWD;	
			vc_userprofile.registrarDomain := PX_IMS_SUT_UE3_REGISTRAR;
			}
			
//			//temporary not used and it can be deleted during validation
@@ -512,7 +521,7 @@ module LibIms_Steps
			vc_userprofile.registrarDomain := PX_IMS_SUT_UE1_REGISTRAR; 	// Authorization
			}
			
			case (c_userProfile_ICSCFwithHomeUE) { 						//variant c_userProfile_ICSCFwithHomeUE
			case (c_userProfile_ICSCFwithHomeUE) { 						//variant c_userProfile_ICSCFwithHomeUE - UE4 parameters
			vc_userprofile.currPort := PX_IMS_TS_ICSCF_PORT;			// via (Mw interface of TS)
			vc_userprofile.currIpaddr := PX_IMS_TS_ICSCF_IPADDR;		// via
			vc_userprofile.contactPort := PX_IMS_TS_UE4_PORT;			// contact (simulated UE)
@@ -598,7 +607,7 @@ module LibIms_Steps
			vc_userprofile.registrarDomain := PX_IMS_SUT_UE1_REGISTRAR; 	// Authorization
			}

			case (c_userProfile_SCSCFwithHomeUE) { 						//variant c_userProfile_SCSCFwithHomeUE
			case (c_userProfile_SCSCFwithHomeUE) { 						//variant c_userProfile_SCSCFwithHomeUE  - UE4 parameters
			vc_userprofile.currPort := PX_IMS_TS_SCSCF_PORT;			// via (Mw interface of TS)
			vc_userprofile.currIpaddr := PX_IMS_TS_SCSCF_IPADDR;		// via
			vc_userprofile.contactPort := PX_IMS_TS_UE4_PORT;			// contact (simulated UE)
@@ -1073,11 +1082,12 @@ module LibIms_Steps
				);

			//Awaiting 2nd REGISTER	with authorization header
			f_awaitingREGISTER(mw_REGISTER_authorizedRequest_IMS(m_Authorization_digest(mw_digestResponse(c_Integrity_protected_yes))));
			f_awaitingREGISTER(mw_REGISTER_unauthorizedRequest_IMS);//mw_REGISTER_authorizedRequest_IMS(m_Authorization_digest(mw_digestResponse(c_Integrity_protected_yes))));
//			f_awaitingREGISTER(mw_REGISTER_authorizedRequest_IMS(m_Authorization_digest(mw_digestResponse(c_Integrity_protected_yes))));

			// 200OK to complete the request
			vc_contact := vc_request.msgHeader.contact;
			vc_contact.contactBody.contactAddresses[0].contactParams := {{"expires",int2str(0)}};
//			vc_contact := vc_request.msgHeader.contact;
//			vc_contact.contactBody.contactAddresses[0].contactParams := {{"expires",int2str(0)}};
			v_passociated_url := vc_caller_From.addressField.nameAddr.addrSpec;
			f_sendResponse(m_Response_2xxonREGISTER_IMS(c_statusLine200,vc_callId, vc_cSeq,vc_callee_From, vc_callee_To, vc_via,vc_contact,f_initSipUrl(c_userProfile_SCSCFwithHomeUE),v_passociated_url));

@@ -1088,6 +1098,7 @@ module LibIms_Steps
		{	
			var SipUrl v_passociated_url;
			//Awaiting 1st REGISTER
  	
			f_awaitingREGISTER(mw_REGISTER_unauthorizedRequest_IMS);

			// 401 response
@@ -1098,11 +1109,11 @@ module LibIms_Steps
				);

			//Awaiting 2nd REGISTER	with authorization header
			f_awaitingREGISTER(mw_REGISTER_authorizedRequest_IMS(m_Authorization_digest(mw_digestResponse(c_Integrity_protected_yes))));
			f_awaitingREGISTER(mw_REGISTER_unauthorizedRequest_IMS);//mw_REGISTER_authorizedRequest_IMS(m_Authorization_digest(mw_digestResponse(c_Integrity_protected_yes))));

			// 200OK to complete the request
			vc_contact := vc_request.msgHeader.contact;
			vc_contact.contactBody.contactAddresses[0].contactParams := {{"expires",int2str(0)}};
//			vc_contact := vc_request.msgHeader.contact;
//			vc_contact.contactBody.contactAddresses[0].contactParams := {{"expires",int2str(0)}};
			v_passociated_url := vc_caller_From.addressField.nameAddr.addrSpec;
			f_sendResponse(m_Response_2xxonREGISTER_IMS(c_statusLine200,vc_callId, vc_cSeq,vc_callee_From, vc_callee_To, vc_via,vc_contact,f_initSipUrl(c_userProfile_SCSCFwithHomeUE),v_passociated_url));

+48 −18
Original line number Diff line number Diff line
@@ -42,9 +42,23 @@ module LibIms_Templates
	
group Subfields{

	template SemicolonParam_List mw_semicolonParams_realm (template charstring p_realm)	:=
		?; //superset({"realm",p_realm},{"rand",?},{"autn",?},{"algorithm","AKAv1-MD5"},{"ik",?},{"ck",?}) // ERROR HERE! Superset operation must contain value list - no templates!

	template SipUrl m_SipUrl_currIpaddr_CSCF(in SipUserProfile p_userprofile) :=  	//*  SIP-URL of the test system on SIP side
	{
			scheme := c_sipScheme,  		//*  contains "sip"
			userInfo := omit,		//*  optional
			hostPort :=
			{
		host := p_userprofile.currIpaddr,	//*  hostname, IPv4 or IPv6 as a charstring
		portField := p_userprofile.currPort	//* optional integer
			},
			urlParameters := omit,
			headers := omit
	} 
	
	template SemicolonParam_List mw_semicolonParams_realm (template charstring p_realm)	:=
	/*?;*/ 
	superset({"realm",p_realm},{"nonce",?},{"algorithm","AKAv1-MD5"},{"ik",?},{"ck",?}) ;//Working with TTWorkbench// ERROR HERE! Superset operation must contain value list - no templates!
	template SemicolonParam_List m_semicolonParams_language (template charstring p_language):=
		{{"language",p_language}}
	
@@ -91,7 +105,7 @@ group HeaderFieldTemplates{
						{nameAddr := {
						displayName := omit, 	 			// optional charstring
						addrSpec := {
                        				scheme := "sip",
                        				scheme := c_sipScheme,
                        				userInfo := {userOrTelephoneSubscriber:="registrar"},
                        				hostPort := {PX_IMS_TS_PCSCF_HOME_DOMAIN, PX_IMS_TS_PCSCF_PORT},
                        				urlParameters := omit,
@@ -139,23 +153,31 @@ group HeaderFieldTemplates{
	template PChargingVector m_pChargingVector_icid_TS :=
	{
		fieldName := P_CHARGING_VECTOR_E,
		chargeParams := {{id:="icid-value",		paramValue :="012345"}}
		chargeParams := {{id:=c_icid,		paramValue :=c_icid_value}}
	};
	
	template PChargingVector m_pChargingVector_fixedValue(charstring p_homeDomain) :=
	template PChargingVector m_pChargingVector_origIoi_fixedValue(charstring p_homeDomain) :=
	{
		fieldName := P_CHARGING_VECTOR_E,
		chargeParams := {{id:="icid-value",			paramValue :="123abc;"},
						 {id:="icid-generated-at",	paramValue :="192.1.1.10;"},
						 {id:="orig-ioi",			paramValue := p_homeDomain}}
		chargeParams := {{id:=c_icid,			paramValue :=c_icid_value &";"},
						 {id:=c_icid_generated_at,	paramValue :="192.1.1.10;"},
						 {id:=c_orig_ioi,			paramValue := p_homeDomain}}
	};
	
	template PChargingVector m_pChargingVector_fixedValue1(charstring p_homeDomain) :=
	template PChargingVector m_pChargingVector_termIoi_fixedValue(charstring p_homeDomain) :=
	{
		fieldName := P_CHARGING_VECTOR_E,
		chargeParams := {{id:=c_icid,			paramValue :=c_icid_value&";"},
							{id:=c_icid_generated_at,	paramValue :="192.1.1.10;"},
							{id:=c_term_ioi,			paramValue := p_homeDomain}}
	};
	
	template PChargingVector m_pChargingVector_origIoi_fixedValue1(charstring p_homeDomain) :=
	{
		fieldName := P_CHARGING_VECTOR_E,
		chargeParams := {
						 {id:="icid-generated-at",	paramValue :="192.1.1.10;"},
						 {id:="orig-ioi",			paramValue := p_homeDomain}}
						 {id:=c_icid_generated_at,	paramValue :="192.1.1.10;"},
						 {id:=c_orig_ioi,			paramValue := p_homeDomain}}
	};
	
	template PChargingVector mw_pChargingVector(template charstring p_id, template charstring p_paramValue) :=
@@ -315,6 +337,13 @@ group HeaderFieldTemplates{
	  viaParams:={{id :=c_branchId,paramValue :=branch_val}}
	}
	
	template ViaBody m_ViaBody_virtual_XCSCF(charstring branch_val,in SipUserProfile p_userprofile) :=
	{
			sentProtocol := m_SentProtocol(PX_SIP_TRANSPORT),
			sentBy:={host:=p_userprofile.currIpaddr, portField:= p_userprofile.currPort},
			viaParams:={{id :=c_branchId,paramValue :=branch_val}}
	}

	template Via m_via_notmatching:=
	{   
		fieldName := VIA_E,
@@ -1541,7 +1570,7 @@ group request_send {
			  {
				pAccessNetworkInfo := m_pAccessNetworkInfo_IEEE_11a,
				pChargingFunctionAddresses := m_pChargingFunctionAddresses_fixedValue,
				pChargingVector := m_pChargingVector_fixedValue(PX_IMS_SUT_UE1_HOME_DOMAIN),
				pChargingVector := m_pChargingVector_origIoi_fixedValue(PX_IMS_SUT_UE1_HOME_DOMAIN),
				require := p_require,
				route := p_route,
				supported := p_supported
@@ -2137,7 +2166,7 @@ group request_receive {

	template SUBSCRIBE_Request mw_SUBSCRIBE_Request_IMS (
		template From p_from, 
		To p_to, 
		template To p_to, 
		template PAssertedID p_pAssertedID, 
		template PChargingVector p_pChargingVector
	)  modifies mw_SUBSCRIBE_Request_Base := {
@@ -2149,7 +2178,7 @@ group request_receive {
		{	fromField := p_from,
			toField := p_to,
			event	:= m_Event_reg,
			pAccessNetworkInfo := m_pAccessNetworkInfo_IEEE_11a,
			pAccessNetworkInfo := *,
			pChargingVector := p_pChargingVector
		}
	}
@@ -2268,12 +2297,12 @@ group response_send
     }
 
	template Response m_Response_18XonINVITE_PchargingVector (StatusLine p_statusLine, CallId p_callId, CSeq p_cSeq,
		  From p_from, To p_to, Via p_via ) modifies m_Response_Base:=
		  From p_from, To p_to, Via p_via, template PChargingVector p_pChargingVector ) modifies m_Response_Base:=
	{
		msgHeader :=
		{
			pChargingFunctionAddresses := m_pChargingFunctionAddresses_fixedValue,
			pChargingVector := m_pChargingFunctionAddresses_fixedValue
			pChargingVector := p_pChargingVector

		}
	}
@@ -2510,12 +2539,13 @@ group response_send
	}

	template Response m_Response_2xxonINVITE_PchargingVector (StatusLine p_statusLine, CallId p_callId, CSeq p_cSeq,
		  From p_from, To p_to, Via p_via,template Route p_route, template RecordRoute p_recordroute, MessageBody p_mb ) modifies m_Response_mbody :=
		  From p_from, To p_to, Via p_via, template Route p_route, template RecordRoute p_recordroute, MessageBody p_mb, template Contact p_contact, template PChargingVector p_pChargingVector ) modifies m_Response_mbody :=
	{
		msgHeader :=
		{
			contact := p_contact,
			pChargingFunctionAddresses := m_pChargingFunctionAddresses_fixedValue,
			pChargingVector := m_pChargingFunctionAddresses_fixedValue
			pChargingVector := p_pChargingVector

		}
	}