object: unbounded allocation in Zstd-compressed section decompression - #3096
Open
scadastrangelove wants to merge 2 commits into
Open
object: unbounded allocation in Zstd-compressed section decompression#3096scadastrangelove wants to merge 2 commits into
scadastrangelove wants to merge 2 commits into
Conversation
Adds advisory for gimli-rs/object#950, fixed in 0.40.0 via PR rustsec#961. Zstandard branch of CompressedData::decompress ignored the declared size cap, allowing unbounded allocation from crafted ELF sections. Affected versions >= 0.31.0 (when Zstd support was added).
djc
approved these changes
Aug 1, 2026
Member
|
You didn't use the PR template... did you get approval from the maintainer(s) to submit an advisory? |
Author
|
Thanks, you are right — I missed the PR template. I have updated the PR body to match it and pushed a follow-up commit that makes the advisory front matter follow the README template more closely. On maintainer approval: the issue was reported publicly upstream and fixed by the maintainer in gimli-rs/object#961, but I have not separately asked whether they want a RustSec advisory published. |
Member
Please do. |
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.
Affected crate(s)
objectLinks to upstream issue(s) or PR(s)
object0.40.0, released 2026-08-01Severity
Denial of service / resource exhaustion. A crafted ELF file with a small
compressed-section size but a Zstandard stream that expands much larger can
cause excessive allocation through
Section::uncompressed_data()when thecompressionfeature is enabled.Affected versions:
>= 0.31.0, < 0.40.0. Zstandard support was added in0.31.0; the issue was fixed in0.40.0.Checklist
RUSTSEC-0000-0000as the IDdatefield is set to the public disclosure date