Skip to main content

NCP/IPX Header Compression

Since most IPX packets are Netware Core Protocol packets (packet type 17), compressing the NCP header will give us added performance. A minimal CIPX implementation MUST also implement NCP/IPX compression.

+------------+
| NCP |
| Type |
+------------+
| Sequence |
| Number |
+------------+
| Connection |
|(low octet) |
+------------+
| Task |
| Number |
+------------+
| Connection |
|(high octet)|
+------------+

NCP HEADER

The NCP header is 6 octets in length consisting of the following fields: NCP type, sequence number, connection number and task number.

The NCP type field values that are currently defined are:

1111 Create Connection 2222 NCP request from workstation 3333 NCP reply from file server 5555 Destroy Connection 7777 Burst Mode Packet 9999 Server Busy Packet This NCP header compression algorithm only compresses packets that have a type field value of 0x2222 or 0x3333. If the NCP type is 0x2222, this packet is a request from the client to the server. Conversely if the NCP type is 0x3333, this is a response from the server to the client. All other types of NCP packets are not compressed at the NCP level, but are compressed at the IPX level. The Create Connection (0x111), Destroy Connection (0x5555) and Server Busy (0x9999) packets are not exchanged frequently enough to justify special NCP compression. The Burst Mode (0x7777) packet is discussed below.

The connection number is a constant for a given connection.

The sequence number is increased by one for each new request. Hence the sequence number can be determined implicitly. The decompressor increments the sequence number for each compressed packet it receives for a connection.

The task number can change unpredictably, although it might remain constant for several packets. If the NCP task number is different from the last one for this connection, the NCP task number must be included.

If the NCP packet is lost, it will be retransmitted through the normal transport layer mechanisms. The Initial NCP packet does not require confirmation, as a re-transmitted packet can be easily identified. This is accomplished by comparing the sequence number of the packet to the sequence number of the previous packet. If the sequence number is not exactly one greater than the previous packet, a new Initial packet must be sent, although the same connection slot may be used.

In the event of compressed packet loss, the sequence number will be too small. When the IPX Checksum is present, the loss can be determined at the destination system by an incorrect checksum. When there is no checksum present, the loss is more likely to be detected upon receiving a later retransmission.