Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integer truncation following parse_unsigned in src/tpi/data.rs #114

Closed
DrChat opened this issue Mar 23, 2022 · 3 comments
Closed

Integer truncation following parse_unsigned in src/tpi/data.rs #114

DrChat opened this issue Mar 23, 2022 · 3 comments

Comments

@DrChat
Copy link

DrChat commented Mar 23, 2022

There are a few calls to parse_unsigned to parse variable-sized integers from the PDB file, but in a few cases immediately afterwards the u64 result is truncated.
This results in pdb using and returning erroneous data.

For example, here:
https://github.com/willglynn/pdb/blob/7c35c3c82fe42a0aa505c0715d57f68ee93196fb/src/tpi/data.rs#L120

The offset member of that structure should be 64-bits to avoid truncation.

Edit: This is fixed in PR #103

@jan-auer
Copy link
Member

Closing this as the PR is merged. It will be released as soon as the remaining open PRs are merged 👍

@DrChat
Copy link
Author

DrChat commented Jun 3, 2022

@jan-auer Thanks for maintaining this crate!
I also wanted to ping you and see what your plans are for cutting a new release on crates.io?

@jan-auer
Copy link
Member

jan-auer commented Jun 3, 2022

👍 I'm still planning two breaking changes to the public API by addressing #120 and #124 in the next few days, will then cut a release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants