NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 1 UNIT - III
Mobile Network Layer: Mobile IP: Goals, assumptions and requirements, Entities and terminology, IP Packet delivery, Agent discovery, Registration, Tunneling and encapsulation, Optimizations.
Dynamic Host Configuration Protocol.
Mobile ad-hoc networks: Routing, DSDV, DSR, Alternative Metrics.
3.1 Mobile IP
Mobile IP (or MIP) is a internet engineering task force(IETF) standard communications protocol that is aimed to solve the mobility problem of network mode. Mobile IP enables a wireless network node to move freely from one point of connection to the internet to another, without disrupting the TCP end-to-end connectivity.
Mobility is the ability of a node to change its point-of-attachment while maintaining all existing communications and using the same IP address.
Nomadicity allows a node to move but is must terminate all existing communications and then can initiate new connections with a new address.
3.1.1 Design Goals
Mobile IP was developed as a means for transparently dealing with problems of mobile users. Mobile IP was designed to make the size and the frequency of required routing updates as small as possible. It was designed to make it simple to implement mobile node software. It was designed to avoid solutions that require mobile nodes to use multiple addresses.
3.1.2 Requirements
There are several requirements for Mobile IP to make it as a standard. Some of them are:
1. Compatibility: The whole architecture of internet is very huge and a new standard cannot introduce changes to the applications or network protocols already in use. Mobile IP is to be integrated into the existing operating systems. Mobile IP must not require special media or MAC/LLC protocols, so it must use the same interfaces and mechanisms to access the lower layers as IP does.
2. Transparency: Mobility should remain ‘invisible’ for many higher layer protocols and applications.
Besides maybe noticing a lower bandwidth and some interruption in service, higher layers should continue to work even if the mobile computer has changed its point of attachment to the network.
3. Scalability and efficiency: The efficiency of the network should not be affected even if a new mechanism is introduced into the internet. Enhancing IP for mobility must not generate many new messages flooding the whole network. Just think of cars, trucks, mobile phones, every seat in every plane around the world etc. – many of them will have some IP implementation inside and move between different networks and require mobile IP. It is crucial for a mobile IP to be scalable over a large number of participants in the whole internet, worldwide.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 2 4. Security: Mobility possesses many security problems. A minimum requirement is the authentication of all messages related to the management of mobile IP. It must be sure for the IP layer if it forwards a packet to a mobile host that this host really is the receiver of the packet. The IP layer can only guarantee that the IP address of the receiver is correct. There is no way to prevent faked IP addresses and other attacks.
The goal of a Mobile IP can be summarized as: ͚supporting end-system mobility while Maintaining scalability, efficiency, and compatibility in all respects with existing applications
And internet protocols.
3.2 Entities and terminology
The following defines several entities and terms needed to understand mobile IP as defined in RFC 3344 Mobile Node (MN): A mobile node is an end-system or router that can change its point of attachment to the internet using mobile IP. The MN keeps its IP address and can continuously communicate with any other system in the internet as long as link-layer connectivity is given. Examples are laptop, mobile phone, router on an aircraft etc.
Correspondent node (CN): At least one partner is needed for communication. In the following the CN represents this partner for the MN. The CN can be a fixed or mobile node.
Home network: The home network is the subnet the MN belongs to with respect to its IP address. No mobile IP support is needed within the home network.
Foreign network: A foreign network is any network other than the home network to which a mobile device may be connected.
Foreign agent (FA):
A foreign agent is a router serving as a mobility agent for a mobile node. a foreign agent works in conjunction with another type of mobility agent known as a home agent to support Internet traffic forwarding for a device connecting to the Internet from any location other than its home network.
Care-of address (COA): A care-of address (usually referred to as CoA) is a temporary IP address for a mobile device. This allows a home agent to forward messages to the mobile device.
There are two different possibilities for the location of the COA:
a) Foreign agent COA: The COA could be located at the FA, i.e., the COA is an IP address of the FA. The FA is the tunnel end-point and forwards packets to the MN. Many MN using the FA can share this COA as common COA.
b) Co-located COA: The COA is co-located if the MN temporarily acquired an additional IP address which acts as COA. This address is now topologically correct, and the tunnel endpoint is at the MN. Co-located addresses can be acquired using services such as DHCP.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 3 Home agent (HA): A home agent is a router on a mobile node's home network that maintains information about the device's current location, as identified in its care-of address. The home agent uses tunneling mechanisms to forward Internet traffic so that the device's IP address doesn't have to be changed each time it connects from a different location
Three alternatives for the implementation of an HA exist.
1. The HA can be implemented on a router that is responsible for the home network. This is obviously the best position, because without optimizations to mobile IP, all packets for the MN have to go through the router anyway.
2. If changing the router’s software is not possible, the HA could also be implemented on an arbitrary node in the subnet. One disadvantage of this solution is the double crossing of the router by the packet if the MN is in a foreign network. A packet for the MN comes in via the router; the HA sends it through the tunnel which again crosses the router.
3. Finally, a home network is not necessary at all. The HA could be again on the router but this time only acting as a manager for MNs belonging to a virtual home network. All MNs are always in a foreign network with this solution.
The example network in Figure shows the following situation:
A CN is connected via a router to the internet, as are the home network and the foreign network. The HA is implemented on the router connecting the home network with the internet, an FA is implemented on the router to the foreign network. The MN is currently in the foreign network. The tunnel for packets toward the MN starts at the HA and ends at the FA, for the FA has the COA in this example.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 4
3.3 IP packet delivery
Consider the above example in which a correspondent node (CN) wants to send an IP packet to the MN.
One of the requirements of mobile IP was to support hiding the mobility of the MN. CN does not to know anything about the MNs current location and sends the packet as usual to the IP address of MN as shown below.
Step 1: CN sends an IP packet with MN as a destination address and CN as a source address. The internet, not having information on the current location of MN, routes the packet to the router responsible for the home network of MN. This is done using the standard routing mechanisms of the internet.
Step 2: (Tunneling and encapsulation) The foreign agent now decapsulates the packet, i.e., removes the additional header, and forwards the original packet with CN as source and MN as destination to the MN.
Step 3: Again, for the MN mobility is not visible. It receives the packet with the same sender and receiver address as it would have done in the home network.
Step 4: The router with the FA acts as default router and forwards the packet in the same way as it would do for any other node in the foreign network.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 5
3.4 Agent discovery
Working of Mobile IP:- Mobile IP has two addresses for a mobile host: one home address and one care of address. The home address is permanent; the care-of address changes as the mobile host moves from one network to another.
One initial problem of an MN after moving is how to find a foreign agent. How does the MN discover that it has moved? For this purpose mobile IP describes two methods:
1. Agent advertisement 2. Agent solicitation 1. Agent advertisement
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 6
3.5 Agent Registration
The main purpose of the registration is to inform the HA of the current location for correct forwarding of packets. Registration can be done in two different ways depending on the location of the COA.
Mobile IP registration provides a flexible mechanism for mobile nodes to communicate their current reachability information to their home agent. The registration process enables mobile nodes to perform the following tasks:
Request forwarding services when visiting a foreign network Inform their home agent of their current care-of address Renew a registration that is due to expire
Deregister when they return home
These registration processes involve the exchange of registration requests and registration reply messages.
When registering using a foreign agent, the registration process takes the following steps, which the subsequent illustration depicts:
a) The mobile node sends a registration request to the prospective foreign agent to begin the registration process.
b) The foreign agent processes the registration request and then relays it to the home agent.
c) The home agent sends a registration reply to the foreign agent to grant or deny the request.
d) The foreign agent processes the registration reply and then relays it to the mobile node to inform it of the disposition of its request.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 7
3.6 Tunneling and encapsulation
Tunneling is a protocol that allows for the secure movement of data from one network to another.
Tunneling involves allowing private network communications to be sent across a public network, such as the Internet, through a process called encapsulation. The encapsulation process allows for data packets to appear as though they are of a public nature to a public network when they are actually private data packets, allowing them to pass through unnoticed.
Tunneling is also known as port forwarding.
In tunneling, the data are broken into smaller pieces called packets as they move along the tunnel for transport. As the packets move through the tunnel, they are encrypted and another process called encapsulation occurs. The private network data and the protocol information that goes with it are encapsulated in public network transmission units for sending. The units look like public data, allowing them to be transmitted across the Internet. Encapsulation allows the packets to arrive at their proper destination. At the final destination, de-capsulation and decryption occur.
Tunneling is also known as port forwarding.
There are various protocols that allow tunneling to occur, including:
a) Point-to-Point Tunneling Protocol (PPTP): PPTP keeps proprietary data secure even when it is being communicated over public networks. Authorized users can access a private network called a virtual private
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 8 network, which is provided by an Internet service provider. This is a private network in the “virtual” sense because it is actually being created in a tunneled environment.
b) Layer Two Tunneling Protocol (L2TP): This type of tunneling protocol involves a combination of using PPTP and Layer 2 Forwarding.
Tunneling is a way for communication to be conducted over a private network but tunneled through a public network. This is particularly useful in a corporate setting and also offers security features such as encryption options.
5 Steps of Data Encapsulations are
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 9 Types if Encapsulations
Three types of encapsulation protocols are specified for Mobile IP
a) IP-in-IP Encapsulation (The default encapsulation process used in mobile IP is called IP Encapsulation within IP)
b) Minimal Encapsulation within IP c) Generic Routing Encapsulation (GRE)
a) IP-in-IP Encapsulation
IP diagram is encapsulated within another IP diagram. Data is carried as payload. Outer header is added before existing IP header. Additional headers can be added for security reasons.
Original, inner IP header unchanged.
b) Minimal Encapsulation within IP
New header is inserted between original IP header and original IP payload. Original IP header modified to form new outer IP header.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 10 c) Generic Routing Encapsulation (GRE)
Generic routing encapsulation (GRE) is an IP encapsulation protocol which is used to transport IP packets over a network. Generic routing encapsulation (GRE) was initially developed by Cisco, but later become industry standard (RFC 1701, RFC 2784, RFC 2890).
Following image shows the difference between original IP datagram and generic routing encapsulation (GRE) encapsulated IP diagram.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 11
3.7 Route Optimizations
One of the problem with mobile IP is triangle Routing. To overcome this, route optimization is implemented.
Triangular routing is a method for transmitting packets of data in communications networks. It uses a form of routing that sends a packet to a proxy system before transmission to the intended destination.
The optimized mobile IP protocol needs four additional messages.
Binding Request
Request for MN’s current location Binding Update
Update or notify MN’s current location Binding acknowledgment
Acknowledge the receipt of update message.
Binding warning
A node sends a warning if it decapsulates a packet for an MN
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 12 The CN request the current location from the HA. If allowed by the MN, the HA returns the COA of the MN via an update message. The CN acknowledges this update message and stores the location. Now the CN can send its data directly to the current foreign agent FAold. FAold forwards the packets to the MN. This scenario shows a COA located at an FA. Encapsulation of data for tunneling to the COA is now done by the CN, not the HA.
The MN might now change its location and register with a new foreign agent, FAnew. This registration is also forwarded to the HA to update its location database.
3.8 Dynamic Host Configuration Protocol
The dynamic host configuration protocol (DHCP) is mainly used to simplify the installation and maintenance of networked computers. If a new computer is connected to a network, DHCP can provide it with all the necessary information for full system integration into the network. e.g., addresses of a DNS server and the default router, the subnet mask, the domain name, and an IP address.
DHCP (Dynamic Host Configuration Protocol) is a network management protocol used to dynamically assign an Internet Protocol (IP) address to any device, or node, on a network so they can communicate using IP. DHCP automates and centrally manages these configurations rather than requiring network administrators to manually assign IP addresses to all network devices. DHCP can be implemented on small local networks as well as large enterprise networks.
Dynamic Host Configuration Protocol (DHCP) is a client/server protocol that automatically provides an Internet Protocol (IP) host with its IP address and other related configuration information such as the subnet mask and default gateway.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 13 How DHCP Works
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 14
3.9 Mobile ad-hoc networks
MANET stands for Mobile ad-hoc Network also called as wireless ad-hoc network or ad-hoc wireless network that usually has a routable networking environment on top of a Link Layer ad hoc network. They consist of set of mobile nodes connected wirelessly in a self-configured, self-healing network without having a fixed infrastructure. MANET nodes are free to move randomly as the network topology changes frequently. Each node behaves as a router as they forward traffic to other specified node in the network.
A mobile ad-hoc network is a collection of wireless nodes that can dynamically be set up anywhere and anytime without using any pre-existing fixed network infrastructure.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 15 Characteristics of MANET
a) Dynamic network topologies
Network topology which is typically multi-hops may change randomly and rapidly with time, it can form unidirectional or bi-directional links.
b) Bandwidth constraints and variable link capacity
Wireless links usually have lower reliability, efficiency, stability and capacity as compared to wired network.
c) Energy constrained nodes
As some or all the nodes rely on batteries or other exhaustible means for their energy. Mobile nodes are characterized with less memory, power and light weight features.
d) Limited security
Wireless network are more prone to security threats. A centralized firewall is absent due to its distributed nature of operation for security, routing and host configuration.
e) Autonomous terminal
Each node can act as a host and router, which shows its autonomous behavior.
f) Less Human Intervention
They require minimum human intervention to configure the network, therefore they are dynamically autonomous in nature.
3.9.1 Ad-hoc Routing Protocol
A standard, that controls how nodes decide which way to route packets between computing devices in a mobile ad-hoc network. In ad-hoc networks, nodes are not familiar with the topology of their networks;
instead, they have to discover it. The basic idea is that a new node may announce its presence and should listen for announcements broadcast by its neighbors. Each node learns about nodes nearby and how to reach, and may announce that it, too, can reach them.
MAC VS Routing Protocol
The MAC protocol is concerned with per-link communications, not end-to end. While routing protocol deal with end-to-end communication.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 16
Figure gives a simple example of an ad-hoc network. At a certain time t1 the network topology might look as illustrated on the left side of the figure. Five nodes, N1 to N5, are connected depending on the current transmission characteristics between them. In this snapshot of the network, N4 can receive N1 over a good link, but N1 receives N4 only via a weak link. Links do not necessarily have the same characteristics in both directions. The reasons for this are, e.g., different antenna characteristics or transmit power. N1 cannot receive N2 at all, N2 receives a signal from N1.
This situation can change quite fast as the snapshot at t2 shows. N1 cannot receive N4 any longer, N4 receives N1 only via a weak link. But now N1 has an asymmetric but bi-directional link to N2 that did not exist before.
Differences between wired networks and ad-hoc wireless networks
Content Wired-Networks Ad-hoc Networks
Asymmetric links IT rely on a symmetric It rely on a Asymmetric
Node A receives a signal from node B. But this does not tell us anything about the quality of the connection in reverse.
B might receive nothing, have a weak link, or even have a better link than the reverse direction. Routing information collected for one direction is of almost no use for the other direction
Redundant Links There some
redundancy in wired networks which, are controlled by a
network administrator.
In ad-hoc networks nobody controls redundancy, so there might be many redundant links up to the extreme of a completely meshed topology
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 17 Routing algorithms for
wired networks can handle some
redundancy, but a high redundancy can cause a large computational overhead for routing table updates
Interference In wired networks links exist only where a wire exists, and
connections are planned by network administrators
This is not the case for wireless ad-hoc networks. Links come and go depending on transmission characteristics, one transmission might interfere with another, and nodes might overhear the transmissions of other nodes.
Dynamic topology Fixed topology The mobile nodes might move in an arbitrary manner or medium characteristics might change. This result in frequent changes in topology and routing algorithms have to be adopted.
3.9.2 Destination Sequence Distance Vector (DSDV) Traditional Routing Algorithms
a) Distance Vector
Periodic exchange of messages with all physical neighbors that contain information about who can be reached at what distance. Selection of the shortest path if several paths available.
b) Link State
Periodic notification of all routers about the current state of all physical links. Router gets a complete picture of the network.
Limited performance of mobile systems
1. Periodic updates of routing tables need energy
2. Limited bandwidth of the system is reduced even more due to the exchange of routing information.
3. Links can be asymmetric, i.e., they can have a direction dependent transmission quality.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 18 c) Destination Sequence Distance Vector (DSDV)
Destination sequence distance vector (DSDV) routing is an enhancement to distance vector routing for ad- hoc networks. Destination Sequenced Distance Vector (DSDV) is a hop-by-hop vector routing protocol requiring each node to periodically broadcast routing updates. This is a table driven algorithm based on modifications made to the Bellman-Ford routing mechanism. Each node in the network maintains a routing table that has entries for each of the destinations in the network and the number of hops required to reach each of them. Each entry has a sequence number associated with it that helps in identifying stale entries.
This mechanism allows the protocol to avoid the formation of routing loops. Each node periodically sends updates tagged throughout the network with a monotonically increasing even sequence number to advertise its location.
New route broadcasts contain the address of the destination, the number of hops to reach the destination, the sequence number of the information received regarding the destination, as well as a new sequence number unique to the broadcast.
The data broadcast by each node contain new sequence number and the following information for each new route:
•The destination address
•The number of hops required to reach the destination
•The new sequence number
Distance vector routing is used as routing information protocol (RIP) in wired networks. It performs extremely poorly with certain network changes due to the count-to-infinity problem (when two routers send updates to each other at the same time). To solve distance vector problems, destination sequence number is added with every routing entry. Destination sequence distance vector (DSDV) routing is an enhancement to distance vector routing for ad-hoc networks.
In DSDV routing table entry includes (Destination, Next-hop, Distance and Sequence number) where in distance vector routing table entry includes (Destination, Next-hop and Distance).
[Or]
Destination sequence distance vector (DSDV) routing is an enhancement to distance vector routing for ad- hoc networks. Distance vector routing is used as routing information protocol (RIP) in wired networks. It performs extremely poorly with certain network changes due to the count-to-infinity problem (when two routers send updates to each other at the same time). Each node exchanges its neighbor table periodically with its neighbors. Changes at one node in the network propagate slowly through the network.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 19 The strategies to avoid this problem which are used in fixed networks do not help in the case of wireless ad-hoc networks, due to the rapidly changing topology. This might create loops or unreachable regions within the network.
[DSDV now adds two things to the distance vector algorithm:
1. Sequence numbers 2. Damping
1. Sequence numbers
Each routing advertisement comes with a sequence number. Within ad-hoc networks, advertisements may propagate along many paths. Sequence numbers help to apply the advertisements in correct order. This mechanism allows the protocol to avoid the formation of routing loops.
2. Damping ] /* No Comments */
Consider the network in Figure 1 shows the movement of node N1. Table 1 is the routing table at node N4 before node N1 moves. Table 2 is the routing table updated for node N4 after node N1 moved.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 20
3.9.3 Dynamic Source Routing (DSR)
Dynamic Source Routing (DSR) is a self-maintaining routing protocol for wireless networks. It is a simple and efficient routing protocol designed specifically for used multi-hop wireless ad-hoc networks of mobile nodes. DSR allows the network to be completely self-organized, without need for any existing network infrastructure or administrator. The protocol is composed of two main mechanism of
1. Route Discovery
A node only tries to discover a route to a destination if it has to send something to this destination and there is currently no known route.
2. Route Maintenance
If a node is continuously sending packets via a route, As soon as a node detects problems with the current route, it has to find an alternative route.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 21 When node S wants to send a packet to node D, but does not know a route to D, node S initiates a route discovery. Source node S floods route request (RREQ). Each RREQ has sender’s address, destination’s address, destinations address, and a unique Request ID determined by the sender. Each node appends own identifier when forwarding RREQ.
Example
DSR-Route Discovery
1. Node S needs a route to D 2. Broadcasts RREQ packet
3. Node A receives packet, has no route to D
Rebroadcasts packet after adding its address to source route.
4. Upon receiving a RREQ, the node takes the following actions:
a) The node is the target (destination)
Returns a route reply (RREP) message to the sender.
Copies the accumulated route record from RREQ into RREP.
Sender upon receiving RREP, caches the route in its route cache for subsequent routing.
b) The node is the intermediate node The node discards this message.
If not, the node appends its own address to the route record in the ROUTE REQUEST message.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 22 1. Node S needs a route to D
2. Broadcasts RREQ packet
3. Node A receives packet, has no route to D
Rebroadcasts packet after adding its address to source route.
4. Node C receives RREQ , has no route to D
Rebroadcasts packet after adding its address to source route.
5. Node D receives RREQ, unicasts RREP to C Puts D in RREP source route
Route Reply in DSR
Route Reply can be sent by reversing the route in Route Request (RREQ) only if links are guaranteed to be bi-directional.
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 23 4. Node C receives RREQ, has no route to D
Rebroadcasts packet after adding its address to source route 5. Node D receives RREQ, unicasts RREP to C
Puts D in RREP source route
6. Node C receives RREP
Adds its address to source route Unicasts to A
NBKRIST-CSE III B.Tech II SEM-Prepared BY::BSR Page 24 7. Node A receives RREP
Adds its address to source route Unicasts to S
8. Node S receives RREP
Uses route for data packet transmissions