LINKTYPE_SLIP

Packet structure

+-------------------------+
|        Direction        |
|        (1 Octet)        |
+-------------------------+
|       Packet type       |
|        (1 Octet)        |
+-------------------------+
| Compression information |
|       (14 Octets)       |
+-------------------------+
|         Payload         |
.                         .
.                         .
.                         .

Description

The direction field contains a value that is one of:

  • 0, if the packet was received by the machine;
  • 1, if the packet was sent by the machine..

If the uppermost bit of the packet type is set, the packet is a compressed TCP packet. Otherwise, the upper 4 bits of the packet type are one of:

  • 0x40, if the packet was an unmodified IP datagram;
  • 0x70, if the packet was a uncompressed TCP segment.

If the packet was an uncompressed TCP segment, the lower 4 bits of the packet type are the connection ID. If the packet was a compressed TCP segment, the packet type and compression information are the header of a compressed TCP/IP datagram, as per Figure 5 of RFC 1144.

The payload begins with an IP header; regardless of the value of the packet type, the IP and TCP headers are uncompressed.