Closed Ernst79 closed 7 months ago
All modified and coverable lines are covered by tests :white_check_mark:
Comparison is base (
6f9969e
) 79.47% compared to head (e2916fb
) 79.96%. Report is 1 commits behind head on main.
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
In the future, I think we should not allow duplicate messages to be delivered to the client though. That could allow the client to operate on a replayed message. This is important for messages that convey an action, like a button press. Allowing the same button press to be received by the client more than once would have unintentional side-effects.
Feedback is always welcome, I do appreciate that. I know that Xiaomi is sending multiple messages that are exactly the same. If the counter is the same, the message is the same, by definition.
In BLE monitor, I programmed it such that if the counter is the same as the counter in the previous message, it skips the message. I think it makes sense to do the same for BTHome. E.g.
I'll fix the other comments later
ToDo
@esev Could you do another check of this PR? I think it is finished.
Add a check to verify that the encryption counter is increasing compared to the previous value #20