You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Remote denial-of-service via stack exhaustion. Document::load_mem recurses without bound on nested PDF arrays/dictionaries; a ~21 KB PDF whose Catalog contains a ~10,380-deep nested array overflows the stack and aborts the process (SIGABRT) on lopdf 0.41.0. The abort is not catchable with catch_unwind, so any service parsing untrusted PDFs can be crashed.
Checklist
Advisory filename(s) starts with RUSTSEC-0000-0000 as the ID
date field is set to the public disclosure date
Contains a concise and descriptive title after advisory metadata
Asked maintainer(s) if publishing an advisory is appropriate
Why did you not use the pull request template? Did you report this upstream? If you did so privately, why are you disclosing the issue through this PR?
Template: I opened this via the CLI and bypassed the template by accident. I've updated the description to follow it (affected crate, upstream link, severity, checklist).
Upstream: I had not reported it upstream before opening the PR. (I am quite new to this process; I know it is not an excuse, but I misunderstood it) I've now filed an upstream issue and asked the maintainer whether publishing an advisory is appropriate: Stack overflow (DoS) parsing deeply nested PDF objects J-F-Liu/lopdf#502. The repo has no security policy, and private vulnerability reporting is disabled, so I used a public issue.
I've converted this PR to a draft and will mark it ready once the maintainer has had a chance to weigh in (or after a reasonable window if there's no response). If you'd rather I close it and reopen after upstream coordination, I'm happy to.
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
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)
Links to upstream issue(s) or PR(s)
Severity
Remote denial-of-service via stack exhaustion.
Document::load_memrecurses without bound on nested PDF arrays/dictionaries; a ~21 KB PDF whose Catalog contains a ~10,380-deep nested array overflows the stack and aborts the process (SIGABRT) on lopdf 0.41.0. The abort is not catchable withcatch_unwind, so any service parsing untrusted PDFs can be crashed.Checklist
RUSTSEC-0000-0000as the IDdatefield is set to the public disclosure date