final
[tt2015.git] / a2 / 1cases.tex
1 \subsection{Preflight checklist}
2 Before actual certification is commenced we perform a manual test using a
3 checklist.
4 If any of the checks fail we immediately reject the product.
5 The checklist is given in the table below. All commands in \texttt{monospace}
6 are to be run in a terminal. Commands prefixed with a \texttt{\#} should be run
7 with root permissions. Commands prefixed with a \texttt{\$} should be run with
8 user permissions.
9
10 \begin{longtable}{|l|rp{.8\linewidth}|}
11 \hline
12 Check 1 & \multicolumn{2}{l|}{Get the SUT in a workable state.}\\
13 \hline
14 \multirow{3}{*}{Course of action}
15 & 1. & Import the VirtualBox image into VirtualBox.\\
16 & 2. & Boot the vm.\\
17 & 3. & Verify the SUT booted successfully and the network modules are
18 loaded.\\
19 \hline
20 Passed & \multicolumn{2}{l|}{\textit{Yes/No}}\\
21 \hline\hline
22 Check 2 & \multicolumn{2}{l|}{Verify the SUT is complete.}\\
23 \hline
24 \multirow{5}{*}{Course of action}
25 & 1. & Boot the SUT as in \emph{Check 1}.\\
26 & 2. & Verify the loopback device exists by running
27 \texttt{\$ ifconfig}.\\
28 & 3. & Verify the \emph{echo-server} is present on the system by running
29 \texttt{\$ file code/server/Main.java}\\
30 & 4. & Verify \emph{Scapy} is present on the system by running
31 \texttt{\$ scapy}.\\
32 & 5. & Verify all scripts used for testing are present on the system.\\
33 \hline
34 Passed & \multicolumn{2}{l|}{\textit{Yes/No}}\\
35 \hline\hline
36 Check 3 & \multicolumn{2}{l|}{Initialize the testing environment..}\\
37 \hline
38 \multirow{6}{*}{Course of action}
39 & 1. & Boot the SUT as in \emph{Check 1}.\\
40 & 2. & Setup iptables by executing
41 \texttt{\# code/iptables.sh}~\footnote{The IPTables script ensures
42 that the OS does not drop packets due to an the unknown source.}\\
43 & 3. & Navigate to the working directory by running
44 \texttt{\$ cd /home/student/tt2015}\\
45 & 4. & Compile the echo server by running
46 \texttt{\# cd code/server \&\& make}\\
47 & 5. & Start the echo server by running
48 \texttt{\# cd code/server \&\& java Main}\\
49 & 6. & Generate all test cases by running
50 \texttt{\$ python code/client/gen.py}\\
51 \hline
52 Passed & \multicolumn{2}{l|}{\textit{Yes/No}}\\
53 \hline\hline
54 Check 4 & \multicolumn{2}{l|}{Test the tool environment.}\\
55 \hline
56 \multirow{3}{*}{Course of action}
57 & 1. & Initialize the SUT as in \emph{Check 3}\\
58 & 2. & Execute the test script by running
59 \texttt{\# code/client/helloworld.py}\\
60 & 3. & Verify the console displays a success message.\\
61 \hline
62 Passed & \multicolumn{2}{l|}{\textit{Yes/No}}\\
63 \hline\hline
64 Check 5 & \multicolumn{2}{l|}{All test inputs and scripts are present.}\\
65 \hline
66 \multirow{2}{*}{Course of action}
67 & 1. & Boot the SUT as in \emph{Check 1}.\\
68 & 2. & Verify that the test generation script is present by running
69 \texttt{\$ file code/client/test.py}\\
70 \hline
71 Passed & \multicolumn{2}{l|}{\textit{Yes/No}}\\
72 \hline
73 \caption{Preflight checklist\label{tbl:preflight}}
74 \end{longtable}
75
76 \subsection{Testing of SUT} \label{sec:testingofsut}
77 The SUT is a series of services for other computer programs with no end-user
78 facing interface. Therefore the SUT will be tested solely by calling it's
79 services through various automated scripts. An automated test suite will be
80 available which executes all these automated scripts and aggregates their
81 results to asses whether or not the SUT has passed the test.
82
83 The implementation of the SUT is tested using black box testing techniques. A
84 series of tests asses the correctness of the implementation with regards to the
85 TCP specification. These tests are specified in Table~\ref{tbl:testpairs}. The test cases aim to cover the most interesting parts of the TCP
86 specification.
87
88 In this test suite the behavior of the outwards (network) interface of the SUT
89 is assessed. This is, the behavior of the SUT as
90 observed by another system on the network trying to communicate with (a system
91 running on the same host as the SUT using) the SUT. This is achieved by running
92 man
93 echo-server on the system which runs the SUT (a virtual machine) which
94 echos back all messages received to the sender. The test scripts will send
95 packets to the echo-server and then checks the received
96 response to asses whether or not the SUT is preforming as expected.
97
98 To cover the TCP specification as complete as possible while still maintaining
99 a feasible test suite the tests are divided into equivalence partitions. Below
100 these partitions are given.
101
102 \begin{enumerate}
103 \item \emph{Number of segments} in request~\footnote{A request is
104 considered establishing a connection (handshake) and a number of
105 payload segments}
106 \begin{enumerate}
107 \item 0 payload segments
108 \item 1 payload segments
109 \item n=small payload segments (1 byte)
110 \item n=big payload segments (65495 bytes)
111 \end{enumerate}
112 \item \emph{source port}
113 \begin{enumerate}
114 \item Correct
115 \item Incorrect
116 \end{enumerate}
117 \item \emph{destination port}
118 \begin{enumerate}
119 \item Correct
120 \item Incorrect
121 \end{enumerate}
122 \item Bit errors in \emph{payload}
123 \begin{enumerate}
124 \item Correct payload
125 \item Payload with bit flips that do not show in checksum
126 \item Payload with bit flips that do show in checksum
127 \end{enumerate}
128 \item \emph{checksum}
129 \begin{enumerate}
130 \item Correct
131 \item Incorrect
132 \end{enumerate}
133 \item \emph{Segment order}
134 \begin{enumerate}
135 \item Correct
136 \item Out of order
137 \item Missing Segments
138 \end{enumerate}
139 \end{enumerate}
140
141 These partitions were chosen since they correspond to key parts of the TCP
142 specification.
143
144 %
145 % één na laatste packket, moet dit B+3 of B+2 zijn?
146 %
147
148 TCP segments are send over a TCP connection from a \emph{source} to a \emph{destination port}. Therefore segments which are received that have a
149 source or destination port set to an incorrect value should not be regarded
150 as segments belonging to the connection by the SUT.
151
152 TCP uses a \emph{checksum} to catch any error introduced in headers, when this
153 checksum does not match the actual computed checksum the SUT should
154 disregard the received segment.
155
156 The TCP checksum is also an inherently weak one, as it is simply the
157 bitwise negation of the addition, in ones complement arithmetic,
158 of all 16 bit words in the header and data of the segment (excluding the
159 checksum itself). Therefore any \emph{bit error} where the ones complement value
160 of one word
161 increases by one, and the value of another decreases by one, is undetected.
162 The SUT should exhibit the same behavior and accept packets where these type
163 of bit errors occur.
164
165 TCP guarantees that segments are delivered \emph{in order}
166 , even when they are received
167 out of order and that missing segments are resend. The SUT should
168 exhibit the same behavior. If segments are received out of order it should
169 either reassemble them when the missing segment has arrived or request them to
170 be resend. Missing segments should be re-requested (by ACK-ing
171 their sequence number).
172
173 A single request consists of a number of segments that are sent
174 to the \emph{echo-server} and back. The TCP specification states that such a
175 transaction requires the following messages.
176
177 \begin{flushleft}
178 Script $-$ SYN $A$ $\rightarrow$ SUT \\
179 Script $\leftarrow$ SYN-ACK $(A+1)$ $B$ $-$ SUT \\
180 Script $-$ ACK $(A+1)$ $(B+1)$ $\rightarrow$ SUT \\
181 Script $-$ ACK-PUSH $(A+1)$ $(B+2)$ \emph{msg} $\rightarrow$ SUT \\
182 Script $\leftarrow$ ACK $(A+2+msg_{length})$ $(B+3)$ $-$ SUT \\
183 Script $\leftarrow$ ACK-PUSH $(A+2+msg_{length})$ $(B+3)$ \emph{msg} $-$ SUT
184 \end{flushleft}
185
186 %
187 % RS ook? FIN?
188 %
189
190 When the \emph{SUT} has received the ACK containing the message it's passed
191 trough to the \emph{echo-server}. The \emph{echo-server} will proceed by ordering
192 the \emph{SUT} to respond by sending the exact same message. When this happens
193 the \emph{SUT} has to construct the last segment in the transaction listed above.
194
195 \bigskip
196
197 Partitions 2 to 6 are tested using pairwise testing to keep the number of test
198 cases feasible. The pairs are then all *except some where it does not make sense
199 to do so) tested with the different request sizes of partition 1.
200
201 This is expressed in Table~\ref{tbl:testpairs}. In this table the first five
202 columns represent the different options for the partitions 2 to 6 of the above
203 enumeration. The last four columns are the different number segments as
204 described in the partition 1 of the above enumeration. These cells identify
205 individual test cases by a number. An \xmark in the cell indicates that this
206 test case can not be created as it is not possible with that number of segments
207 (eg. sending segments out of order when the number of segments is 1).
208
209 \setcounter{TCC}{1}
210 \begin{table}[H]
211 \centering
212 \begin{tabular}{|l|l|l|l|l|l||l|l|l|l|}
213 \hline
214 & \multicolumn{9}{c|}{\textbf{Partition}}\\
215 \hline
216 & 4 & 5 & 3 & 6 & 2 & 1a & 1b & 1c & 1d\\
217 \hline\hline
218 \multirow{9}{*}{Instance}
219 & a & a & a & a & a & \doTCC & \doTCC & \doTCC & \doTCC\\
220 & a & b & b & c & b & \xmark & \xmark & \doTCC & \doTCC\\
221 & c & a & b & a & b & \xmark & \xmark & \doTCC & \doTCC\\
222 & c & b & a & c & a & \xmark & \xmark & \doTCC & \doTCC\\
223 & b & a & b & c & a & \xmark & \xmark & \xmark & \doTCC\\
224 & b & b & a & b & b & \xmark & \xmark & \xmark & \doTCC\\
225 & c & b & b & a & b & \xmark & \doTCC & \doTCC & \doTCC\\
226 & b & b & b & a & b & \xmark & \xmark & \xmark & \doTCC\\
227 & a & b & b & b & a & \xmark & \xmark & \doTCC & \doTCC\\
228 \hline
229 \end{tabular}
230 \caption{Combinations of test cases}
231 \label{tbl:testpairs}
232 \end{table}
233
234 \subsection{Quality, completeness and coverage of tests}
235
236 The network packets used in testing are constructed from prerecorded, known to
237 be correct, network traffic. These packets are then modified with well used and
238 field tested tools. Due to this the chance of errors in the test cases is quite
239 low. However, no formal proof of correctness of the test cases is present, this
240 means that any defects found might not be the result of a fault in the SUT.
241 Therefore detected defects should only indicate there is a high chance that
242 there is a fault in the SUT and can not result directly in the conclusion that
243 there actually is one.
244
245 \bigskip
246
247 Due to the nature of black-box testing coverage of the code in the
248 implementation of the SUT is unknown. However completeness of the tests over
249 the specification of the SUT can be assessed.
250
251 \bigskip
252
253 Due to the clear and exhaustive specification of TCP the completeness of the
254 test suite can be clearly assessed.
255
256 As always, $100\%$ completeness is not feasible, therefore test cases are
257 carefully selected to cover the most interesting parts of the TCP specification
258 to ensure a complete but feasible test suite.
259
260 %To further increase the coverage of the test suites tests are randomized. The
261 %tests which test the handling of \emph{bit errors}, changes in the \emph{segment
262 %order} and \emph{dropped segments} randomize where they introduce an error. The
263 %test suite runs these tests multiple times to increase the likelihood that they
264 %discover a fault which is only present when an error occurs in a certain
265 %position.
266
267 To further decrease the number of tests needed test cases are divided into
268 equivalence partitions and the combination of cases as described in
269 Table~\ref{tbl:testpairs} ensures that all partitions are
270 covered and the number of individual tests is still feasible.
271
272
273 %
274 % wat ik ook probeer ik krijg de eerste collum
275 % zijn tekst niet verticaal gecentered
276 %
277
278
279 \subsection{Test suite}
280
281 Before executing the test suite the test environment has to be initialized.
282
283 \begin{enumerate}
284 \item Boot the vm using VirtualBox.
285 \item Setup iptables by executing \texttt{\# code/iptables.sh}
286 \item Navigate to the working directory by running
287 \texttt{\$ cd /home/student/tt2015}
288 \item Start the echo server by running
289 \texttt{\# cd code/server \&\& Java Main}
290 \end{enumerate}
291
292 \subsubsection{Preflight checks}
293 The we do the preflight checks as defined in Table~\ref{tbl:preflight}.
294
295 \subsubsection{Test Cases}
296 If the SUT passes the preflight checks the actual test cases can be executed.
297 Table~\ref{tbl:testcases} shows the expected results of each of the test cases
298 described in Table~\ref{tbl:testpairs}.
299
300 \setcounter{TCC}{1}
301 \begin{table}[H]
302 \centering
303 \begin{tabular}{|l|p{.7\linewidth}|}
304 \hline
305 Test number & Expected results\\
306 \hline\hline
307 \doTCC & An ACK\# of the send sequence number + 1.\\ \hline
308 \doTCC & An ACK\# of the sequence number of the last send segment + the
309 size of the payload of that segment.\\ \hline
310 \doTCC & An ACK\# of the sequence number of the last send segment + the
311 size of the payload of that segment.\\ \hline
312 \doTCC & An ACK\# of the sequence number of the last send segment + the
313 size of the payload of that segment.\\ \hline
314 \doTCC & The ACK\# for the SEQ\# of the first segments which is
315 corrupted is received for each consecutive segment send.\\
316 $\vdots$ & \\
317 \setcounter{TCC}{12}
318 \doTCC & The ACK\# for the SEQ\# of the first segments which is
319 corrupted is received for each consecutive segment send.\\ \hline
320 \doTCC & The segment is not attributed to the current connection
321 and therefore no ACK\# is received. \\ \hline
322 \doTCC & The ACK\# for the SEQ\# of the first segments which is
323 corrupted is received for each consecutive segment send.\\ \hline
324 \doTCC & The ACK\# for the SEQ\# of the first segments which is
325 corrupted is received for each consecutive segment send.\\ \hline
326 \doTCC & The ACK\# for the SEQ\# of the first segments which is
327 corrupted is received for each consecutive segment send.\\ \hline
328 \doTCC & The ACK\# for the SEQ\# of the first segments which is
329 corrupted is received for each consecutive segment send.\\ \hline
330 \doTCC & The ACK\# for the SEQ\# of the first segments which is
331 corrupted is received for each consecutive segment send.\\ \hline
332 \end{tabular}
333 \caption{Expected results of test cases}
334 \label{tbl:testcases}
335 \end{table}
336
337 % Bij Ramons afwezigheid
338 % Paul Vitero (linkerkant lange gang)
339 % verdieping Mercator
340
341
342 \begin{longtable}{|p{.2\linewidth}|p{.8\linewidth}|}
343 \hline
344
345 Nr & 1 \\\hline
346 Title & Connect to the \emph{echo-server} without sending a payload. \\\hline
347 Input & Generated packets. \\\hline
348 Expected output & \emph{Echo-server} accepts the connection. \\\hline
349 \multirow{2}{*}{Course of action}
350 & 1. Use the steps listed above in order to start the SUT. \\
351 & 2. Execute the script by running \texttt{\# code/client/tests/1.py} \\\hline
352 Valid trace & Verify that the script prints 'Success'. \\\hline
353 \hline
354
355 Nr & 2 \\\hline
356 Title & Single valid request with 1byte payload. \\\hline
357 Input & Generated packets. \\\hline
358 Expected output & Packets echoed back by Echo-Server. \\\hline
359 \multirow{2}{*}{Course of action}
360 & 1. Use the steps listed above in order to start the SUT. \\
361 & 2. Execute the script by running \texttt{\# code/client/tests/1.py} \\\hline
362 Valid trace & Verify that the script prints 'Success'. \\\hline
363 \hline
364
365 % Nr & 3 \\\hline
366 % Title & Single valid request with 65495bytes payload. \\\hline
367 % Input & Generated packets. \\\hline
368 % Expected output & Packets echoed back by Echo-Server. \\\hline
369 % \multirow{2}{*}{Course of action}
370 % & 1. Use the steps listed above in order to start the SUT. \\
371 % & 2. Execute the script by running \texttt{\# code/client/tests/2.py} \\\hline
372 % Valid trace & Verify that the script prints 'Success'. \\\hline
373 % \hline
374
375 Nr & 3 \\\hline
376 Title & 5 valid requests with 1byte payload. \\\hline
377 Input & Generated packets. \\\hline
378 Expected output & Packets echoed back by Echo-Server, in the same order as the client sent them. \\\hline
379 \multirow{2}{*}{Course of action}
380 & 1. Use the steps listed above in order to start the SUT. \\
381 & 2. Execute the script by running \texttt{\# code/client/tests/3.py} \\\hline
382 Valid trace & Verify that the script prints 'Success'. \\\hline
383 \hline
384
385 Nr & 4 \\\hline
386 Title & 5 valid requests with 65495bytes payload. \\\hline
387 Input & Generated packets with 65495bytes payload. \\\hline
388 Expected output & Packets echoed back by Echo-Server, in the same order as the client sent them. \\\hline
389 \multirow{2}{*}{Course of action}
390 & 1. Use the steps listed above in order to start the SUT. \\
391 & 2. Execute the script by running \texttt{\# code/client/tests/4.py} \\\hline
392 Valid trace & Verify that the script prints 'Success'. \\\hline
393 \hline
394
395 Nr & 5 \\\hline
396 Title & 5 requests with 1byte payload with corrupted source port, destination port and checksum. The second segment is omitted in order to simulate a packet drop on the client side. \\\hline
397 Input & Generated packets with 1byte payload, second generated segment is removed. \\\hline
398 Expected output & All packets are dropped resulting in a connection time-out. \\\hline
399 \multirow{2}{*}{Course of action}
400 & 1. Use the steps listed above in order to start the SUT. \\
401 & 2. Execute the script by running \texttt{\# code/client/tests/5.py} \\\hline
402 Valid trace & Verify that the script prints 'Success'. \\\hline
403 \hline
404
405 Nr & 6 \\\hline
406 Title & 5 requests with 65495byte payload with corrupted source port, destination port and checksum. The second segment is omitted in order to simulate a packet drop on the client side. \\\hline
407 Input & Generated segments with 65495byte payload, second generated segment is removed. \\\hline
408 Expected output & All packets are dropped resulting in a connection time-out. \\\hline
409 \multirow{2}{*}{Course of action}
410 & 1. Use the steps listed above in order to start the SUT. \\
411 & 2. Execute the script by running \texttt{\# code/client/tests/6.py} \\\hline
412 Valid trace & Verify that the script prints 'Success'. \\\hline
413 \hline
414
415 %% HIER
416
417 Nr & 7 \\\hline
418 Title & 5 requests with 1byte corrupted payload, corrupted source and destination port. \\\hline
419 Input & Generated packets with 1byte payload, in these packets the payload byte, source and destination ports are increased by one. \\\hline
420 Expected output & All packets are dropped resulting in a connection time-out. \\\hline
421 \multirow{2}{*}{Course of action}
422 & 1. Use the steps listed above in order to start the SUT. \\
423 & 2. Execute the script by running \texttt{\# code/client/tests/7.py} \\\hline
424 Valid trace & Verify that the script prints 'Success'. \\\hline
425 \hline
426
427 Nr & 8 \\\hline
428 Title & 5 requests with 65495byte corrupted payload, corrupted source and destination port. \\\hline
429 Input & Generated packets with 65495byte payload, in these packets one of the payload bytes, source and destination ports are increased by one. \\\hline
430 Expected output & All packets are dropped resulting in a connection time-out. \\\hline
431 \multirow{2}{*}{Course of action}
432 & 1. Use the steps listed above in order to start the SUT. \\
433 & 2. Execute the script by running \texttt{\# code/client/tests/8.py} \\\hline
434 Valid trace & Verify that the script prints 'Success'. \\\hline
435 \hline
436
437
438 Nr & 9 \\\hline
439 Title & 5 requests with 1byte corrupted payload, invalid checksum and the second packet is dropped. \\\hline
440 Input & Generated packets with 1byte payload, in these packets the payload byte and checksum are increased by one. The second segment is removed. \\\hline
441 Expected output & All packets are dropped resulting in a connection time-out. \\\hline
442 \multirow{2}{*}{Course of action}
443 & 1. Use the steps listed above in order to start the SUT. \\
444 & 2. Execute the script by running \texttt{\# code/client/tests/9.py} \\\hline
445 Valid trace & Verify that the script prints 'Success'. \\\hline
446 \hline
447
448 Nr & 10 \\\hline
449 Title & 5 requests with 65495byte corrupted payload, invalid checksum and the second packet is dropped. \\\hline
450 Input & Generated packets with 65495byte payload, in these packets one of the payload bytes and the checksum are increased by one. The second packet is removed. \\\hline
451 Expected output & All packets are dropped resulting in a connection time-out. \\\hline
452 \multirow{2}{*}{Course of action}
453 & 1. Use the steps listed above in order to start the SUT. \\
454 & 2. Execute the script by running \texttt{\# code/client/tests/10.py} \\\hline
455 Valid trace & Verify that the script prints 'Success'. \\\hline
456 \hline
457
458 Nr & 11 \\\hline
459 Title & 5 requests with 65495byte corrupted payload that doesn't show up in checksum and corrupted destination port. The second packet is dropped. \\\hline
460 Input & Generated packets with 65495byte payload, in these packets one 16bit word in the payload is increased by 1 and another 16bit word is decreased by 1. The destination port is also increase by one and the second segment is removed. \\\hline
461 Expected output & All packets are dropped resulting in a connection time-out. \\\hline
462 \multirow{2}{*}{Course of action}
463 & 1. Use the steps listed above in order to start the SUT. \\
464 & 2. Execute the script by running \texttt{\# code/client/tests/11.py} \\\hline
465 Valid trace & Verify that the script prints 'Success'. \\\hline
466 \hline
467
468
469 Nr & 12 \\\hline
470 Title & 5 requests with 65495byte corrupted payload that doesn't show up in checksum and corrupted source port and checksum. The 2nd and 3rd packets are swapped. \\\hline
471 Input & Generated packets with 65495byte payload, in these packets one 16bit word in the payload, the source port and checksum are increased by one. A different 16bit word in the payload is decreased by one. The 2nd and 3rd packets are swapped in order to simulate a out-of-order transmission. \\\hline
472 Expected output & All packets are dropped resulting in a connection time-out. \\\hline
473 \multirow{2}{*}{Course of action}
474 & 1. Use the steps listed above in order to start the SUT. \\
475 & 2. Execute the script by running \texttt{\# code/client/tests/12.py} \\\hline
476 Valid trace & Verify that the script prints 'Success'. \\\hline
477 \hline
478
479
480 Nr & 13 \\\hline
481 Title & Single request with 1byte corrupted payload and corrupted source port, destination port and checksum. \\\hline
482 Input & Generated segment with 1byte payload, in this segment one byte in the payload, the source port and checksum are increased by one. \\\hline
483 Expected output & All packets are dropped resulting in a connection time-out. \\\hline
484 \multirow{2}{*}{Course of action}
485 & 1. Use the steps listed above in order to start the SUT. \\
486 & 2. Execute the script by running \texttt{\# code/client/tests/13.py} \\\hline
487 Valid trace & Verify that the script prints 'Success'. \\\hline
488 \hline
489
490 Nr & 14 \\\hline
491 Title & 5 requests with 1byte corrupted payload and corrupted source port, destination port and checksum. \\\hline
492 Input & Generated packets with 1byte payload, in these segment one byte in the payload, the source port and checksum are increased by one. \\\hline
493 Expected output & All packets are dropped resulting in a connection time-out. \\\hline
494 \multirow{2}{*}{Course of action}
495 & 1. Use the steps listed above in order to start the SUT. \\
496 & 2. Execute the script by running \texttt{\# code/client/tests/14.py} \\\hline
497 Valid trace & Verify that the script prints 'Success'. \\\hline
498 \hline
499
500 Nr & 15 \\\hline
501 Title & 5 requests with 65495byte corrupted payload and corrupted source port, destination port and checksum. \\\hline
502 Input & Generated packets with 65495byte payload, in these packets one byte in the payload, the source port and checksum are increased by one. \\\hline
503 Expected output & All packets are dropped resulting in a connection time-out. \\\hline
504 \multirow{2}{*}{Course of action}
505 & 1. Use the steps listed above in order to start the SUT. \\
506 & 2. Execute the script by running \texttt{\# code/client/tests/15.py} \\\hline
507 Valid trace & Verify that the script prints 'Success'. \\\hline
508 \hline
509
510 Nr & 16 \\\hline
511 Title & 5 requests with 65495byte corrupted payload that doesn't show up in the checksum, corrupted source port, destination port and checksum. \\\hline
512 Input & Generated packets with 65495byte payload, in these packets one 16bit word in the payload, the source port and checksum are increased by one. Another 16bit word in the payload is decreased by 1. \\\hline
513 Expected output & All packets are dropped resulting in a connection time-out. \\\hline
514 \multirow{2}{*}{Course of action}
515 & 1. Use the steps listed above in order to start the SUT. \\
516 & 2. Execute the script by running \texttt{\# code/client/tests/16.py} \\\hline
517 Valid trace & Verify that the script prints 'Success'. \\\hline
518 \hline
519
520
521 Nr & 17 \\\hline
522 Title & 5 requests with 1byte payload, corrupted destination port and checksum. The 2nd and 3rd packets are swapped \\\hline
523 Input & Generated packets with 1byte payload, in these packets the destination port and checksum are increased by one. The 2nd and 3rd packets are swapped in order to simulate an out-of-order transmission. \\\hline
524 Expected output & All packets are dropped resulting in a connection time-out. \\\hline
525 \multirow{2}{*}{Course of action}
526 & 1. Use the steps listed above in order to start the SUT. \\
527 & 2. Execute the script by running \texttt{\# code/client/tests/17.py} \\\hline
528 Valid trace & Verify that the script prints 'Success'. \\\hline
529 \hline
530
531
532 Nr & 18 \\\hline
533 Title & 5 requests with 65495byte payload, corrupted destination port and checksum. The 2nd and 3rd packets are swapped \\\hline
534 Input & Generated packets with 65495byte payload, in these packets the destination port and checksum are increased by one. The 2nd and 3rd packets are swapped in order to simulate an out-of-order transmission. \\\hline
535 Expected output & All packets are dropped resulting in a connection time-out. \\\hline
536 \multirow{2}{*}{Course of action}
537 & 1. Use the steps listed above in order to start the SUT. \\
538 & 2. Execute the script by running \texttt{\# code/client/tests/18.py} \\\hline
539 Valid trace & Verify that the script prints 'Success'. \\\hline
540 \hline
541 \end{longtable}
542
543 %\begin{tabularx}{\linewidth}{| l | X|}
544 %\hline
545 %Nr & 1 \\\hline
546 %Title & Single valid request. \\\hline
547 %Input & Pcap file with prerecorded valid packets. \\\hline
548 %Expected output & Pcap file with valid response to request. \\\hline
549 %Course of action & \begin{enumerate}
550 % \item Execute \emph{./scripts/tests/case1-single-valid.sh}
551 % \item Load \emph{output/case1.pcap} with ...
552 %\end{enumerate} \\\hline
553 %Valid trace & \begin{enumerate}
554 % \item \textbf{Hier packets benoemen?}
555 %\end{enumerate} \\\hline
556 %\end{tabularx}
557 %
558 %\begin{tabularx}{\linewidth}{| l | X|}
559 % \hline
560 % Nr & 2 \\\hline
561 %Title & Single request with corrupted checksum. \\\hline
562 % Input & Pcap file used as \emph{test-case 1} input. \\\hline
563 % Expected output & No response from SUT, logs with rejected packets. \\\hline
564 % Course of action & \begin{enumerate}
565 % \item Load input pcap file into ....
566 % \item Corrupt checksum of loaded packets.
567 % \item Save resulting packets as pcap file.
568 % \item Load new pcap file into ...
569 % \item Replay new pcap file.
570 % \item Record SUT response using...
571 % \item Extract log with rejected packets.
572 % \item Save recorded packets as a pcap file.
573 % \item Analyze packets in resulting file.
574 % \end{enumerate} \\\hline
575 % Valid trace & \begin{enumerate}
576 % \item \textbf{Aangeven welke packets corrupted zijn?}
577 % \end{enumerate} \\\hline
578 %\end{tabularx}
579 %\end{table}