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

Function to enable / disable encryption requirements #13

Open
unknownconstant opened this issue Jan 4, 2021 · 0 comments
Open

Function to enable / disable encryption requirements #13

unknownconstant opened this issue Jan 4, 2021 · 0 comments
Milestone

Comments

@unknownconstant
Copy link
Owner

Function to enable and disable encryption requirements as a whole.

The original Arduino BLE library uses uint8_t for characteristic properties, and the new uses the same bits for the properties but changes the type to uint16_t to allow for BLE permissions too. If uint8_t is passed to the new uint16_t then the 8 MSBs may become undefined leading to unpredictable behaviour.

  • Will the compiler catch this to prevent the issue?
  • Does there need to be another location to define permissions? I.e. revert to uint8_t for properties & add new constructor,
  • Use uint16_t as is & add function to prevent encryption / auth checks.

I think the third is the most stable but if the compiler will warn developers putting uint8_t into uint16_t then this doesn’t need to happen.

@unknownconstant unknownconstant added this to the Stable milestone Jan 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant