Mobile Computing Mobile Network Layer: Prof. Sang-Jo Yoo
Mobile Computing Mobile Network Layer: Prof. Sang-Jo Yoo
Mobile Computing
Chapter 8:
Mobile Network Layer
http://multinet.inha.ac.kr
http://multinet.inha.ac.kr The Graduate School of Information Technology and Telecommunications,
Telecommunications, INHA University
Contents
Mobile IP overview
Agent discovery
Registration
Tunneling
DHCP
Mobile IP multicasting
Requirements to Mobile IP
Transparency
Mobility should remain ‘invisible’ for many higher layer protocols and
applications
For TCP, mobile computer must keep its IP address.
Compatibility
support of the same layer 2 protocols as IP
no changes to current end-systems and routers required
mobile end-systems can communicate with fixed systems
Security
The minimum requirement: all the messages related to the management
of Mobile IP are authenticated.
Efficiency and scalability
Only little additional messages to the mobile system required (connection
typically via a low bandwidth radio link)
Terminology
Mobile Node (MN)
system (node) that can change the point of connection
to the network without changing its IP address
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 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
Correspondent Node (CN)
communication partner
Terminology
Care-of Address (COA)
Co-located COA
MN temporarily acquired an additional IP address which acts as COA.
Tunnel end-point is at the MN.
Co-located care-of address can be acquired using services such as DHCP
Example network
HA
MN
router
end-system router
FA foreign
network
FA foreign
network
Overview
COA
foreign
Internet network
CN router
3.
home router router
2. MN
network HA FA
4.
foreign
Internet network
1.
CN router
Protocol Overview
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 MN reads a COA from the FA advertisement messages
A mobile node can solicit for mobility agents
Delivering Datagrams
Datagrams must be forwarded by the Home Agent to the Foreign Agent
for delivery to the care-of address.
The delivery mechanism must handle all packets (including broadcast and
multicast)
A tunnel is used for this
Overall Behaviors
1. Agent Discovery
Problems:
How to find a foreign agent?
How does the MN discover that it has moved?
Æ Agent advertisement and Agent solicitation
Agent advertisement
HA and FA advertise their presence periodically using Agent
advertisement messages
ICMP (Internet Control Message Protocol) message with some mobility
extensions : RFC 1256
IP header: TTL=1
destination IP: 224.0.0.1 (multicasting), 255.255.255.255(broadcasting)
Agent advertisement
0 7 8 15 16 23 24 31
Type=9 Code checksum
#addresses addr. size lifetime
router address 1
preference level 1
router address 2
type = 16 preference level 2
length = 6 + 4 * #COAs
...
Lifetime: max lifetime in seconds
a node can request
R: registration required type = 16 length sequence number
B: busy, no more registrations registration lifetime R B H F M G r T reserved
H: home agent COA 1
COA 2
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 Solicitation
MN can send Agent solicitation message
If no agent advertisement are present,
The inter-arrival time of agent advertisements is too high, or
The MN just power on.
Based on RFC 1256, ICMP router solicitation message
Move detection
Move detection using lifetime
If a MN fails to hear an advertisement from the foreign agent (or home agent)
with the specified Lifetime.
The MN can assume that it has moved to a different link, waits Agent
Advertisement or sends Agent Solicitation.
Move detection using network-prefixes
If the network-prefix of the received Agent Advertisement is different from the
that of the previous foreign agent, then registration process should be invoked.
2. Registration
Request forwarding services when visiting a foreign network
This allocates a local (foreign) node address
Inform home agent of their current care-of address
This creates a binding of the foreign node address to the home address
Renew a binding that’s about to expire
Bindings have lifetimes
De-register when they return home
A replay attack occurs when a 3rd party can capture your packets and
then “replay” them, fooling you into thinking they are correctly
authenticated.
E.g., sending an encrypted password over a network leaves you open to a
replay attack. Note that attack didn’t decrypt.
Nonces: Each message from A -> B includes a new random number.
When B replies to A, it must include that same random number. Likewise,
each B->A message includes a new random number generated by B and
echoed by A.
Registration Request
Registration Request Message
The message is sent to FA when foreign agent care-of address is used or
R bit of Advertisement is set.
The message is directly sent to HA when collocated care-of address is
used .
MN re FA HA
g is
requ tration
e st MN re HA
regi gist
s requ ra t ion
requ tration est
est
on
g i strati trati
on
re g i s
y re
repl repl
y
tion
stra
regi
y
repl t
Registration Request
• Both send to
UDP
port 434.
(Registration
Reply also)
• IP source
address:
interface
address of the
MN
• IP destination
address:
•HA: when
co-located
care-of
address is
used
•FA: when
FA care-of
address
The Graduate is of Information Technology and Telecommunications,
School Telecommunications, INHA University 21
used
Registration Request
Type =1
S – set to 1 to ask that its HA create or delete a binding for the
specified care-of address.
B – to tell the HA to encapsulate broadcast datagrams from
home network to the care-of address.
D – to inform the HA where the exit-point of the tunnel is
located.
Lifetime – the number of seconds it would like its registration to
last before it expires.
Home address
Home agent address
Care-of address
Identification – 64 bits for replay protection.
Mobile-home authentication extension – to prevent remote
redirect attack.
Registration Request
Registration Reply
Lifetime:tells the mobile node how long the registration will be honored by the HA.
It can be shorter than requested, but never longer.
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
3. Tunneling
Tunnel
Establishes a virtual pipe for data packets between a tunnel entry and a
tunnel endpoint.
Tunneling is achieved by using encapsulation
Encapsulation
Encapsulation
Mechanism of taking a packet consisting of packet header and data and
putting it into the data part of a new packet.
Decapsulation: reverse operation
Outerheader: the new header
IP-in-IP-encapsulation, minimal encapsulation or GRE (Generic Record
Encapsulation)
Encapsulation (IP-in-IP)
IP-in-IP-encapsulation (mandatory, RFC 2003)
tunnel between HA and COA
Encapsulation (IP-in-IP)
The outer IP header source & destination address identify the tunnel
endpoints (e.g., HA & FA).
Outer protocol is ‘4’ (IP protocol)
Indicates payload is also IP datagram (version 4)
Encapsulation (Minimal)
Minimal encapsulation (optional)
avoids repetition of identical fields
e.g. TTL, IHL, version, DS (RFC 2474, old: TOS)
only applicable for unfragmented packets, no space left for fragment
identification
GRE original
outer header original data
header header
RFC 1701
new header new data
ver. IHL DS (TOS) length
IP identification flags fragment offset
TTL GRE IP checksum
IP address of HA RFC 2784
Care-of address COA
CR K S s rec. rsv. ver. protocol C reserved0 ver. protocol
checksum (optional) offset (optional) checksum (optional) reserved1 (=0)
key (optional)
sequence number (optional)
routing (optional)
ver. IHL DS (TOS) length
IP identification flags fragment offset
TTL lay. 4 prot. IP checksum
IP address of CN
IP address of MN
Data Data
MN changes
location
Update Registration Registration
ACK to HA is not
Data shown
Data Data
Warning
Smooth
Request Handover
Update
ACK
Data
Data
t
Reverse tunneling
HA
2
MN
1. MN sends to FA
3 2. FA tunnels packets to HA
CN by encapsulation
3. HA forwards the packet to the
receiver receiver (standard case)
tunnel
HA FA MN1
Source2 Source1
HA updates its soft state based upon ICMP messages received from
routers within the tunnel.
If the received ICMP message is “fragmentation needed”, then increase
path MTU.
If HA receives the ICMP “time exceeded”, then increase the length of the
tunnel.
If HA receives “destination unreachable”, then it knows that the tunnel is
now un reachable.
MN
HA
MAC frame
S MN
ARP cache
HA
1. ARP
2. to HA
S MN
ARP cache
4. IP Micro-mobility support
IP Micro-mobility support
Micro-mobility support:
Efficient local handover inside a foreign domain without involving a home
agent
Reduces control traffic on backbone
Especially needed in case of route optimization
Example approaches:
Cellular IP
HAWAII
Hierarchical Mobile IP (HMIP)
Important criteria:
Security Efficiency, Scalability, Transparency, Manageability
Mobility Classification
Micro-mobility is the movement of an MN within or across different
BSs within a subnet and occurs very rapidly. (local mobility)
Cellular IP
Operation:
“CIP Nodes“ maintain routing Internet
entries (soft state) for MNs
Multiple entries possible Mobile IP
Routing entries updated based on
packets sent by MN CIP Gateway
data/control
CIP Gateway: packets
Mobile IP tunnel endpoint from MN 1
Initial registration processing
BS BS BS
packets from
MN2 to MN 1
MN1 MN2
Cellular IP(Routing)
Cellular IP gateway periodically broadcasts a beacon packet that is
flooded in the access network.
Base station records the neighbor they last received this beacon
from and use it to route packets toward gateway.
All packets transmitted by mobile hosts, regardless of their
destination address, are routed toward the gateway using these
routes.
Cellular IP(Routing)
R(X,BS1)
Gateway,
R
care of address BS2 (X,BS3)
BS1(X,BS2)
BS3
Data packet are transmitted by MH
Data packet are destined to MH X
Beacon packet Mobile Host X
Cellular IP(Handoff)
Cellular IP hard handoff is based on a simple approach that trade
off some packet loss for minimizing handoff signaling rather than
try to guarantee zero packet loss.
Cellular IP semisoft handoff exploits the notion that some mobile
hosts can simultaneously receive packets from the new and old
base stations during handoff.
Semisoft handoff minimizes packet loss,providing improved TCP
and UDP performance over hard handoff.
HAWAII
Handoff-Aware Wireless Access
Internet Infrastructure Internet
HA
Operation:
MN obtains co-located COA 1 Backbone
and registers with HA 2
Router
Handover: MN keeps COA,
new BS answers Reg. Request 3
and updates routers 4 Crossover
MN views BS as foreign agent Router
2
Security provisions: 4 Mobile IP
MN-FA authentication mandatory DHCP
Challenge/Response Extensions BS BS BS
Server
mandatory Mobile IP
3
MN MN DHCP
1
MN MN
DHCPDISCOVER
server client
client relay
selection of configuration
DHCPREQUEST DHCPREQUEST
(reject) (options) confirmation of
configuration
DHCPACK
initialization completed
release
DHCPRELEASE delete context
DHCP characteristics
Server
several servers can be configured for DHCP, coordination not yet
standardized (i.e., manual configuration)
Renewal of configurations
IP addresses have to be requested periodically, simplified protocol
Options
available for routers, subnet mask, NTP (network time protocol)
timeserver, SLP (service location protocol) directory,
DNS (domain name system)
Remote-subscription
Optimal routing (con) Internetwork
Bidirectional-tunneling
No out-of-synch problem (con)
Correspond Node
No tree updating and join procedure (con)
Multiple unicast tunnels from a HA to a FA (pro) Internetwork
Registration delay
Mobile Host Mobile Host
Mobile IP Multicasting
MOM (ACM Mobicom’97)
Use bidirectional tunneling
Solve tunneling convergence problem
Select one HA from multiple HAs in FA for a group: DMSP
DMSP
HA HA HA HA HA HA
FA FA
Problems of MOM
No optimal routing (still exists)
Out-of-synch problem (newly generated)
Registration delay for tunneling (still exists)
Losses during DMSP handoff (newly generated)
Problems of RBMOM
It does not consider reliable multicasting
Data structure and operational procedures for all agent types are
not perfect.
Distance between FA and MHA is not only thing to decide for
joining the tree.
HA is receiving the multicasting data (as a member of the tree)
even though there is no MH that is receiving data from the HA.
Problems
It still has many problems of RS
join
2) leave[4,6]
FA FA FA
3) 4.5.6
1) 7.8.9
1.2.3
REMMIP
Objectives
Tunneling from MA (multicast agent, HA or FA) instead of HA.
FA can be a MA for the MH that visited before.
Reduce path length from source to MH.
Reduce packet loss and out-of-synch problem
Eliminate HAs from multicasting tree
If it does not have any MHs in its home network and it does not act as MA for other FAs.
Reliable and efficient mobile IP multicasting mechanism.
MA
HA maintains the MH’s location.
MA is the agent that has a responsibility to send multicast data to a certain FA.
MA should join the multicast tree.
1. MH moves to new FA
MH sends the GroupInfo when it initiates normal mobile IP registration
procedure.
IF the new FA does not receives data of the group.
The MH is the first host of the group.
FA sends TUNNELING REQUEST[SEQmh+1] to the MA of the MH
FA sets the MH’s MA to the FA’s MA
IF there is out-of-synch problem, FA requests RECOVERY REQUEST [SEQmh+1,
SEQma-1] to the MH’s prev agent.
Optionally, MH can send MOVE message to the MH’s prev agent.
S
HA Normal MIP GroupInfo
registration
Group ID
MA Address
1
MA FA Prev Agent Address
2 3 Registration
1. TR[SEQmh+1] HA Address
FA 4 (GroupInfo)
2. Data transmission
3. RR[a,b] Sequence Number
4. Recovery data SEQmh
S prev
new 9.STOP
MA
MA 7.RR
6.data
SEQfa 8.data
5.TR
FA 1. MC
2. RR
4
FA 3. data
prev
SEQmh
IF FA selects a new MA(MH’s MA).
¾ Notify (MA CHANGE) to all MHs except the new MH in FA network that MA has been
changed.
¾ FA sets the new MA as its MA.
¾ IF FA cannot send all data [SEQmh+1,SEQfa] to the new MH, FA requests RR
[SEQmh+1, SEQfalast-1] to the MH’s prev Agent.
• After FA received the data, it forwards them to the new MH.
¾ FA sends TUNNELING REQUEST[SEQfa+1] to the new MA.
¾ IF there is out-of-synch problem, FA sends RR[SEQfa+1, SEQma-1] to the FA’s prev MA.
¾ FA sends STOP to the FA’s prev MA.
¾ FA sends reordered data to all MHs in the network..
¾ Optionally, the new MH can send MOVE message to the MH’s prev agent.
2. BT to RS by FA
When FA is not on the tree and uses BT, if one of the following
conditions is satisfied, then join the multicasting tree.
2) Join
3) 7.8.9
MA 1)1.2.3 4) MA=FA
6) STOP[4,6] FA
5) MA CHANGE(MA=FA)
7) 4.5.6
8) 4.5.6.7.8.9
STOP FA STOP
FA FA
or HA
All hosts moved.
FA STOP
MA
or HA
All hosts moved.
Group ID SEQ(agent)