S115 SoftDevice for nRF54LS05 API documentation 10.0.0
Loading...
Searching...
No Matches

◆ sd_ble_gap_lesc_dhkey_reply()

uint32_t sd_ble_gap_lesc_dhkey_reply ( uint16_t conn_handle,
uint8_t sec_status,
ble_gap_lesc_dhkey_t const * p_dhkey )

#include <ble_gap.h>

Reply with an LE Secure connections DHKey.

This function is only used to reply to a BLE_GAP_EVT_LESC_DHKEY_REQUEST, calling it at other times will result in an NRF_ERROR_INVALID_STATE.

Note
Application is required to validate ble_gap_evt_lesc_dhkey_request_t::p_pk_peer received in BLE_GAP_EVT_LESC_DHKEY_REQUEST according to Bluetooth Core Specification, Vol 3, Part H, Section 2.3.5.6.1.
Events generated
This function is used during authentication procedures, see the list of events in the documentation of sd_ble_gap_authenticate.
Relevant Message Sequence Charts
Peripheral LESC Pairing: Just Works
Peripheral LESC Bonding: Numeric Comparison
Peripheral LESC Bonding: Passkey Entry, Peripheral Displays
Peripheral LESC Bonding: Passkey Entry, User Inputs on Peripheral
Peripheral LESC Bonding: Out of Band
Parameters
[in]conn_handleConnection handle.
[in]sec_statusSecurity status, see GAP Security status
[in]p_dhkeyLE Secure Connections DHKey. This parameter is ignored if sec_status is not set to BLE_GAP_SEC_STATUS_SUCCESS.
Return values
NRF_SUCCESSDHKey successfully set.
NRF_ERROR_INVALID_ADDRInvalid pointer supplied.
NRF_ERROR_INVALID_PARAMInvalid parameter(s) supplied.
NRF_ERROR_INVALID_STATEInvalid state to perform operation. Either:
BLE_ERROR_INVALID_CONN_HANDLEInvalid connection handle supplied.