Mobile IP: Asst. Prof. Sumegha C. Sakhreliya

Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 23

Mobile IP

Prepared By
Asst. Prof. Sumegha C. Sakhreliya
Outline
What is Mobile IP?
How does Mobile IP Work?
Entities and Terminology,
IP Packet Delivery
Agent Discovery
Registration
Tunneling and Encapsulation.
What is Mobile IP ?
Mobile IP is different from the portable computing
environment.
Mobility management deals with the situation where
the user is at vehicular state and accessing the
network.
A data connection between two end-points requires
a source IP address and source TCP port and
destination IP address and destination TCP port.
Combination of IP address and TCP port is identified
as a point of attachment for an end-point.
TCP port number is application specific and remains
constant.


IP address on the other hand network-specific and
varies from network to network.
IP addresses are assigned to a node from the set of
addresses assigned to a network. This structure
works well as long as the client is static and using
desktop computer.
For Example, user is using the laptop with WiFi.
Change in IP address.
This will force connection to terminate.
Therefore, the question is that how do we allow
mobility while, data connection is alive.
The technology to do so is Mobile IP.
What is Mobile IP ?
IP routes packets from a source endpoint to a
destination end point through various routers.
An IP address of a node can be considered to be a
combination of network address and the node address.
For Example class C IP address 75.126.113.230 to be the
mail server.
So, we can assume that first 24 bit 75.126.113 is the
address of a network and the last 8 bits containing 230
is the address of a node.
The network portion of an IP address is used by routers
to deliver the packet to the last router in the chain.
How does Mobile IP Works ?
The TCP port are application specific and generally
constant they do not change after an end-to-end
connection is established.
However, IP address will change when a node moves
from one subnet to another.
Therefore, to fix this problem mobile IP allows the
mobile node to use two IP addresses.
These IP addresses called home and care-of address.
Home address is static and care-of address changes
at each new point of attachment.

How does Mobile IP Works ?
Entities and Terminology
Mobile end-system
Internet
Router
FA
Router
Router
HA
End-System
MN
(Physical Home Network
for the MN)
(Current Physical Foreign Network
for the MN)
CN
COA
Entities and Terminology I
Mobile Node (MN)
System (node) that can change the point of attachement
to the network without changing its IP address.
Home Network
Home Agent (HA)
System in the home network of the MN, typically a
router registers the location of the MN, tunnels IP
datagrams to the COA.
Foreign Network
Foreign Agent (FA)
System in the current foreign network of the MN,
typically a router forwards the tunneled datagrams to
the MN, typically also the default router for the MN.
Care-of Address (COA)
Address of the current tunnel end-point for the MN (at
FA or MN).
Actual location of the MN from an IP point of view.
Packet to the MN delivered to the COA.
1. Foreign Agent COA
COA could be located at the FA.
2. Co-located COA
COA could be co-located if the MN temporarily
acquired an additional IP address which act as COA.
Correspondent Node (CN)
Communication partner.

Entities and Terminology II
IP Packet Delivery
Internet
sender
FA
HA
MN
Foreign Network
Receiver
1
2
3
1. Sender sends to the IP address of MN,
HA intercepts packet (proxy ARP)
2. HA tunnels packet to COA, here FA,
by encapsulation
3. FA forwards the packet to the MN
4. MN forward this packet to CN.
CN
Home Network
Overview
CN
router
HA
router
FA
Internet
router
1.
2.
3.
home
network
MN
foreign
network
4.
CN
router
HA
router
FA
Internet
router
home
network
MN
foreign
network
COA
Agent Discovery

How to find a foreign agent. How does MN discovers
that it has moved?
1. Agent Advertisement
HA and FA periodically send advertisement
messages into their physical subnets
MN listens to these messages and detects, if it is in
the home or a foreign network (standard case for
home network)
MN reads a COA from the FA advertisement
messages
2. Agent Solicitation
If no agent advertisements are present or inter-arrival
time is too high, MN has not received a COA by other
means.










type = 16
length = 6 + 4 * #COAs
R: registration required
B: busy, no more registrations
H: home agent
F: foreign agent
M: minimal encapsulation
G: GRE encapsulation
r: =0, ignored (former Van Jacobson compression)
T: FA supports reverse tunneling
reserved: =0, ignored
Agent Discovery I
preference level 1
router address 1
#addresses
type
addr. size lifetime
checksum
COA 1
COA 2
type = 16 sequence number length
0
7 8 15 16 31 24 23
code
preference level 2
router address 2
. . .
registration lifetime
. . .
R B H F M G r reserved T
Figure 1 . Agent Advertisement Packet (RFC 1256 + Mobility Extension
Registration
The main purpose of the registration is to inform the HA
of the current location for correct forwarding of packet.

1. If the COA is at the FA.
MN signals COA to the HA via the FA, HA
acknowledges via FA to MN.
These actions have to be secured by
authentication

2. If the COA is co-located.
MN send the request directly to the HA and vise
versa.












t
MN
HA
t
MN
FA HA
Registration I
Figure 2 . Registration of a mobile node via the FA or direct with the HA
Registration II
home agent
home address
type = 1 lifetime
0
7 8 15 16 31 24 23
identification
COA
extensions . . .
S B D M G r
S: simultaneous bindings
B: broadcast datagrams
D: decapsulation by MN
M mininal encapsulation
G: GRE encapsulation
r: =0, ignored
T: reverse tunneling requested
x: =0, ignored
T x
Figure 3 . Mobile IP Registration Request
Registration III
home agent
home address
type = 3 lifetime
0
7 8 15 16 31
code
identification
extensions . . . Example codes:
registration successful
0 registration accepted
1 registration accepted, but simultaneous mobility bindings unsupported
registration denied by FA
65 administratively prohibited
66 insufficient resources
67 mobile node failed authentication
68 home agent failed authentication
69 requested Lifetime too long
registration denied by HA
129 administratively prohibited
131 mobile node failed authentication
133 registration Identification mismatch
135 too many simultaneous mobility bindings
Figure 3 . Mobile IP Registration Reply
Tunneling and Encapsulation
A tunnel is used for forwarding packets between the HA
and the COA.
A Tunnel establishes a virtual pipe for data packets
between a tunnel entry and endpoint.
Packet entering a tunnel are forwarded inside the tunnel
and leaves the tunnel unchanged.
Tunneling, i.e. sending a packet through a tunnel is
achieved by using encapsulation.
Encapsulation is the mechanism of taking a packet
consisting of packet header and data and putting it into
the data part of a new packet.
The reverse operation, taking a packet out of the data part
of another packet is called decapsulation.
Encapsulation
original IP header original data
new data new IP header
outer header inner header original data
The HA takes the original packet with the MN as destination,
puts it into the data part of a new packet and sets the new IP
header in such a way that the packet is routed to the COA.
Here: e.g. IP-in-IP-encapsulation, minimal encapsulation or
GRE (Generic Routing Encapsulation)
Encapsulation I
IP-in-IP Encapsulation (mandatory, RFC 2003)
Tunnel between HA and COA.
Version=4, IHL(internet header length)=length of the header in 32 bit
words, DS(TOS)=copied from inner header, length=covers the
complete encapsulated packet, TTL=high.
Care-of address COA
IP address of HA
TTL
IP identification
IP-in-IP IP checksum
flags fragment offset
length DS (TOS) ver. IHL
IP address of MN
IP address of CN
TTL
IP identification
lay. 4 prot. IP checksum
flags fragment offset
length DS (TOS) ver. IHL
TCP/UDP/ ... payload
RFC 791
RFC 2474
Encapsulation II
Minimal Encapsulation
Avoids repetition of identical fields.
e.g. TTL, IHL, version, DS (RFC 2474, old: TOS).
Only applicable for non fragmented packets, no space left for fragment
identification.






If the S bit is set, the original sender address of the CN is included as
omitting the source is quite not often not an option.
care-of address COA
IP address of HA
TTL
IP identification
min. encap. IP checksum
flags fragment offset
length DS (TOS) ver. IHL
IP address of MN
original sender IP address (if S=1)
S lay. 4 protoc. IP checksum
TCP/UDP/ ... payload
reserved
RFC 2004
Encapsulation III
original
header
original data
new data new header
outer header
GRE
header
original data
original
header
Care-of address COA
IP address of HA
TTL
IP identification
GRE IP checksum
flags fragment offset
length DS (TOS) ver. IHL
IP address of MN
IP address of CN
TTL
IP identification
lay. 4 prot. IP checksum
flags fragment offset
length DS (TOS) ver. IHL
TCP/UDP/ ... payload
routing (optional)
sequence number (optional)
key (optional)
offset (optional) checksum (optional)
protocol rec. rsv. ver. C R K S s
RFC 1701
RFC 2784 (updated by 2890)
reserved1 (=0) checksum (optional)
protocol reserved0 ver. C
Generic Routing Encapsulation (GRE)
C=checksum
R=offset and routing fields
K=key for authentication
S=sequence number
S=strict routing
rec=recursive control
rsv=reserved and ignore on reception
ver=0 for GRE
Protocol=protocol of packet following GRE
Thank You !!

You might also like