Skip to content

Commit

Permalink
Skip bytes on Decode cancel to avoid exploiting
Browse files Browse the repository at this point in the history
  • Loading branch information
linsaftw committed Mar 9, 2021
1 parent c67a63e commit 3c605b3
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ protected void decode(final ChannelHandlerContext channelHandlerContext, final B

if (!event.isCancelled()) {
list.add(bytebuf.readBytes(bytebuf.readableBytes()));
} else {
bytebuf.skipBytes(bytebuf.readableBytes());
}
}
}

0 comments on commit 3c605b3

Please sign in to comment.