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

Modified the FreeSpaceModifier to mark patch bytes written to the binary as not free #409

Conversation

rbs-alexr
Copy link
Contributor

@rbs-alexr rbs-alexr commented Feb 1, 2024

One sentence summary of this PR (This should go in the CHANGELOG!)
Change FreeSpaceModifier & PartialFreeSpaceModifier behavior: an optional stub that isn't free space can be provided and fill-bytes for free space can be specified.

Link to Related Issue(s)
N/A.

Please describe the changes in your request.
This changes the signature and intended behavior of the configs for FreeSpaceModifier and PartialFreeSpaceModifier. Each modifier now allows for injecting a "stub" at the beginning of the targeted code to be freed. This stub is not included in the FreeSpace. The config's "fill" parameter is now the data pattern used to overwrite the bytes that fall in the FreeSpace.

Anyone you think should look at this, specifically?
@rbs-afflitto, @rbs-alexr.
Optionally: @rbs-jacob, @EdwardLarson .

@whyitfor whyitfor force-pushed the bugfix/freespace_modifier_mark_patch_as_not_free branch 3 times, most recently from fa1e38c to bcc8114 Compare February 2, 2024 23:10
@whyitfor whyitfor requested a review from rbs-jacob February 2, 2024 23:15
@whyitfor
Copy link
Contributor

whyitfor commented Feb 2, 2024

@rbs-afflitto, @rbs-alexr, can you please review these update?

@whyitfor whyitfor requested a review from EdwardLarson February 2, 2024 23:16
- stub is optional bytes that displace the beginning of the free space
- update tests to assert correct functionality of this
@whyitfor whyitfor force-pushed the bugfix/freespace_modifier_mark_patch_as_not_free branch from bcc8114 to 1af5537 Compare February 2, 2024 23:19
@rbs-alexr
Copy link
Contributor Author

I took a look at Andrew's feedback and your fix, it all looks good!

@whyitfor whyitfor requested a review from rbs-afflitto February 5, 2024 23:38
Copy link
Collaborator

@rbs-afflitto rbs-afflitto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me

@whyitfor whyitfor merged commit 4fba351 into redballoonsecurity:master Feb 6, 2024
5 checks passed
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

Successfully merging this pull request may close these issues.

3 participants