Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Distribution: Slackware, Debian, Mac OS X, Zenwalk, Puppy, Gentoo
Posts: 199
Original Poster
Rep:
I noticed when trying to open a binary(as in a compiled program) in a gui text editor, it says it can't read it, like it doesn't know 1's and 0's? i guess you could call it "reverse engineering", if by that you mean forming it back into a format humans could actually understand. im familiar with C but not how the computer reads the compiled binary.
I doubt a gui editor will handle it, that's not what they are for. There may be an 'advanced' option somewhere in the menus...
You'll prob have to go cmd line; try vi/vim or you can use od http://linux.die.net/man/1/od
Distribution: Slackware, Debian, Mac OS X, Zenwalk, Puppy, Gentoo
Posts: 199
Original Poster
Rep:
command line is actually my preference, gui makes me feel like an idiot and typically just takes more work to do anything. any programs that can convert binary to a more human format?
Try that od cmd with the relevant params. Provides a dual col display; eg hex codes for a ew bytes, then the equiv (if possible) in ACII (ie human readable).
Note that it can't reverse compile; that's specialised task.
To comply with LQ rules I'd like to ask exactly what you are trying to do and is it strictly legal?
Distribution: Slackware, Debian, Mac OS X, Zenwalk, Puppy, Gentoo
Posts: 199
Original Poster
Rep:
im curious about how computers work. i have been interested in how things and computers work since a wee child, but there is a giant gap between hardware and software like a giant black hole that i'm just trying to figure out.
Ok, just be aware that reverse engineering/decompiling someone else's code is frequently illegal.
I believe(?) it's allowed for 'interoperability' purposes in some(!) jurisdictions. Maybe a moderator will come along and clarify.
Feel free to work on GPL (Linux stuff) as it comes with the src anyway.
Alternately, write a short C prog & compile & link it, then see if you can de-compile it.
If your interest is merely didactic, you should first start with assembler. That's the closest you are going to get to the hardware nowadays. You could open a binary program in an hex editor, but all you are going to see is a lot of number in base 16 which will make absolutely no sense to you, unless you know all the assembly mnemonics from memory (that's why first of anything, your'd need to learn assembly to make any sense at all of what you see in an hex editor.
Hexadecimal editors usually provide options to view number in binary format and the ascii equivalents as well. But that depends on the editor you choose.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.