Skip to content

fix: harden minidump parser against malformed inputs#150

Merged
MarshallOfSound merged 1 commit into
mainfrom
fix-malformed-issue
Apr 22, 2026
Merged

fix: harden minidump parser against malformed inputs#150
MarshallOfSound merged 1 commit into
mainfrom
fix-malformed-issue

Conversation

@codebytere
Copy link
Copy Markdown
Member

format.readMinidump() and its helpers trusted RVAs and header fields without validating them against the buffer size, so unexpected inputs produced ERR_OUT_OF_RANGE from Buffer reads rather than an Error the caller could handle.

Add bounds checks at the header, stream directory, and each RVA-consuming helper, and guard moduleList()'s fs.readFile callback with try/catch so parse failures always arrive through the user-supplied callback.

@codebytere codebytere requested a review from a team as a code owner April 20, 2026 07:04
@codebytere codebytere marked this pull request as draft April 20, 2026 07:05
format.readMinidump() and its helpers trusted RVAs and header
fields without validating them against the buffer size, so
unexpected inputs produced ERR_OUT_OF_RANGE from Buffer reads
rather than an Error the caller could handle.

Add bounds checks at the header, stream directory, and each
RVA-consuming helper, and guard moduleList()'s fs.readFile
callback with try/catch so parse failures always arrive through
the user-supplied callback.
@codebytere codebytere force-pushed the fix-malformed-issue branch from 1e77e75 to 81e1c83 Compare April 20, 2026 07:06
@codebytere codebytere marked this pull request as ready for review April 20, 2026 07:10
@MarshallOfSound MarshallOfSound merged commit 6f0d92d into main Apr 22, 2026
6 checks passed
@MarshallOfSound MarshallOfSound deleted the fix-malformed-issue branch April 22, 2026 02:22
@electron-npm-package-publisher
Copy link
Copy Markdown

🎉 This PR is included in version 0.26.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants