Wednesday, August 1, 2012

How to view the textual content of a binary file in linux?

Linux strings command displays the textual content in the binary file that is longer than 3 characters. (to change that default behaviour use the flag -n 0)
$ strings fizzbuzz
 Example result:
$ strings fizzbuzz
/lib/ld-linux.so.2
libc.so.6
printf
__deregister_frame_info
_IO_stdin_used
__libc_start_main
__register_frame_info
__gmon_start__
GLIBC_2.0
PTRh@
FizzBuzz
Fizz
Buzz
Ref: http://linux.die.net/man/1/strings

No comments: