IPX/SPX
Lan Life
Lan Life
IPX (Internetwork Packet Exchange) and SPX (Sequenced Packet Exchange) are networking protocols used by Novell NetWare. IPX is similar to IP and SPX is similar to TCP. IPX/SPX is mostly used for LAN.
Network Address
The complete address to a target is made up of the Node address, the network number and the socket number. The node address is the MAC address of the target node. The human-friendly form is six groups of hexadecimal digits, separated by hyphens. Ex 11-22-33-44-55-66.
Immediate Address
IPX Header
The IPX header is 30 bytes long and the packet can then contain 546 bytes of data. To send a packet some fields need to be filled in and some fields will be filled in by IPX. In comments application set field start with App and Ipx/Spx set fields start with IPX.
int16_t CheckSum // Ipx. Set to 0xFFFF.
int16_t Length // Ipx. Total packet length (inc header).
int8_t TransportControl // Ipx.
int8_t PacketType // App. 4 for Ipx, 5 for Spx.
int8_t DestinationNetwork[4] // App. Set field to network nr of target. 0 = Same network as source.
int8_t DesitnationNode[6] // App. Set to node address of target
int16_t DestinationSocket // App. Set to socket id of target socket.
int8_t SourceNetwork[4] // Ipx
int8_t SourceNode[6] // Ipx
int16_t SourceSocket // Ipx
SPX Header
The SPX header has a total size of 42 bytes and the first 30 is the IPX header.
int8_t IPXHeader[30];
int8_t ConnectionControl // App. Bit field
int8_t DataStreamType // Ipx
int16_t SourceConnectionId // Ipx
int16_t DestinationConnectionId // Ipx
int16_t SequenceNumber // Ipx
int16_t AcknowledgeNumber // Ipx.
int16_t AllocationNumber // Ipx.
Event Control Block
FragDescr
void* Ptr // Ptr to memory for packet fragment.
int16_t Length // Length of packet fragment. First must be able to hold IPX or SPX header.
ECB
void* LinkAddress // Ipx
void* EventServiceRoutine // Ipx
int8_t InUseFlag // Ipx
int8_t CompletionCode // Ipx
int16_t SocketNumber // App
int16_t ConnectionID // Ipx
int8_t Unused[2] // Ipx
int8_t DriverWorkspace[12] // Ipx.
int8_t ImmediateAddress[6] // Set by Ipx for received packets, app for transmitted packets.
int16_t FragmentCount // App.
FragDescr Fragments[2] // App.
Service
GetConnectionInformation
GetConnectionNumber
GetObjectConnectionNumbers
GetInternetAddress
IPX
IPX_SPX_OpenSocket : 0x00
IPX_SPX_CloseSocket : 0x01
IPX_GetLocalTarget : 0x02
IPX_SendPacket : 0x03
IPX_ListenForPacket : 0x04
IPX_Schedule_IPX_Event : 0x05
IPX_CancelEvent : 0x06
IPX_GetIntervalMarker : 0x08
IPX_GetInternetworkAddress : 0x09
IPX_RelingquishControl : 0x0A
IPX_DisconnectFromTarget : 0x0B
SPX
SPX_Initilize : 0x10
SPX_EstablishConnection : 0x11
SPX_LIstenForConnection : 0x12
SPX_TerminateConnection : 0x13
SPX_AbortConnection : 0x14
SPX_GetConnectionStatus : x015
SPX_SendSequncePacket : 0x16
SPX_ListenForSequencePacket : 0x17