net80211.h 20 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031
  1. /*++
  2. Copyright (c) 2015 Minoca Corp. All Rights Reserved
  3. Module Name:
  4. net80211.h
  5. Abstract:
  6. This header contains definitions for the 802.11 core wireless networking
  7. library.
  8. Author:
  9. Chris Stevens 19-Oct-2015
  10. --*/
  11. //
  12. // ------------------------------------------------------------------- Includes
  13. //
  14. #include <minoca/kernel/driver.h>
  15. #include <minoca/net/netdrv.h>
  16. //
  17. // Redefine the API define into an export.
  18. //
  19. #define NET80211_API __DLLEXPORT
  20. #include <minoca/net/net80211.h>
  21. #include <minoca/net/net8022.h>
  22. //
  23. // ---------------------------------------------------------------- Definitions
  24. //
  25. #define NET80211_ALLOCATION_TAG 0x69666957 // 'ifiW'
  26. //
  27. // Define the maximum number of supported keys.
  28. //
  29. #define NET80211_MAX_KEY_COUNT NET80211_CCMP_MAX_KEY_COUNT
  30. //
  31. // Define the maximum passphrase supported by 802.11 encryption. WPA2-PSK has
  32. // a maximum of 64 characters. This is internal as it may change over time.
  33. //
  34. #define NET80211_MAX_PASSPHRASE_LENGTH 64
  35. //
  36. // Define the set of scan flags.
  37. //
  38. #define NET80211_SCAN_FLAG_BACKGROUND 0x00000001
  39. #define NET80211_SCAN_FLAG_BROADCAST 0x00000002
  40. #define NET80211_SCAN_FLAG_JOIN 0x00000004
  41. //
  42. // Define the default amount of time to wait on a channel during a scan.
  43. //
  44. #define NET80211_DEFAULT_SCAN_DWELL_TIME (100 * MICROSECONDS_PER_MILLISECOND)
  45. //
  46. // Define the set of 802.11 link flags.
  47. //
  48. #define NET80211_LINK_FLAG_DATA_PAUSED 0x00000001
  49. #define NET80211_LINK_FLAG_TIMER_QUEUED 0x00000002
  50. #define NET80211_LINK_FLAG_SCANNING 0x00000004
  51. //
  52. // Define the set of BSS entry flags.
  53. //
  54. #define NET80211_BSS_FLAG_ENCRYPT_DATA 0x00000001
  55. //
  56. // Define the set of 802.11 encryption flags.
  57. //
  58. #define NET80211_ENCRYPTION_FLAG_USE_GROUP_CIPHER 0x00000001
  59. //
  60. // ------------------------------------------------------ Data Type Definitions
  61. //
  62. typedef
  63. VOID
  64. (*PNET80211_SCAN_COMPLETION_ROUTINE) (
  65. PNET80211_LINK Link,
  66. KSTATUS ScanStatus
  67. );
  68. /*++
  69. Routine Description:
  70. This routine is called when a scan for nearby BSS access points has
  71. completed.
  72. Arguments:
  73. Link - Supplies a pointer to the 802.11 link that performed the scan.
  74. ScanStatus - Supplies the status result of the scan.
  75. Return Value:
  76. None.
  77. --*/
  78. /*++
  79. Structure Description:
  80. This structure defines the scan state for the 802.11 node.
  81. Members:
  82. Link - Stores a pointer to the 802.11 link over which the scan will be
  83. performed.
  84. Flags - Stores a bitmask of flags that dictate the scan's behavior. See
  85. NET80211_SCAN_FLAG_* for definitions.
  86. Channel - Stores the current channel that is being scanned.
  87. Bssid - Stores an optional BSSID to be used when scanning for a specific
  88. BSS. This is only valid when the broadcast flag is not set.
  89. SsidLength - Stores the number of characters in the SSID for which the scan
  90. is searching.
  91. Ssid - Stores the SSID of the ESS for which the scan is searching.
  92. PassphraseLength - Stores the number of characters in the passphrase of the
  93. ESS for which the scan is searching.
  94. Passphrase - Stores the passphrase of the ESS for which the scan is
  95. searching.
  96. CompletionRoutine - Stores a pointer to the routine to call once the scan
  97. has completed.
  98. --*/
  99. typedef struct _NET80211_SCAN_STATE {
  100. PNET80211_LINK Link;
  101. ULONG Flags;
  102. ULONG Channel;
  103. UCHAR Bssid[NET80211_ADDRESS_SIZE];
  104. ULONG SsidLength;
  105. UCHAR Ssid[NET80211_MAX_SSID_LENGTH];
  106. ULONG PassphraseLength;
  107. UCHAR Passphrase[NET80211_MAX_PASSPHRASE_LENGTH];
  108. PNET80211_SCAN_COMPLETION_ROUTINE CompletionRoutine;
  109. } NET80211_SCAN_STATE, *PNET80211_SCAN_STATE;
  110. /*++
  111. Structure Description:
  112. This structure defines a key for the 802.11 core networking library.
  113. Members:
  114. Flags - Stores a bitmask of flags describing the key. See
  115. NET80211_KEY_FLAG_* for definitions.
  116. Id - Stores the key ID negotiatied between the station and access point.
  117. Length - Stores the length of the key, in bytes.
  118. PacketNumber - Stores a 64-bit packet number that is incremented for each
  119. encrypted packet sent with the key. Only the lower 48-bits are used.
  120. ReplayCounter - Stores a 64-bit replay counter that is updated on each
  121. accepted data frame. All subsequent data frames must have a packet
  122. number greater than the current replay counter.
  123. Value - Stores the array holding the value of the key.
  124. --*/
  125. typedef struct _NET80211_KEY {
  126. ULONG Flags;
  127. ULONG Id;
  128. ULONG Length;
  129. volatile ULONGLONG PacketNumber;
  130. ULONGLONG ReplayCounter;
  131. UCHAR Value[ANYSIZE_ARRAY];
  132. } NET80211_KEY, *PNET80211_KEY;
  133. /*++
  134. Structure Description:
  135. This structure defines the encryption information for a BSS.
  136. Members:
  137. Pairwise - Stores the pairwise encryption algorithm.
  138. Group - Stores the group encryption algorithm.
  139. PairwiseKeyIndex - Stores the index in the key array of the pairwise key.
  140. GroupKeyIndex - Stores the index in the key array of the group key.
  141. Flags - Stores a bitmask of encryption flags. See
  142. NET80211_ENCRYPTION_FLAG_* for definitions.
  143. Keys - Stores an array of keys for an authenticated connection.
  144. ApRsn - Stores a pointer to the RSN information gathered from the BSS's AP.
  145. StationRsn - Stores a pointer to the local RSN information for this station.
  146. --*/
  147. typedef struct _NET80211_ENCRYPTION {
  148. NETWORK_ENCRYPTION_TYPE Pairwise;
  149. NETWORK_ENCRYPTION_TYPE Group;
  150. ULONG PairwiseKeyIndex;
  151. ULONG GroupKeyIndex;
  152. ULONG Flags;
  153. PNET80211_KEY Keys[NET80211_MAX_KEY_COUNT];
  154. PVOID ApRsn;
  155. PVOID StationRsn;
  156. } NET80211_ENCRYPTION, *PNET80211_ENCRYPTION;
  157. /*++
  158. Structure Description:
  159. This structure defines an available BSS that is within range of the 802.11
  160. wireless device.
  161. Members:
  162. ListEntry - Stores pointers to the next and previous BSS entries.
  163. ReferenceCount - Stores the reference count on the BSS entry.
  164. LastUpdated - Stores the time counter value of when the BSS entry was last
  165. seen by a scan or beacon.
  166. State - Stores the BSS state.
  167. Encryption - Stores the encryption information for the BSS including the
  168. active keys.
  169. EapolHandle - Stores a pointer to the encryption handshake handle.
  170. Elements - Stores a pointer to the information elements for the BSS
  171. supplied by either a beacon or probe response.
  172. ElementsSize - Stores the size of the information elements in bytes.
  173. Flags - Stores a bitmask of flags describing the BSS entry. See
  174. NET80211_BSS_FLAG_* for definitions.
  175. Ssid - Stores the SSID element for the BSS. This is a pointer to the SSID
  176. element within the information elements buffer.
  177. PassphraseLength - Stores the number of characters in the passphrase.
  178. Passphrase - Stores the passphrase for the BSS.
  179. --*/
  180. typedef struct _NET80211_BSS_ENTRY {
  181. LIST_ENTRY ListEntry;
  182. volatile ULONG ReferenceCount;
  183. ULONGLONG LastUpdated;
  184. NET80211_BSS State;
  185. NET80211_ENCRYPTION Encryption;
  186. HANDLE EapolHandle;
  187. PVOID Elements;
  188. ULONG ElementsSize;
  189. ULONG Flags;
  190. PVOID Ssid;
  191. ULONG PassphraseLength;
  192. UCHAR Passphrase[NET80211_MAX_PASSPHRASE_LENGTH];
  193. } NET80211_BSS_ENTRY, *PNET80211_BSS_ENTRY;
  194. /*++
  195. Structure Description:
  196. This structure defines link information that is private to the 802.11 core.
  197. Members:
  198. NetworkLink - Stores a pointer to the networking core's link context.
  199. ReferenceCount - Stores the reference count of the link.
  200. State - Stores the current state of the 802.11 link.
  201. ProbePreviousState - Stores the state before the 802.11 link started
  202. probing.
  203. ProbeNextState - Stores the state that the 802.11 link should transition to
  204. after leaving the probe state.
  205. Flags - Stores a bitmask of flags describing the link.
  206. See NET80211_LINK_FLAG_* for definitions.
  207. SequenceNumber - Stores the current sequence for the 802.11 link.
  208. Lock - Stores a pointer to a queued lock that synchronizes access to the
  209. 802.11 link structure.
  210. ScanLock - Stores a pointer to a queued lock that synchronizes network
  211. scans. A scan is triggered before a network is ever joined, so this
  212. protects the link from joining a network while it's already in the
  213. middle of a scan.
  214. StateTimer - Stores a pointer to a timer used to monitor state transitions.
  215. TimeoutDpc- Stores a pointer to a DPC that is executed when the state timer
  216. expires.
  217. TimeoutWorkItem - Stores a pointer to a low level work item queued by the
  218. DPC on state transition timeouts.
  219. BssList - Stores a list of BSSs that are within range of this 802.11 device.
  220. ActiveBss - Stores a pointer to the BSS to which the link is attempting to
  221. connect or is already connected.
  222. PausedPacketList - Stores a list of paused 802.11 packets that are ready
  223. for transmission.
  224. Properites - Stores the 802.11 link properties.
  225. --*/
  226. struct _NET80211_LINK {
  227. PNET_LINK NetworkLink;
  228. volatile ULONG ReferenceCount;
  229. NET80211_STATE State;
  230. NET80211_STATE ProbePreviousState;
  231. NET80211_STATE ProbeNextState;
  232. ULONG Flags;
  233. volatile ULONG SequenceNumber;
  234. PQUEUED_LOCK Lock;
  235. PQUEUED_LOCK ScanLock;
  236. PKTIMER StateTimer;
  237. PDPC TimeoutDpc;
  238. PWORK_ITEM TimeoutWorkItem;
  239. LIST_ENTRY BssList;
  240. PNET80211_BSS_ENTRY ActiveBss;
  241. NET_PACKET_LIST PausedPacketList;
  242. NET80211_LINK_PROPERTIES Properties;
  243. };
  244. //
  245. // -------------------------------------------------------------------- Globals
  246. //
  247. //
  248. // -------------------------------------------------------- Function Prototypes
  249. //
  250. VOID
  251. Net80211pProcessManagementFrame (
  252. PNET80211_LINK Link,
  253. PNET_PACKET_BUFFER Packet
  254. );
  255. /*++
  256. Routine Description:
  257. This routine processes 802.11 management frames.
  258. Arguments:
  259. Link - Supplies a pointer to the 802.11 link on which the frame arrived.
  260. Packet - Supplies a pointer to the network packet.
  261. Return Value:
  262. None.
  263. --*/
  264. KSTATUS
  265. Net80211pStartScan (
  266. PNET80211_LINK Link,
  267. PNET80211_SCAN_STATE Parameters
  268. );
  269. /*++
  270. Routine Description:
  271. This routine starts a scan for one or more BSSs within range of this
  272. station.
  273. Arguments:
  274. Link - Supplies a pointer to the link on which to perform the scan.
  275. Parameters - Supplies a pointer to a scan state used to initialize the
  276. scan. This memory will not be referenced after the function returns,
  277. so this may be a stack allocated structure.
  278. Return Value:
  279. Status code.
  280. --*/
  281. VOID
  282. Net80211pSetState (
  283. PNET80211_LINK Link,
  284. NET80211_STATE State
  285. );
  286. /*++
  287. Routine Description:
  288. This routine sets the given link's 802.11 state by alerting the driver of
  289. the state change and then performing any necessary actions based on the
  290. state transition.
  291. Arguments:
  292. Link - Supplies a pointer to the 802.11 link whose state is being updated.
  293. State - Supplies the state to which the link is transitioning.
  294. Return Value:
  295. None.
  296. --*/
  297. PNET80211_BSS_ENTRY
  298. Net80211pGetBss (
  299. PNET80211_LINK Link
  300. );
  301. /*++
  302. Routine Description:
  303. This routine gets the link's active BSS entry and hands back a pointer with
  304. a reference to the caller.
  305. Arguments:
  306. Link - Supplies a pointer to the 802.11 link whose active BSS is to be
  307. returned.
  308. Return Value:
  309. Returns a pointer to the active BSS.
  310. --*/
  311. VOID
  312. Net80211pBssEntryAddReference (
  313. PNET80211_BSS_ENTRY BssEntry
  314. );
  315. /*++
  316. Routine Description:
  317. This routine increments the reference count of the given BSS entry.
  318. Arguments:
  319. BssEntry - Supplies a pointer to the BSS entry whose reference count is to
  320. be incremented.
  321. Return Value:
  322. None.
  323. --*/
  324. VOID
  325. Net80211pBssEntryReleaseReference (
  326. PNET80211_BSS_ENTRY BssEntry
  327. );
  328. /*++
  329. Routine Description:
  330. This routine decrements the reference count of the given BSS entry,
  331. destroying the entry if there are no more references.
  332. Arguments:
  333. BssEntry - Supplies a pointer to the BSS entry whose reference count is to
  334. be decremented.
  335. Return Value:
  336. None.
  337. --*/
  338. KSTATUS
  339. Net80211pQueueStateTransitionTimer (
  340. PNET80211_LINK Link,
  341. ULONGLONG Timeout
  342. );
  343. /*++
  344. Routine Description:
  345. This routine queues the given network link's state transition timer.
  346. Arguments:
  347. Link - Supplies a pointer to a 802.11 link.
  348. Timeout - Supplies the desired timeout in microseconds.
  349. Return Value:
  350. Status code.
  351. --*/
  352. VOID
  353. Net80211pCancelStateTransitionTimer (
  354. PNET80211_LINK Link
  355. );
  356. /*++
  357. Routine Description:
  358. This routine cancels the given link's state transition timer if it is
  359. queued.
  360. Arguments:
  361. Link - Supplies a pointer to the 802.11 link whose state transition timer
  362. shall be canceled.
  363. Return Value:
  364. None.
  365. --*/
  366. VOID
  367. Net80211pStateTimeoutDpcRoutine (
  368. PDPC Dpc
  369. );
  370. /*++
  371. Routine Description:
  372. This routine implements the 802.11 state transition timeout DPC that gets
  373. called after a remote node does not respond to a management frame.
  374. Arguments:
  375. Dpc - Supplies a pointer to the DPC that is running.
  376. Return Value:
  377. None.
  378. --*/
  379. VOID
  380. Net80211pStateTimeoutWorker (
  381. PVOID Parameter
  382. );
  383. /*++
  384. Routine Description:
  385. This routine performs the low level work when an 802.11 state transition
  386. times out due to a remote node not responding.
  387. Arguments:
  388. Parameter - Supplies a pointer to the nework link whose 802.11 state
  389. transition has timed out.
  390. Return Value:
  391. None.
  392. --*/
  393. PNET80211_BSS_ENTRY
  394. Net80211pLookupBssEntry (
  395. PNET80211_LINK Link,
  396. PUCHAR Bssid
  397. );
  398. /*++
  399. Routine Description:
  400. This routine searches the link for a known BSS entry with the given BSSID.
  401. It does not take a reference on the BSS entry and assumes that the link's
  402. lock is already held.
  403. Arguments:
  404. Link - Supplies a pointer to the 802.11 link on which to search.
  405. Bssid - Supplies a pointer to the BSSID for the desired BSS entry.
  406. Return Value:
  407. Returns a pointer to the matching BSS entry on success, or NULL on failure.
  408. --*/
  409. VOID
  410. Net80211pProcessControlFrame (
  411. PNET80211_LINK Link,
  412. PNET_PACKET_BUFFER Packet
  413. );
  414. /*++
  415. Routine Description:
  416. This routine processes an 802.11 control frame.
  417. Arguments:
  418. Link - Supplies a pointer to the 802.11 link on which the frame arrived.
  419. Packet - Supplies a pointer to the network packet.
  420. Return Value:
  421. None.
  422. --*/
  423. KSTATUS
  424. Net80211pSendDataFrames (
  425. PNET80211_LINK Link,
  426. PNET_PACKET_LIST PacketList,
  427. PNETWORK_ADDRESS SourcePhysicalAddress,
  428. PNETWORK_ADDRESS DestinationPhysicalAddress,
  429. ULONG ProtocolNumber
  430. );
  431. /*++
  432. Routine Description:
  433. This routine adds 802.2 SAP headers and 802.11 data frame headers to the
  434. given packets and sends them down the the device link layer.
  435. Arguments:
  436. Link - Supplies a pointer to the 802.11 link on which to send the data.
  437. PacketList - Supplies a pointer to a list of network packets to send. Data
  438. in these packets may be modified by this routine, but must not be used
  439. once this routine returns.
  440. SourcePhysicalAddress - Supplies a pointer to the source (local) physical
  441. network address.
  442. DestinationPhysicalAddress - Supplies the optional physical address of the
  443. destination, or at least the next hop. If NULL is provided, then the
  444. packets will be sent to the data link layer's broadcast address.
  445. ProtocolNumber - Supplies the protocol number of the data inside the data
  446. link header.
  447. Return Value:
  448. Status code.
  449. --*/
  450. VOID
  451. Net80211pProcessDataFrame (
  452. PNET80211_LINK Link,
  453. PNET_PACKET_BUFFER Packet
  454. );
  455. /*++
  456. Routine Description:
  457. This routine processes an 802.11 data frame.
  458. Arguments:
  459. Link - Supplies a pointer to the 802.11 link on which the frame arrived.
  460. Packet - Supplies a pointer to the network packet.
  461. Return Value:
  462. None.
  463. --*/
  464. VOID
  465. Net80211pPauseDataFrames (
  466. PNET80211_LINK Link
  467. );
  468. /*++
  469. Routine Description:
  470. This routine pauses the outgoing data frame traffic on the given network
  471. link. It assumes that the 802.11 link's queued lock is held.
  472. Arguments:
  473. Link - Supplies a pointer to the 802.11 link on which to pause the outgoing
  474. data frames.
  475. Return Value:
  476. None.
  477. --*/
  478. VOID
  479. Net80211pResumeDataFrames (
  480. PNET80211_LINK Link
  481. );
  482. /*++
  483. Routine Description:
  484. This routine resumes the outgoing data frame traffic on the given network
  485. link, flushing any packets that were held while the link was paused. It
  486. assumes that the 802.11 link's queued lock is held.
  487. Arguments:
  488. Link - Supplies a pointer to the 802.11 link on which to resume the
  489. outgoing data frames.
  490. Return Value:
  491. None.
  492. --*/
  493. ULONG
  494. Net80211pGetSequenceNumber (
  495. PNET80211_LINK Link
  496. );
  497. /*++
  498. Routine Description:
  499. This routine returns the sequence number to use for the given link.
  500. Arguments:
  501. Link - Supplies a pointer to the 802.11 link whose sequence number is
  502. requested.
  503. Return Value:
  504. Returns the sequence number to use for the given link.
  505. --*/
  506. KSTATUS
  507. Net80211pSetChannel (
  508. PNET80211_LINK Link,
  509. ULONG Channel
  510. );
  511. /*++
  512. Routine Description:
  513. This routine sets the 802.11 link's channel to the given value.
  514. Arguments:
  515. Link - Supplies a pointer to the 802.11 link whose channel is being updated.
  516. Channel - Supplies the channel to which the link should be set.
  517. Return Value:
  518. Status code.
  519. --*/
  520. VOID
  521. Net80211pDestroyKey (
  522. PNET80211_KEY Key
  523. );
  524. /*++
  525. Routine Description:
  526. This routine destroys the given 802.11 encryption key.
  527. Arguments:
  528. Key - Supplies a pointer to the key to be destroyed.
  529. Return Value:
  530. None.
  531. --*/
  532. KSTATUS
  533. Net80211pInitializeEncryption (
  534. PNET80211_LINK Link,
  535. PNET80211_BSS_ENTRY Bss
  536. );
  537. /*++
  538. Routine Description:
  539. This routine initializes the 802.11 core to handle the completion of an
  540. advanced encryption handshake.
  541. Arguments:
  542. Link - Supplies a pointer to the 802.11 link establishing an ecrypted
  543. connection.
  544. Bss - Supplies a pointer to the BSS on which the encryption handshake will
  545. take place.
  546. Return Value:
  547. Status code.
  548. --*/
  549. VOID
  550. Net80211pDestroyEncryption (
  551. PNET80211_BSS_ENTRY Bss
  552. );
  553. /*++
  554. Routine Description:
  555. This routine destroys the context used to handle encryption initialization.
  556. It is not necessary to keep this context once the encrypted state is
  557. reached.
  558. Arguments:
  559. Bss - Supplies a pointer to the BSS on which encryption initialization took
  560. place.
  561. Return Value:
  562. None.
  563. --*/
  564. KSTATUS
  565. Net80211pEncryptPacket (
  566. PNET80211_LINK Link,
  567. PNET80211_BSS_ENTRY Bss,
  568. PNET_PACKET_BUFFER Packet
  569. );
  570. /*++
  571. Routine Description:
  572. This routine encrypts the given network packet's plaintext data. The
  573. supplied packet buffer is modified directly and should already include the
  574. full MPDU (i.e. the 802.11 headers should be present).
  575. Arguments:
  576. Link - Supplies a pointer to the 802.11 network link that owns the packet.
  577. Bss - Supplies a pointer to the BSS over which this packet should be sent.
  578. Packet - Supplies a pointer to the packet to encrypt.
  579. Return Value:
  580. Status code.
  581. --*/
  582. KSTATUS
  583. Net80211pDecryptPacket (
  584. PNET80211_LINK Link,
  585. PNET80211_BSS_ENTRY Bss,
  586. PNET_PACKET_BUFFER Packet
  587. );
  588. /*++
  589. Routine Description:
  590. This routine decrypts the given network packet's ciphertext. The supplied
  591. packet buffer is modified directly and should contain the full encrypted
  592. MPDU, including the 802.11 headers.
  593. Arguments:
  594. Link - Supplies a pointer to the 802.11 network link that owns the packet.
  595. Bss - Supplies a pointer to the BSS over which this packet was received.
  596. Packet - Supplies a pointer to the packet to decrypt.
  597. Return Value:
  598. Status code.
  599. --*/
  600. KSTATUS
  601. Net80211pEapolInitialize (
  602. VOID
  603. );
  604. /*++
  605. Routine Description:
  606. This routine initializes support for EAPOL packets.
  607. Arguments:
  608. None.
  609. Return Value:
  610. Status code.
  611. --*/
  612. VOID
  613. Net80211pEapolDestroy (
  614. VOID
  615. );
  616. /*++
  617. Routine Description:
  618. This routine tears down support for EAPOL packets.
  619. Arguments:
  620. None.
  621. Return Value:
  622. None.
  623. --*/
  624. KSTATUS
  625. Net80211pNetlinkInitialize (
  626. VOID
  627. );
  628. /*++
  629. Routine Description:
  630. This routine initializes the generic netlink 802.11 family.
  631. Arguments:
  632. None.
  633. Return Value:
  634. Status code.
  635. --*/
  636. VOID
  637. Net80211pNetlinkDestroy (
  638. VOID
  639. );
  640. /*++
  641. Routine Description:
  642. This routine tears down support for the generic netlink 802.11 family.
  643. Arguments:
  644. None.
  645. Return Value:
  646. None.
  647. --*/