MENU

Fun & Interesting

Writing a Linux ELF Binary by Hand

Simon Racz 7,180 2 years ago
Video Not Working? Fix It Now

We write a 164 bytes long x86-64 ELF binary. A proper "Hello World" executable. The only requirement is a C compiler. 0:00 Introduction 01:00 ELF File Format 05:45 Taking apart C Hello World 11:52 Shared Object? 18:08 Writing The ELF Header 27:42 Getting the Object Code from Assembly 43:35 Writing The Program Header 53:42 BONUS - Hiding a Message in The Binary Code: https://github.com/simonracz/elf-binary Useful links: man 5 elf https://www.man7.org/linux/man-pages/man5/elf.5.html Intel Manuals: https://www.intel.com/content/www/us/en/developer/articles/technical/intel-sdm.html #linux #elf #binary #binutils #assembly #nasm #objcode #hexdump #linker #compiler

Comment