次の方法で共有


Dot11ExtSetDefaultKeyId (Compact 2013)

3/26/2014

The IHV Extensions DLL calls this function to set the table index of the default or per-station cipher key with which the wireless LAN (WLAN) adapter uses by default when encrypting transmitted packet data.

Syntax

DWORD WINAPI  Dot11ExtSetDefaultKeyId(
    HANDLE  hDot11SvcHandle,
    ULONG  uDefaultKeyId
);

Parameters

  • hDot11SvcHandle
    [in] The handle that is used by the operating system to reference the WLAN adapter. This handle value was specified through a previous call to the Dot11ExtIhvInitAdapter IHV Handler function.
  • uDefaultKeyId
    [in] The index value of the key within the adapter’s default or per-station cipher key tables.

    For standard 802.11 cipher algorithms, such as WEP or TKIP, uDefaultKeyId must be from 0 through 3. For a proprietary cipher algorithm developed by an IHV, uDefaultKeyId can be any value within the IHV-defined range.

Return Value

If the call succeeds, the function returns ERROR_SUCCESS. Otherwise, it returns an error code defined in Winerror.h.

Remarks

The default key identifier (ID) specifies the index of a cipher key in the adapter’s default key and per-station default key tables that the adapter uses for data encryption. The adapter uses the cipher key referenced by the default key ID as the default encryption key for transmitted packets unless a key-mapping key exists for the destination media access control (MAC) address.

A call to the Dot11ExtSetDefaultKeyId function results in a set request of the OID_DOT11_CIPHER_DEFAULT_KEY_ID object identifier (OID) to the Native 802.11 miniport driver. This manages the WLAN adapter.

Requirements

Header

wlanihv.h

See Also

Reference

Native 802.11 IHV Extensibility Functions
Dot11ExtIhvInitAdapter
OID_DOT11_CIPHER_DEFAULT_KEY_ID
Native 802.11 IHV Extensions DLL