Peering into binary files on Linux
Any file on a Linux system that isn't a text file is considered a binary file--from system commands and libraries to image files and compiled programs. But these files being binary doesn't mean that you can't look into them. In fact, there are quite a few commands that you can use to extract data from binary files or display their content. In this post, we'll explore quite a few of them.file One of the easiest commands to pull information from a binary file is the file command that identifies files by type. It does this in several ways--by evaluating the content, looking for a "magic number" (file type identifier), and checking the language. While we humans generally judge a file by its file extension, the file command largely ignores that. Notice how it responds to the command shown below.To read this article in full, please click here