Loading ttcn/Ats6RD/Ats6RD_Functions.ttcn3 +27 −0 Original line number Diff line number Diff line Loading @@ -28,6 +28,7 @@ module Ats6RD_Functions { // Ats6RD import from Ats6RD_TypesAndValues all; import from Ats6RD_Interfaces all; import from Ats6RD_Pixits all; group initialiseFunctions { Loading Loading @@ -347,8 +348,34 @@ module Ats6RD_Functions { } // End of group globalSteps group getFunctions { function f_getTcpTimeWait() return float { return PX_TCP_TIME_WAIT; } // End of function f_getTcpTimeWait } // End of group getFunctions group auxiliary { function f_checkTcpPayload(in TcpPacket p_tcpPacket, in SentIpv6Messages v_sentIpv6Messages) return FncRetCode { var FncRetCode v_result := e_error; var Ipv6Packet v_payload; var UInt v_counter; if (decvalue(oct2bit(p_tcpPacket.payload.httpPayload), v_payload) == 0) { for (v_counter := 0; v_counter < lengthof(v_sentIpv6Messages); v_counter := v_counter + 1) { if (match(v_payload, v_sentIpv6Messages) == true) { v_result := e_success; break; } } // End of 'for' statement } return v_result; } // End of function f_checkTcpPayload /** * @desc Rebuild IPv6 HTTP message from fragmented Ipv4 packets * @param p_ipv4Packet Loading ttcn/Ats6RD/Ats6RD_Interfaces.ttcn3 +5 −1 Original line number Diff line number Diff line Loading @@ -17,7 +17,7 @@ module Ats6RD_Interfaces { // AtsCommon import from AtsCommon_Interfaces { type DHCPv4Port, DHCPv6Port, DHCPv4Port, DHCPv6Port, InterCompDataPort, DHCPv4Component, DHCPv6Component, UtComponent }; Loading Loading @@ -88,6 +88,8 @@ module Ats6RD_Interfaces { port Ipv6Port ipPort; /** IPv4 message port */ port Ipv4Port brPort; /** Inter-component communication port */ port InterCompDataPort dataPort; /** Timer used for expected received message */ timer tc_ac:= PX_TAC; /** Timer used for unexpected received message */ Loading @@ -110,6 +112,8 @@ module Ats6RD_Interfaces { type component HostHTTPv6Component extends UtComponent, SelfSyncComp { /** HTTP message port */ port HttpV6Port httpPort; /** Inter-component communication port */ port InterCompDataPort dataPort; /** Timer used for expected received message */ timer tc_ac:= PX_TAC; /** Timer used for unexpected received message */ Loading ttcn/Ats6RD/Ats6RD_Pics.ttcn3 +5 −0 Original line number Diff line number Diff line Loading @@ -15,4 +15,9 @@ module Ats6RD_Pics { */ modulepar boolean PICS_ROLE_IS_BR := false; /** * @desc Does the IUT support port range conifguration? */ modulepar boolean PICS_PORT_RANGE := false; } // End of module Ats6RD_Pics No newline at end of file ttcn/Ats6RD/Ats6RD_Pixits.ttcn3 +46 −8 Original line number Diff line number Diff line Loading @@ -6,6 +6,7 @@ module Ats6RD_Pixits { // LibCommon import from LibCommon_BasicTypesAndValues all; import from LibCommon_DataStrings all; // LibIPv6 Loading @@ -17,22 +18,27 @@ module Ats6RD_Pixits { /** * @desc Indicates the IPv4 address of the CPE equipment */ modulepar Ipv4Address PX_CPE_IPv4_ADDRESS := c_4ZeroBytes; modulepar Ipv4Address PX_CPE_IPv4_ADDRESS := c_4ZeroBytes; // Such as 10.1.1.1 /** * @desc Indicates the IPv6 address of the CPE equipment * @desc Indicates the IPv4 address of the BR equipment */ modulepar Ipv6Address PX_CPE_IPv6_ADDRESS := c_16ZeroBytes; // TODO To be removed? modulepar Ipv4Address PX_BR_GW_IPv4_ADDRESS := c_4ZeroBytes; // Such as 10.1.3.1 /** * @desc Indicates the IPv4 address of the CPE equipment * @desc Indicates the IPv4 anycast address */ modulepar Ipv4Address PX_CPE_ADDRESS := c_4ZeroBytes; // Such as 10.1.1.1 modulepar Ipv4Address PX_IPv4_ANYCAST_ADDRESS := c_4ZeroBytes; /** * @desc Indicates the IPv4 address of the BR equipment * @desc The MSS value. */ modulepar UInt PX_NAT64_MSS_SIZE := 1500; /** * @desc The TCP_time_wait timer value. */ modulepar Ipv4Address PX_BR_GW_ADDRESS := c_4ZeroBytes; // Such as 10.1.3.1 modulepar float PX_TCP_TIME_WAIT := 15.0; /** * @desc Defines a list of IPv6 host services with a segment size greater than the IUT MSS value Loading @@ -45,7 +51,7 @@ module Ats6RD_Pixits { dstAddress := c_16ZeroBytes, // Containing destination address indicating a public IPv6 address from multiple hosts dstPort := 3373, payload := { rawPayload := 'CAFEDECA'O // TODO With a segment size greater than the IUT MSS value rawPayload := c_1280ZeroBytes } } // Host #0 // TODO Could be extended Loading Loading @@ -106,4 +112,36 @@ module Ats6RD_Pixits { } // Host #2 } // End of modulepar PX_MSSC_HOST_V6_LIST_CPE /** * @desc Defines a list of IPv6 in IPv4 host services * @see TC_6RD_CPE_MSSC_BV_001 */ modulepar HostV6Descriptions PX_MULTIPLE_HOSTS_V6_IN_V4 := { { srcAddress := c_16ZeroBytes, // Containing source address indicating a private IPv6 address srcPort := 3372, dstAddress := c_16ZeroBytes, // Containing destination address indicating a public IPv6 address from multiple hosts dstPort := 3373, payload := { rawPayload := 'CAFEDECA'O } } // Host #0 // TODO Could be extended } // End of modulepar PX_MULTIPLE_HOSTS_V6_IN_V4 /** * @desc CPE IPv4 source port number */ modulepar UInt16 PX_ETS_PORT := 0; /** * @desc BR IPv4 port */ modulepar UInt16 PX_IUT_PORT := 0; /** * @desc BR IPv4 port */ modulepar UInt16 PX_IUT_PORT_RANGE := 3000; } // End of module Ats6RD_Pixits No newline at end of file ttcn/Ats6RD/Ats6RD_TestCases.ttcn3 +1813 −97 File changed.Preview size limit exceeded, changes collapsed. Show changes Loading
ttcn/Ats6RD/Ats6RD_Functions.ttcn3 +27 −0 Original line number Diff line number Diff line Loading @@ -28,6 +28,7 @@ module Ats6RD_Functions { // Ats6RD import from Ats6RD_TypesAndValues all; import from Ats6RD_Interfaces all; import from Ats6RD_Pixits all; group initialiseFunctions { Loading Loading @@ -347,8 +348,34 @@ module Ats6RD_Functions { } // End of group globalSteps group getFunctions { function f_getTcpTimeWait() return float { return PX_TCP_TIME_WAIT; } // End of function f_getTcpTimeWait } // End of group getFunctions group auxiliary { function f_checkTcpPayload(in TcpPacket p_tcpPacket, in SentIpv6Messages v_sentIpv6Messages) return FncRetCode { var FncRetCode v_result := e_error; var Ipv6Packet v_payload; var UInt v_counter; if (decvalue(oct2bit(p_tcpPacket.payload.httpPayload), v_payload) == 0) { for (v_counter := 0; v_counter < lengthof(v_sentIpv6Messages); v_counter := v_counter + 1) { if (match(v_payload, v_sentIpv6Messages) == true) { v_result := e_success; break; } } // End of 'for' statement } return v_result; } // End of function f_checkTcpPayload /** * @desc Rebuild IPv6 HTTP message from fragmented Ipv4 packets * @param p_ipv4Packet Loading
ttcn/Ats6RD/Ats6RD_Interfaces.ttcn3 +5 −1 Original line number Diff line number Diff line Loading @@ -17,7 +17,7 @@ module Ats6RD_Interfaces { // AtsCommon import from AtsCommon_Interfaces { type DHCPv4Port, DHCPv6Port, DHCPv4Port, DHCPv6Port, InterCompDataPort, DHCPv4Component, DHCPv6Component, UtComponent }; Loading Loading @@ -88,6 +88,8 @@ module Ats6RD_Interfaces { port Ipv6Port ipPort; /** IPv4 message port */ port Ipv4Port brPort; /** Inter-component communication port */ port InterCompDataPort dataPort; /** Timer used for expected received message */ timer tc_ac:= PX_TAC; /** Timer used for unexpected received message */ Loading @@ -110,6 +112,8 @@ module Ats6RD_Interfaces { type component HostHTTPv6Component extends UtComponent, SelfSyncComp { /** HTTP message port */ port HttpV6Port httpPort; /** Inter-component communication port */ port InterCompDataPort dataPort; /** Timer used for expected received message */ timer tc_ac:= PX_TAC; /** Timer used for unexpected received message */ Loading
ttcn/Ats6RD/Ats6RD_Pics.ttcn3 +5 −0 Original line number Diff line number Diff line Loading @@ -15,4 +15,9 @@ module Ats6RD_Pics { */ modulepar boolean PICS_ROLE_IS_BR := false; /** * @desc Does the IUT support port range conifguration? */ modulepar boolean PICS_PORT_RANGE := false; } // End of module Ats6RD_Pics No newline at end of file
ttcn/Ats6RD/Ats6RD_Pixits.ttcn3 +46 −8 Original line number Diff line number Diff line Loading @@ -6,6 +6,7 @@ module Ats6RD_Pixits { // LibCommon import from LibCommon_BasicTypesAndValues all; import from LibCommon_DataStrings all; // LibIPv6 Loading @@ -17,22 +18,27 @@ module Ats6RD_Pixits { /** * @desc Indicates the IPv4 address of the CPE equipment */ modulepar Ipv4Address PX_CPE_IPv4_ADDRESS := c_4ZeroBytes; modulepar Ipv4Address PX_CPE_IPv4_ADDRESS := c_4ZeroBytes; // Such as 10.1.1.1 /** * @desc Indicates the IPv6 address of the CPE equipment * @desc Indicates the IPv4 address of the BR equipment */ modulepar Ipv6Address PX_CPE_IPv6_ADDRESS := c_16ZeroBytes; // TODO To be removed? modulepar Ipv4Address PX_BR_GW_IPv4_ADDRESS := c_4ZeroBytes; // Such as 10.1.3.1 /** * @desc Indicates the IPv4 address of the CPE equipment * @desc Indicates the IPv4 anycast address */ modulepar Ipv4Address PX_CPE_ADDRESS := c_4ZeroBytes; // Such as 10.1.1.1 modulepar Ipv4Address PX_IPv4_ANYCAST_ADDRESS := c_4ZeroBytes; /** * @desc Indicates the IPv4 address of the BR equipment * @desc The MSS value. */ modulepar UInt PX_NAT64_MSS_SIZE := 1500; /** * @desc The TCP_time_wait timer value. */ modulepar Ipv4Address PX_BR_GW_ADDRESS := c_4ZeroBytes; // Such as 10.1.3.1 modulepar float PX_TCP_TIME_WAIT := 15.0; /** * @desc Defines a list of IPv6 host services with a segment size greater than the IUT MSS value Loading @@ -45,7 +51,7 @@ module Ats6RD_Pixits { dstAddress := c_16ZeroBytes, // Containing destination address indicating a public IPv6 address from multiple hosts dstPort := 3373, payload := { rawPayload := 'CAFEDECA'O // TODO With a segment size greater than the IUT MSS value rawPayload := c_1280ZeroBytes } } // Host #0 // TODO Could be extended Loading Loading @@ -106,4 +112,36 @@ module Ats6RD_Pixits { } // Host #2 } // End of modulepar PX_MSSC_HOST_V6_LIST_CPE /** * @desc Defines a list of IPv6 in IPv4 host services * @see TC_6RD_CPE_MSSC_BV_001 */ modulepar HostV6Descriptions PX_MULTIPLE_HOSTS_V6_IN_V4 := { { srcAddress := c_16ZeroBytes, // Containing source address indicating a private IPv6 address srcPort := 3372, dstAddress := c_16ZeroBytes, // Containing destination address indicating a public IPv6 address from multiple hosts dstPort := 3373, payload := { rawPayload := 'CAFEDECA'O } } // Host #0 // TODO Could be extended } // End of modulepar PX_MULTIPLE_HOSTS_V6_IN_V4 /** * @desc CPE IPv4 source port number */ modulepar UInt16 PX_ETS_PORT := 0; /** * @desc BR IPv4 port */ modulepar UInt16 PX_IUT_PORT := 0; /** * @desc BR IPv4 port */ modulepar UInt16 PX_IUT_PORT_RANGE := 3000; } // End of module Ats6RD_Pixits No newline at end of file
ttcn/Ats6RD/Ats6RD_TestCases.ttcn3 +1813 −97 File changed.Preview size limit exceeded, changes collapsed. Show changes