DOT11EXT_SET_DEFAULT_KEY_ID - NtDoc

Native API online documentation, based on the System Informer (formerly Process Hacker) phnt headers
// wlanihv.h

DOT11EXT_SET_DEFAULT_KEY_ID Dot11extSetDefaultKeyId;

DWORD Dot11extSetDefaultKeyId(
  [in, optional] HANDLE hDot11SvcHandle,
  [in]           ULONG uDefaultKeyId
)
{...}
View the official Windows Driver Kit DDI reference

NtDoc

No description available.

Windows Driver Kit DDI reference (nc-wlanihv-dot11ext_set_default_key_id)

DOT11EXT_SET_DEFAULT_KEY_ID callback

Description

Important The Native 802.11 Wireless LAN interface is deprecated in Windows 10 and later. Please use the WLAN Device Driver Interface (WDI) instead. For more information about WDI, see WLAN Universal Windows driver model.

The IHV Extensions DLL calls the Dot11ExtSetDefaultKeyId 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.

Parameters

hDot11SvcHandle [in, optional]

The handle 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 range defined by the IHV.

Return value

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

Prototype

DWORD WINAPI * Dot11ExtSetDefaultKeyId(
  _In_opt_ HANDLE hDot11SvcHandle,
  _In_     ULONG  uDefaultKeyId
);

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. For more information about these cipher key types, see 802.11 Cipher Key Types.

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, which manages the WLAN adapter.

See also

OID_DOT11_CIPHER_DEFAULT_KEY_ID

Dot11ExtIhvInitAdapter

802.11 Cipher Key Types