Posts

Showing posts from September, 2020

Endianness

Image
 Endianness is the order of storing sequence of bytes of data in computer memory. We will showcase this with the help of following example - The first command 'xxd test.txt ' takes the content of file and displays in Hex format. Since the byte range are ASCII strings, which is not affected by the endianness ordering of the system. However, the second command 'hexdump test.txt' takes the file (as stored) and displays its contents in Hex format following system supported Endian order. The byte sequence are displayed here in Little Endian order, hence the order of each byte need to be switched for understanding. It can be concluded that "Hexdump" displays the data based on the supported endian order of the system, e.g. Intel x86 and AMD64/x86-64 processors. Interestingly, there is a difference in the Hex byte display order for the output of both the commands.  It will be more appealing to analyze the output of Hexdump in the system supporting Big Endian order.