[fuzzer] Add Huffman decompression fuzzer#2784
Merged
terrelln merged 1 commit intofacebook:devfrom Sep 20, 2021
Merged
Conversation
Contributor
|
For some reason, github doesn't let us select only the 2nd commit to see |
Contributor
Author
|
Strange... Well once I figure out this compiler error, I'll merge the first PR. |
Add a fuzzer for Huffman decompression. Fix several bugs in Huffman decompression, mostly related to `op == NULL` and pointer underflow.
3c4b720 to
d7542aa
Compare
Cyan4973
approved these changes
Sep 20, 2021
terrelln
added a commit
to terrelln/zstd
that referenced
this pull request
Sep 27, 2021
PR facebook#2784 introduced a bug in the decompressor that caused some valid inputs to fail to decompress. The bitstream isn't reloaded after the 4X* loop if the number of elements remaining is small enough, causing us to read more bits than are available in the bitcontainer. This was caught by the MSAN fuzzer in OSS-Fuzz because the assembly implementation isn't used in the MSAN build. Credit to OSS-Fuzz.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add a fuzzer for Huffman decompression. Fix several bugs in Huffman
decompression, mostly related to
op == NULLand pointer underflow.Note: Review only the 2nd commit. The first is from PR #2783, and will disappear after it is merged.