Source code of Windows XP (NT5)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

71 lines
1.8 KiB

  1. /***************************************************************************
  2. *
  3. * tdipx.h
  4. *
  5. * This module contains private Transport Driver defines and structures
  6. *
  7. * Copyright 1998, Microsoft
  8. *
  9. ****************************************************************************/
  10. #define htons(x) ((((x) >> 8) & 0x00FF) | (((x) << 8) & 0xFF00))
  11. /*
  12. * Well known Citrix IPX socket
  13. */
  14. #define CITRIX_IPX_SOCKET 0xBB85
  15. #define DD_IPX_DEVICE_NAME L"\\Device\\NwlnkIpx"
  16. #define DD_SPX_DEVICE_NAME L"\\Device\\NwlnkSpx"
  17. //
  18. // IPX_PACKET - format of packet submitted to IPX for sending. The maximum
  19. // size of an IPX packet is 576 bytes, 30 bytes header, 546 bytes data
  20. //
  21. typedef struct {
  22. BYTE Net[4]; // hi-lo
  23. BYTE Node[6]; // hi-lo
  24. USHORT Socket; // hi-lo
  25. } NETWARE_ADDRESS ;
  26. typedef struct {
  27. USHORT Checksum; // always set to 0xFFFF
  28. USHORT Length; // set by IPX - header + data
  29. BYTE TransportControl; // set by IPX to 0. Used by routers
  30. //
  31. // for IPX, PacketType is 0 (Unknown Packet Type) or 4 (Packet Exchange
  32. // Packet)
  33. //
  34. BYTE PacketType;
  35. NETWARE_ADDRESS Destination;
  36. NETWARE_ADDRESS Source;
  37. BYTE Data[]; // 546 bytes max.
  38. } IPX_PACKET ;
  39. typedef IPX_PACKET UNALIGNED *LPIPX_PACKET;
  40. #define IPX_HEADER_LENGTH sizeof(IPX_PACKET)
  41. #define MAXIMUM_IPX_PACKET_LENGTH 576
  42. #define MAXIMUM_IPX_DATA_LENGTH (MAXIMUM_IPX_PACKET_LENGTH - IPX_HEADER_LENGTH)
  43. /*
  44. * IPX TD structure
  45. */
  46. typedef struct _TDIPX {
  47. LIST_ENTRY IgnoreList; // list of ipx addresses to ignore
  48. ULONG AliveTime; // keep alive time (msec)
  49. PVOID pAliveTimer; // watchdog timer handle
  50. ULONG AlivePoll;
  51. ULONG fClientAlive : 1;
  52. } TDIPX, * PTDIPX;