NWC203

You might also like

Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 6

Q1.

a, In a three – way handshake procedure, one must ensure the


selection of the initial sequence number is always unique. If station B
receives on old SYN segment from A, B acknowledge the request based
on the old sequence number. When A receives the acknowledge
segment from B, A will find out that B receives a wrong sequence
number. A will discard the acknowledge packet and reset the
connection.

b, If an old SYN segment from A arrives at B, followed by an old ACK


segment from A to a SYN segment from B the connection will also be
rejected. Initially, when B receives old SYN segment B will send a SYN
segment with its own distinct segment the old ACK from A, B will notify
A that the connection is invalid since the old ACK sequence number
does not match the sequence number previously defined by B.
Therefore, the connections rejected.

Q2.
A0 = 11111111 11111111 = 216 – 1 = 65535
A1 = 11111111 00000000 = 216 – 256 = 65280
A2 = 11110000 11110000 =216 – 3856 = 61680
A3 = 11000000 11000000 = 216 – 16192 = 49344
X = (A0 + A1 + A2 + A3) mod 65535 = 241839 mod 65535 = 45234
A4 = -X mod 65535 = -45234 mod 65535 = 20301.
The Internet checksum for this code is 0100111101001101

Q.3.
a,
8∗1024∗1024
T 32 K = = 262.144 s
32000

b,
8∗1024∗1024
T 1M = = 8,38 s
1∗10 6

c,
8∗1024∗1024
T 32 K = = 43,69 s
32000∗6
8∗1024∗1024
T 1M = = 1,4 s
1∗106∗6

Q4.
a,
Taking the first 22 bit as the network
135.46.63.10 = 135.46.00111111.10 = 135.46.00111100.0 = 135.46.60.0
 Interface 1.
b,
Taking the first 22 bits as the network
135.46.57.14 = 136.46.00111001.14 = 135.46.00111000.0 = 135.46.56.0
 Interface 0.
Q5.
Bits = 110110
a, g1(x) = x+1
generative polynomial : 11
Step 1:
Machine a assigns n-1 bits 0s to the end of the data bit string ( n is the
generative polynomial bits string)
We get: n – 1 = 2-1 = 1
Bit = 1101100
Step 2: Take the bits string obtained in step 1 and divide module 2 by
the generative polynomial
1101100
11
------------
00
00
-------------
01
00
-----------------
11
11
-----------------------
00
00
---------------------
00
00
------------------
0
Codeword = 1101100

b,
g2(x) = x 3 + x 2+ 1
generative polynomial : 1101
Step 1:
Machine a assigns n-1 bits 0s to the end of the data bit string ( n is the
generative polynomial bits string)
We get: n – 1 = 4-1 = 3
Bit = 110110000
Step 2: Take the bits string obtained in step 1 and divide module 2 by
the generative polynomial
11011000000
1101
-----------------------
0001
0000
-------------------------
0010
0000
-------------------------
0100
0000
--------------------------
1000
1101
----------------------------
1010
1101
------------------------------
111
Codeword = 110110111

You might also like