Skip to main content

Message HEX dump

· 2 min read
Alejandro Revilla
jPOS project founder

From time to time, we may ask for a message hex dump, and here is how a dump looks like:

    0000  08 00 A0 20 00 00 00 80  00 00 04 00 00 00 00 00  ... ............
0010 00 00 00 00 00 00 00 01 32 39 31 31 30 30 30 31 ........29110001
0020 00 01 ..

See? It's ASCII text that one can easily copy and paste in order to load it in a simulator or test program (please move your mouse over the hex digits, you can see they are selectable).

It is extremely simple, you can capture a message using NetCat and then you can use the hd Unix command, or just send us the binary image in raw format, but please PLEASE P L E A S E, don't send us a screen capture in graphic format inside a Word document or inside a cell of an spreadsheet.

When you send a graphic capture of a dump, like this:

HexDump

We need to re-type the dump in a text editor, which is error-prone and a waste of time. This is a very small example, but with large messages, the chances of introducing an error are high.

Another very common problem when we ask for a dump is that we get a high level representation of the message, some times in ASCII, copy and pasted into a message, but the mailers usually wrap around lines, not preserve blanks, and don't show unprintable characters, so it's extremely naive to think that we can do something useful with those kind of "dumps".

When we ask for a message dump, we don't want a full wall of IP-packets either, we are not debugging the TCP/IP protocol, we believe it works, so we are not interested in the session establishing, ICMP packets and IP-level headers.

We just ask, actually we cry for, a simple hex dump. Is that difficult?