COMPUTER NETWORK AND SECURITY

5.3 Network layer: 

 

Addressing (Internet address, classful address)

 

1. What is the purpose of an IP address in computer networks?

a. To identify the physical location of a device
b. To uniquely identify a device on a network
c. To determine the speed of data transmission
d. To control access to the internet

Answer: b. To uniquely identify a device on a network

2. Which of the following is a valid IPv4 address?

a. 256.168.1.1
b. 192.256.0.1
c. 192.168.1.1
d. 300.0.0.1

Answer: c. 192.168.1.1

3. In classful addressing, how is the IP address space divided into classes?

a. Based on geographical location
b. Based on the size of the network
c. Based on the speed of the network
d. Based on the type of devices connected

Answer: b. Based on the size of the network

4. Which class of IP addresses is reserved for multicast groups?

a. Class A
b. Class B
c. Class C
d. Class D

Answer: d. Class D

5. How many bits are used for the host portion in a Class A IP address?

a. 8 bits
b. 16 bits
c. 24 bits
d. 32 bits

Answer: c. 24 bits

6. What is the default subnet mask for a Class B network?

a. 255.0.0.0
b. 255.255.0.0
c. 255.255.255.0
d. 255.255.255.255

Answer: b. 255.255.0.0

7. Which range of IP addresses is reserved for private networks according to RFC 1918?

a. 10.0.0.0 - 10.255.255.255
b. 172.16.0.0 - 172.31.255.255
c. 192.168.0.0 - 192.168.255.255
d. All of the above

Answer: d. All of the above

8. In CIDR notation, what does the "/24" in 192.168.1.0/24 represent?

a. The number of available subnets
b. The number of host bits
c. The number of network bits
d. The total number of IP addresses

Answer: c. The number of network bits

9. Which protocol is responsible for converting domain names to IP addresses?

a. DHCP
b. DNS
c. ARP
d. ICMP

Answer: b. DNS

10. What is the purpose of the loopback address 127.0.0.1?

a. Reserved for broadcast messages
b. Reserved for testing and troubleshooting
c. Reserved for multicast communications
d. Reserved for private networks

1. Which class of IP addresses is used for loopback addresses, often represented as 127.0.0.1?

a. Class A
b. Class B
c. Class C
d. Class D

Answer: a. Class A

2. In a Class B IP address, how many bits are allocated for the network portion?

a. 8 bits
b. 16 bits
c. 24 bits
d. 32 bits

Answer: b. 16 bits

3. What is the purpose of subnetting in IP addressing?

a. To create smaller, more manageable networks
b. To increase the speed of data transmission
c. To reserve IP addresses for future use
d. To simplify network configuration

Answer: a. To create smaller, more manageable networks

4. Which classless addressing scheme allows for variable-length subnet masks?

a. IPv4
b. Classful addressing
c. CIDR
d. DNS

Answer: c. CIDR

5. What is the primary motivation for the transition from IPv4 to IPv6?

a. Improved network speed
b. Increased security
c. Exhaustion of IPv4 address space
d. Enhanced compatibility with older devices

Answer: c. Exhaustion of IPv4 address space

6. Which of the following is a private IP address in the Class A range?

a. 10.10.10.10
b. 172.16.1.1
c. 192.168.0.1
d. 255.255.255.0

Answer: a. 10.10.10.10

7. What is the purpose of the Address Resolution Protocol (ARP) in networking?

a. To convert IP addresses to MAC addresses
b. To translate domain names to IP addresses
c. To discover the default gateway
d. To authenticate users on the network

Answer: a. To convert IP addresses to MAC addresses

8. Which of the following subnet masks corresponds to a Class C network?

a. 255.0.0.0
b. 255.255.0.0
c. 255.255.255.0
d. 255.255.255.255

Answer: c. 255.255.255.0

9. What is the role of DHCP in network addressing?

a. To translate domain names to IP addresses
b. To dynamically assign IP addresses to devices on a network
c. To manage the security of network connections
d. To identify the physical location of a device

Answer: b. To dynamically assign IP addresses to devices on a network

10. In classful addressing, how are Class D addresses identified?

a. They start with the binary sequence '01' in the first octet
b. They start with the binary sequence '10' in the first octet
c. They start with the binary sequence '110' in the first octet
d. They start with the binary sequence '1110' in the first octet


 

Subnetting

 

1. What is subnetting in networking?

a. Dividing a network into smaller, logical sub-networks
b. Increasing the overall size of a network
c. Connecting two separate networks
d. Allocating IP addresses to devices

Answer: a. Dividing a network into smaller, logical sub-networks

2. Why is subnetting used?

a. To improve network speed
b. To simplify network configuration
c. To create smaller, more manageable networks
d. To enhance data security

Answer: c. To create smaller, more manageable networks

3. What is the purpose of a subnet mask in subnetting?

a. To identify the network portion of an IP address
b. To convert IP addresses to MAC addresses
c. To determine the speed of data transmission
d. To control access to the internet

Answer: a. To identify the network portion of an IP address

4. In subnetting, what is the maximum number of subnets you can create with a subnet mask of 255.255.255.224?

a. 4
b. 8
c. 16
d. 32

Answer: b. 8

5. Which subnet mask provides the largest number of host addresses in a subnet?

a. 255.255.255.0
b. 255.255.0.0
c. 255.255.255.128
d. 255.255.255.192

Answer: a. 255.255.255.0

6. What is the purpose of Variable Length Subnet Masking (VLSM) in subnetting?

a. To allocate IP addresses dynamically
b. To create subnets of different sizes within the same network
c. To simplify the subnetting process
d. To encrypt subnet communications

Answer: b. To create subnets of different sizes within the same network

7. How does subnetting contribute to efficient IP address utilization?

a. By reducing the number of available IP addresses
b. By limiting the number of devices on a network
c. By minimizing IP address conflicts
d. By conserving and optimizing available IP address space

Answer: d. By conserving and optimizing available IP address space

8. What is the default subnet mask for a Class C network?

a. 255.0.0.0
b. 255.255.0.0
c. 255.255.255.0
d. 255.255.255.255

Answer: c. 255.255.255.0

9. Which of the following CIDR notations represents a subnet with 64 IP addresses?

a. /26
b. /28
c. /30
d. /32

Answer: a. /26

10. What is the primary benefit of subnetting in terms of network management?

a. Enhanced network security
b. Simplified troubleshooting
c. Improved network performance
d. Efficient utilization of IP addresses


 

Routing Protocols (RIP,

OSPF, BGP, Unicast and multicast routing protocols)

 

1. What does RIP stand for in the context of routing protocols?

a. Routing Internet Protocol
b. Reliable Internet Protocol
c. Routing Information Protocol
d. Remote Internet Protocol

Answer: c. Routing Information Protocol

2. Which type of routing protocol is RIP?

a. Distance Vector
b. Link State
c. Path Vector
d. Hybrid

Answer: a. Distance Vector

3. What is the maximum hop count supported by RIP?

a. 8
b. 15
c. 16
d. 255

Answer: b. 15

4. OSPF operates based on which type of routing algorithm?

a. Distance Vector
b. Link State
c. Path Vector
d. Hybrid

Answer: b. Link State

5. In OSPF, what is the purpose of the designated router (DR) and backup designated router (BDR)?

a. They handle authentication between routers
b. They are responsible for forwarding data packets
c. They facilitate efficient communication within a broadcast network
d. They manage routing tables

Answer: c. They facilitate efficient communication within a broadcast network

6. Which routing protocol is commonly used for routing between autonomous systems in the Internet?

a. RIP
b. OSPF
c. BGP
d. EIGRP

Answer: c. BGP

7. BGP is primarily designed for:

a. Interior routing within an autonomous system
b. Exterior routing between autonomous systems
c. Multicast routing
d. Unicast routing

Answer: b. Exterior routing between autonomous systems

8. What is the administrative distance of BGP?

a. 90
b. 100
c. 110
d. 120

Answer: d. 120

9. Which of the following is a characteristic of Unicast routing?

a. One-to-Many communication
b. One-to-One communication
c. Many-to-Many communication
d. Broadcast communication

Answer: b. One-to-One communication

10. What is the main advantage of Multicast routing?

a. Improved security
b. Reduced network traffic-
c. Faster data transmission
d. Simpler network configurations : b. Reduced network traffic**

11. Which routing protocol uses a metric based on bandwidth and delay to determine the best path?

a. RIP
b. OSPF
c. BGP
d. EIGRP-

12. What is the purpose of the TTL (Time-To-Live) field in routing protocols?

a. To limit the number of hops a packet can traverse-
b. To authenticate routers on the network
c. To specify the type of data being transmitted
d. To control the priority of routing updates

13. Which routing protocol uses DUAL (Diffusing Update Algorithm) to calculate the shortest path?

a. RIP
b. OSPF
c. BGP
d. EIGRP-

14. In which type of network is OSPF particularly well-suited?

a. Small, simple networks
b. Large, complex networks-
c. Point-to-point networks
d. Broadcast networks

 

15. What is the primary advantage of Link State routing protocols over Distance Vector routing protocols?

a. Faster convergence-
b. Lower bandwidth usage
c. Simpler configuration
d. Better support for multicast

 

16. Which of the following is a characteristic of BGP routing tables?

a. Hierarchical structure-
b. Flat structure
c. Limited scalability
d. Dynamic updates

17. What type of routing protocol is EIGRP (Enhanced Interior Gateway Routing Protocol)?

a. Distance Vector
b. Link State
c. Hybrid-
d. Path Vector

18. What is the primary drawback of RIP in larger networks?

a. Limited hop count
b. Slow convergence-
c. Inefficient use of bandwidth
d. Lack of support for VLSM (Variable Length Subnet Masking)

19. Which protocol is commonly used for multicast routing in IP networks?

a. OSPF
b. IGMP
c. PIM (Protocol Independent Multicast)-
d. BGP

20. In Unicast routing, what is the purpose of the routing table?

a. To store multicast group information
b. To identify the best path for data transmission to a specific destination-
c. To manage the routing of broadcast packets
d. To authenticate routers on the network


 

Routing algorithms (shortest path algorithm,

flooding, distance vector routing, link state routing) 

1. Which routing algorithm is used by OSPF (Open Shortest Path First)?

a. Dijkstra's Shortest Path Algorithm
b. Flooding Algorithm
c. Bellman-Ford Algorithm
d. Distance Vector Routing Algorithm

Answer: a. Dijkstra's Shortest Path Algorithm

2. What is the primary goal of the Shortest Path Algorithm in routing?

a. Minimizing the number of hops between source and destination
b. Maximizing the network bandwidth
c. Minimizing the delay in data transmission
d. Maximizing the number of available routes

Answer: a. Minimizing the number of hops between source and destination

3. In flooding, how are routing updates propagated throughout the network?

a. Only to neighboring routers
b. To all routers in the network
c. Along the shortest path only
d. Based on the distance vector

Answer: b. To all routers in the network

4. Which routing algorithm is susceptible to the count-to-infinity problem?

a. Dijkstra's Shortest Path Algorithm
b. Flooding Algorithm
c. Bellman-Ford Algorithm
d. Link State Routing Algorithm

Answer: c. Bellman-Ford Algorithm

5. What information does a distance vector routing algorithm use to make routing decisions?

a. Complete map of the network
b. The hop count to each destination
c. Link state information
d. Shortest path calculations

Answer: b. The hop count to each destination

6. Which algorithm uses a routing table that is periodically exchanged with neighboring routers?

a. Dijkstra's Shortest Path Algorithm
b. Flooding Algorithm
c. Distance Vector Routing Algorithm
d. Link State Routing Algorithm

Answer: c. Distance Vector Routing Algorithm

7. What is the primary advantage of Link State Routing over Distance Vector Routing?

a. Faster convergence
b. Simpler configuration
c. Reduced bandwidth usage
d. Lower overhead

Answer: a. Faster convergence

8. Which algorithm is used by RIP (Routing Information Protocol)?

a. Dijkstra's Shortest Path Algorithm
b. Flooding Algorithm
c. Bellman-Ford Algorithm
d. Link State Routing Algorithm

Answer: c. Bellman-Ford Algorithm

9. In Link State Routing, what information is exchanged between routers to build a complete map of the network?

a. Routing tables
b. Distance vectors
c. Link state packets
d. Broadcast packets

Answer: c. Link state packets

10. Which algorithm is prone to the "count-to-infinity" problem?

a. Dijkstra's Shortest Path Algorithm
b. Flooding Algorithm
c. Bellman-Ford Algorithm-
d. Link State Routing Algorithm


 

Routing Protocols (ARP, RARP, IP, ICMP)

 

1. What is the primary purpose of ARP (Address Resolution Protocol)?

a. To map a MAC address to an IP address
b. To map an IP address to a MAC address
c. To discover the default gateway
d. To authenticate routers on the network

Answer: b. To map an IP address to a MAC address

2. Which protocol is responsible for dynamically assigning IP addresses to devices on a network?

a. ARP
b. RARP
c. DHCP
d. ICMP

Answer: c. DHCP

3. In RARP (Reverse Address Resolution Protocol), what is the purpose of a device broadcasting its hardware address?

a. To obtain its IP address from a server
b. To obtain its MAC address from a server
c. To identify the default gateway
d. To update the ARP cache

Answer: a. To obtain its IP address from a server

4. Which layer of the OSI model does IP (Internet Protocol) operate at?

a. Data Link Layer
b. Network Layer
c. Transport Layer
d. Application Layer

Answer: b. Network Layer

5. What is the size of an IPv4 address in bits?

a. 16 bits
b. 32 bits
c. 64 bits
d. 128 bits

Answer: b. 32 bits

6. Which of the following is a reserved private IP address range specified by RFC 1918?

a. 10.0.0.0 - 10.255.255.255
b. 172.16.0.0 - 172.31.255.255
c. 192.168.0.0 - 192.168.255.255
d. All of the above

Answer: d. All of the above

7. What function does ICMP (Internet Control Message Protocol) primarily serve in networking?

a. To translate domain names to IP addresses
b. To manage the security of network connections
c. To control the flow of data packets
d. To provide error reporting and diagnostic functions

Answer: d. To provide error reporting and diagnostic functions

8. What ICMP message type is sent by a router to inform the source that a network or host is unreachable?

a. Echo Request
b. Destination Unreachable
c. Time Exceeded
d. Redirect

Answer: b. Destination Unreachable

9. In the context of IP addressing, what is a subnet mask used for?

a. To map IP addresses to MAC addresses
b. To identify the network portion of an IP address
c. To determine the speed of data transmission
d. To control access to the internet

Answer: b. To identify the network portion of an IP address

10. What is the purpose of the ARP cache in a device's memory?

a. To store a list of available IP addresses on the network
b. To store a mapping of IP addresses to corresponding MAC addresses-
c. To manage the routing tables
d. To authenticate devices on the network



 

IPv6 (Packet formats, Extension headers, Transition from IPv4 to IPv6, and Multicasting).

 

1. What is the size of an IPv6 address in bits?

a. 32 bits
b. 64 bits
c. 128 bits
d. 256 bits

Answer: c. 128 bits

2. In IPv6, what type of address is typically represented as "fe80::/10"?

a. Unicast
b. Multicast
c. Anycast
d. Link-local

Answer: d. Link-local

3. What is the purpose of the IPv6 extension header?

a. To contain the payload data
b. To specify the source and destination addresses
c. To provide additional routing information
d. To encapsulate the IPv6 header

Answer: c. To provide additional routing information

4. Which IPv6 extension header is used to identify the upper-layer protocol and process it accordingly?

a. Routing Header
b. Fragmentation Header
c. Hop-by-Hop Options Header
d. Next Header

Answer: d. Next Header

5. What is the main advantage of IPv6 over IPv4 in terms of address space?

a. IPv6 addresses are shorter
b. IPv6 allows for variable-length subnet masks
c. IPv6 has a larger address space
d. IPv6 addresses are backward-compatible with IPv4

Answer: c. IPv6 has a larger address space

6. How is IPv6 represented in textual form?

a. Binary
b. Decimal
c. Hexadecimal
d. Octal

Answer: c. Hexadecimal

7. What is the purpose of the "Anycast" addressing in IPv6?

a. To identify a specific device on the network
b. To represent a group of devices
c. To provide broadcast communication
d. To route packets to the nearest of a group of servers

Answer: d. To route packets to the nearest of a group of servers

8. What is the IPv6 equivalent of the IPv4 private address range (e.g., 192.168.0.0/16)?

a. fc00::/7
b. 2000::/3
c. fe80::/10
d. fd00::/8

Answer: d. fd00::/8

9. Which transition mechanism allows IPv6-enabled devices to communicate over an IPv4 network without dual-stack support?

a. 6to4
b. ISATAP
c. Teredo
d. NAT64