Skip to content

Commit

Permalink
Merge branch 'bugfix/reset_irk_when_all_unpair_v5.1' into 'release/v5.1'
Browse files Browse the repository at this point in the history
fix(nimble): Fixed BLE security vulnerability when using fixed IRK (v5.1)

See merge request espressif/esp-idf!32158
  • Loading branch information
rahult-github committed Jul 18, 2024
2 parents d65755e + 0095bc4 commit cd4714d
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 1 deletion.
10 changes: 10 additions & 0 deletions components/bt/host/nimble/Kconfig.in
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,16 @@ config BT_NIMBLE_NVS_PERSIST
help
Enable this flag to make bonding persistent across device reboots

config BT_NIMBLE_SMP_ID_RESET
bool "Reset device identity when all bonding records are deleted"
default n
help
There are tracking risks associated with using a fixed or static IRK.
If enabled this option, Bluedroid will assign a new randomly-generated IRK
when all pairing and bonding records are deleted. This would decrease the ability
of a previously paired peer to be used to determine whether a device
with which it previously shared an IRK is within range.

menuconfig BT_NIMBLE_SECURITY_ENABLE
bool "Enable BLE SM feature"
depends on BT_NIMBLE_ENABLED
Expand Down
2 changes: 1 addition & 1 deletion components/bt/host/nimble/nimble
8 changes: 8 additions & 0 deletions components/bt/host/nimble/port/include/esp_nimble_cfg.h
Original file line number Diff line number Diff line change
Expand Up @@ -889,6 +889,14 @@
#define MYNEWT_VAL_BLE_SM_THEIR_KEY_DIST (0)
#endif

#ifndef MYNEWT_VAL_BLE_SMP_ID_RESET
#ifdef CONFIG_BT_NIMBLE_SMP_ID_RESET
#define MYNEWT_VAL_BLE_SMP_ID_RESET CONFIG_BT_NIMBLE_SMP_ID_RESET
#else
#define MYNEWT_VAL_BLE_SMP_ID_RESET (0)
#endif
#endif

#ifndef MYNEWT_VAL_BLE_CRYPTO_STACK_MBEDTLS
#define MYNEWT_VAL_BLE_CRYPTO_STACK_MBEDTLS (CONFIG_BT_NIMBLE_CRYPTO_STACK_MBEDTLS)
#endif
Expand Down

0 comments on commit cd4714d

Please sign in to comment.