next up previous contents
Next: UDP header Up: TCP/IP header fields Previous: IPv4 header   Contents

TCP header

The following fields are defined for the TCP header, as described in [RFC793]:

\begin{tabular}{l\vert cccccccccccccccccccccccccccccccc\vert...
\multicolumn{33}{l}{{\tt tcp\_data}} \\

TCP flags:

\begin{tabular}{\vert c\vert c\vert c\vert c\vert c\vert c\v...
...ST} & {\tt tcp\_SYN} & {\tt tcp\_FIN} \\

All fields listed above are based on tcp_hdr, which in turn is defined as follows:

field tcp_hdr = ip_nexthdr if ip_proto == IPPROTO_TCP;

Therefore, accessing any TCP header field automatically adds the precondition (see section 2.6.2) ip_proto == IPPROTO_TCP. defines a few additional fields for TCP options. Because tcng has currently no mechanism for iterating over a list of options, these fields are of no practical use and are therefore not documented.

Martin A. Brown 2003-11-06