Computer Networks Questions & Answers – IPv4

This set of Computer Networks Multiple Choice Questions & Answers (MCQs) focuses on “IPv4”.

1. Which of the following is not applicable for IP?
a) Error reporting
b) Handle addressing conventions
c) Datagram format
d) Packet handling conventions
View Answer

Answer: a
Explanation: The Internet Protocol is the networking protocol which establishes the internet by relaying datagrams across network boundaries. ICMP is a supporting protocol for IP which handles the Error Reporting functionality.

2. Which of the following field in IPv4 datagram is not related to fragmentation?
a) Flags
b) Offset
c) TOS
d) Identifier
View Answer

Answer: c
Explanation: TOS-type of service identifies the type of packets. It is not related to fragmentation but is used to request specific treatment such as high throughput, high reliability or low latency for the IP packet depending upon the type of service it belongs to.

3. The TTL field has value 10. How many routers (max) can process this datagram?
a) 11
b) 5
c) 10
d) 1
View Answer

Answer: c
Explanation: TTL stands for Time to Live. This field specifies the life of the IP packet based on the number of hops it makes (Number of routers it goes through). TTL field is decremented by one each time the datagram is processed by a router. When the value is 0, the packet is automatically destroyed.
advertisement
advertisement

4. If the value in protocol field is 17, the transport layer protocol used is _____________
a) TCP
b) UDP
c) ICMP
d) IGMP
View Answer

Answer: b
Explanation: The protocol field enables the demultiplexing feature so that the IP protocol can be used to carry payloads of more than one protocol type. Its most used values are 17 and 6 for UDP and TCP respectively. ICMP and IGMP are network layer protocols.

5. The data field cannot carry which of the following?
a) TCP segment
b) UDP segment
c) ICMP messages
d) SMTP messages
View Answer

Answer: c
Explanation: Data field usually has transport layer segments, but it can also carry ICMP messages. SMTP is an application layer protocol. First it must go through the transport layer to be converted into TCP segments and then it can be inserted into IP packets.
Note: Join free Sanfoundry classes at Telegram or Youtube

6. What should be the flag value to indicate the last fragment?
a) 0
b) 1
c) TTl value
d) Protocol field value
View Answer

Answer: a
Explanation: The Flag field in the IP header is used to control and identify the fragments. It contains three bits: reserved, don’t fragment and more fragments. If the more fragments bit is 0, it means that the fragment is the last fragment.

7. Which of these is not applicable for IP protocol?
a) is connectionless
b) offer reliable service
c) offer unreliable service
d) does not offer error reporting
View Answer

Answer: b
Explanation: IP does not provide reliable delivery service for the data. It’s dependent upon the transport layer protocols like TCP to offer reliability.
advertisement

8. Which of the following demerits does Fragmentation have?
a) complicates routers
b) open to DOS attack
c) overlapping of fragments.
d) all of the mentioned
View Answer

Answer: d
Explanation: Fragmentation makes the implementation of the IP protocol complex and can also be exploited by attackers to create a DOS attack such as a teardrop attack. Fragmentation won’t be required if the transport layer protocols perform wise segmentation.

9. Which field helps to check rearrangement of the fragments?
a) offset
b) flag
c) ttl
d) identifer
View Answer

Answer: a
Explanation: The Fragment Offset field specifies where the fragment fits in the original datagram. The offset of the first fragment will always be 0. The size of the field (13 bits) is 3-bits shorter than the size of the total length field (16 bits).
advertisement

Sanfoundry Global Education & Learning Series – Computer Networks.

To practice all areas of Computer Networks, here is complete set of 1000+ Multiple Choice Questions and Answers.

If you find a mistake in question / option / answer, kindly take a screenshot and email to [email protected]

advertisement
advertisement
Subscribe to our Newsletters (Subject-wise). Participate in the Sanfoundry Certification contest to get free Certificate of Merit. Join our social networks below and stay updated with latest contests, videos, internships and jobs!

Youtube | Telegram | LinkedIn | Instagram | Facebook | Twitter | Pinterest
Manish Bhojasia - Founder & CTO at Sanfoundry
Manish Bhojasia, a technology veteran with 20+ years @ Cisco & Wipro, is Founder and CTO at Sanfoundry. He lives in Bangalore, and focuses on development of Linux Kernel, SAN Technologies, Advanced C, Data Structures & Alogrithms. Stay connected with him at LinkedIn.

Subscribe to his free Masterclasses at Youtube & discussions at Telegram SanfoundryClasses.