BT_SSP_AUTHENTICATION_COMPLETED_EVENT (Compact 2013)
3/26/2014
This structure contains event data for the BTE_SSP_AUTHENTICATION_COMPLETED event.
Syntax
typedef struct BT_SSP_AUTHENTICATION_COMPLETED_EVENT {
DWORD Result;
} BT_SSP_AUTHENTICATION_COMPLETED_EVENT;
Members
- Result
Result of the authentication attempt. 0x00 if authentication was successful; otherwise, an appropriate Bluetooth error code.
Remarks
This structure is the AuthenticationCompleted member of the BTSSPEvent structure. It is present in the union in BTSSPEvent when BTSSPEvent.BTECode is set to BTE_SSP_AUTHENTICATION_COMPLETED.
Example
The following C code shows how to access this structure.
Important
For readability, the following code example does not contain security checking or error handling. Do not use the following code in a production environment.
BTEVENT event;
// Insert code to retrieve event from message queue.
ASSERT(event.dwEventId == BTE_SSP_AUTHENTICATION_COMPLETED);
BTSSPEvent *pSSPEventData = (BTSSPEvent *) event.baEventData;
BT_SSP_AUTHENTICATION_COMPLETED_EVENT authEventData =
pSSPEventData->AuthenticationCompleted;
The event associated with this structure is generated when the authentication process ends, whether the connection was successfully authenticated or not. If the Result member of this structure (authEventData.Reason
in the above code) is 0x00, the connection was successfully authenticated.
Although the name of this structure and its associated event includes "SSP" (for Secure Simple Pairing), the BTE_SSP_AUTHENTICATION_COMPLETED event is also generated for legacy personal identification number (PIN) pairing.
The application is only notified of this event if it is registered to receive BTE_CLASS_SSP events, by using RequestBluetoothNotifications or BthSSPRequestNotifications.
Requirements
Header |
bt_api.h |
See Also
Reference
Bluetooth Application Development Structures
BT_SSP_PAIRING_COMPLETE_EVENT
RequestBluetoothNotifications
StopBluetoothNotifications
Bluetooth Application Development Events