bluedroid: support oob pairing for smp secure connection

This commit is contained in:
chenjianhua
2022-12-07 12:15:25 +08:00
parent 7d7a710b60
commit 2048322429
20 changed files with 437 additions and 43 deletions

View File

@@ -1765,6 +1765,7 @@ typedef union {
#if BLE_INCLUDED == TRUE && SMP_INCLUDED == TRUE
tBTM_LE_COMPLT complt; /* BTM_LE_COMPLT_EVT */
tSMP_OOB_DATA_TYPE req_oob_type;
tSMP_LOC_OOB_DATA local_oob_data;
#endif
tBTM_LE_KEY key;
} tBTM_LE_EVT_DATA;

View File

@@ -1809,6 +1809,29 @@ void BTM_BleConfirmReply (BD_ADDR bd_addr, UINT8 res);
//extern
void BTM_BleOobDataReply(BD_ADDR bd_addr, UINT8 res, UINT8 len, UINT8 *p_data);
/*******************************************************************************
**
** Function BTM_BleSecureConnectionOobDataReply
**
** Description This function is called to provide the OOB data for
** SMP in response to BTM_LE_SC_OOB_REQ_EVT when secure connection
**
** Parameters: bd_addr - Address of the peer device
** p_c - pointer to Confirmation
** p_r - pointer to Randomizer
**
*******************************************************************************/
void BTM_BleSecureConnectionOobDataReply(BD_ADDR bd_addr, UINT8 *p_c, UINT8 *p_r);
/*******************************************************************************
**
** Function BTM_BleSecureConnectionCreateOobData
**
** Description This function is called to create the OOB data for
** SMP when secure connection
**
*******************************************************************************/
void BTM_BleSecureConnectionCreateOobData(void);
/*******************************************************************************
**

View File

@@ -498,13 +498,9 @@ extern void SMP_KeypressNotification (BD_ADDR bd_addr, UINT8 value);
** Description This function is called to start creation of local SC OOB
** data set (tSMP_LOC_OOB_DATA).
**
** Parameters: bd_addr - Address of the device to send OOB data block
** to.
**
** Returns Boolean - TRUE: creation of local SC OOB data set started.
*******************************************************************************/
extern BOOLEAN SMP_CreateLocalSecureConnectionsOobData (
tBLE_BD_ADDR *addr_to_send_to);
extern BOOLEAN SMP_CreateLocalSecureConnectionsOobData (void);
#ifdef __cplusplus
}