Radare2: Graph View is broken

Created on 31 Aug 2016  Â·  24Comments  Â·  Source: radareorg/radare2

The graph view on the webui doesn't work.
[0x00000000]> agv
leads to /m/ which is a known bug #5564, but even after changing to /graph/ manually, the graph isn't shown. Instead one gets to see html code, because <, > etc. get escaped.

I tried to debug it a little, but I'm not very experienced.
if /graph/ is opened, I.is_html is set to true, thus the "filter" r_cons_html_print inside r_cons_flushis called, which escapes <, etc.

Just to check I commented out the r_cons_html_print call, the graph view renders, but there is another bug. The assembly code always starts with \x.2\x)4\x(2

bug webui

Most helpful comment

what do you think about agv? i dont use for since ascii graphs are there.. and imho it can just confuse users. suggestion in changes or removal?

On 31 Aug 2016, at 22:52, Loris Reiff [email protected] wrote:

Ah, I see. I thought that /m/ is WIP, that's the reason I checked out /graph/, so I guess /graph/ will be removed in the foreseeable future.
Thanks for clarification!

—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub https://github.com/radare/radare2/issues/5662#issuecomment-243897508, or mute the thread https://github.com/notifications/unsubscribe-auth/AA3-lk7_9z_ADhbPMpZIccLb1xYMs4tpks5qlel2gaJpZM4Jxz79.

All 24 comments

Did you analyse the binary before going in graph

Yes, I did and I added a picture ;)
After commenting out r_cons_html_printI might not have analyzed the binary though, I have to check the \x.2\x)4\x(2 thing again.

r2_bug_graph

Also this is old graph, to get the graph use /p/ or use /m/ -> disassembly -> info -> graph, but this is highly WIP by @gcolajan https://github.com/radare/radare2-webui

Ah, I see. I thought that /m/ is WIP, that's the reason I checked out /graph/, so I guess /graph/ will be removed in the foreseeable future.
Thanks for clarification!

Don't know if will be removed but surely be updated.

what do you think about agv? i dont use for since ascii graphs are there.. and imho it can just confuse users. suggestion in changes or removal?

On 31 Aug 2016, at 22:52, Loris Reiff [email protected] wrote:

Ah, I see. I thought that /m/ is WIP, that's the reason I checked out /graph/, so I guess /graph/ will be removed in the foreseeable future.
Thanks for clarification!

—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub https://github.com/radare/radare2/issues/5662#issuecomment-243897508, or mute the thread https://github.com/notifications/unsubscribe-auth/AA3-lk7_9z_ADhbPMpZIccLb1xYMs4tpks5qlel2gaJpZM4Jxz79.

+1 on removal because it's confusing and removal of graph.web: Display graph in web browser (VV) too

+1 for removal.

As I got confused by it: +1 for removal

afaik agv was honoring cmd.graph and graph.web before... now looks like someone killed all that functionality and just called "=H /graph".. which is completely wrong. so i would go for bringing back the old functionality

Well, agv now launches /graph/, but it still doesn't render the graph, so this bug shouldn't be closed.

< is escaped to &lt; and > to &gt;, so one just gets to see html code as in the screenshot above.

Update.

nope. agv doesnt spawns the web by default unless you enable graph.web=true

try again

On 03 Sep 2016, at 17:50, Maijin [email protected] wrote:

Update.

—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub https://github.com/radare/radare2/issues/5662#issuecomment-244553981, or mute the thread https://github.com/notifications/unsubscribe-auth/AA3-liumv83kLkKWzVUYxNJVVPUyx97aks5qmZcsgaJpZM4Jxz79.

Sorry for not mentioning it, I set graph.web=true, and then I ran agv. The browser opens, but I just see html code.

well then same message as the beginning:

Also this is old graph, to get the graph use /p/ or use /m/ -> disassembly -> info -> graph, but this is highly WIP by @gcolajan https://github.com/radare/radare2-webui

I know about the new graph view, but it's just confusing for a radare2 beginner. He sets graph.web=true, and it doesn't work. I think its better to remove the old graph view, if it doesn't work, don't you think so?

why a beginner would change default settings? the webui lives in a separate repository. im not talking about removing, but filling an issue in the radare2-webui repo to get it working again. this is a regression.

On 03 Sep 2016, at 18:06, Loris Reiff [email protected] wrote:

I know about the new graph view, but it's just confusing for a radare2 beginner. He sets graph.web=true, and it doesn't work. I think its better to remove the old graph view, if it doesn't work, don't you think so?

—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub https://github.com/radare/radare2/issues/5662#issuecomment-244554855, or mute the thread https://github.com/notifications/unsubscribe-auth/AA3-liUXoxADV4L4iRf-iqP47_buSnFJks5qmZrpgaJpZM4Jxz79.

Newbies like GUIs, they might change settings ;)
There is a new web graph ui as @Maijin said, that's why I thought it wasn't really a regression, if this one is deleted, but I see your point.
Thanks for the help and this awesome project!

What @radare says is: This is not the place for writing this issue but here https://github.com/radare/radare2-webui/issues is.

well. that’s an issue in the webui, not in r2 itself, so imho the issue here is gone for now.

the /graph/ thing was working but was pretty bad, i was expecting this to be done by the gsoc webui task but didnt get done in time

On 03 Sep 2016, at 18:01, Loris Reiff [email protected] wrote:

Sorry for not mentioning it, I set graph.web=true, and then I ran agv. The browser opens, but I just see html code.

—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub https://github.com/radare/radare2/issues/5662#issuecomment-244554591, or mute the thread https://github.com/notifications/unsubscribe-auth/AA3-lonlmiGmpep2Q7hpURUb14UbP-RRks5qmZnJgaJpZM4Jxz79.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

securitykitten picture securitykitten  Â·  4Comments

0ki picture 0ki  Â·  6Comments

S01den picture S01den  Â·  4Comments

radare picture radare  Â·  8Comments

XVilka picture XVilka  Â·  3Comments