Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium


access ELF header

Posted on 2004-11-24
Medium Priority
Last Modified: 2008-03-17
can somebody show me an exmaple how to read elf head in a elf file? Thanks.
Question by:rongz
  • 2
LVL 45

Expert Comment

ID: 12663354
Hi rongz,

you mean read the contents of the executable in the executable?
If you are using C, fopen it (argv[0]) and use fread to read until EOF .... That should suffice


Author Comment

ID: 12663855
no, I mean how to access ELF header (e.g. retrieve information encoded in ELF header) in an ELF format file.
LVL 45

Accepted Solution

sunnycoder earned 500 total points
ID: 12663902

or go to www.wotsit.org and downloaf ELF file format. All you need to do is fopen the ELF file and fread(or fscanf) the header into the structs which are defined in the file format specification

Featured Post

Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The purpose of this article is to fix the unknown display problem in Linux Mint operating system. After installing the OS if you see Display monitor is not recognized then we can install "MESA" utilities to fix this problem or we can install additio…
The purpose of this article is to demonstrate how we can upgrade Python from version 2.7.6 to Python 2.7.10 on the Linux Mint operating system. I am using an Oracle Virtual Box where I have installed Linux Mint operating system version 17.2. Once yo…
How can you see what you are working on when you want to see it while you to save a copy? Add a "Save As" icon to the Quick Access Toolbar, or QAT. That way, when you save a copy of a query, form, report, or other object you are modifying, you…
Enter Foreign and Special Characters Enter characters you can't find on a keyboard using its ASCII code ... and learn how to make a handy reference for yourself using Excel ~ Use these codes in any Windows application! ... whether it is a Micr…
Suggested Courses
Course of the Month11 days, 22 hours left to enroll

564 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question