Mobile IP FEUP Manuel P. Ricardo Faculdade de Engenharia da - - PowerPoint PPT Presentation

mobile ip
SMART_READER_LITE
LIVE PREVIEW

Mobile IP FEUP Manuel P. Ricardo Faculdade de Engenharia da - - PowerPoint PPT Presentation

Mobile IP 1 Mobile IP FEUP Manuel P. Ricardo Faculdade de Engenharia da Universidade do Porto Mobile IP 2 Mobile IP, v4 Mobile IP 3 Motivation Forwarding of IP datagrams Based on IP destination address IP network address


slide-1
SLIDE 1

Mobile IP 1

Mobile IP

FEUP

Manuel P. Ricardo Faculdade de Engenharia da Universidade do Porto

slide-2
SLIDE 2

Mobile IP 2

Mobile IP, v4

slide-3
SLIDE 3

Mobile IP 3

Motivation

♦ Forwarding of IP datagrams

– Based on IP destination address – IP network address  physical network – Changing network changing IP address

♦ Possible mobility solution

» Register new IP address at the DNS server » Problems

– DNS update takes long time – TCP connections broke (source-ip, source-port, destination-ip, destination-port)

slide-4
SLIDE 4

Mobile IP 4

Mobile IPv4

♦ Characteristics

– Point of attachement to the network can be changed – Host maintains its IP address while it moves – Existing routers are not modified

♦ Terminology

» MN, Mobile Node » HA, Home Agent, registers MN location » FA, Foreign Agent, agent at the visited network » COA, Care-of Address, IP address at the visited network » CN, Correspondent Node, host which communicates with the MN

slide-5
SLIDE 5

Mobile IP 5

Example

mobile end-system Internet router router router end-system

FA HA MN

home network foreign network (physical home network for the MN) (current physical network for the MN)

CN

slide-6
SLIDE 6

Mobile IP 6

Data Transferred to the MN

Internet sender

FA HA MN

home network foreign network receiver

1 2 3

  • 1. Sender sends to the IP address of MN,

HA intercepts packet

  • 2. HA tunnels packet to COA (FA)

by encapsulation

  • 3. FA forwards the packet to the MN

CN

slide-7
SLIDE 7

Mobile IP 7

Transferência de Dados do MN

Internet receiver

FA HA MN

home network foreign network sender

1

  • 1. Sender sends to the IP address
  • f the receiver as usual,

FA works as default router

CN

slide-8
SLIDE 8

Mobile IP 8

Mobility Phases

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

slide-9
SLIDE 9

Mobile IP 9

Comunication MN - Agents

♦ MN discovers the network

» Mobility agents send regularly messages to their networks

ICMP Router Advertisment Protocol (RFC 1256) messages

» MN listens to the messages; decides about the networks

– Its home network, or – A visited network  also gets a CoA

♦ When the MN visits a network

» In the visited network

– MN sends COA to HA (via FA)  new location registered at the HA

» In the home network

– HA assumes the MN IP address – Packets destined to MN are intercepted by HA and tunnelled to the MN (CoA address)

slide-10
SLIDE 10

Mobile IP 10

ICMP Router Advertisment Messages – Mobility Extension

preference level 1 router address 1 #addresses type

  • addr. size

lifetime checksum COA 1 COA 2 type sequence number length 7 8 15 16 31 24 23 code preference level 2 router address 2 . . . registration lifetime . . .

R B H F M G r

reserved

R – registration required B – FA busy H – agent is HA F – agent is FA M – minimal encaspulation accepted G – GRE encapsulation accepted r – not used T – FA supports reverse tunneling

T

Message sent by mobility agents (HA and FA)

slide-11
SLIDE 11

Mobile IP 11

To think about

♦ Can we remove the Foreign Agent from MIPv4? What are the

consequences of it?

slide-12
SLIDE 12

Mobile IP 12

MN registers in the Home Agent

t MN HA t MN FA HA

  • Co-located address
  • Tunnel will end at the MN
  • Address obtained by DHCP, for instance
slide-13
SLIDE 13

Mobile IP 13

Register Messages

Type – registration request, registration reply S – keep old binding B – broadcast reception required D – co-located address M – minimal encapsulation accepted G – GRE encapsulation accepted r – not used T – FA supports reverse tunneling x - ignorado

home agent home address type lifetime 7 8 15 16 31 24 23 identification COA extensions . . .

S B DMG r T x

porta UDP 434

slide-14
SLIDE 14

Mobile IP 14

Encapsulation, Tunnels

  • riginal IP header
  • riginal data

new data new IP header

  • uter header

inner header

  • riginal data
slide-15
SLIDE 15

Mobile IP 15

IP em IP (mandatory)

Care-of address COA IP address of HA TTL IP identification IP-in-IP IP checksum flags fragment offset length TOS ver. IHL IP address of MN IP address of CN TTL IP identification

  • lay. 4 prot.

IP checksum flags fragment offset length TOS ver. IHL TCP/UDP/ ... payload

Tunnel HA  COA

slide-16
SLIDE 16

Mobile IP 16

To think about

♦ What is NAT (Network Address Translation)?

slide-17
SLIDE 17

Mobile IP 17

NAT – Network Address Translation

slide-18
SLIDE 18

Mobile IP 18

To think about

♦ Does MIPv4 work if the MN gets a private CoA address?

slide-19
SLIDE 19

Mobile IP 19

Mobile IP, v6

slide-20
SLIDE 20

Mobile IP 20

Mobile IPv6 Móvel – Working Principles

♦ Differences to MIPv4

» No ForeignAgent » Regsistration signalling (HomeAddress  CareOfAddress )

– Sent as an IPv6 extension header  Mobility Header – Binding relations (HomeAddress  CareOfAddress ) also stored in CNs

♦ Binding messages

» BindingUpdate

– MN informs HA/CN about CareOfAddress

» BindingAcknowledgement

– Received by MN. Confirms BindingUpdate

» BindingRefreshRequest

– Sent by HA/CN. Asks MN to refresh the binding

slide-21
SLIDE 21

Mobile IP 21

Register Operation

♦ Register  Node moves to the visited network

– Autoconfigures new address, in the visited network (next slide)  CareOfAddress – CareOfAddress prefix == prefix in the visited network – MN registers COA in HA  IPv6 packet with BindingUpdate (mobility extension) – HA registers MN. Sends BindingAcknowledgment

♦ Tunnel between MN e HA

– HA, in home network

> intercepts packet to MN > sends packet to registered CareOfAddress; by tunnel

– MN

> Sends packet in tunnel to HA

slide-22
SLIDE 22

Mobile IP 22

Autoconfiguration of CoA, in the visited network

♦ MN

» Listens to RouterAdvertisment messages

(up to 50 msg/s) – Determines network address

» Builds address, in the visited network: the CareOfAddress

♦ DHCPv6 can be used in alternative for the MN to get CoA

Routing Prefix MAC address

slide-23
SLIDE 23

Mobile IP 23

Route Optimization

♦ When MN receives a tunnelled packet

» it sends BindingUpdate to CN

♦ HomeAddress  CareOfAddress binding

– also at the CN

♦ Packets exchanged directly between MN and CN

slide-24
SLIDE 24

Mobile IP 24

Route Optimization

♦ Packets in the direction CN  MN

» CN

– Before sending packet to MN  reads binding cache – If there is no entry for the MN  sends packet as usual – If there is an entry

> Sends packet to CareOfAddress (IP destination address = CareOfAddress) > Add to packet a RoutingHeader with 2 hops (list of addresses to visit)

  • 1º hop  CareOfAddress; 2º hop  HomeAddress of MN

» MN

– receives packet in CareOfAddress (co-located address) – Forwards the packet to itself

♦ Packets in the direction MN  CN

– Source address = CareOfAddress – Inclusion of DestinationHeader with information about HomeAddress – CN receives packet and fills packet source address with HomeAddress received

> In order to put this information in the socket structure  HomeAddress

slide-25
SLIDE 25

Mobile IP 25

Routing Header – Packet Forwarding Packet Sent from S to D, through I1, I2, I3

As the packet travels from S to I1: Source Address = S Hdr Ext Len = 6 Destination Address = I1 Segments Left = 3 Address[1] = I2 Address[2] = I3 Address[3] = D As the packet travels from I1 to I2: Source Address = S Hdr Ext Len = 6 Destination Address = I2 Segments Left = 2 Address[1] = I1 Address[2] = I3 Address[3] = D As the packet travels from I2 to I3: Source Address = S Hdr Ext Len = 6 Destination Address = I3 Segments Left = 1 Address[1] = I1 Address[2] = I2 Address[3] = D As the packet travels from I3 to D: Source Address = S Hdr Ext Len = 6 Destination Address = D Segments Left = 0 Address[1] = I1 Address[2] = I2 Address[3] = I3

To remember ….

slide-26
SLIDE 26

Mobile IP 26

cn ha mn new router mn | | node moves | | | | +------------------------------>| | | | |radv | | | | +-------------->| | | binding update | | | |<--------------------------------------------+ | |binding ack | | | | +-------------------------------------------->| |echo request| | | | + -----------=============================================>| | echo reply | | | | |<-----------==============================================+ |home test init | | | |<-----------==============================================+ | care of test init | | | |<---------------------------------------------------------+ |care of test| | | | +--------------------------------------------------------->| |home test | | | | +------------=============================================>| | binding update | | | |<---------------------------------------------------------+ | binding ack | | | +--------------------------------------------------------->| |echo request| | | | +--------------------------------------------------------->| | echo reply | | | | |<---------------------------------------------------------+ | | | | | ping ping