fix invalid read on corrupt ziplist#9831
Merged
oranagra merged 2 commits intoredis:unstablefrom Nov 23, 2021
oranagra:ziplist_invalid_read
Merged
fix invalid read on corrupt ziplist#9831oranagra merged 2 commits intoredis:unstablefrom oranagra:ziplist_invalid_read
oranagra merged 2 commits intoredis:unstablefrom
oranagra:ziplist_invalid_read
Conversation
oranagra
commented
Nov 23, 2021
| start_server [list overrides [list loglevel verbose use-exit-on-panic yes crash-memcheck-enabled no] ] { | ||
| r debug set-skip-checksum-validation 1 | ||
| r config set sanitize-dump-payload no | ||
| r restore _listbig 0 "\x12\x02\x02\x1B\x1B\x00\x00\x00\x16\x00\x00\x00\x05\x00\x00\x02\x5F\x39\x04\xF9\x02\x02\x5F\x37\x04\xF7\x02\x02\x5F\x35\xFF\x02\x19\x19\x00\x00\x00\x16\x00\x00\x00\x05\x00\x00\xF5\x02\x02\x5F\x33\x04\xF3\x02\x02\x5F\x31\xFE\xF1\xFF\x0A\x00\x64\x0C\xEB\x03\xDF\x36\x61\xCE" |
Member
Author
There was a problem hiding this comment.
@sundb i guess that once the listpack PR is merged, RESTORE will fail and we'll need to catch it (graceful failure instead of an assertion)
sundb
added a commit
to sundb/redis
that referenced
this pull request
Nov 24, 2021
hwware
pushed a commit
to hwware/redis
that referenced
this pull request
Dec 20, 2021
If the last bytes in ziplist are corrupt and we decode from tail to head, we may reach slightly outside the ziplist.
oranagra
added a commit
that referenced
this pull request
Apr 27, 2022
If the last bytes in ziplist are corrupt and we decode from tail to head, we may reach slightly outside the ziplist. (cherry picked from commit a3a0142)
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.
If the last bytes in ziplist are corrupt and we decode from tail to head, we may reach slightly outside the ziplist.
Found by ASAN on daily CI.
https://github.com/redis/redis/runs/4293567869?check_suite_focus=true