Commit 1c5a3be6 authored by peter's avatar peter
Browse files

No commit message

No commit message
parent 2249bbf9
Loading
Loading
Loading
Loading
+517 −508
Original line number Original line Diff line number Diff line
@@ -175,25 +175,6 @@
			 nbrSolOptions:= p_opts
			 nbrSolOptions:= p_opts
		 }
		 }


		 /*
		  *	@param  p_src Binary IPv6 address associated with the
		  *          test component.
		  *	@param  p_dst Binary IPv6 address associated with NUT.
		  *	@param  p_targetAddr Binary IPv6 address associated with target.
		 */
		 template NeighborSolicitation mw_nbrSol_noExtHdr_anyOpts (	template Ipv6Address p_src,
															 template Ipv6Address p_dst,
															 Ipv6Address p_targetAddr) := {
			 ipv6Hdr := mw_ipHdr_srcDst(c_icmpHdr, p_src, p_dst),
			 extHdrList := omit,
			 icmpType:= c_nbrSol,
			 icmpCode:= c_icmpCode0,
			 checksum:= ?,
			 reserved:= 0,
			 targetAddr:= p_targetAddr,
			 nbrSolOptions:= *
		 }

		 /*
		 /*
		  *	@param  p_src Binary IPv6 address associated with the
		  *	@param  p_src Binary IPv6 address associated with the
		  *          test component.
		  *          test component.
@@ -267,7 +248,6 @@
		  *	@param  p_dst Binary IPv6 address associated with NUT.
		  *	@param  p_dst Binary IPv6 address associated with NUT.
		  *	@param  p_rFlag Router flag value.
		  *	@param  p_rFlag Router flag value.
		  *	@param  p_sFlag Solicited flag value.
		  *	@param  p_sFlag Solicited flag value.
		  *	@param  p_oFlag Override flag value.
		  *	@param  p_targetAddr Binary IPv6 address associated with target.
		  *	@param  p_targetAddr Binary IPv6 address associated with target.
		  *	@param  p_opts Neighborhood advertisement options value or template.
		  *	@param  p_opts Neighborhood advertisement options value or template.
		 */
		 */
@@ -298,7 +278,6 @@
		  * @param  p_hopLimit Hop Limit value to be used in the IPv6 Header.
		  * @param  p_hopLimit Hop Limit value to be used in the IPv6 Header.
		  *	@param  p_rFlag Router flag value.
		  *	@param  p_rFlag Router flag value.
		  *	@param  p_sFlag Solicited flag value.
		  *	@param  p_sFlag Solicited flag value.
		  *	@param  p_oFlag Override flag value.
		  *	@param  p_targetAddr Binary IPv6 address associated with target.
		  *	@param  p_targetAddr Binary IPv6 address associated with target.
		  *	@param  p_opts Neighborhood advertisement options value or template.
		  *	@param  p_opts Neighborhood advertisement options value or template.
		 */
		 */
@@ -330,7 +309,6 @@
		  * @param	p_icmpCode ICMPv6 Code value that is used.
		  * @param	p_icmpCode ICMPv6 Code value that is used.
		  *	@param  p_rFlag Router flag value.
		  *	@param  p_rFlag Router flag value.
		  *	@param  p_sFlag Solicited flag value.
		  *	@param  p_sFlag Solicited flag value.
		  *	@param  p_oFlag Override flag value.
		  *	@param  p_targetAddr Binary IPv6 address associated with target.
		  *	@param  p_targetAddr Binary IPv6 address associated with target.
		  *	@param  p_opts Neighborhood advertisement options value or template.
		  *	@param  p_opts Neighborhood advertisement options value or template.
		 */
		 */
@@ -370,16 +348,40 @@
			prefixInfoList := omit,
			prefixInfoList := omit,
			otherOption := omit }
			otherOption := omit }


		/*
		template RtAdvOptions m_rtAdvOpt_otherOpt (template Oct6to15 p_otherOpt):={
		 *  @param  p_otherOpt Other binary option
		 */
		template RtAdvOptions m_rtAdvOpt_otherOpt (template octetstring p_otherOpt):={
			srcLinkLayerAddr := omit,
			srcLinkLayerAddr := omit,
			mtuOption := omit,
			mtuOption := omit,
			prefixInfoList := omit,
			prefixInfoList := omit,
			otherOption := p_otherOpt
			otherOption := p_otherOpt
		}
		}


		/*
		 *	@param  p_prefixLength Length of the prefix.
		 *	@param  p_lFlag Value for link flag.
		 *	@param  p_aFlag Value for autoconfiguration flag.
		 *	@param  p_validLifetime Value for valid life time duration.
		 *	@param  p_preferredLifetime Value for preffered life time duration.
		 *	@param  p_prefix Address prefix to be used
		 *	@param  p_macSlla Binary MAC source address associated with
		 *          link layer of test component
	    */
		template RtAdvOptions m_rtAdvOpt_prefix_macSrc  (	UInt8 p_prefixLength,
															UInt1 p_lFlag,
															UInt1 p_aFlag,
															UInt32 p_validLifetime,
															UInt32 p_preferredLifetime, 
															Ipv6Address p_prefix,
															template Oct6to15 p_macSlla ):={
			mtuOption:= omit,
			prefixInfoList := {  m_prefixInfo(	p_prefixLength,
												p_lFlag,
												p_aFlag,
												p_validLifetime,
												p_preferredLifetime, 
												p_prefix) },
			srcLinkLayerAddr := m_macSlla(p_macSlla),
			otherOption := omit }

		/*
		/*
		 *	@param  p_macSlla Binary MAC source address associated with
		 *	@param  p_macSlla Binary MAC source address associated with
		 *          link layer of test component
		 *          link layer of test component
@@ -464,11 +466,18 @@
			prefix:= p_prefix
			prefix:= p_prefix
		}
		}


		template NbrAdvOptions m_nbrAdvOpt_macTlla3 (template Oct6to15 p_macTlla):={
			tgtLinkLayerAddr := m_macTlla(p_macTlla),
			tgtLinkLayerAddr := m_macTlla(p_macTlla),
			tgtLinkLayerAddr := m_macTlla(p_macTlla),
			otherOption := omit
		}

	
	
		/*
		/*
		 *  @param  p_otherOpt Other binary option
		 *  @param  p_otherOpt Other binary option
		*/
		*/
		template NbrAdvOptions m_nbrAdvOpt_otherOpt (template octetstring p_otherOpt):={
		template NbrAdvOptions m_nbrAdvOpt_otherOpt (octetstring p_otherOpt):={
			tgtLinkLayerAddr := omit,
			tgtLinkLayerAddr := omit,
			otherOption := p_otherOpt
			otherOption := p_otherOpt
		}
		}
@@ -476,7 +485,7 @@
		/*
		/*
		 *  @param  p_otherOpt Other binary option
		 *  @param  p_otherOpt Other binary option
		*/
		*/
		template NbrSolOptions m_nbrSolOpt_otherOpt (template octetstring p_otherOpt):={
		template NbrSolOptions m_nbrSolOpt_otherOpt (octetstring p_otherOpt):={
			srcLinkLayerAddr := omit,
			srcLinkLayerAddr := omit,
			otherOption := p_otherOpt
			otherOption := p_otherOpt
		}
		}
@@ -487,7 +496,7 @@
		 *  @param  p_otherOpt Other binary option
		 *  @param  p_otherOpt Other binary option
		*/
		*/
		template NbrAdvOptions m_nbrAdvOpt_macTlla_otherOpt (template Oct6to15 p_macTlla,
		template NbrAdvOptions m_nbrAdvOpt_macTlla_otherOpt (template Oct6to15 p_macTlla,
													template octetstring p_otherOpt ):={
													octetstring p_otherOpt ):={
			tgtLinkLayerAddr := m_macTlla(p_macTlla),
			tgtLinkLayerAddr := m_macTlla(p_macTlla),
			otherOption := p_otherOpt
			otherOption := p_otherOpt
		}
		}
@@ -497,7 +506,7 @@
		 *	@param  p_macTlla Binary MAC source address associated with
		 *	@param  p_macTlla Binary MAC source address associated with
		 *          link layer of target
		 *          link layer of target
		*/
		*/
		template NbrAdvOptions m_nbrAdvOpt_otherOpt_macTlla (template octetstring p_otherOpt,
		template NbrAdvOptions m_nbrAdvOpt_otherOpt_macTlla (octetstring p_otherOpt,
														template Oct6to15 p_macTlla):={
														template Oct6to15 p_macTlla):={
			otherOption := p_otherOpt,
			otherOption := p_otherOpt,
			tgtLinkLayerAddr := m_macTlla(p_macTlla)
			tgtLinkLayerAddr := m_macTlla(p_macTlla)
+342 −351
Original line number Original line Diff line number Diff line
@@ -20,6 +20,7 @@
	import from LibIpv6_ModuleParameters all ;
	import from LibIpv6_ModuleParameters all ;
	import from LibIpv6_MultiRfcs_Templates all;
	import from LibIpv6_MultiRfcs_Templates all;
	import from LibIpv6_MultiRfcs_TypesAndValues all;
	import from LibIpv6_MultiRfcs_TypesAndValues all;
	import from LibIpv6_Interface { type Ipv6Packet };
	import from LibIpv6_Rfc2460Root_TypesAndValues { type all };
	import from LibIpv6_Rfc2460Root_TypesAndValues { type all };
	import from LibIpv6_Rfc2460Root_Templates all;
	import from LibIpv6_Rfc2460Root_Templates all;
	import from LibIpv6_Rfc2463Icmpv6_Templates all;
	import from LibIpv6_Rfc2463Icmpv6_Templates all;
@@ -120,16 +121,6 @@
		} // end alt
		} // end alt
	} // end f_getIcmpAfterEchoReq
	} // end f_getIcmpAfterEchoReq
	
	
	/*
	** @desc 	This sends an ICMPv6 Echo Request from an IPv6 node to any NUT,
	**			and waits for an ICMPv6 Time Exceeded packet for a fixed amount of time.
	** @remark  Time limit is defined by module parameter PX_TAC (see comp type)
	** @param 	p_hops Number of hops to be used in IPv6 header
	** @param 	p_llaAddrTn address of testing node which calls this function
	** @param 	p_llaAddrNut address of node under test
	** @param 	p_llaAddrRut address of the node that sends the Time Exceeded message
	** @return 	execution status
	*/
	function f_getTimeExceededAfterEchoReq( 	in  UInt8 			p_hops,
	function f_getTimeExceededAfterEchoReq( 	in  UInt8 			p_hops,
											in  Ipv6Address 	p_llaAddrTn,
											in  Ipv6Address 	p_llaAddrTn,
											in  Ipv6Address 	p_llaAddrNut,
											in  Ipv6Address 	p_llaAddrNut,
@@ -300,7 +291,7 @@
	** @desc  	This sends an ICMPv6 echo request from an IPv6 node to 
	** @desc  	This sends an ICMPv6 echo request from an IPv6 node to 
	**          any NUT. Prior it modifies IPv6 packet payload length 
	**          any NUT. Prior it modifies IPv6 packet payload length 
	**			and ICMPv6 checksum to their correct values using external 
	**			and ICMPv6 checksum to their correct values using external 
	**          functions. Waits for an answer which must not be an Echo Reply.
	**          functions. Waits for a Parameter Problem message.
	** @param 	p_echoRequest Ipv6 packet value or template with echo request to be sent (must not contains wildcards)
	** @param 	p_echoRequest Ipv6 packet value or template with echo request to be sent (must not contains wildcards)
	** @param 	p_parameterProblem Parameter Problem message we are waiting for.
	** @param 	p_parameterProblem Parameter Problem message we are waiting for.
	** @returns	execution status
	** @returns	execution status
@@ -326,7 +317,7 @@
					repeat;
					repeat;
				}
				}
			[]	ipPort.receive ( ParameterProblem:? ) {
			[]	ipPort.receive ( ParameterProblem:? ) {
			        tc_ac.stop;
					v_ret := e_error ;
					log("**** f_getParameterProblemAfterEchoReq_ignoreEchoReply: ERROR: Template mismatch **** ");
					log("**** f_getParameterProblemAfterEchoReq_ignoreEchoReply: ERROR: Template mismatch **** ");
					v_ret := e_error;
					v_ret := e_error;
				}
				}