Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

UDP and TCP use 1\'s complement for their checksums. While UDP and TCP use 16-bi

ID: 3861627 • Letter: U

Question

UDP and TCP use 1's complement for their checksums. While UDP and TCP use 16-bit words in computing their checksum, for this problem you are asked to consider 8-bit sums. Don't forget to wrap-around any overflow if it occurs. Suppose you have the following three 8-bit bytes: 01010011, 01010100, and 01110100. Compute the checksum for these three bytes by finding the 1's complement of the sum of the bytes. Show all your work. For the three bytes shown above, give an example where one bit is flipped in each of the first two bytes and yet the checksum does not change. Suppose that a UDP receiver computes the Internet checksum for a received UDP segment and finds that it matches the value carried in the checksum field. Can the receiver be absolutely certain that no bit errors have occurred? Explain. With the Internet checksum used by UDP, it is possible that a 1-bit error will go undetected? How about a 2-bit error?

Explanation / Answer

a) 01010011
+01010100
----------
10100111
+01110100
----------
00011011

ones's complement = 11100100

b)  01010010
+01010001
----------
10100011
+01110100
----------
00011011
Here we have interchange last bit of first two bytes still the checksum is same

c) No because if two bits are chnaged then they will be same checksum. So receiver cannot guarentee that no bit error has occured

d) All one bit erros are detected where as 2bit errors are undetected. Example question (b) as two bits are changes the sum is still the same. But if only one bit has changed then sum would be differetnt