Skip to content

NimBLEClient not processing passkey correctly #115

@projecta98

Description

@projecta98

It appears that NimBLEClient does not process the passkey correctly for the client callback cases.

           ```
          // Compatibility only - Do not use, should be removed the in future
            if(NimBLEDevice::m_securityCallbacks != nullptr) {
                pkey.passkey = NimBLEDevice::m_securityCallbacks->onPassKeyRequest();
            /////////////////////////////////////////////
            } else {
                client->m_pClientCallbacks->onPassKeyRequest(); // <-- bug here , passkey not assigned to anything
            }

The bold line above should be: pkey.passkey = client->m_pClientCallbacks->onPassKeyRequest();

Actually this [revision ](https://github.com/h2zero/NimBLE-Arduino/commit/1aeb2fed80f64a430d26f1537b9f5811fe33a294#diff-8f692c893f6a420d294d6426dcac9a9c) has a better implementation, which for some reason was removed from the master.

My apologies if I am completely off base!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions