mirror of
https://github.com/threefoldtech/mycelium.git
synced 2026-10-23 06:01:16 +00:00
Fix message ack bound check
Signed-off-by: Lee Smet <lee.smet@hotmail.com>
This commit is contained in:
2 files changed
+2
-1
No files matched your search
@@ -22,6 +22,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
||||
duplicates to peers.
|
||||
- Make sure the configuration for Quic connections is the same for outbound and
|
||||
inbound connections.
|
||||
- Fix bound check on message ACK.
|
||||
|
||||
## [0.7.4] - 2026-03-23
|
||||
|
||||
|
||||
@@ -359,7 +359,7 @@ where
|
||||
let mc = MessageChunk::new(mp);
|
||||
// Sanity checks. This is just to protect ourselves, if the other party is
|
||||
// malicious it can return any data it wants here.
|
||||
if mc.chunk_idx() > message.chunks.len() as u64 {
|
||||
if mc.chunk_idx() >= message.chunks.len() as u64 {
|
||||
debug!("Dropping CHUNK ACK for message because ACK'ed chunk is out of bounds");
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user