TCP option 14, TCP Alternate checksum request |
Description | Glossary | RFCs | Publications | Obsolete RFCs |
Protocol suite: | TCP/IP. |
Protocol type: | Transport layer protocol. |
Option length: | 3 bytes. |
Host implementation: | |
Router implementation: | |
Links: | IANA: TCP option numbers. |
RFC 1146, pg 1:
The option described in this memo provides a mechanism to negotiate the use of an alternate checksum at connection-establishment time, as well as a mechanism to carry additional checksum information for algorithms that utilize checksums that are longer than 16 bits.
Definition of the option: the TCP Alternate Checksum Request Option may be sent in a SYN segment by a TCP to indicate that the TCP is prepared to both generate and receive checksums based on an alternate algorithm. During communication, the alternate checksum replaces the regular TCP checksum in the checksum field of the TCP header. Should the alternate checksum require more than 2 bytes to transmit, the checksum may either be moved into a TCP Alternate Checksum Data Option and the checksum field of the TCP header be sent as 0, or the data may be split between the header field and the option. Alternate checksums are computed over the same data as the regular TCP checksum.
Alternate checksum negotiation proceeds as follows:
A SYN segment used to originate a connection may contain the Alternate Checksum Request Option, which specifies an alternate checksum-calculation algorithm to be used for the connection. The acknowledging SYN-ACK segment may also carry the option.
If both SYN segments carry the Alternate Checksum Request option, and both specify the same algorithm, that algorithm must be used for the remainder of the connection. Otherwise, the standard TCP checksum algorithm must be used for the entire connection. Thus, for example, if one TCP specifies type 1 checksums, and the other specifies type 2 checksums, then they will use type 0 (the regular TCP checksum). Note that in practice, one TCP will typically be responding to the other's SYN, and thus either accepting or rejecting the proposed alternate checksum algorithm.
Any segment with the SYN bit set must always use the standard TCP checksum algorithm. Thus the SYN segment will always be understood by the receiving TCP. The alternate checksum must not be used until the first non-SYN segment. In addition, because RST segments may also be received or sent without complete state information, any segment with the RST bit set must use the standard TCP checksum.
The option may not be sent in any segment that does not have the SYN bit set.
MAC header | IP header | TCP header | TCP option 14 | Data |
TCP Option 14:
00 | 01 | 02 | 03 | 04 | 05 | 06 | 07 | 08 | 09 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Kind | Length | Checksum |
Kind. 8 bits. Set to 14.
Length. 8 bits. Set to 3.
Checksum.
8 bits.
Specifies the checksum algorithm to be used.
Value | Description |
---|---|
0 | TCP checksum. |
1 | 8-bit Fletcher's algorithm. |
2 | 16-bit Fletcher's algorithm. |
3 | Redundant Checksum Avoidance. |
RFCs:
[RFC 1146] TCP Alternate Checksum Options.
[RFC 1145] TCP Alternate Checksum Options.
Description | Glossary | RFCs | Publications | Obsolete RFCs |