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.

86 lines
1.9 KiB

  1. //+-------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. //
  5. // Copyright (C) Microsoft Corporation, 1998 - 1999
  6. //
  7. // File: xportst.h
  8. //
  9. //--------------------------------------------------------------------------
  10. #ifndef HEADER_XPORTST
  11. #define HEADER_XPORTST
  12. /*=======================< Function prototypes >===========================*/
  13. BOOL WSLoopBkTest( PVOID Context );
  14. BOOL NqTest(PVOID Context);
  15. HRESULT
  16. InitIpconfig(IN NETDIAG_PARAMS *pParams,
  17. IN OUT NETDIAG_RESULT *pResults);
  18. /*============================< Constants >================================*/
  19. #define DEFAULT_SEND_SIZE 32
  20. #define MAX_ICMP_BUF_SIZE ( sizeof(ICMP_ECHO_REPLY) + 0xfff7 + MAX_OPT_SIZE )
  21. #define DEFAULT_TIMEOUT 1000L
  22. #define PING_RETRY_CNT 4
  23. #define PORT_4_LOOPBK_TST 3038
  24. //
  25. // WINS related constants
  26. //
  27. #define NM_QRY_XID 0x6DFC
  28. #define NBT_NAME_SIZE 32
  29. #define MAX_NBT_PACKET_SIZE 1500
  30. #define NBT_NM_OPC_REQUEST 0x0000
  31. #define NBT_NM_OPC_RESPONSE 0x0080
  32. #define NBT_NM_OPC_QUERY 0x0000
  33. #define NBT_NM_OPC_REGISTRATION 0x0028
  34. #define NBT_NM_OPC_RELEASE 0x0030
  35. #define NBT_NM_OPC_WACK 0x0038
  36. #define NBT_NM_OPC_REFRESH 0x0040
  37. //
  38. // Name Service Flags
  39. //
  40. #define NBT_NM_FLG_BCAST 0x1000
  41. #define NBT_NM_FLG_RECURS_AVAIL 0x8000
  42. #define NBT_NM_FLG_RECURS_DESRD 0x0001
  43. #define NBT_NM_FLG_TRUNCATED 0x0002
  44. #define NBT_NM_FLG_AUTHORITATIV 0x0004
  45. //
  46. // Name Service question types
  47. //
  48. #define NBT_NM_QTYP_NB 0x2000
  49. #define NBT_NM_QTYP_NBSTAT 0x2100
  50. #define NBT_NM_QCLASS_IN 0x0100
  51. /*=====================< type/struct declarations >========================*/
  52. #include "pshpack1.h"
  53. typedef struct {
  54. WORD xid;
  55. WORD flags;
  56. WORD question_cnt;
  57. WORD answer_cnt;
  58. WORD name_serv_cnt;
  59. WORD additional_cnt;
  60. } NM_FRAME_HDR;
  61. typedef struct {
  62. BYTE q_name[NBT_NAME_SIZE+2];
  63. WORD q_type;
  64. WORD q_class;
  65. } NM_QUESTION_SECT;
  66. #include "poppack.h"
  67. #endif