60-375 Midterm II Answer
Q.1(15Marks)
a) What are the advantages of having a UDP checksum separate from the IP checksum?
Answer:
The UDP checksum provides the only way to guarantee that the date has arrived intact and should be used .IP does not compute a checksum on the date portion of an IP datagram.
Moreover the Source and Destination IP address and the UDP length are also covered in the pseudo-Header.
Hence a UDP checksum verifies the correct receipt of these items also.
b) Why do we use protocol ports rather than process identifiers to specify the destination within a machine?
Answer:
(1). Processes are created and destroyed dynamically. A Sender ,therefore, cannot
identify the processes on the Receiver machine .
(2) The Receiver may replace processes (say by rebooting the machine) without
informing all the Senders .
(3). The need is to identify destinations form the functions they implement.
(4). A process may handle two or more functions simultaneously.
So abstract destination points called Protocol Ports are used to define functional destinations in machines using UDP/TCP.
c) Describe briefly how TCP is able to provide Reliability for messages travelling in unreliable IP datagrams.
Answer:
TCP is able to provide Reliabilities by
----numbering the date bytes by a Sequence Number .This helps the Receiver in
Reassembly to detect Duplication or out of order delivery . .
----Positive Acknowledgement & Retransmission .
d) What do you understand by VIRTUAL CIRCUIT CONNECTION ?
Answer:
In the beginning when an Application as to send date to an Application or another machine , TCP establishes the connection by confirming the sequence number and other parameters like maximum segment size between the TCP software packages of the Sender and the Receiver .Then the application is informed that the connection has been established.
As the date is sent, the TCP packages continue to exchange messages to verify that the date is being transferred correctly .
In case of failure ,the two packages detect it and inform the application. At the end
of data transfer, the connection is closed.
Thus, TCP provides an illusion of a physical connection btw the two machines, even though the underlying protocol (IP) provides a connectionless delivery only.
e) Discuss Karn’s algorithm.
Answer:
When computing RTT estimate, ignore the samples corresponding to retransmitted segments but Use a back off strategy for time out value for the Retransmission timer as follow.
New-time out = r* timeout
Where r = 2
Retain the timeout valve from =Retransmitted segment till a ‘valid’ sample (without retransmission) is obtained.
Q.2(20 Marks )
a) Does PUSH ,in a TCP segment ,cause low throughput and does it defeat the Silly Window
Avoidance mechanism?
Answer:
Yes, Push will cause low throughput , particularly if it is used continuously in a large number of messages.
No, However it dose not defeat the Silly Window Avoidance mechanism since the Nagle algorithm ,used for the purpose, over-rides PUSH.
b) Consider an Application which generates data for sending at a slow rate and which uses TCP .Before sending a segment, is CLUMPING of data – till it reaches the Maximum Segment Size –a requirement?
Answer: yes
CLUMPING is a requirement in that the date is stored in the output butter until it reaches the Max Seg Size –OR-until an Acknowledgement arrives ,when the whole date in the output butter is sent even if it has not yet reached the Max Seg size.
c) Is a network using PROXY ARP vulnerable to SPOOFING?
Answer: yes
Since the PROXY ARP router is going to provide its own physical address as a proxy for the machines connected in a LAW to the other side of the Router , the ‘routing’ tables of the hosts may contain the same physical address for multiple , distinct IP addresses.
Since this a normal process in proxy ARP systems ,one cannot build a protection against spoofing since it would require a prohibition against having the same physical address for distinctly (different) IP addresses.
d) Suppose a FIN message, sent to shut down the first connection btw two machines on Internet, is duplicated and delayed until a second connection btw the same two machines has been established. If a copy o f the old FIN is delivered, will TCP terminate the new connection?
Answer: No
The message for the new TCP connection would be required to have identical source & destination IP addresses, protocol port numbers and TCP sequence numbers for the earlier message to have an effect.
Q3(20 marks)
a)
Refer to the fig. below.
![]()
![]()
Rest of the Internet

131.108.0.0 78.0.0.28
![]()
![]()
223.240.129.0 151.100.0.1

![]()
![]()

Experimental Technology
Draw the routing table for R4.
The table should have 3 columns as follows. Subnet mask, Network
address, Next hop address.
Answer:
|
Subnet Mask |
Network Address |
Next Hop Address |
|
255.255.0.0 |
151.100.0.0 |
Direct Delivery |
|
255.255.240.0 |
128.10.16.0 |
Direct Delivery |
|
255.255.240.0 |
128.10.32.0 |
Direct Delivery |
|
255.255.255.0 |
223.240.125.0 |
151.100.0.9 |
|
255.255.0.0 |
131.108.0.0 |
151.100.0.9 |
|
255.0.0.0 |
78.0.0.0 |
151.100.0.9 |
|
0.0.0.0 |
0.0.0.0 |
151.100.0.28 |
b) State and explain the Routing Algorithm used by Router on Internet.
Answer:
Unified Routing Algorithm:
Special cases in the Routing Algorithm can be integrated by a creative selection of masks. For example:
A mask of all 1’s and network address = host’s IP address .
Default Route :
Subnet mask of all 0’s and network address =all 0’s
Algorithm:
Extract destination IP address ID from the dataegram .
Computer IP address of destination network In.
If In matches any Directly Connected Network address, send the datagram to its destination over that network, (this involves resolving Td to a physical address ,
encapsulating the datagram and sending the frame.)
else
for each entry in the routing table do
let N be the bitwise AND of Id and the subnet mask.
If N equals the network address field of the entry, then route the datagram to
the specified next hop address .
end_for _loop.
If no matches were found, declare a routing error.
Q4.(Refer to Fig.I and Fig.II) (25 marks)
Specify the value of each one of the following fields in the pseudo-header and the TCP Segment:
TCP LENGTH,HLEN, OPTION-LENGTH CHECKSUM
Specify the values in the decimal number system only.
Given that:
Source port number=23, destination port number=4096,
Sequence number=257, acknowledgement number=129,
Window=131,urgent pointer=0,option-kind=2,
Maximum segment size=1024 bytes, protocal=6,
Source IP address=193.144.8.26,
Destination IP address=193.144.8.21.
The segment is carrying no data.
The values above are given in the decimal number system. The IP address are in dotted-decimal notation.
The code bits in binary are 010010.
Fig. I
Pseudo Header
0 8 16 31
|
SOURCE IP ADDRESS |
|
DESTINATION ADDRESS |
|
ZERO ZERO PROTOCOL TCP LENGTH |
Fig.II
TCP HEADER
0 4 8 16 31
|
SOURCE PORT DESTINATION PORTS |
|
SEQUENCE NUMBER |
|
ACKNOWLEDGEMENT NUMBER |
|
HLEN RESERVED CODE BITS WINDOW |
|
CHECKSUM URGENT POINTER |
|
OPTION KIND OPTION LENGTH MAXIMUM SEGMENT SIZE |
Answer:
193.144.8.26----->c1 90 08 1A
193.144.8.21----->c1 90 08 15
0017 1000
0000 0101
0000 0081
6012 0083
0204 0400
1 2 2
c 1 9 0
0 8 1 A
c 1 9 0
0 8 1 5
0 0 0 6
0 0 1 8
0 0 1 7
1 0 0 0
0 1 0 1
0 0 8 1
6 0 1 2
0 0 8 3
0 2 0 4
0 4 0 0
2 0 B 9 F
2
0 B A 1
CHECKSUM= F45E
Decimal val=4096*15 + 256 4 + 16*5 +15=62559
TCP length=24
Hlen=6
Option length=4
Checksum=62559
Q5 (20Marks)
(1) Which of the following is the world’s largest computer network?
(a) Prodigy
(b) CompuServe
(c) Novell Netware
(d) The Internet
(2) Which of the following would you use if you want to run a program on a remote computer over the Internet?
(a) FTP
(b) WAIS
(c) Telnet
(d) Gopher
(3) Which of the following is NOT a function of TCP?
(a) binding physical addresses to IP addresses
(b) reassembling segments.
(c) Acknowledging receipt of segments.
(d) Retransmission of segments
(4) Subnetting and Supernetting techniques are used to help avoid
(a) congestion at Routers.
(b) The Running Out of Address Space problem.
(c) Overflow of buffer at receiver.
(d) Duplication of datagrams.
(e) Effects of noise on data communication.
(5) To avoid the Silly Window Syndrome problem , a software solution is required to be worked out
(a) at the intermediate routers.
(b) In the physical layer of the software package.
(c) In the application layer of the software package.
(d) For setting the RST and the PST and the PSH bits.
(e) At both the sending end as well as at the receiving end.
Answer:
(1).d (2).c (3).a (4).b (5).e