Open ikey4u opened 5 years ago
Please attach the binaries.
Please attach the binaries.
The attachment has been uploaded.
This is just a result of template expansions in the STL, the job of the reverser is to discern the exact meaning, though I do agree that reading C++ symbols in radare2 is a complete pain in the ass since the range of characters used in demangled C++ symbols (<
, >
, etc.) are not used in radare2's symbol listing. For perspective, IDA simply leaves the name in its mangled form and leaves a comment with the demangled form adjacent in the linear disassembly view. In Binary Ninja the "proper" demangled name is displayed in all occurrences, and it will as well "shorten" names like
call method.std::__1::vector_std::__1::basic_string_char__std::__1::char_traits_char___std::__1::allocator_char_____std::__1::allocator_std::__1::basic_string_char__std::__1::char_traits_char___std::__1::allocator_char_______.vector
to
call std::__1::vector<std::__...d::__1::allocator<char> > > >::vector
Perhaps an option for eliding "unimportant" template internals in the disassembly listing is a feature worth the work...
e bin.demangle=false or e asm.demangle=false should be good for you i guess but its indeed a pain
On 15 Aug 2019, at 23:48, meme notifications@github.com wrote:
This is just a result of template expansions in the STL, the job of the reverser is to discern the exact meaning, though I do agree that reading C++ symbols in radare2 is a complete pain in the ass since the range of characters used in demangled C++ symbols (<, >, etc.) are not used in radare2's symbol listing. For perspective, IDA simply leaves the name in its mangled form and leaves a comment with the demangled form adjacent in the linear disassembly view. In Binary Ninja the "proper" demangled name is displayed in all occurrences, and it will as well "shorten" names like
call method.std::1::vector_std::1::basic_string_charstd::__1::char_traitscharstd::1::allocator_char___std::1::allocator_std::1::basic_string_charstd::__1::char_traitscharstd::1::allocatorchar____.vector to
call std::1::vector<std::...d::__1::allocator
> > >::vector Perhaps an option for eliding "unimportant" template internals in the disassembly listing is a feature worth the work... — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or mute the thread.
When do reverse engineer of C++ program, STL function has very long name in asm code which causes difficult analysis. As a result, could we make the name more shorter and clear?
Take the following simple c++ program as an example:
Compile it with
g++ -Wall main.cpp -o main
.When you open the main executable, you will have the following asm codes:
In the terminal, the line is long so that it wraps into the next line. It is not convenient to read the asm code.
And
another big issue
I have found in visual mode, the line calling STL function is not show fully which makes big trouble to figure out what the function is. Showed in the below image:My environment information:
The compiled binary is here:
democ++.zip