Usage of Hext Dump in programming

M

Matt

I want to know what is Hex Dump? I tried to search in google but
didn't get useful results. From java programmer's perspective,
when do we need to use hex dump? what's the importances of hex dump?

please advise. thanks!!
 
F

Frank

I want to know what is Hex Dump? I tried to search in google but
didn't get useful results. From java programmer's perspective,
when do we need to use hex dump? what's the importances of hex dump?

please advise. thanks!!


Very few programmers these days can read a Hex Dump. When one finally
gives up and must examine a hex dump as a last resort to debugging a
program (usually even after rewriting it), you can expect on not seeing
them again for at least a few months.

In java, a dump is pointless unless you're actually designing the VM.
Memory contents are specific to the processor architecture, the operating
system, the memory manager, and practically every other variable you can
think of (and many more), short only of phases of the moon.

In terms of importance... when you've really got to know what the system
is doing, there is nothing like doing a memory dump in order to look at
memory *exactly* as the CPU sees it, then looking for the first sign that
something is amis.

Hope this answers your question,

Frank
 
R

Roedy Green

In java, a dump is pointless unless you're actually designing the VM.
Memory contents are specific to the processor architecture, the operating
system, the memory manager, and practically every other variable you can
think of (and many more), short only of phases of the moon.

He is talking about general "core" dump. The thing you sometimes get
in Windows when the JVM crashes.


A small hex dump of a string for example can be useful to figure out
whether characters that are not displaying have the correct unicode
values.

A hex editor peek at a file will let you know if it is big or little
endian binary.

A hex editor peek at a serialised file will give you pretty good idea
of that fields and objects were actually included.
 
S

Socket

I want to know what is Hex Dump? I tried to search in google but
didn't get useful results. From java programmer's perspective,
when do we need to use hex dump? what's the importances of hex dump?

please advise. thanks!!

47 45 54 20 2F 20 48 54 54 50 2F 31 2E 31 0D 0A GET / HTTP/1.1..
41 63 63 65 70 74 3A 20 2A 2F 2A 0D 0A 55 73 65 Accept: */*..Use
72 2D 41 67 65 6E 74 3A 20 4D 6F 7A 69 6C 6C 61 r-Agent: Mozilla
2F 34 2E 30 20 28 63 6F 6D 70 61 74 69 62 6C 65 /4.0 (compatible
3B 20 4D 53 49 45 20 35 2E 30 3B 20 57 69 6E 33 ; MSIE 5.0; Win3
32 29 0D 0A 48 6F 73 74 3A 20 70 72 6F 78 79 3A 2)..Host: proxy:
38 30 38 30 0D 0A 0D 0A 8080....

this is example of hex dump of HTTP GET request sent by IExplorer to
HTTP server.
The dump was produced by SMIKE itility
http://smike.ru
 
T

Tris Orendorff

(e-mail address removed) (Socket) wrote in
(e-mail address removed) (Matt) wrote in message


47 45 54 20 2F 20 48 54 54 50 2F 31 2E 31 0D 0A GET / HTTP/1.1..
41 63 63 65 70 74 3A 20 2A 2F 2A 0D 0A 55 73 65 Accept: */*..Use
72 2D 41 67 65 6E 74 3A 20 4D 6F 7A 69 6C 6C 61 r-Agent: Mozilla
2F 34 2E 30 20 28 63 6F 6D 70 61 74 69 62 6C 65 /4.0 (compatible
3B 20 4D 53 49 45 20 35 2E 30 3B 20 57 69 6E 33 ; MSIE 5.0; Win3
32 29 0D 0A 48 6F 73 74 3A 20 70 72 6F 78 79 3A 2)..Host: proxy:
38 30 38 30 0D 0A 0D 0A 8080....

this is example of hex dump of HTTP GET request sent by IExplorer to
HTTP server.

In this example a hex dump is not useful since the file is readable text.

--
Sincerely,

Tris Orendorff

-----BEGIN GEEK CODE BLOCK-----
Version: 3.12
GCS d++ s+:- a+ C+ UL++++ P+ L+ E- W+ N++ o- K++ w+ O+ M !V PS+ PE Y+ PGP t+ !5 X- R- tv--- b++
DI++ D+ G++ e++ h---- r+++ y+++
------END GEEK CODE BLOCK------
 
R

Roedy Green

In this example a hex dump is not useful since the file is readable text.

Hex dumps are useful even then figuring out things like.

1. are there tabs in this file?
2. does it use cr, crlf, or lf terminators?
3. are there "funny" space characters -- chars other than 32 that
display as blank?
4. what encoding is this file?
5. what is that character an mdash or an ndash?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,769
Messages
2,569,582
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top