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

Invalid parsing of relocation block #5

Open
theKidOfArcrania opened this issue Nov 29, 2022 · 0 comments
Open

Invalid parsing of relocation block #5

theKidOfArcrania opened this issue Nov 29, 2022 · 0 comments

Comments

@theKidOfArcrania
Copy link

Probably a dead project, but I'll still file the issue:

RelocationIter assumes that the (rblock.block_size / 2) is the number of relocation entries in one block, though this is actually wrong, since, according to msft docs:

block size: The total number of bytes in the base relocation block, including the Page RVA and Block Size fields and the Type/Offset fields that follow.

When determining the next relocation block, the code correctly interprets it, but when trying to determine the number of relocation entries in one block, it forgets to subtract the block header size from the total block size.

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

1 participant