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.

141 lines
3.2 KiB

  1. /*++
  2. Copyright (c) 1999, Microsoft Corporation
  3. Module Name:
  4. eapol.h
  5. Abstract:
  6. This module contains declarations which will be used by other processes.
  7. This may be placed in sdk\inc
  8. Revision History:
  9. sachins, Apr 23 2000, Created
  10. --*/
  11. #ifndef _EAPOL_H_
  12. #define _EAPOL_H_
  13. //
  14. // Structure: EAPOL_STATS
  15. //
  16. typedef struct _EAPOL_STATS
  17. {
  18. DWORD dwEAPOLFramesRcvd;
  19. DWORD dwEAPOLFramesXmt;
  20. DWORD dwEAPOLStartFramesXmt;
  21. DWORD dwEAPOLLogoffFramesXmt;
  22. DWORD dwEAPRespIdFramesXmt;
  23. DWORD dwEAPRespFramesXmt;
  24. DWORD dwEAPReqIdFramesRcvd;
  25. DWORD dwEAPReqFramesRcvd;
  26. DWORD dwEAPOLInvalidFramesRcvd;
  27. DWORD dwEAPLengthErrorFramesRcvd;
  28. DWORD dwEAPOLLastFrameVersion;
  29. BYTE bEAPOLLastFrameSource[6]; // assuming 6-byte MAC addr
  30. } EAPOL_STATS, *PEAPOL_STATS;
  31. //
  32. // Structure: EAPOL_CONFIG
  33. //
  34. typedef struct _EAPOL_CONFIG
  35. {
  36. DWORD dwheldPeriod; // Time in seconds, for which the
  37. // port will be held in HELD state
  38. DWORD dwauthPeriod; // Time in seconds, for which the
  39. // port will wait in AUTHENTICATING/
  40. // ACQUIRED state waiting for requests
  41. DWORD dwstartPeriod; // Time in seconds, the port will
  42. // wait in CONNECTING state, before
  43. // re-issuing EAPOL_START packet
  44. DWORD dwmaxStart; // Max number of EAPOL_Start packets
  45. // that can be sent out without any
  46. // response
  47. } EAPOL_CONFIG, *PEAPOL_CONFIG;
  48. //
  49. // Structure: EAPOL_CUSTOM_AUTH_DATA
  50. //
  51. typedef struct _EAPOL_CUSTOM_AUTH_DATA
  52. {
  53. DWORD dwSizeOfCustomAuthData;
  54. BYTE pbCustomAuthData[1];
  55. } EAPOL_CUSTOM_AUTH_DATA, *PEAPOL_CUSTOM_AUTH_DATA;
  56. //
  57. // Structure: EAPOL_EAP_UI_DATA
  58. //
  59. typedef struct _EAPOL_EAP_UI_DATA
  60. {
  61. DWORD dwContextId;
  62. PBYTE pEapUIData;
  63. DWORD dwSizeOfEapUIData;
  64. } EAPOL_EAP_UI_DATA, *PEAPOL_EAP_UI_DATA;
  65. // Definitions common to elport.c and eleap.c
  66. //
  67. // Defines states for the EAP protocol.
  68. //
  69. typedef enum _EAPSTATE
  70. {
  71. EAPSTATE_Initial,
  72. EAPSTATE_IdentityRequestSent,
  73. EAPSTATE_Working,
  74. EAPSTATE_EapPacketSentToAuthServer,
  75. EAPSTATE_EapPacketSentToClient,
  76. EAPSTATE_NotificationSentToClient
  77. } EAPSTATE;
  78. typedef enum _EAPTYPE
  79. {
  80. EAPTYPE_Identity = 1,
  81. EAPTYPE_Notification,
  82. EAPTYPE_Nak,
  83. EAPTYPE_MD5Challenge,
  84. EAPTYPE_SKey,
  85. EAPTYPE_GenericTokenCard
  86. } EAPTYPE;
  87. //
  88. // Actions that need to be performed on EAP data after it is processed
  89. //
  90. typedef enum _ELEAP_ACTION
  91. {
  92. ELEAP_NoAction,
  93. ELEAP_Done,
  94. ELEAP_SendAndDone,
  95. ELEAP_Send
  96. } ELEAP_ACTION;
  97. //
  98. // EAPOL Authentication Types - Used for MACHINE_AUTH
  99. //
  100. typedef enum _EAPOL_AUTHENTICATION_TYPE
  101. {
  102. EAPOL_UNAUTHENTICATED_ACCESS = 0,
  103. EAPOL_USER_AUTHENTICATION,
  104. EAPOL_MACHINE_AUTHENTICATION
  105. } EAPOL_AUTHENTICATION_TYPE;
  106. #endif // _EAPOL_H_