This question already has an answer here:
- Finding out what a file is 4 answers
Say you are given a file whose extension has been removed or changed (file.tar.gz --> file.blah). This file is decompressed and its contents are used by an application. But you don't have access to that application to know how. So how do you figure the file's extension to be able to decompress it for yourself? For example can you do that by inspecting the file with a hex editor?