You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Every so often, calls to keepassxc get stuck, which seems to be caused by nonce increment code not matching keepassxc's incremented nonces when multiple bytes need to be incremented
What software is involved?
KeePassXC 2.7.4
Reproduced bug on both Windows and Linux OSes.
Steps to Reproduce
Keep making KeepassXC calls, such as Connection.getLogins() although it can happen with any call that requires a response that needs incremented nonce matching. Most will work, but about 1 in 256 will get stuck and block forever. Debugging it, this seemed to be due to the nonce of KeepassXC's response not matching what Connection.incrementNonce() has calculated it should be.
This happens when the last nonce byte rolls over from 255 to 0. Proxy access's increment code only increments the last byte, but KeepassXC's will increment the next byte (and so on) in this case.
Expected Behavior
Nonce should match and call should work every time.
Actual Behavior
Occasionally calls get stuck and block forever.
Reproducibility
Intermittent
Relevant Log Output
No response
Anything else?
No response
The text was updated successfully, but these errors were encountered:
I wrote a repeating test case in my fork that you might be able to use to reproduce this behaviour. Since the generated nonce is random, I guess there's a 1/256 chance of getting the last byte of the nonce to be 255 which requires the next byte to be incremented.
I also made an additional unit test in another branch for testing just the nonce increment code, but haven't added this to the PR. This is the commit. I can add it if you want.
I also made an additional unit test in another branch for testing just the nonce increment code, but haven't added this to the PR. This is the commit. I can add it if you want.
Thanks, that won't be necessary. I can find the unit test there.
Hopefully I'll find the time to look into this issue within this week, as unfortunately I am quite busy right now.
Please agree to the following
Summary
Every so often, calls to keepassxc get stuck, which seems to be caused by nonce increment code not matching keepassxc's incremented nonces when multiple bytes need to be incremented
What software is involved?
KeePassXC 2.7.4
Reproduced bug on both Windows and Linux OSes.
Steps to Reproduce
Keep making KeepassXC calls, such as
Connection.getLogins()
although it can happen with any call that requires a response that needs incremented nonce matching. Most will work, but about 1 in 256 will get stuck and block forever. Debugging it, this seemed to be due to the nonce of KeepassXC's response not matching whatConnection.incrementNonce()
has calculated it should be.This happens when the last nonce byte rolls over from 255 to 0. Proxy access's increment code only increments the last byte, but KeepassXC's will increment the next byte (and so on) in this case.
Expected Behavior
Nonce should match and call should work every time.
Actual Behavior
Occasionally calls get stuck and block forever.
Reproducibility
Intermittent
Relevant Log Output
No response
Anything else?
No response
The text was updated successfully, but these errors were encountered: