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.

92 lines
2.6 KiB

  1. /********************************************************************/
  2. /** Microsoft LAN Manager **/
  3. /** Copyright (c) Microsoft Corporation. All rights reserved. **/
  4. /********************************************************************/
  5. //** LLINFO.H - Lower layer SNMP information definitions.
  6. //
  7. // This file contains all of the definitions for SNMP information collected
  8. // by layers below IP.
  9. #ifndef LLINFO_INCLUDED
  10. #define LLINFO_INCLUDED
  11. #include <ipifcons.h>
  12. #ifndef CTE_TYPEDEFS_DEFINED
  13. #define CTE_TYPEDEFS_DEFINED
  14. typedef unsigned long ulong;
  15. typedef unsigned short ushort;
  16. typedef unsigned char uchar;
  17. typedef unsigned int uint;
  18. #endif // CTE_TYPEDEFS_DEFINED
  19. #define IF_MIB_STATS_ID 1
  20. #define IF_FRIENDLY_NAME_ID 2
  21. #define MAX_PHYSADDR_SIZE 8
  22. typedef struct IPNetToMediaEntry {
  23. ulong inme_index;
  24. ulong inme_physaddrlen;
  25. uchar inme_physaddr[MAX_PHYSADDR_SIZE];
  26. ulong inme_addr;
  27. ulong inme_type;
  28. } IPNetToMediaEntry;
  29. #define INME_TYPE_OTHER 1
  30. #define INME_TYPE_INVALID 2
  31. #define INME_TYPE_DYNAMIC 3
  32. #define INME_TYPE_STATIC 4
  33. #define MAX_IFDESCR_LEN 256
  34. #define IFE_FIXED_SIZE offsetof(struct IFEntry, if_descr)
  35. typedef struct IFEntry {
  36. ulong if_index;
  37. ulong if_type;
  38. ulong if_mtu;
  39. ulong if_speed;
  40. ulong if_physaddrlen;
  41. uchar if_physaddr[MAX_PHYSADDR_SIZE];
  42. ulong if_adminstatus;
  43. ulong if_operstatus;
  44. ulong if_lastchange;
  45. ulong if_inoctets;
  46. ulong if_inucastpkts;
  47. ulong if_innucastpkts;
  48. ulong if_indiscards;
  49. ulong if_inerrors;
  50. ulong if_inunknownprotos;
  51. ulong if_outoctets;
  52. ulong if_outucastpkts;
  53. ulong if_outnucastpkts;
  54. ulong if_outdiscards;
  55. ulong if_outerrors;
  56. ulong if_outqlen;
  57. ulong if_descrlen;
  58. uchar if_descr[1];
  59. } IFEntry;
  60. //
  61. // MIB-II interface status values. The latest definition of these values
  62. // is in RFC 2863. ifOperStatus can use all values. ifAdminStatus only
  63. // uses the first three values.
  64. //
  65. typedef enum {
  66. IF_STATUS_UP = 1,
  67. IF_STATUS_DOWN = 2,
  68. IF_STATUS_TESTING = 3,
  69. IF_STATUS_UNKNOWN = 4,
  70. IF_STATUS_DORMANT = 5,
  71. IF_STATUS_NOT_PRESENT = 6,
  72. IF_STATUS_LOWER_LAYER_DOWN = 7
  73. } IF_STATUS_ENUM;
  74. #endif // LLINFO_INCLUDED