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.

284 lines
5.6 KiB

  1. /*++
  2. Copyright (c) 2000, Microsoft Corporation
  3. Module Name:
  4. eapolutil.h
  5. Abstract:
  6. Definitions for tools and ends
  7. Revision History:
  8. sachins, May 04 2000, Created
  9. --*/
  10. #ifndef _EAPOLUTIL_H_
  11. #define _EAPOLUTIL_H_
  12. //
  13. // FUNCTION DECLARATIONS
  14. //
  15. VOID
  16. HostToWireFormat16(
  17. IN WORD wHostFormat,
  18. IN OUT PBYTE pWireFormat
  19. );
  20. WORD
  21. WireToHostFormat16(
  22. IN PBYTE pWireFormat
  23. );
  24. VOID
  25. HostToWireFormat32(
  26. IN DWORD dwHostFormat,
  27. IN OUT PBYTE pWireFormat
  28. );
  29. DWORD
  30. WireToHostFormat32(
  31. IN PBYTE pWireFormat
  32. );
  33. DWORD
  34. ElSetCustomAuthData (
  35. IN CHAR *pszGuid,
  36. IN DWORD dwEapTypeId,
  37. IN CHAR *pszSSID,
  38. IN BYTE *pbConnInfo,
  39. IN DWORD dwInfoSize
  40. );
  41. DWORD
  42. ElGetCustomAuthData (
  43. IN CHAR *pszGuid,
  44. IN DWORD dwEapTypeId,
  45. IN CHAR *pszSSID,
  46. IN OUT BYTE *pbConnInfo,
  47. IN OUT DWORD *pdwInfoSize
  48. );
  49. DWORD
  50. ElSetEapUserInfo (
  51. IN HANDLE hToken,
  52. IN CHAR *pszGuid,
  53. IN DWORD dwEapTypeId,
  54. IN CHAR *pszSSID,
  55. IN BYTE *pbUserInfo,
  56. IN DWORD dwInfoSize
  57. );
  58. DWORD
  59. ElGetEapUserInfo (
  60. IN HANDLE hToken,
  61. IN CHAR *pszGuid,
  62. IN DWORD dwEapTypeId,
  63. IN CHAR *pszSSID,
  64. IN OUT BYTE *pbUserInfo,
  65. IN OUT DWORD *pdwInfoSize
  66. );
  67. DWORD
  68. ElSetInterfaceParams (
  69. IN CHAR *pszGUID,
  70. IN DWORD *pdwDefaultEAPType,
  71. IN CHAR *pszLastUsedSSID,
  72. IN DWORD *pdwEapolEnabled
  73. );
  74. DWORD
  75. ElGetInterfaceParams (
  76. IN CHAR *pszGUID,
  77. IN OUT DWORD *pdwDefaultEAPType,
  78. IN OUT CHAR *pszLastUsedSSID,
  79. IN OUT DWORD *pdwEapolEnabled
  80. );
  81. DWORD
  82. ElGetEapKeyFromToken (
  83. IN HANDLE hUserToken,
  84. OUT HKEY *phkey
  85. );
  86. DWORD
  87. ElInitRegPortData (
  88. IN CHAR *pszDeviceGUID
  89. );
  90. RAS_AUTH_ATTRIBUTE *
  91. ElAuthAttributeGetVendorSpecific (
  92. IN DWORD dwVendorId,
  93. IN DWORD dwVendorType,
  94. IN RAS_AUTH_ATTRIBUTE *pAttributes
  95. );
  96. RAS_AUTH_ATTRIBUTE *
  97. ElAuthAttributeGetFirst (
  98. IN RAS_AUTH_ATTRIBUTE_TYPE raaType,
  99. IN RAS_AUTH_ATTRIBUTE *pAttributes,
  100. OUT HANDLE *phAttribute
  101. );
  102. RAS_AUTH_ATTRIBUTE *
  103. ElAuthAttributeGetNext (
  104. IN OUT HANDLE *phAttribute,
  105. IN RAS_AUTH_ATTRIBUTE_TYPE raaType
  106. );
  107. RAS_AUTH_ATTRIBUTE *
  108. ElAuthAttributeGet (
  109. IN RAS_AUTH_ATTRIBUTE_TYPE raaType,
  110. IN RAS_AUTH_ATTRIBUTE *pAttributes
  111. );
  112. VOID
  113. ElReverseString (
  114. IN CHAR *psz
  115. );
  116. CHAR*
  117. ElEncodePw (
  118. IN OUT CHAR *pszPassword
  119. );
  120. CHAR*
  121. ElDecodePw (
  122. IN OUT CHAR *pszPassword
  123. );
  124. VOID
  125. ElEncryptBlockUsingMD5 (
  126. IN BYTE *pbSecret,
  127. IN ULONG ulSecretLen,
  128. IN OUT BYTE *pbBuf,
  129. IN ULONG ulBufLen
  130. );
  131. VOID
  132. ElDecryptBlockUsingMD5 (
  133. IN BYTE *pbSecret,
  134. IN ULONG ulSecretLen,
  135. IN OUT BYTE *pbBuf,
  136. IN ULONG ulBufLen
  137. );
  138. VOID
  139. ElGetHMACMD5Digest (
  140. IN BYTE *pbBuf,
  141. IN DWORD dwBufLen,
  142. IN BYTE *pbKey,
  143. IN DWORD dwKeyLen,
  144. IN OUT VOID *pvDigest
  145. );
  146. DWORD
  147. ElWmiGetValue (
  148. IN GUID *pGuid,
  149. IN CHAR *pszInstanceName,
  150. IN OUT BYTE *pbOutputBuffer,
  151. IN OUT DWORD *pdwOutputBufferSize
  152. );
  153. DWORD
  154. ElWmiSetValue (
  155. IN GUID *pGuid,
  156. IN CHAR *pszInstanceName,
  157. IN BYTE *pbInputBuffer,
  158. IN DWORD dwInputBufferSize
  159. );
  160. DWORD
  161. ElNdisuioSetOIDValue (
  162. IN HANDLE hInterface,
  163. IN NDIS_OID Oid,
  164. IN BYTE *pbOidData,
  165. IN ULONG ulOidDataLength
  166. );
  167. DWORD
  168. ElNdisuioQueryOIDValue (
  169. IN HANDLE hInterface,
  170. IN NDIS_OID Oid,
  171. IN BYTE *pbOidData,
  172. IN ULONG *pulOidDataLength
  173. );
  174. DWORD
  175. ElGuidFromString (
  176. IN OUT GUID *pGuid,
  177. IN CHAR *pszGuidString
  178. );
  179. DWORD
  180. ElGetLoggedOnUserName (
  181. IN EAPOL_PCB *pPCB
  182. );
  183. DWORD
  184. ElGetMachineName (
  185. IN EAPOL_PCB *pPCB
  186. );
  187. DWORD
  188. ElUpdateRegistryInterfaceList (
  189. IN PNDIS_ENUM_INTF Interfaces
  190. );
  191. VOID
  192. ElWatchGlobalRegistryParams (
  193. IN PVOID pvContext
  194. );
  195. DWORD
  196. ElReadGlobalRegistryParams ();
  197. VOID
  198. ElWatchEapConfigRegistryParams (
  199. IN PVOID pvContext
  200. );
  201. DWORD
  202. ElReadGlobalRegistryParams ();
  203. DWORD
  204. ElProcessEapConfigChange ();
  205. VOID
  206. ElStringToGuid (
  207. IN CHAR *psGuid,
  208. OUT LPGUID pGuid
  209. );
  210. DWORD
  211. ElGetIdentity (
  212. IN EAPOL_PCB *pPCB
  213. );
  214. HANDLE
  215. ElNLAConnectLPC ();
  216. VOID
  217. ElNLACleanupLPC ();
  218. VOID
  219. ElNLARegister_802_1X (
  220. IN PLOCATION_802_1X plocation
  221. );
  222. VOID
  223. ElNLADelete_802_1X (
  224. IN PLOCATION_802_1X plocation
  225. );
  226. DWORD
  227. ElGetInterfaceNdisStatistics (
  228. IN CHAR *pszInterfaceName,
  229. IN OUT NIC_STATISTICS *pStats
  230. );
  231. #endif // _EAPOLUTIL_H_