You are on page 1of 4

1

EP2120 Internetworking/Internetteknik
IK2218 Internets Protokoll och Principer

Homework Assignment 5

Solutions due 17:00, October 22, 2013
Review due 17:00, October 24, 2013
Revised version. Corrections marked in yellow.
Problems


1. Addressing and address allocation (20 p)
R1
A
B
C
E
F
C
D
R2
R3
R7
R6
R5
R4
Rest of the network

Consider the corporate network shown in the above figure. There are six networks (A-F).
Networks A-D contain 500 hosts each. Network F contains one host. Network E is a switched
Ethernet network, and does not contain any hosts. There are 7 routers (R1-R7) connecting the
networks. There are no point-to-point links in the network.
a) What is the longest prefix that can be used for the networks A, B, C, D, E, and F? (4 p)
b) Assume that you have the 11.185.208.0/20 block of addresses available for address allocation.
Allocate addresses to the individual networks such that every host and every router is
addressable on each of its interfaces. Network A should have the lowest IP address block
allocated. Allocate the blocks such that address aggregation can be done efficiently, that is,
router R1 should have only 2 forwarding table entries for the corporate network (plus one for
the rest of the network). Provide the address blocks allocated to the individual networks. (6 p)
c) What is the directed broadcast address of network A? (2 p)
d) Compare the All hosts multicast address and the Limited broadcast address. What is the similarity and
what is the difference between the two in terms of purpose and use? (2 p)
e) Provide the forwarding table of router R1. The forwarding table should contain at most 2
entries (apart from the default route to the rest of the network). (6 p)
2

2. ARP (20 p)

The figure above illustrates five hosts H
1
to H
5
connected by an inter-network running IPv4. The
hosts are on three Ethernet networks, which are connected by router R
1
. Note the learning bridge
B
1
that connects hosts H
3
, H
4
and router R
1
. The figure shows the IP and MAC addresses of the
hosts and the routers interfaces, and the interface names of the bridge. It also shows the ARP
caches of the hosts and the router, and the MAC address table of the learning bridge. Assume that
the ARP caches and the MAC address table are initially empty and that no packets have been sent
yet. The forwarding tables of all hosts and the router are correctly configured. All hosts know each
others IP addresses. The hosts and the routers use ARP snooping.
Consider that host H
2
sends an IPv4 unicast datagram to host H
3
.

a) Provide the state of the five ARP caches as they will appear after the IPv4 unicast datagram has
been delivered to host H
3
, that is, after dynamic ARP resolution has been made. (16 p)
b) Provide the state of the bridges MAC address table as it will appear after the IPv4 unicast
datagram has been delivered to host H
3
, that is, after dynamic ARP resolution has been made.
(4p)

3. TCP (20 p)
Consider two TCP entities A and B connected by an IPv4 network. The MSS is 1480 bytes. The
propagation time is 200 ms, the transmission time is small enough that it can be ignored. The
receiving TCP entity B has a receive buffer worth 15000 bytes, which it advertises to the sender.
The receiving process reads data from the TCP buffer immediately upon reception. Delayed ACKs
are not used. You want to transmit 100000 bytes from A to B. The initial value of the CWND is
3*MSS.
Assuming that the connection has just been established, how much time is needed for the reliable
transmission of the data, not including connection teardown?

4. IPsec (10 p)

Alice is sending an IPsec packet to Bob. Briefly explain outbound IPsec processing in Alices
computer. Your solution should cover the following parts: SPD (Security Policy Database), SAD
(Security Association Database), SA (Security Association), SPI (Security Parameter Index).
3

5. Firewalls (10 p)

In packet filtering firewalls you can sometimes find a rule saying that inbound TCP segments with
ACK flag set to 0 should be blocked. What is the purpose with such a rule?

6. IPv6 autoconfiguration (20 p)

When a host joins an IPv6 network, it can learn its global unicast IP address without assistance
from DHCP, using stateless autoconfiguration. Briefly describe the steps in this procedure. What
type of address will the host use during this process? What ICMPv6 messages will be exchanged
between the host and the other systems (routers and other hosts) on the subnet? When will the
host finally have all information needed to form its global unicast address?

7. DNS (20 p)

You use the dig lookup tool to get the IP address of KTHs web server www.kth.se:

dig www.kth.se

You receive the following response:

;; ANSWER SECTION:
www.kth.se 26 IN A 130.237.32.143
;; AUTHORITY SECTION:
kth.se. 1178 IN NS b.ns.kth.se.
kth.se. 1178 IN NS nic2.lth.se.
kth.se. 1178 IN NS ns2.chalmers.se.
kth.se. 1178 IN NS a.ns.kth.se.


Then you make another lookup for the same domain name, but this time you specify the name
server to query:

dig www.kth.se @a.ns.kth.se

Now you receive the following response:

;; ANSWER SECTION:
www.kth.se 60 IN A 130.237.32.143
;; AUTHORITY SECTION:
kth.se. 1800 IN NS b.ns.kth.se.
kth.se. 1800 IN NS nic2.lth.se.
kth.se. 1800 IN NS ns2.chalmers.se.
kth.se. 1800 IN NS a.ns.kth.se.

a) Explain the two responses. What are the differences? Why are they different? (10 p)
b) What can you learn from comparing the responses? (5 p)
c) Give an example of a dig command that would return the names of all root servers. (5 p)

8. Multimedia Communication (15 p)

A video source is generating video frames of size 10,000 bytes at a constant rate of 25 frames per
second. The frames are transmitted over a network with 1 Gb/s Ethernet links, and arrive at the
receiver with a maximum jitter (delay variation) of 200 milliseconds.
4
a) What is the minimum size of the playback buffer in order to ensure smooth playback of the
video stream at the receiver? (10 p)
b) The video frames are encapsulated in RTP and then transmitted over UDP. What is the reason
for using RTP on top of UDP? What does it provide, that UDP does not? (5 p)

9. Socket Interface (15 p)

The pseudo-code sample below (with most details omitted) describes an application that uses the
socket interface (API) for communication.

s = socket();
bind(s, );
listen(s, );
while true {
t = accept(s, );
recv(t, );
HandleRequest();
send(t, );
close(t);
}

a) Is the sample code for a client or a server? Does it use TCP or UDP? Explain your answer. (5 p)
b) The textbook gives two examples of communication using the socket interface: connection-
oriented, concurrent communication and connectionless iterative communication. Characterize
the communication in the sample code using the same terminology. (5 p)
c) In practice, this kind of communication is not frequently used. What is the main limitation?
(5 p)

You might also like