diff --git a/subsys/bluetooth/host/classic/Kconfig b/subsys/bluetooth/host/classic/Kconfig index 5c084f03609..3723e117620 100644 --- a/subsys/bluetooth/host/classic/Kconfig +++ b/subsys/bluetooth/host/classic/Kconfig @@ -18,6 +18,15 @@ config BT_CLASSIC This option enables Bluetooth BR/EDR support if BT_CLASSIC +config BT_BR_MIN_ENC_KEY_SIZE + int + prompt "Minimum encryption key size accepted in octets" if !BT_SMP_SC_ONLY + default BT_SMP_MIN_ENC_KEY_SIZE + range 7 16 + help + This option sets the minimum encryption key size accepted during pairing + for classic. + config BT_MAX_SCO_CONN int "Maximum number of simultaneous SCO connections" default 1 diff --git a/subsys/bluetooth/host/classic/br.c b/subsys/bluetooth/host/classic/br.c index 65a0fe80125..afdbb0b1d9e 100644 --- a/subsys/bluetooth/host/classic/br.c +++ b/subsys/bluetooth/host/classic/br.c @@ -141,7 +141,7 @@ static bool br_sufficient_key_size(struct bt_conn *conn) return key_size == BT_HCI_ENCRYPTION_KEY_SIZE_MAX; } - return key_size >= BT_HCI_ENCRYPTION_KEY_SIZE_MIN; + return key_size >= CONFIG_BT_BR_MIN_ENC_KEY_SIZE; } bool bt_br_update_sec_level(struct bt_conn *conn)