Passkey/password pairing with BLE with NimBLE stack
Posted: Thu Feb 24, 2022 4:13 pm
Hello,
I have the following problem. I have a BLE device based on ESP32. It does not have input or output capabilities. I am using ESP-IDF and the NimBLE stack.
I want to do password authentication as follows:
1. User pairs to the ESP32 device from a smartphone app.
2. User generates a passkey or password and sends it to the ESP32 device, which in turn sets it as a password for pairing.
3. The next time a user wants to connect, the ESP32 device sends him a request for password.
4. If he enters the correct password, he pairs to the device. If not, he cannot pair.
I found this sample project - https://github.com/espressif/esp-idf/tr ... ity_server, but it's for Bluedroid and not quite what I need, at first glance.
Is this possible with the NimBLE stack and is there example code for this scenario?
I have the following problem. I have a BLE device based on ESP32. It does not have input or output capabilities. I am using ESP-IDF and the NimBLE stack.
I want to do password authentication as follows:
1. User pairs to the ESP32 device from a smartphone app.
2. User generates a passkey or password and sends it to the ESP32 device, which in turn sets it as a password for pairing.
3. The next time a user wants to connect, the ESP32 device sends him a request for password.
4. If he enters the correct password, he pairs to the device. If not, he cannot pair.
I found this sample project - https://github.com/espressif/esp-idf/tr ... ity_server, but it's for Bluedroid and not quite what I need, at first glance.
Is this possible with the NimBLE stack and is there example code for this scenario?