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

Executing REIL code going from one function to another #5

Open
schomatis opened this issue Dec 28, 2016 · 1 comment
Open

Executing REIL code going from one function to another #5

schomatis opened this issue Dec 28, 2016 · 1 comment
Labels

Comments

@schomatis
Copy link

Continuing the development of #4, with the CFG and CG created for the factorial_example.elf, the next step would be to execute REIL code between two functions (arbitrarily chosen for now), that would include the execution path between the first function (e.g., main) and all the calls that happen until the second function (e.g., malloc) is reached. No specific execution environment (i.e., register or memory values) is neither set nor looked for.

@cnheitman What would be the BARF API/code for that? (there is some commented code in the current example that go towards that direction)

@schomatis schomatis added the reil label Dec 28, 2016
@cnheitman
Copy link

I've just pushed a new script in the example folder that does something similar to what you are trying to do. First, it builds the callgraph of the binary. Then, it finds two function, main and find_of_interest, and checks if there is a path between them. Finally, it executes main until the starting address of the other function. In this case, you have to set up the parameters of main in order to execute it. You can find the script here.

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

No branches or pull requests

2 participants