// SCTP Conformance Test Suite Implementation // (C) Copyright Fujitsu Ltd. 2008, 2009 // // This file is part of the SCTP Conformance Test Suite implementation. // // The SCTP Conformance Test Suite implementation is free software; // you can redistribute it and/or modify it under the terms of // the GNU General Public License version 2 as published by // the Free Software Foundation. // // The SCTP Conformance Test Suite implementation is distributed in the // hope that it will be useful, but WITHOUT ANY WARRANTY; without even // the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR // PURPOSE. See the GNU General Public License for more details. // // You should have received a copy of the GNU General Public License // along with GNU CC; see the file COPYING. If not, write to // the Free Software Foundation, 59 Temple Place - Suite 330, // Boston, MA 02111-1307, USA. // // Please send any bug reports or fixes you make to the // email address(es): // networktest sctp // // Or submit a bug report through the following website: // http://networktest.sourceforge.net/ // // Written or modified by: // Hiroaki Kago // Wei Yongjun // // Any bugs reported given to us we will try to fix... any fixes shared will // be incorporated into the next SCTP release. // #include "../common/STD_PKT_COMMON.def" // // SCTP CHUNK_DATA // PKG_SCTP_SHORT_RECV( sctp_chunk_data_1, { chunk = chunk_data_1; } ) CHUNK_DATA chunk_data_1 { UFlag = any; BFlag = 1; EFlag = 0; TSN = any; Identifier = any; SequenceNumber = any; Protocol = any; payload = data1; } Payload data1 { #if ENABLE_IPV6 data = left(data1500, 1432); #else data = left(data1500, 1452); #endif } // // SCTP CHUNK_SACK // PKG_SCTP_SHORT_SEND( sctp_chunk_sack_seg, { chunk = chunk_sack_seg; } ) CHUNK_SACK chunk_sack_seg { #ifdef SACK ACK = SACK; #endif AdvRecvWindow = ARWND; NumOfGapAck = 0; NumOfDupTSN = 0; } // // SCTP CHUNK_DATA // PKG_SCTP_SHORT_RECV( sctp_chunk_data_2, { chunk = chunk_data_2; } ) CHUNK_DATA chunk_data_2 { UFlag = any; BFlag = 0; EFlag = 0; #ifdef SACK TSN = SACK + 1; #endif Identifier = any; SequenceNumber = any; Protocol = any; payload = data2; } Payload data2 { #if ENABLE_IPV6 data = substr(data1500, 2, 1432); #else data = substr(data1500, 2, 1452); #endif } // // SCTP CHUNK_DATA // PKG_SCTP_SHORT_RECV( sctp_chunk_data_3, { chunk = chunk_data_3; } ) CHUNK_DATA chunk_data_3 { UFlag = any; BFlag = 0; EFlag = 0; #ifdef SACK TSN = SACK + 2; #endif Identifier = any; SequenceNumber = any; Protocol = any; payload = data3; } Payload data3 { #if ENABLE_IPV6 data = substr(data1500, 4, 1432); #else data = substr(data1500, 4, 1452); #endif } // // SCTP CHUNK_DATA // PKG_SCTP_SHORT_RECV( sctp_chunk_data_4, { chunk = chunk_data_4; } ) CHUNK_DATA chunk_data_4 { UFlag = any; BFlag = 0; EFlag = 1; #ifdef SACK TSN = SACK + 3; #endif Identifier = any; SequenceNumber = any; Protocol = any; payload = data4; } Payload data4 { #if ENABLE_IPV6 data = substr(data1500, 6, 1431); #else data = substr(data1500, 6, 1451); #endif data = hexstr("00"); }