Share via


BT_SSP_USER_CONFIRMATION_REQUEST_EVENT (Compact 7)

3/12/2014

This structure contains event data for the BT_SSP_USER_CONFIRMATION_REQUEST event.

Syntax

typedef struct BT_SSP_USER_CONFIRMATION_REQUEST_EVENT {
    UINT NumericValue;
} BT_SSP_USER_CONFIRMATION_REQUEST_EVENT;

Members

  • NumericValue
    A randomly generated, six decimal-digit passkey to be compared by the user on both the local and remote Bluetooth devices.

Remarks

The BTE_SSP_USER_CONFIRMATION_REQUEST event provides the randomly generated passkey for display to, and confirmation from, the user.

When the application receives the event associated with this structure, it must display the provided passkey (six decimal digits) to the user. The Bluetooth peer device will also display a passkey.

The user either accepts the passkeys as matching, which indicates that pairing should continue, or rejects them as nonmatching, which indicates that pairing should not continue. The application calls BthSSPUserConfirmationRequestReply or BthSSPAbortPairing accordingly.

If the application is not capable of displaying the passkey to the user, it calls BthSSPUserConfirmationRequestReply. See that function for details.

This structure is the UserConfirmationRequest member of the BTSSPEvent structure. It is present in the union in BTSSPEvent when BTSSPEvent.BTECode is set to BTE_SSP_USER_CONFIRMATION_REQUEST.

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_USER_CONFIRMATION_REQUEST);
BTSSPEvent *pSSPEventData = (BTSSPEvent *) event.baEventData;
BT_SSP_USER_CONFIRMATION_REQUEST_EVENT confirmEventData =
  pSSPEventData->UserConfirmationRequest;

Requirements

Header

bt_api.h

See Also

Reference

Bluetooth Application Development Structures
BTSecurityLevel
RequestBluetoothNotifications
StopBluetoothNotifications
Bluetooth Application Development Events