Category "elf"

What to do with "DWARF error: section .debug_info is larger than its filesize!"?

Looking for ways to see generated assembler of a specific function in my binary (an .so to be exact), just as I can see similar on Compiler Explorer, I found Ho

Can the global offset table manually be defined?

I'm attempting to build a flat 32-bit PIC binary with the following C++ code: extern "C" { void print(const char *){} void entry_func() { print("abcd\n"); }

Error /lib/x86_64-linux-gnu/libc.so.6: version `GLIBC_2.34' not found

firstly, I google'd a lot but nothing I found related to my case, I have an ELF executable file I'm trying to run it in my Ubuntu WSL, I've changed the permissi

python file to excutable file at any operating system

Now I created a python app using tkinter which it should be used in pc, but I am using windows, so I executed the .py file to .exe. My problem now is my program

How to manually postprocess CMake target during installation?

I am working on a library that provides gdb pretty-printers. They could be automatically located by including the .debug_gdb_scripts section in the generated bi

ELF file variable addresses of C structure in debug info

I have .elf file. I am trying to learn symbol address. I could find main variable addresses with many ways. I used pyelftools, nm.exe, objdump.exe, readelf.exe.

How to modify byte strings?

Let's say I have the following ELF file in python: >>> data=open('file','rb').read() >>> data b'\x7fELF\x02\x01\x01\x00\x00\x00\x00\x00\x00\x0

Getting the error: bash: (program): cannot execute binary file: Exec format error, on both 32-bit and 64-bit Windows

There is a program developed for linguistic research (http://people.csail.mit.edu/mcollins/code.html). When I try to run the parser using Git bash terminal on W

How to get the strings of shstrtab?

I am writing a simplified version of Linux' readelf. I want to print section information, so I need the names of the sections. In the Elf64_Shdr struct, the sh

relocation error when implementing my own elf loader

I am currently implementing an elf loader to emulate binaries with the unicorn engine. To avoid implementing my own dynamic linker, I load the ld-linux-x86-64.s