The GMA encapsulation protocol supports the following three methods:
Non-IP encapsulation
MUST be used if the original IP packet is IPv6.
Trailer-based IP encapsulation
MUST be used if it is supported by GMA endpoints and the original IP packet is IPv4.
Header-based encapsulation
MUST be used if the trailer-based method is not supported by either the client or Multi-Access Gateway. In this case, if the adaptation layer, e.g., UDP tunneling, supports non-IP packet format, non-IP encapsulation
MUST be used; otherwise, header-based IP encapsulation
MUST be used.
If non-IP encapsulation is configured, a GMA header
MUST be present in every packet. In comparison, if IP encapsulation is configured, a GMA header or trailer may be added dynamically on a per-packet basis, and it indicates the presence of a GMA header (or trailer) to set the protocol type of the GMA PDU to "114" (see
Section 4.4).
The GMA endpoints
MAY configure the GMA encapsulation method through control signaling or pre-configuration. For example, the "MX UP Setup Configuration Request" message as specified in Multi-Access Management Service [
MAMS] includes "MX Convergence Method Parameters", which provides the list of parameters to configure the convergence layer, and can be extended to indicate the GMA encapsulation method.
GMA endpoint
MUST discard a received packet and
MAY log an error to report the situation (although such error logging
MUST be subject to rate limits) under any of the following conditions:
-
The GMA version number in the GMA header (or trailer) is not understood or supported by the GMA endpoint.
-
A flag bit in the GMA header (or trailer) not understood or supported by the GMA endpoint is set to "1".
|<---------------------GMA PDU ----------------------->|
+------------------------------------------------------+
| IP hdr | IP payload | GMA Trailer |
+------------------------------------------------------+
|<------- GMA SDU (user payload)-------->|
This method
SHALL NOT be used if the original IP packet (GMA service data unit (GMA SDU)) is IPv6.
Figure 3 shows the trailer-based IP encapsulation GMA protocol data unit (GMA PDU) format. A (GMA) PDU may carry one or multiple IP packets, aka (GMA) SDUs, in the payload, or a fragment of the SDU.
The protocol type field in the IP header of the GMA PDU
MUST be changed to 114 (Any 0-Hop Protocol) (see
Section 4.4) to indicate the presence of the GMA trailer.
The following three IP header fields
MUST be changed:
-
IP Length:
-
Add the length of "GMA Trailer" to the length of the original IP packet.
-
Time To Live (TTL):
-
Set to "1".
-
IP checksum:
-
Recalculate after changing "protocol type", "TTL", and "IP Length".
The GMA (Generic Multi-Access) trailer
MUST consist of two mandatory fields (the last 3 bytes): Next Header and Flags.
This is defined as follows:
-
Next Header (1 byte):
-
This is the IP protocol type of the (first) SDU in a PDU; it stores the value before it was overwritten to 114.
-
Flags (2 bytes):
-
Bit 0 is the most significant bit (MSB), and bit 15 is the least significant bit (LSB).
-
Checksum Present (bit 0):
-
If the Checksum Present bit is set to 1, then the Checksum field is present.
-
Concatenation Present (bit 1):
-
If the Concatenation Present bit is set to 1, then the PDU carries multiple SDUs, and the First SDU Length field is present.
-
Connection ID Present (bit 2):
-
If the Connection ID Present bit is set to 1, then the Connection ID field is present.
-
Flow ID Present (bit 3):
-
If the Flow ID Present bit is set to 1, then the Flow ID field is present.
-
Fragmentation Present (bit 4):
-
If the Fragmentation Present bit is set to 1, then the PDU carry a fragment of the SDU and the Fragmentation Control field is present.
-
Delivery SN Present (bit 5):
-
If the Delivery SN (Sequence Number) Present bit is set to 1, then the Delivery SN field is present and contains the valid information.
-
Flow SN Present (bit 6):
-
If the Flow SN Present bit is set to 1, then the Sequence Number field is present.
-
Timestamp Present (bit 7):
-
If the Timestamp Present bit is set to 1, then the Timestamp field is present.
-
TTL Present (bit 8):
-
If the TTL Present bit is set to 1, then the TTL field is present.
-
Reserved (bit 9-12):
-
This is set to "0" and ignored on receipt.
-
Version (bit 13~15):
-
This is the GMA version number; it is set to 0 for the GMA encapsulation protocol specified in this document.
The Flags field is at the end of the PDU, and the Next Header field is the second last. The receiver
SHOULD first decode the Flags field to determine the length of the GMA trailer and then decode each optional field accordingly. The Generic Multi-Access (GMA) trailer
MAY consist of the following optional fields:
-
Checksum (1 byte):
-
This contains the (one's complement) checksum sum of all 8 bits in the trailer. For purposes of computing the checksum, the value of the Checksum field is zero. This field is present only if the Checksum Present bit is set to 1.
-
First SDU Length (2 bytes):
-
This is the length of the first IP packet in the PDU, only included if a PDU contains multiple IP packets. This field is present only if the Concatenation Present bit is set to 1.
-
Connection ID (1 byte):
-
This contains an unsigned integer to identify the anchor and delivery connection of the GMA PDU. This field is present only if the Connection ID Present bit is set to 1.
-
Anchor Connection ID (MSB 4 bits):
-
This contains an unsigned integer to identify the anchor connection.
-
Delivery Connection ID (LSB 4 bits):
-
This contains an unsigned integer to identify the delivery connection.
-
Flow ID (1 byte):
-
This contains an unsigned integer to identify the IP flow that a PDU belongs to, for example Data Radio Bearer (DRB) ID [LWIPEP] for a cellular (e.g., LTE) connection. This field is present only if the Flow ID Present bit is set to 1.
-
Fragmentation Control (FC) (1 byte):
-
This provides necessary information for reassembly, only needed if a PDU carries fragments. This field is present only if the Fragmentation Present bit is set to 1. Please refer to Section 5 for its detailed format and usage.
-
Delivery SN (1 byte):
-
This contains an auto-incremented integer to indicate the GMA PDU transmission order on a delivery connection. Delivery SN is needed to measure packet loss of each delivery connection and therefore generated per delivery connection per flow. This field is present only if the Delivery SN Present bit is set to 1.
-
Flow SN (3 bytes):
-
This contains an auto-incremented integer to indicate the GMA SDU (IP packet) order of a flow. Flow SN is needed for retransmission, reordering, and fragmentation. It SHALL be generated per flow. This field is present only if the Flow SN Present bit is set to 1.
-
Timestamp (4 bytes):
-
This contains the current value of the timestamp clock of the transmitter in the unit of 1 millisecond. This field is present only if the Timestamp Present bit is set to 1.
-
TTL (1 byte):
-
This contains the TTL value of the original IP header if the GMA SDU is IPv4, or the Hop-Limit value of the IP header if the GMA SDU is IPv6. This field is present only if the TTL Present bit is set to 1.
Figure 4 shows the GMA trailer format with all the fields present, and the order of the GMA control fields
SHALL follow the bit order in the Flags field. Note that the bits in the Flags field are ordered with the first bit transmitted being bit 0 (MSB). All fields are transmitted in regular network byte order and appear in reverse order to their corresponding flag bits. If a flag bit is clear, the corresponding optional field is absent.
For example, bit 0 (the MSB) of the Flags field is the Checksum Present bit, and the Checksum field is the last in the trailer with the exception of the two mandatory fields. Bit 1 is the Concatenation Present bit, and the FSL field is the second last.
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
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| TTL | Timestamp
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Flow SN |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Delivery SN | FC | Flow ID | Connection ID |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| First SDU Length (FSL) | Checksum | Next Header |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Flags |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
This method
SHALL NOT be used if the original IP packet (GMA SDU) is IPv6.
Figure 5 shows the header-based IP encapsulation format. Here, the GMA header is inserted right after the IP header of the GMA SDU, and the IP header fields of the GMA PDU
MUST be changed the same way as in trailer-based IP encapsulation.
+-----------------------------------------------+
|IP hdr | GMA Header | IP payload |
+-----------------------------------------------+
Figure 6 shows the GMA header format. In comparison to the GMA trailer, the only difference is that the Flags field is now in the front so that the receiver can first decode the Flags field to determine the GMA header length.
The "TTL" field
MUST be included and the "TTL" bit in the GMA header (or Trailer)
MUST be set to 1 if (trailer- or header-based) IP encapsulation is used.
+------------------------------------------------------+
| Flags | other fields (TTL, Timestamp, Flow SN, etc.) |
+------------------------------------------------------+
Figure 7 shows the header-based non-IP encapsulation format. Here, "UDP Tunneling" is configured at the MX adaptation layer. The ports for "UDP Tunneling" at the client are chosen from the Dynamic Port range, and the ports for "UDP Tunneling" at the Multi-Access Gateway are configured and provided to the client through additional control messages, e.g., [
MAMS].
"TTL", "FSL", and "Next Header" are no longer needed and
MUST not be included. Moreover, the IP header fields of the GMA SDU remain unchanged.
+-------------------------------------------------------------+
| IP hdr | UDP hdr | GMA Header | IP hdr | IP payload |
+-------------------------------------------------------------+
|<------- GMA SDU------------>|
|<------------------- GMA PDU------------>|
As described in
Section 4.1, IP-encapsulated GMA PDUs are indicated using the IP protocol type 114. This is designated and recorded by IANA [
IANA] to indicate "any 0-Hop Protocol". No reference is given in the IANA registry for the definition of this protocol type, and IANA has no record of why the assignment was made or how it is used, although it was probably assigned before 1999 [
IANA1999].
There is some risk associated with "reusing" protocol type 114 because there may be implementations of other protocols also using this protocol type. However, because the protocol described in this document is used only between adjacent devices specifically configured for this purpose, the use of protocol type 114 should be safe.
As described in
Section 1.1, one of the purposes of the experiment described in this document is to verify the safety of using this protocol type. Deployments should be aware of the risk of a clash with other uses of this protocol type.