Spin like mad between:
- standards
- high level generators. We use the assembler
as
and linkerld
. - hexdumps
- file decompilers. We use
readelf
. It makes it faster to read the ELF file by turning it into human readable output. But you must have seen one byte-by-byte example first, and think howreadelf
output maps to the standard. - low-level generators: stand-alone libraries that let you control every field of the ELF files you generated. github.com/BR903/ELFkickers, github.com/sqall01/ZwoELF and many more on GitHub.
- consumer: the
exec
system call of the Linux kernel can parse ELF files to starts processes: github.com/torvalds/linux/blob/v4.11/fs/binfmt_elf.c, stackoverflow.com/questions/8352535/how-does-kernel-get-an-executable-binary-file-running-under-linux/31394861#31394861
Array of
Elf64_Shdr
structs.Each entry contains metadata about a given section.
e_shoff
of the ELF header gives the starting position, 0x40 here.So the table takes bytes from 0x40 to
0x40 + 7 + 0x40 - 1
= 0x1FF.Some section names are reserved for certain section types: www.sco.com/developers/gabi/2003-12-17/ch4.sheader.html#special_sections e.g.
.text
requires a SHT_PROGBITS
type and SHF_ALLOC
+ SHF_EXECINSTR
Running:outputs:
readelf -S hello_world.o
There are 7 section headers, starting at offset 0x40:
Section Headers:
[Nr] Name Type Address Offset
Size EntSize Flags Link Info Align
[ 0] NULL 0000000000000000 00000000
0000000000000000 0000000000000000 0 0 0
[ 1] .data PROGBITS 0000000000000000 00000200
000000000000000d 0000000000000000 WA 0 0 4
[ 2] .text PROGBITS 0000000000000000 00000210
0000000000000027 0000000000000000 AX 0 0 16
[ 3] .shstrtab STRTAB 0000000000000000 00000240
0000000000000032 0000000000000000 0 0 1
[ 4] .symtab SYMTAB 0000000000000000 00000280
00000000000000a8 0000000000000018 5 6 4
[ 5] .strtab STRTAB 0000000000000000 00000330
0000000000000034 0000000000000000 0 0 1
[ 6] .rela.text RELA 0000000000000000 00000370
0000000000000018 0000000000000018 4 2 4
Key to Flags:
W (write), A (alloc), X (execute), M (merge), S (strings), l (large)
I (info), L (link order), G (group), T (TLS), E (exclude), x (unknown)
O (extra OS processing required) o (OS specific), p (processor specific)
The
struct
represented by each entry is:typedef struct {
Elf64_Word sh_name;
Elf64_Word sh_type;
Elf64_Xword sh_flags;
Elf64_Addr sh_addr;
Elf64_Off sh_offset;
Elf64_Xword sh_size;
Elf64_Word sh_link;
Elf64_Word sh_info;
Elf64_Xword sh_addralign;
Elf64_Xword sh_entsize;
} Elf64_Shdr;
The best science fiction works deeply explore the consequences of one single technology Updated 2025-04-24 +Created 1970-01-01
The impact of the work is greater when you examine what one single new technology would do to existing society, as in Primer (2004), rather than "start on a society with severl new technologies", like in Star Wars.
Covers some specific hardcore subjects, notably quantum electrodynamics, in full mathematical detail, e.g.: "Quantum Field Theory Lecture Series" playlist: www.youtube.com/playlist?list=PLSpklniGdSfSsk7BSZjONcfhRGKNa2uou
As of 2020 Dietterich was a condensed matter PhD candidate or post-doc at the University of Minnesota Twin Cities, and he lives in Minnesota, sources:
Unfortunately the channel is too obsessed with mathematical detail (which it does amazingly), and does not give enough examples/application/intuition, which is what would be useful to most people, thus falling too much on the hardcore side of the missing link between basic and advanced.
This channel does have on merit however: compared to other university courses, it is much more direct, which might mean that you get to something interesting before you got bored to death, Section "You can learn more from older students than from faculty" comes to mind.
Videos generally involves short talks + a detailed read-through of a pre-prepared PDF. Dietterich has refused however giving the PDF or LaTeX source as of 2020 on comments unfortunately... what a wasted opportunity for society. TODO find the comment. Sam, if you ever Google yourself to this page, let's make a collab on OurBigBook.com and fucking change education forever man.
The Ultimate Goal Of My YouTube Channel by Dietterich Labs (2020)
Source. In this video Dietterich gives his ideal for the channel. Notably, he describes how the few experimental videos he has managed to make were done in a opportunistic way from experiments that were happening around him. This resonated with Ciro Santilli's ideas from videos of all key physics experiments.Sam Dietterich interview by Dietterich Labs (2022)
Source. TODO find patience to watch and summarize key points.The Sting Of Soft Corruption: My College Experience by Dietterich Labs
. Source. Academia is broken video.Those guys are really good, Ciro Santilli especially enjoyed their quantum mechanics playlist: www.youtube.com/playlist?list=PL193BC0532FE7B02C
The quantum electrodynamics one was a bit too slow paced for Ciro unfortunately, too much groundwork and too little results.
If Ciro Santilli ever becomes rich, he's going to solve this with: website front-end for a mathematical formal proof system, promise.
Looks a lot like: Bristan Monza EF Sink Mixer Chrome www.bathroomsensations.co.uk/Bristan-Monza-EF-Sink-Mixer-Chrome.html
How to open: www.youtube.com/watch?v=oHTpOG1Uhzw
- SQLite with
rowid
: stackoverflow.com/questions/8190541/deleting-duplicate-rows-from-sqlite-database - SQL Server has crazy "CTEs" change backing table extension: stackoverflow.com/questions/18390574/how-to-delete-duplicate-rows-in-sql-server
Section type:
sh_type == SHT_STRTAB
.Common name: "section header string table".
This section gets pointed to by the
e_shstrnd
field of the ELF header itself.String indexes of this section are are pointed to by the
sh_name
field of section headers, which denote strings.This section does not have outputs:
SHF_ALLOC
marked, so it will not appear on the executing program.readelf -x .shstrtab hello_world.o
Hex dump of section '.shstrtab':
0x00000000 002e6461 7461002e 74657874 002e7368 ..data..text..sh
0x00000010 73747274 6162002e 73796d74 6162002e strtab..symtab..
0x00000020 73747274 6162002e 72656c61 2e746578 strtab..rela.tex
0x00000030 7400 t.
Unlisted articles are being shown, click here to show only listed articles.