8000 Improve afl_fuzz wrapper by kiddo-pwn · Pull Request #1330 · qilingframework/qiling · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Improve afl_fuzz wrapper #1330

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

Merged
merged 2 commits into from
Apr 9, 2023
Merged

Improve afl_fuzz wrapper #1330

merged 2 commits into from
Apr 9, 2023

Conversation

kiddo-pwn
Copy link
Contributor
@kiddo-pwn kiddo-pwn commented Mar 29, 2023

The current ql_afl_fuzz wrapper in Qiling supports setting exit addresses using the exits parameter. It sets the exit addresses at the start and calls the ql_afl_fuzz_custom wrapper with a dummy fuzz callback.

Although both ql_afl_fuzz and ql_afl_fuzz_custom wrappers have almost the same API, it is impossible to set exit addresses if ql_afl_fuzz_custom is called directly.

To address this issue, I passed the exits parameter seamlessly to ql_afl_fuzz_custom for both wrappers to support setting exit addresses.

Checklist

Which kind of PR do you create?

  • This PR only contains minor fixes.
  • This PR contains major feature update.
  • This PR introduces a new function/api for Qiling Framework.

Coding convention?

  • The new code conforms to Qiling Framework naming convention.
  • The imports are arranged properly.
  • Essential comments are added.
  • The reference of the new code is pointed out.

Extra tests?

  • No extra tests are needed for this PR.
  • I have added enough tests for this PR.
  • Tests will be added after some discussion and review.

Changelog?

  • This PR doesn't need to update Changelog.
  • Changelog will be updated after some proper review.
  • Changelog has been updated in my PR.

Target branch?

  • The target branch is dev branch.

One last thing


@xwings
Copy link
Member
xwings commented Mar 29, 2023

@wtdcode can u take a look?

@wtdcode
Copy link
Member
wtdcode commented Mar 29, 2023

LGTM but I think you have to update samples.

@kiddo-pwn
Copy link
Contributor Author
kiddo-pwn commented Mar 30, 2023

Thanks. I have tested some sample scripts in the examples/fuzzing/ directory to ensure that they run smoothly without modifications.

For the stm32f429 using the ql_afl_fuzz_custom function, I updated the necessary modifications to comply with the updated API.
For the linux_x8664 and qnx_arm using the ql_afl_fuzz function, I confirmed that they run seamlessly.

@kiddo-pwn
Copy link
Contributor Author

@wtdcode are these commits ready to be merged?

@wtdcode
Copy link
Member
wtdcode commented Apr 4, 2023

Yes, LGTM now. Let's wait for CI.

@kiddo-pwn
Copy link
Contributor Author

@xwings can u help review this request?

@xwings
Copy link
Member
xwings commented Apr 6, 2023

Thanks for the PR. Need to wait for one more approve before we are good to merge. @wtdcode

@elicn elicn merged commit bb0c5f3 into qilingframework:dev Apr 9, 2023
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.

5 participants
0