Redundant epoch check in dtls_get_bitmap? #23555
Replies: 1 comment 1 reply
-
I think this check ( Things work differently since I refactored the record layer (implemented in 3.2). Prior to that there was one queue of unprocessed records. If you got a record destined for the next epoch you would queue it. When swapping epoch's the first thing you would do is empty the unprocessed records that we'd previously queued and reinject them into the new "current" epoch. In that context this comment makes perfect sense - basically we shouldn't queue new unprocessed records if we haven't finished transferring all the old ones into the current epoch. After the record layer refactor each epoch has a different record layer object - and each record layer object has its own unprocessed records queue. There will never be records in this queue that are "leftover" from the previous epoch and haven't been transferred yet. |
Beta Was this translation helpful? Give feedback.
-
Doesn't the check
rl->unprocessed_rcds.epoch != rl->epoch
always evaluate true?openssl/ssl/record/methods/dtls_meth.c
Lines 92 to 100 in 925118e
From the comment it seems more correct to check
pqueue_size(rl->unprocessed_rcds.q) == 0
?Beta Was this translation helpful? Give feedback.
All reactions