GithubHelp home page GithubHelp logo

Query on Symbolic Execution. about miasm HOT 2 CLOSED

cea-sec avatar cea-sec commented on August 15, 2024
Query on Symbolic Execution.

from miasm.

Comments (2)

commial avatar commial commented on August 15, 2024

Hi @bsmondal,

What you're actually using here is the DependencyGraph, which is using itself the symbolic execution to render solutions.
Apparently, you've used the explicit version. That is to say, ask Miasm to give me all implicated lines, and if they represent different paths, yield each ones.

That's what you have in the *.dot files.
Then, using the .emul method, you can symbolic executes each solution history / path / implicated lines to obtain the equation of the result. That's the output: EAX: (@32[(ESP_init+0x4)]+(- @32[(ESP_init+0x8)])) <=> EAX: Arg1 - Arg2 <=> ret = a - b.

So, at this point, there is no value for a, b or op. This is, in fact, the interest of the algorithm.
Now if you want to obtain a value for op reaching each solution, you have to used the implicit DependencyGraph, a version which also tracks implicit (coming from control flow) dependencies.
You'll need the z3 Python dependency.

I advise you to modify expression to inject ABI + signature information (@32[(ESP_init+0x4)] -> Arg_A, ...). This will prevent your having memory constraint in the result.

See #152 for a very similar example.

from miasm.

bsmondal avatar bsmondal commented on August 15, 2024

Hi @commial

Thanks a lot. It works fine. I was getting some error during z3 installation. But its solve now. That's why it takes time to check and give you feedback.

from miasm.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.