Comments (4)
Can you give more details what you exactly mean by legend
?
What I'm currently planning is to have the ability to specify extra meta-data for the nodes and edges.
Here is an example of what I think of. In this sample the nodes contain the extra metadata HA and HF, while the edges display how many times that edge was executed. Of course these would be arbitrary, and supplied by the caller.
from angr-utils.
Oh, I should have told you more clearly. I meant the legend of the arrows. (i.e., colors)
As defined in your source, black means 'call', grey means 'ret' and so forth.
Some might take those colors for granted, but some might not like me. :)
from angr-utils.
I really don't know how to plot that onto a '.dot' graph, but will create a wiki page for them.
from angr-utils.
Since I can't put that on the output file, I write down the latest colorings here:
color | description |
---|---|
black | 'call' edge |
gray | 'ret' edge |
gray, dashed | 'fakeret' edge |
blue | unconditional jump |
blue, dashed | 'next' edges created by cfg normalization |
green | conditional edge, condition is true branch |
red | conditional jump, condition is false branch |
yellow | unknown edge (exception while evaluating, or not handled case) |
Note:
Before 1ac8d7a :
The util generates the conditional red, green edges based on the VEX IR exit targets, and not by the original asm, this can be misleading when interpreting the colors.
For example, the conditional edges are reversed in VEX for this sample code:
0x0: cmp si, 0x7f
0x4: jg 0x1d
IRSB {
[...]
11 | if (t5) { PUT(eip) = 0x6; Ijk_Boring }
NEXT: PUT(eip) = 0x0000001d; Ijk_Boring
}
After 1ac8d7a :
Both colorings possible:
- if
printvex == True
then its based on VEX exit targets - if
printvex == False and printasm == True
then its based on asm exit targets (works currently only for x86 codes) - you can create a custom visualization pipeline and use your own coloring
I will add these to the documentation some time in the future.
Also coloring will be configurable in the near future.
from angr-utils.
Related Issues (20)
- plot_cfg not working HOT 3
- how to speed up cfg_path HOT 1
- Getting error while running examples HOT 5
- WARNING | 2018-07-16 17:19:33,677 | angr.analyses.disassembly_utils | Your version of capstone does not support MIPS instruction groups. HOT 2
- No module named "expr" HOT 3
- Multiple duplicated CFG in a graph HOT 2
- RuntimeError when running angrutils.plot_ddg_data(ddg.simplified_data_graph, xxx) HOT 2
- Getting VEX-IR of a function HOT 1
- Save CFG to a file instead of rendering in new window HOT 2
- plot_cfg(): Plotted CFG is not readable HOT 2
- DDG example HOT 1
- Are there limitations to plot_cfg()? HOT 2
- can't generate graph HOT 1
- Is there a way to walk a dissasembly graph? HOT 2
- graph is not getting generated HOT 1
- No module named 'angrutils' HOT 1
- plot_ CFG cannot draw disassembly code HOT 8
- AttributeError: 'XRef' object has no attribute 'sort' HOT 5
- I got an error when I was import angr HOT 3
- Regarding CFG construction HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from angr-utils.