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
I've searched the existing issues, & I couldn't find one for this bug
Issue
Cipher streaming object (a)finalize calls can be made simultaneously in concurrent contexts, leading to invalid data processing.
Remediation
Utilize ConcurrencyGuard and atomic deque objects to track and allow the first call to (a)finalize while raising IncoherentConcurrencyState for all other calls.
The buffers that are queued to run before the (a)finalize call are allowed to finish, but all buffers queued to run afterwards raise CipherStreamIsClosed.
Is this a new bug in aiootp?
Issue
Cipher streaming object
(a)finalize
calls can be made simultaneously in concurrent contexts, leading to invalid data processing.Remediation
Utilize
ConcurrencyGuard
and atomicdeque
objects to track and allow the first call to(a)finalize
while raisingIncoherentConcurrencyState
for all other calls.aiootp/aiootp/ciphers/cipher_streams.py
Lines 193 to 209 in 1bdbfba
aiootp/aiootp/ciphers/decipher_streams.py
Lines 251 to 266 in 1bdbfba
The buffers that are queued to run before the
(a)finalize
call are allowed to finish, but all buffers queued to run afterwards raiseCipherStreamIsClosed
.aiootp/aiootp/ciphers/cipher_streams.py
Lines 255 to 260 in df07919
aiootp/aiootp/ciphers/decipher_streams.py
Lines 320 to 325 in df07919
Tests were written to ensure the correct exception is raised.
Environment
Additional Context
Refs (bd5cd12)
The text was updated successfully, but these errors were encountered: