nrf-softdevice-s113

Crates

git

Versions

default

Flavors

pub unsafe fn sd_ble_gap_lesc_oob_data_set(
conn_handle: u16,
p_oobd_own: *const ble_gap_lesc_oob_data_t,
p_oobd_peer: *const ble_gap_lesc_oob_data_t
) -> u32
Expand description

@brief Provide the OOB data sent/received out of band.

@note An authentication procedure with OOB selected as an algorithm must be in progress when calling this function. @note A @ref BLE_GAP_EVT_LESC_DHKEY_REQUEST event with the oobd_req set to 1 must have been received prior to calling this function.

@events @event{This function is used during authentication procedures, see the list of events in the documentation of @ref sd_ble_gap_authenticate.} @endevents

@mscs @mmsc{@ref BLE_GAP_PERIPH_LESC_BONDING_OOB_MSC} @endmscs

@param[in] conn_handle Connection handle. @param[in] p_oobd_own The OOB data sent out of band to a peer or NULL if the peer has not received OOB data. Must correspond to @ref ble_gap_sec_params_t::oob flag in @ref BLE_GAP_EVT_SEC_PARAMS_REQUEST. @param[in] p_oobd_peer The OOB data received out of band from a peer or NULL if none received. Must correspond to @ref ble_gap_sec_params_t::oob flag in @ref sd_ble_gap_sec_params_reply in the peripheral role.

@retval ::NRF_SUCCESS OOB data accepted. @retval ::NRF_ERROR_INVALID_ADDR Invalid pointer supplied. @retval ::NRF_ERROR_INVALID_STATE Invalid state to perform operation. Either: - Authentication key not requested - Not expecting LESC OOB data - Have not actually exchanged passkeys. @retval ::BLE_ERROR_INVALID_CONN_HANDLE Invalid connection handle supplied.