Subject: [mobile-ip] Unresolved issue #7: MH format

From: Jari Arkko <[email-masked]>
Date: Thu, 02 May 2002 01:57:44 +0300

Background: The new Mobility Header messages need to fullfil a number of
requirements, including proper alignment, ability to be extended later,
compact form to preserve bandwidth on constrained wireless links, and so on.

Question: Are these formats good?

Proposal: See formats below.

Text:

MH: (8n)

     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |Payload Proto  |  Header Len   |            MH Type            |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |           Checksum            |                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+                               |
     |                                                               |
     .                                                               .
     .                       Message Data                            .
     .                                                               .
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

BR: (8n)

                                     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
                                     |          Reserved             |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     .                                                               .
     .                        Mobility options                       .
     .                                                               .
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

HOTI: (8n)

                                     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
                                     |           Reserved            |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                        Mobile cookie                          |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     .                                                               .
     .                       Mobility Options                        .
     .                                                               .
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

COTI: (8n)

                                     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
                                     |          Reserved             |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                        Mobile cookie                          |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     .                                                               .
     .                        Mobility Options                       .
     .                                                               .
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

HOT: (8n)

                                     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
                                     |           Reserved            |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |        Home Nonce Index       |           Reserved            |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                         Mobile cookie                         |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     +                                                               +
     |                      Home Cookie (128 bits)                   |
     +                                                               +
     |                                                               |
     +                                                               +
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     .                                                               .
     .                         Mobility options                      .
     .                                                               .
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

COT:  (8n)

                                     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
                                     |           Reserved            |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |      Care-of Nonce Index      |           Reserved            |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                           Mobile cookie                       |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     +                                                               +
     |                      Care-of Cookie (128 bits)                |
     +                                                               +
     |                                                               |
     +                                                               +
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     .                                                               .
     .                        Mobility Options                       .
     .                                                               .
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

BU: (8n)

                                     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
                                     |A|H|S|D|      Reserved         |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |          Sequence #           |          Reserved             |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                            Lifetime                           |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     +                                                               +
     |                                                               |
     +                           Home Address                        +
     |                                                               |
     +                                                               +
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     .                                                               .
     .                         Mobility options                      .
     .                                                               .
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     (This would typically have a Nonce Indices and an Authorization
     Data mobility options following it. Nonce Indices can go in
     right after home address since it is 2n. It is 6 bytes long, so
     the alignment after that is 8n+6, which enables us to fit in
     Authorization Data immediately (4n+2).

     It may or may not be necessary to add a Mobile cookie in this
     message. The alternative is to rely on Sequence #.)

BA: (8n)

                                     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
                                     |           Reserved            |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |  Status     |   Reserved      |           Sequence #          |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                            Lifetime                           |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                            Refresh                            |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     .                                                               .
     .                        Mobility options                       .
     .                                                               .
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     (This may or may not be followed by an authorization data
     mobility option, depending on resolution to issue #3. If it
     is necessary, then between the Refresh field and the option
     there would have to be 2 bytes of padding.

     It may or may not be necessary to add a Mobile cookie in this
     message. The alternative is to rely on Sequence #.)

BM: (8n)

                                     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
                                     |          Reserved             |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     +                                                               +
     |                                                               |
     +                          Home Address                         +
     |                                                               |
     +                                                               +
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |    Status     |                  Reserved                     |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     .                                                               .
     .                        Mobility Options                       .
     .                                                               .
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     (The status field can be used to tell if there's a missing
     binding or an unrecognized MH Type field - ICMP Parameter Problem
     pointers to packet contents are typically not used for actual
     behaviour.)

Mobility option: (-)

     0                   1                   2                   3
     0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
    |Option Type    |  Option Len   |   Option Data...              |
    +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

Pad1: (-)

      0
      0 1 2 3 4 5 6 7
     +-+-+-+-+-+-+-+-+
     |       0       |
     +-+-+-+-+-+-+-+-+

PadN: (-)

      0                   1
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+- - - - - - - - -
     |       1       | Option Len | Option Data
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+- - - - - - - - -

Unique Identifier: (2n)

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |       2       |       4       |       Unique Identifier       |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

Alternate Care-of Address: (8n+6)

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
                                     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
                                     |       3       |      18       |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     +                                                               +
     |                                                               |
     +                   Alternate Care-of Address                   +
     |                                                               |
     +                                                               +
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

Nonce indices: (2n)

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
                                     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
                                     |       4       |       6       |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |         Home Nonce Index      |     Care-of Nonce Index       |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

Authorization Data: (4n+2)

      0                   1                   2                   3
      0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
                                     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
                                     |       5       |      18       |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
     |                                                               |
     +                                                               +
     |                         Authenticator                         |
     +                                                               +
     |                                                               |
     +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

     (The alignment is 4, not 8. Authenticator is 96 bits or 12 bytes.)

---

From: Francis Dupont <[email-masked]>
Date: Thu, 02 May 2002 10:16:18 +0200

=> I don't know if the checksum (does it cover a pseudo-header ?) is
useful because there is already an integrity protection (by the
authorization data or another mechanism). This will make the common
header 32 bit aligned...

Regards

[email-masked]

---

From: Jari Arkko <[email-masked]>
Date: Thu, 02 May 2002 12:14:03 +0300

Francis Dupont wrote:

> => I don't know if the checksum (does it cover a pseudo-header ?)

It does cover a pseudo-header as well.

> is

Yes, but not all MH messages are covered, at least directly, by the
authorization data. For instance, Binding Missing is never covered,
and [HC]oT{,I} are covered only indirecly after several messages have
been exchanged.

Jari

---

From: Francis Dupont <[email-masked]>
Date: Thu, 02 May 2002 11:34:45 +0200

=> don't forget to specify the pseudo-header details (source address,
length field), including in the case the MH is not a terminal header.

=> so we should keep the checksum for simplicity...

Thanks

---

From: Jari Arkko <[email-masked]>
Date: Thu, 02 May 2002 12:39:11 +0300

> => so we should keep the checksum for simplicity...

Ok.

 > length field), including in the case the MH is not a terminal header.

Here's the current text. Is this good enough or is something missing?
TBD is MH's protocol number.

Checksum
	16-bit unsigned integer. This field contains the checksum of the
	Mobility Header. The checksum is the 16-bit one's complement of the
	one's complement sum of the entire Mobility Header starting with the
	Payload Proto field, prepended with a "pseudo-header" of IPv6 header
	fields, as specified in Section 8.1 of [rfc 2460]. The Next
	Header value used in the pseudo-header is TBD. For computing the
	checksum, the checksum field is set to zero.

Jari

---

From: Francis Dupont <[email-masked]>
Date: Thu, 02 May 2002 11:57:18 +0200

Checksum
   
=> you need in all cases a reference to section 10.1 for the addresses
to use (no surprise but IMHO we should be as clear as possible here).
For the non-terminal version of MH you have a problem with the protocol
number (just do a choice) and (more interesting) with the payload length
field. So I am afraid the current text is not yet enough...
Of course, I suppose you'll include draft-ietf-mobileip-piggyback-00.txt
in the new draft as most of the missing details are for the non-terminal
version.

Thanks

---

From: Vijay Devarapalli <[email-masked]>
Date: Thu, 02 May 2002 08:48:43 -0700

hi Jari,

couple of comments

> Proposal: See formats below.

Can we move the Home Address to a Mobility Option? It is not always
going to be there (esp if you use AH for BU protection).

>  Authorization Data: (4n+2)

What happened to the SPI field? I dont think there was concensus
on removing the SPI field.

regards
Vijay

---

From: Robert Chalmers <[email-masked]>
Date: Thu, 02 May 2002 09:46:47 -0700

> Proposal: See formats below.

(.snip.)

> BU: (8n)
I would keep the sequence number in the same place as it is in the BU.
Also, move the status to the first byte of the message:

(.snip.)

> BM: (8n)
Here, I would move the status field to the first byte of the message,
and elide the last 32-bits. This will allow the option to end on an 8n
boundary:

(.snip.)

-- 
/****************************************************************

 Robert Chalmers
 UCSB Computer Science Doctoral Candidate
 Network and Multimedia Systems Lab (NMSL)

 "My heart is in the code, but my soul lies in the process"
 
 | [email-masked] || http://www.cs.ucsb.edu/~robertc/ |

*****************************************************************/

---

From: Jari Arkko <[email-masked]>
Date: Thu, 02 May 2002 21:05:05 +0300

> going to be there (esp if you use AH for BU protection).

Yes. Or more exactly, it is unnecessary if AH is used. But we have
an open issue I believe on whether AH or ESP should be used. Could
we decided that first, and then make a decision on the HoA place. If
AH is used or either AH or ESP is used => make it an option. If only
ESP is used => make it a part of the message.

> on removing the SPI field.

Yes. As I recall it, there wasn't any consensus whatsoever, not on keeping
it either. Keep a 16 bit SPI field? ;-)

Jari

---

From: Jari Arkko <[email-masked]>
Date: Thu, 02 May 2002 21:37:00 +0300

Robert Chalmers wrote:

> BA

> Also, move the status to the first byte of the message:

Yes.

> and elide the last 32-bits. This will allow the option to end on an 8n

Yes.

Updated issue description and formats at

http://www.piuha.net/~jarkko/publications/mipv6/issues/issue7.txt

Jari

---

From: Vijay Devarapalli <[email-masked]>
Date: Thu, 02 May 2002 11:46:34 -0700

> ESP is used => make it a part of the message.

Not just AH. Any future authentication mechanism which relies on 
a MAC field covering the HAO. So I prefer an option for the home
address.

> it either. Keep a 16 bit SPI field? ;-)

I think it has to be a 32 bit SPI field. And I guess the Authenticator 
field has no alignment requirements.

Vijay