Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GattCharacteristic.ProtectionLevel fails #2473

Open
corby opened this issue Jul 29, 2024 · 2 comments
Open

GattCharacteristic.ProtectionLevel fails #2473

corby opened this issue Jul 29, 2024 · 2 comments
Assignees
Labels
Pri3 Topic is in the bottom 50% of page views for the repo or was not created via Feedback control.

Comments

@corby
Copy link

corby commented Jul 29, 2024

I have a BLE device that has several services including one custom service with 2 characteristics.
The CHARs are setup as RX/TX. The RX CHAR receives commands and the TX CHAR sends responses using NOTIFY.
Everything works fine using BluetoothLEDevice to connect and read.
I can also configure the CCCD on the standard CHARs to send nodifications.

Here's the problem:
The custom TX CHAR has AUTHENTICATION_REQUIRED set on the CCCDescriptor.
So when I call. WriteClientCharacteristicConfigurationDescriptorAsync I get an AccessDenied error and a message saying I need to enable Authentication before writing to this attribute.

I've tried the following:

  • DeviceInformationPairing.PairingAsync - Doesn't do anything. protection level set to PLAIN.
  • Custom Pairing - ConfirmOnly with handler. Nothing. Protection level == PLAIN
  • Scan and read in all Chars and set ProtectionLevel.AuthenticationRequired. When I write the CCCD after this I get an UNREACHABLE error

I'm at a loss on how to get this device to read using windows (Linux DBus, MacOSX CoreDevice, and nRF softdevice have no issues)

I'm using python with winrt bindings

@issues-automation issues-automation bot added the Pri3 Topic is in the bottom 50% of page views for the repo or was not created via Feedback control. label Jul 29, 2024
@stevewhims
Copy link
Member

Thanks, @corby, I've pinged the product team subject-matter experts for help.

-Steve

@stevewhims
Copy link
Member

Can you give us more information on what's meant by “doing nothing”, as in exactly how are you calling the pairing APIs and how is it failing?

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Pri3 Topic is in the bottom 50% of page views for the repo or was not created via Feedback control.
Projects
None yet
Development

No branches or pull requests

2 participants