2.2.10 Session ACK Message
The Session ACK message is the acknowledgment/reply to the Session Activation message (section 2.2.11). The transport-provided length of this message MUST be used by the receiver in order to determine the existence or number of extension structures that follow the non-optional portions of the message. The publisher MUST NOT publish messages that are less than 75 bytes long to a Session Activation message's ReplyChannelID. The subscriber MUST drop all Session ACK messages that are less than 75 bytes long.
The Session ACK message format is specified as follows.
|
|
|
|
|
|
|
|
|
|
1 |
|
|
|
|
|
|
|
|
|
2 |
|
|
|
|
|
|
|
|
|
3 |
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
ECDHPublicKeyMagicNumber |
|||||||||||||||||||||||||||||||
|
ECDHPublicKeyLength |
|||||||||||||||||||||||||||||||
|
ECDHXParam |
|||||||||||||||||||||||||||||||
|
ECDHYParam |
|||||||||||||||||||||||||||||||
|
TCPPort |
RFCOMMPort |
Reserved1 (optional) |
|||||||||||||||||||||||||||||
|
Reserved2 (optional) |
|||||||||||||||||||||||||||||||
|
Reserved3 (optional) |
|||||||||||||||||||||||||||||||
|
Reserved4 (optional) |
ExtensionCount (optional) |
||||||||||||||||||||||||||||||
|
ExtensionStructures (variable, optional) |
|||||||||||||||||||||||||||||||
|
... |
|||||||||||||||||||||||||||||||
ECDHPublicKeyMagicNumber (4 bytes): The 4-byte value 0x45, 0x43, 0x4B, and 0x31. This indicates that the Elliptic Curve Diffie-Hellman (ECDH) key exchange follows the P256 convention [NSA].
ECDHPublicKeyLength (4 bytes): A 32-bit, unsigned integer in little-endian format that specifies the key length in bytes. This value MUST be 0x00000020.
ECDHXParam (4 bytes): A 32-bit, unsigned integer that specifies the X coordinate of a single-use, generated ECDH public key. The private key portion MUST NOT be transmitted and is used in the local Session object (section 3.1.1.4) with the ECDH Public Key received from the Session Activation message (section 2.2.11).
ECDHYParam (4 bytes): A 32-bit, unsigned integer that specifies the Y coordinate of a single-use, generated ECDH public key. The private key portion MUST NOT be transmitted and is used in the local Session object with the ECDH Public Key received from the Session Activation message.
TCPPort (2 bytes): The TCP port that the publisher's session is listening on.
RFCOMMPort (1 byte): The RFCOMM port that the publisher's session is listening on.
Reserved1 (1 byte, optional): If present, this field MUST be set to zero when sent and MUST be ignored when received.
Reserved2 (4 bytes, optional): If present, this field MUST be set to zero when sent and MUST be ignored when received.
Reserved3 (4 bytes, optional): If present, this field MUST be set to zero when sent and MUST be ignored when received.
Reserved4 (2 bytes, optional): If present, this field MUST be set to zero when sent and MUST be ignored when received.
ExtensionCount (2 bytes, optional): The number of Extension structures (section 2.2.3) in the ExtensionStructures field. Use of this field is platform specific. A subscriber MUST ignore extensions that it does not process.
-
If this message is between 75 and 87 bytes long (inclusive), the value of this field is treated as zero.
ExtensionStructures (variable, optional): Zero or more Extension structures. Any incorrectly formatted Extension structures MUST be ignored by the subscriber.