ble/security_db.h header reference
[Bluetooth Low Energy library module]
The source code of this header can be browsed online.
Description [link]
This header contains definitions for security database.
Members [link]
Type [link]
- struct ble_security_db_s
Functions [link]
- void ble_security_db_cleanup(struct ble_security_db_s *security_db)
- void ble_security_db_clear(struct ble_security_db_s *security_db)
- bool_t ble_security_db_contains(struct ble_security_db_s *security_db, const struct ble_addr_s *addr)
- uint_fast8_t ble_security_db_count(struct ble_security_db_s *security_db)
- uint_fast8_t ble_security_db_count(struct ble_security_db_s *security_db)
- error_t ble_security_db_init(struct ble_security_db_s *security_db, struct persist_context_s *persist, const char *aes, struct dev_rng_s *rng)
- error_t ble_security_db_load(struct ble_security_db_s *security_db, const struct ble_addr_s *addr, struct ble_peer_s *peer)
- error_t ble_security_db_peer_reconnect_addr_set(struct ble_security_db_s *security_db, uint8_t slot, struct ble_addr_s *addr)
- error_t ble_security_db_remove(struct ble_security_db_s *security_db, uint64_t id)
Members detail [link]
#define BLE_SECURITY_DB_H_ [link]
This macro is declared in ble/security_db.h source file, line 21.
void ble_security_db_cleanup(struct ble_security_db_s *security_db) [link]
This function is declared in ble/security_db.h source file, line 89.
this function releases all context data of cryptography DB.
void ble_security_db_clear(struct ble_security_db_s *security_db) [link]
This function is declared in ble/security_db.h source file, line 125.
this function erases all security_db entries.
Preprocessor condition: defined( CONFIG_BLE_SECURITY_DB )
bool_t ble_security_db_contains(struct ble_security_db_s *security_db, const struct ble_addr_s *addr) [link]
This function is declared in ble/security_db.h source file, line 107.
this function tells whether passed address is known by security database.
Preprocessor condition: defined( CONFIG_BLE_SECURITY_DB )
uint_fast8_t ble_security_db_count(struct ble_security_db_s *security_db) [link]
This function is declared in ble/security_db.h source file, line 114.
this function tells how many entries are populated in the security database. This cannot be more than CONFIG_BLE_SECURITY_DB_MAX.
Alternate declarations with same identifier: [1], [2].
Preprocessor condition: defined( CONFIG_BLE_SECURITY_DB )
uint_fast8_t ble_security_db_count(struct ble_security_db_s *security_db) [link]
This function is declared in ble/security_db.h source file, line 131.
Documentation from alternate declaration:
this function tells how many entries are populated in the security database. This cannot be more than CONFIG_BLE_SECURITY_DB_MAX.
Alternate declarations with same identifier: [1], [2].
Preprocessor condition: not defined( CONFIG_BLE_SECURITY_DB )
error_t ble_security_db_init(struct ble_security_db_s *security_db, struct persist_context_s *persist, const char *aes, struct dev_rng_s *rng) [link]
This function is declared in ble/security_db.h source file, line 84.
this function initializes a peer database lookup context.
Parameter list:
- persist: Path to a DRIVER_CLASS_PERSIST device, can be NULL if Security DB is disabled
error_t ble_security_db_load(struct ble_security_db_s *security_db, const struct ble_addr_s *addr, struct ble_peer_s *peer) [link]
This function is declared in ble/security_db.h source file, line 98.
this function looks up a peer entry by address, either random (using IRK) or public.
Preprocessor condition: defined( CONFIG_BLE_SECURITY_DB )
error_t ble_security_db_peer_reconnect_addr_set(struct ble_security_db_s *security_db, uint8_t slot, struct ble_addr_s *addr) [link]
This function is declared in ble/security_db.h source file, line 101.
Preprocessor condition: defined( CONFIG_BLE_SECURITY_DB )
error_t ble_security_db_remove(struct ble_security_db_s *security_db, uint64_t id) [link]
This function is declared in ble/security_db.h source file, line 120.
this function erases a security_db entry by its number.
Preprocessor condition: defined( CONFIG_BLE_SECURITY_DB )
struct ble_security_db_s [link]
This struct is declared in ble/peer.h source file, line 39.
this struct is a BLE Security database containing data associated to peers. Security DB contains:
local device private key and IRK,
per-peer cryptography parameters negociated during pairing,
per-peer GATT DB subscriptions.
Security DB object always exists, but may, depending on configuration parameters, only handle a volatile context (if CONFIG_BLE_SECURITY_DB is disabled) or no cryptographic operations at all (if CONFIG_BLE_CRYPTO is disabled).