PDA

View Full Version : Question :D



Reiko
November 13th, 2006, 02:05 AM
How can i open in Ubuntu files to view their hexadecimal form.

Christmas
November 13th, 2006, 02:08 AM
I do not know.

Reiko
November 13th, 2006, 02:09 AM
funny :))

Reiko
November 13th, 2006, 02:12 AM
bine mai Danutz

oxEz
November 13th, 2006, 02:14 AM
How can i open in Ubuntu files to view their hexadecimal form.

In console you can do: xxd (yourfilehere)

Example: xxd data.dat

If you want to echo the output in another file, just do:

xxd data.dat >> someotherfile

Hope this helps.

Reiko
November 13th, 2006, 02:18 AM
YEY THANK YOU oxEz

Reiko
November 13th, 2006, 02:32 AM
Now the problem is : How can I modify that object file, in his hexadecimal form. xxd just prints his hexadecimal. So if i make a C "hello world" program and "$ xxd "the compiled file" > executeMe" . I can't run executeMe (with no errors) cuz is a ASCII file. So I want that file to be still binary. And i want to edit it in that form :D thx

DoctorMO
November 13th, 2006, 03:32 AM
You could always write a perl program to insert the correct bytes at given locations.

once you have your mod use patch --binary to store it.

IYY
November 13th, 2006, 04:27 AM
hexedit is the program you're looking for.

pmj
November 13th, 2006, 07:08 AM
Try ghex.

Reiko
November 13th, 2006, 12:06 PM
thank you