hobune Channels Contact About Donate

In-depth: ELF - The Extensible & Linkable Format

Back to video page | Download comments jsonl

Comments (archived 2022-07-05 20:26; 103 top, 157 total comments)

connor horman 2020-10-27 23:31:22 (edited 2020-10-27 23:31:42 )

The difference between the program headers on 64-bit is for layout. The fields in the elf headers are aligned to their natural alignment, so 8-byte types are likely going to want to be aligned to 64-bit. It was done to move the 32-bit members together so the header wouldn't have to contain unnecessary padding.

166 likes
Replies (2)
Colaholiker 2021-02-13 23:40:07

LOL I just watched the video, saw the part where he explains the difference and immediately had the same idea. I paused, thinking "I wonder if..." and found your comment right away. :-)

7 likes
Luciano Osinaga 2021-02-17 22:35:09

@Colaholiker lol same. cheers

3 likes
Karl Xu 2021-03-04 02:40:02 (edited 2021-03-04 02:58:41 )

0:47 segment and section differentiation
2:05 ELF structure
3:39 ELF header data structure
9:34 Program header data structure
13:54 Section header data structure

35 likes
Replies (1)
stacksmashing 2022-03-26 19:49:33

Thanks a lot, I put it in the description!

3 likes
Matteo Bucci 2021-02-17 21:57:46

Incredible how a format developed so much time ago is still capable of being fully functional without any need of a version change. That tells a lot on the foresight of the creators!

32 likes
Replies (2)
daniel jimenez 2022-01-18 05:07:57

I agree. The Unix design is quite elegant, some have called it timeless.

4 likes
Stephen A 2022-02-20 00:22:24

WebAssembly is another format that I think is well designed and will last well into the future.

1 like
Bon Bon 2020-11-02 13:49:33

13:00 Ah, the infamous `p_align` field that everyone understands wrong :P This is not about 4-byte vs. 8-byte alignment (and you would know that if you ever tried hand-crafting ELF files or fiddling with existing ones), but it is meant to facilitate paging . Many people say that segments have to be aligned to page boundaries, but this is also wrong! The only true requirement is that their offsets in file and in memory must be congruent modulo the `p_align` value (which is usually some reasonable multiple of the page size). The reason for this is that when segments from the file are memory-mapped (using `mmap`), the granularity of that mapping is the page size (i.e. you can only map whole pages), but the address is usually assigned by the kernel, and it might change on different runs. This isn't a problem, though, as long as data and instructions keep the same offsets from the page boundary. Then they can be easily mapped to different addresses in different address spaces, and yet their offsets from page boundaries stay the same as they were in the segment in the file. If the offset in the file were different than in memory, the system loader would have to shift it so that the offsets matched again, but then the beginning of the segment in memory would have to cross the page boundary, so the loader would have to map an additional page in front of our page, with lots of padding at the beginning. It would impact performance, memory usage, and be much more complicated to implement. Hence the alignment criterion that makes sure that when segments are mapped into memory, the offsets in the file and in memory match each other (i.e. they're the same modulo `p_align`).
13:16 This is because of machine word alignment. Two `Word`s are 64-bit together, so the next field will be aligned to 64-bit machine word boundary. Otherwise a padding would be needed which would only waste space. But since this padding is precisely the size of `p_flags`, they decided to rather move the `p_flags` field in there than waste this space for paddings.

14 likes
Silica 🏳️‍⚧️ 2020-10-28 09:50:29 (edited 2020-10-28 10:05:32 )

Oh, acturally ELF is not exactly the executable format of the PS4,

Rather 'SELF' which is like ELF but with some extra stuff added at the start mostly some boot flags, authentication & permissions info if its unencrypted (only on devkits) etc and then the actural elf header and stuff

Though it's often pretty easy to strip away the SELF stuff (and sometimes decrypt its contents too..) which basically just converts your SELF into a standard ELF binary- but the console cannot run ELF directly !

Oh also SELF is used on the PSVita and PS3 as well. and the format of SELF is different on all there consoles..

Lol on PSVita SELFs acturally have 2 ELF headers lol not sure about PS4 though.

Only PS2 and PS1 use ELF directly!

143 likes
Replies (15)
Eder Barrero 2020-11-04 09:46:43

As far as I know the PS1 uses EXE's, they are kind of based off the ELF format, but simpler. The PSP does use plain old ELF's, iirc.

4 likes
Silica 🏳️‍⚧️ 2020-11-04 17:24:09 (edited 2020-11-04 17:24:25 )

@Eder Barrero nope PSP is self too (see ~PSP header) on UMDs or its PBP for digital stuff

6 likes
Eder Barrero 2020-11-04 18:38:41

@Silica 🏳️‍⚧️ Ah, you are right, I forgot the PSP does have an encryption scheme for its executables too.
Welp, that only leaves PS2 in the "it runs ELF files directly" gang.

11 likes
skilz8098 2021-02-18 13:14:19

That's how I was able to load Free McBoot onto one of my PS2 memory cards without having to `hard-mod` the system! It is a process though as you need a specific game title that you have to rip from disc using specific software to a computer, then you need different software to modify the copy, and another piece of software to patch the modified copy, a dvd burner with a specific program to burn it properly. It does involve taking the PS2 apart and removing a spring, and blocking a couple of push buttons to stop indicating that the tray is opened. This works for the "slim" model only, there are other methods for the fat model... Then you will need a blank memory card, a USB thumb drive less than 1GB preferably 256 - 521 MB as the USB ports on the PS2 only support USB 1, maybe USB2 with some of the newest versions of the slim models... and they don't support large size drives that you see today such as 8-256 GB. You will then have to play that specific title up to a certain point, save the game at a certain point, and then when you go to proceed to another game state such as a loading screen to the next level, you have to pop the original disc out with the tray open and while the system is still spinning because it believes the tray is closed, you will then have to pop in your burnt version of the game that will have the `elf` file that you added to that game disc within a specific track and sector... Then if done properly, the console will read that `elf` file and execute it. This acts like a `flash bios operating system - file manager`. Now with this elf running, you can now insert your flash drive that has other elf files... It's been a while since I've done this, but you either move them over to the memory card directly, or you "run" the Free McBoot directly from the USB as it will format your memory card, you can also have other applications and utilities on that USB such as media players, NES, SNES, Sega Emulators and Roms, and more. Once you have Free McBoot installed onto the memory card, you can then shut the system down, remove the discs and USB drive... start the system back up, with the modified memory card. Now, when your PS2 loads the main menu that you would see without any discs have changed. You can customize this list of applications with the same elf file that you used from the modified game disc, however, you will have a copy of this on your memory card so you won't have to do the hot disc swap trick. From there I was able to install, I believe it's called OPL2 or something close to that... and I configured one of my hard drives on my PC to have `ISO` images of all my game discs. This is another long process to setup... but I can now run any of my PS2 and PS1 games from computers had drive across my network. This process is involved too... Even though I am a Windows user when it comes to PCs mostly due to "Gaming" reasons and that most of my systems came with Windows... Now, I don't mind Linux, but I can't stand Apple! But yes, that is the power of ELF unlike Window's EXE!

4 likes
Xeno Idaltu 2021-06-20 05:55:28

@skilz8098

Interesting.

You should upload a tutorial!

1 like
skilz8098 2021-06-20 10:08:22

@Xeno Idaltu Just do a Free McBoot search on YouTube they're already out there... An old programmer's saying: "why reinvent the wheel?"

0 likes
Xeno Idaltu 2021-06-20 18:03:11

@skilz8098
Okay

0 likes
Null 2021-07-20 12:20:36

@skilz8098 for fun?

1 like
skilz8098 2021-07-20 15:18:10

@Null Well, that and to preserve my PS2's system laser. They don't last forever...

1 like
Robert Kiestov 2021-07-30 21:08:19

>weaboo pfp

0 likes
Silica 🏳️‍⚧️ 2021-07-30 23:38:41

@Robert Kiestov "yea, and?'

2 likes
Robert Kiestov 2021-07-30 23:45:23

@Silica 🏳️‍⚧️ Nobody will ever take a tranime poster seriously. If you want anyone to listen to you, drop the childish obsessions.

0 likes
Null 2021-07-30 23:50:19

lol we got a salt right here

3 likes
Silica 🏳️‍⚧️ 2021-07-31 00:59:10

@Robert Kiestov i like to see cute anime girls die i find it cute for cute people to die. and this is irrelevant to the fact that ps4 and psvita, etc do not use ELF directly.

4 likes
Null 2021-07-31 01:55:26

@Silica 🏳️‍⚧️ True true. That's irrelevant to ELF.

2 likes
jwaffe 2020-10-28 18:13:49

Very well presented video, it would be interesting to see more details on the symbol table and how it compares to PE binaries and pdb files on Windows.

13 likes
Jordan Hargrave 2021-02-21 15:54:37

Great explanation! I love digging into executable formats... wrote my own disassembler and have PE/COFF/ELF/etc loaders. My Elf reader code converts the ELF32 structures to ELF64.

3 likes
nikoshalk 2021-04-15 11:45:49

Very nice explanation! Definitely helpful and clearly explained! I would love to see/hear more from the reverse engineer's perspective like when you demonstrated the "sstrip" tool and that an ELF can still run without section headers. In other words things that we take for granted in a normal workflow but during reversing they may appear differently.

0 likes
Matthias Reik 2020-10-27 22:28:33 (edited 2020-10-27 22:29:46 )

The order of the ProgramHeader is surely (my guess not confirmed knowledge) different between 32 and 64 so that the data aligns to 32 respective 64bit boundaries. For 32bit you have: Word = 32, Offset = 32, ... so all is fine, but for 64bit that does not work: Word=32, Offset=64. Thus, you want to have: Word+Word=32+32=64, Offset = 64. I guess the 32bit version wasn't changed to not break backwards compatibility

11 likes
Replies (1)
stacksmashing 2020-10-27 22:30:21

Interesting theory, that might be it 🤔

4 likes
Sascha Kaupp 2020-10-27 22:02:06

Awesome tutorial! Haven't looked into what happens inside an ELF since the time when Amigas used 68k and PowerPC simultaneously!

7 likes
David Joseph 2020-11-17 18:37:16

Please keep making videos like this, all of your videos are so helpful and the topics are explained so well! You are awesome man, I have not absorbed info like this in a while.

0 likes
koeningyou 2020-10-31 06:31:48

Thank you for the well presented, well written video. Keep up the good work!

2 likes
Paul van den Bergen 2021-02-16 00:58:40

Subscribed!
always a good day when you learn something new.

Just curious - if sections are only used during compiling, and removing them doesn't affect the execution of the program, why aren't they stripped out as part of the compile process?

(I'm presuming this only applies to executable ELF files - unsure if an object or library still needs these, but I can kinda see that they would...)

0 likes
Ethan Trithon 2022-05-13 23:11:57

Very nice explanation, clear, and directly to the point! Thank you!

0 likes
pablojrl123 2021-02-07 21:50:21

Really interesting video!
If anyone is interested in learning about the execution of programs in Linux, I recommend a series of articles by LWN titled 'How programs get run', and its follow up 'How programs get run: ELF binaries'. It explains how the OS loads executables into memory and how it invokes an interpreter on them if needed (eg. the shell for scripts, or the ELF program loader for dynamically-link programs).

6 likes
Replies (2)
Vivek Yadav 2021-07-26 05:35:18

Much needed info. Thanks for the tip!

1 like
edward mac nab 2022-05-14 00:59:13

hopefully when I google LWN ?

0 likes
Jason Gurtz-Cayla 2021-02-21 09:52:30

Great explanation, thank you. Definitely keeping this in my favorites list

0 likes
w3w3w3 2021-02-24 04:20:09

This video was so well made and thought out! Kudos! :)

1 like
Nerussa 2020-10-27 23:11:35

Great tutorial! I learned a lot.

8 likes
tolisec 2020-10-27 23:07:36 (edited 2020-10-27 23:08:26 )

Very concise and precise overview of the ELF format. One of the best, if not best summary of the elf, program and section headers

1 like
João Francisco Barata 2020-10-28 17:55:17

Awesome Work. I really enjoy these deeply technical videos, keep up with them.

1 like
Lexmax 2020-10-28 02:37:01

Thanks for a hugely informative description. I've been working with elf files for years without fully understanding the structure. Great job.

4 likes
Andrew Dunbar 2021-02-23 03:08:08

It would be good to see a video on reverse engineering a React Native app for Android, iOS, or both. Especially one that just uses a WebView. Should be very easy but I'm struggling.

0 likes
Thomas Carlsen 2021-03-30 16:00:26

nice animations and explanation - must have taking a long time to make 👍

0 likes
muskit 2020-10-28 09:14:44

the editing style reminds me of retro games mechanics explained! nice explanations, though maybe a touch too fast-paced in explanations

34 likes
Replies (2)
stacksmashing 2020-10-28 09:22:15

Glad you liked it! Yeah, it's definitely difficult to find a good pace :)

9 likes
x90slide 2021-03-24 09:13:52

I liked the pace

0 likes
John Hammer 2021-11-09 08:24:21

Amazing . Densely packed , saved a lot of time

0 likes
Soveu 2020-10-28 06:32:06

i just started writing a bootloader and this is exactly what i need :)

36 likes
Replies (3)
Squidwayne Johnswardson 2020-10-31 13:01:53

What is your bootloader doing with ELF? I am genuinely interested.

4 likes
Mcpg 2020-11-03 12:11:31

@Squidwayne Johnswardson Probably stuff like loading kernels, as you can use ELF for that

6 likes
El Virus 2020-11-11 20:32:22

Well, I guess it's a second stage bootloader then.

1 like
Godnyx 2022-03-26 15:19:00

Thank you! I'm trying to make a compiler and this is very helpful. The System V spec is very detailed and it's not the best thing to start up for beginners.

0 likes
AlphaK 2020-10-28 14:43:30 (edited 2020-10-28 14:43:48 )

It's also used in PS2 games and PSP games. Both the main executable on the PS2 disc and the boot.bin (once decrypted) on PSP umds are standard ELFs.

0 likes
Stavsen ⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻ 2020-10-27 23:21:27

Nice video i literally just started studying about executable file formats and then i see you uploaded this.
Will you do one about the PE format next? I heard its kinda complicated compared to ELF so it would be a big help

7 likes
Replies (10)
SillySimon 2020-10-27 23:38:40

Wow cool nickname (even screws with the site layout a little bit). How did you do it? (Especially the line break)

1 like
Nuszkat 2020-10-28 12:22:20

Yeah I agree too. A video on PE file format would be great help.

1 like
Lawrence D’Oliveiro 2020-10-29 02:00:54

PE is Windows-only. It’s not used on any other platforms.

0 likes
Stavsen ⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻⸻ 2020-10-29 06:16:32

@Lawrence D’Oliveiro thats actually exactly why im so interested in it. So many closed source programs are windows only and so knowing the windows executable format would be helpful in reverse engineering. Most ELF programs are open source anyway :p

0 likes
Lawrence D’Oliveiro 2020-10-29 06:33:28

Most of those programs also have EULAs that prohibit reverse-engineering, decompiling and general snooping about.

0 likes
stacksmashing 2020-10-29 06:53:43

In a ton of countries such EULAs are not lawful. (For example in Germany you have the right to reverse engineer software.)

2 likes
Moritz Hedtke 2020-10-30 20:15:31

@stacksmashing I'm not a lawyer but I think this may not be entirely correct because of copyright law. But I don't know if this applies for private use.

0 likes
stacksmashing 2020-10-30 20:17:33

You are not allowed to share the binaries, reverse engineering is still completely valid :) it’s even allowed to reverse engineer to find trade secrets etc

0 likes
Lawrence D’Oliveiro 2020-10-30 22:14:53

So when you click “agree” on the EULA, you are really doing it under false pretences?

0 likes
Björn Bidar 2020-11-06 19:54:51

@Lawrence D’Oliveiro The EULA can't modify law its invalid then.

0 likes
Maciej Grochowski 2020-10-30 05:55:12

Please do a video about relocations, is such a important topic about ELF format! That one was pretty good walkthrough.

1 like
Name Surname 2020-12-08 15:36:17

Hello to ITMO students, who are trying to write an elf parser for Risc-V. And thanks for an excellent video explanation.

0 likes
Clement Poon 2020-10-29 23:05:23

I'm developing my own operating system, and this is EXACTLY what i need.

3 likes
Replies (1)
qwerty keyboard 2021-02-15 04:46:39

Might yoink elf for my weird graphing calculator bytecode virtual machine thing.

0 likes
Lawrence D’Oliveiro 2020-10-31 23:41:56

Have you looked at how, say, it compares to COFF? I recall that was popular among some Unix vendors back in the day. IBM (of course) created their own variant, called XCOFF, which Apple adopted for use on the PowerPC Macs.

0 likes
Daniel Simpson 2020-10-28 03:11:41

This is excellent! Thank you so much!

1 like
玩牛牛 2020-10-28 09:21:33

great work. it really helps to understand elf

1 like
Massimo Mengarda 2020-10-27 22:50:40

Nice video! Thanks also for the further readings!

1 like
Antoine PINS 2020-10-30 16:19:18

Underrated channel, it's an awesome video (very useful for the ctf i m doing right now xD), great job ! Can't wait for other videos.

0 likes
Pichaya Morimoto 2021-01-17 17:07:15

10:58 you said that only executable will have PT_INTERP, but in fact, the shared libraries (e.g. libc.so) also have PT_INTERP because they may link other libs as well. Correct?

1 like
Aubob 2020-10-28 09:35:22

Nice Video and Awesome Explanation thank you so much :)

2 likes
Pablo Sanjo 2020-12-01 12:24:16 (edited 2020-12-01 12:24:29 )

Looking forward for the next videos!! great job :)

0 likes
ggzh a Argue With Everyone 2021-02-14 20:09:23

A few time you mentioned some differences between 32 and 64 bit. A bit sad that you didn't said how it is on other systems, like 16 bit and 8 bit. My MSP430 is a 16 bit processor and my AVR is a 8 bit processor, i use GCC and ELF-Files for both of them.

0 likes
Replies (2)
stacksmashing 2021-02-14 20:11:22

And they are either 32 bit or 64 bit ELF files :) it says nothing about the contents of the sections, but about the addressing used in the file.

1 like
ggzh a Argue With Everyone 2021-02-27 11:51:44

@stacksmashing Thank you, i didn't know that. It would probably help to mention that because it is easy to confuse ELF bit width with architecture bit with.

1 like
Rahul Deshpande 2021-08-08 06:58:12

One of the few youtube videos where you have to reduce the playback speed. Great Video !!

0 likes
qianqian wwy 2021-01-09 09:05:33

Great video !!!! Looking forward to your update of ELF!!!

0 likes
Dan Jay 2020-10-27 23:50:22

Thank you for this awesome video.

1 like
João Pedro 2020-10-28 13:21:54 (edited 2020-10-28 13:23:25 )

That was good, now please do as many other file formats as possible (executables or not), including proprietary ones

2 likes
Shivam Sharma 2020-12-28 01:54:55

very good explaination.

1 like
JGSH 2020-10-27 22:03:37

Great to see you're back!

82 likes
edgeeffect 2021-02-07 01:05:01

All these years, I've been thinking ELF was "a Linux thing".

0 likes
Roman 2021-01-28 23:41:44

Thank you! Very cool video!

0 likes
Xeno Idaltu 2021-09-23 13:04:24

KDE has a new program called ELF Dissector.

Please review it!

1 like
Pramit Chaudhury 2022-02-16 12:57:18

awesome explanation

0 likes
Null 2021-07-20 13:48:53

What is different between e_version and EI_VERSION?

0 likes
NTxC 2020-10-27 22:38:47

Great video! Happy to see you back.

1 like
Omar CHIDA 2021-02-15 22:36:20

Great video !

1 like
FloatingBlaze 2020-10-27 23:25:49

Great video!

1 like
Cinnamon 2021-05-18 04:16:27 (edited 2021-05-18 04:17:28 )

Wii stuff on the middle and end of it's generation moved from elf to dol, also iirc the gamecube also uses elf sometimes

0 likes
Linux Inside 2020-11-01 09:01:20 (edited 2020-11-01 09:03:00 )

Long time .
Learned alot .
Next PE please .

0 likes
Pheenoh 2020-10-27 23:42:28

great video :)

1 like
saimon sam 2021-06-02 07:27:22

How can I encrypted ELF 64-bit /32-bit in my python script.. Full vedio needed

0 likes
Laharl Krichevskoy 2021-02-15 04:43:15

ELF was also used in the ps1 and ps2 afaik.

0 likes
Pajeet Singh 2020-11-19 12:05:01

Why can't I read the segments and sections using their c struct from withing the program?

0 likes
HikikomoriDev 2021-02-22 05:13:48

Quite extensive.

0 likes
Hakim 2020-10-28 01:35:04

Glad you back, thanks for the infos

1 like
Thế Hiển 2021-05-27 09:44:38

ELF: headers ok
PE: "This program cannot be run in DOS mode."

0 likes
Tyler Furrison 2021-02-10 03:13:16

an extensible video about the extensible and linkable format

0 likes
Similak Child 2021-03-13 16:18:00

A reverse engineer expert for a hack group called "CODEX" pointed me to this video.

0 likes
Replies (1)
daniel jimenez 2022-01-18 05:16:00

Nice, where do those cool guys gather?

0 likes
Robert Butler 2020-11-30 07:32:36

PT_SHLIB is in fact in the spec. It's just undefined as of right now, so you can do whatever you like with it, but "here be dragons".

0 likes
Replies (1)
Robert Butler 2020-11-30 07:33:51

In that, there's no guarantee that you'll stay conformant if it changes. So yeah.

0 likes
qwerty keyboard 2021-02-15 04:35:25

Fun fact elf is used under brewmp.


Sometimes

0 likes
P3chv0gel 2021-05-21 10:30:04

In depth ELF:
Elf is the german word for the number eleven, which comes after zehn and before zwölf.

1 like
Replies (1)
stacksmashing 2021-05-21 10:30:30

😆

1 like
Enrique Coello 2021-03-15 00:56:51

The Force is strong with this one.

0 likes
NoNameBAM 2020-10-27 22:27:01

oof, the intro shows the E being "Executable", but in the title, it's "Extensible". Voice says "Extensible". Executable is right though lol

15 likes
Replies (2)
stacksmashing 2020-10-27 22:28:19

Oof, thanks! It used to be called Extensible, must’ve gotten confused eventually :)

11 likes
NoNameBAM 2020-10-27 22:37:26

@stacksmashing Oh, seems like it actually was formerly called Extensible, but now it's Executable.

7 likes
Lawrence D’Oliveiro 2020-10-29 02:29:11

12:56 You can have a segment which is both writable and executable. For example, this can happen to your program stack segment if you use the GNU C extension of declaring one function inside another.

0 likes
Borealis 2020-12-03 06:14:33

... are you saying that the Wii and the PS4 share the same executable format?

0 likes
Lawrence D’Oliveiro 2020-10-29 02:10:49

5:23 I suppose one should distinguish between revisions to the fundamental architectural ABI, versus revisions to the ABI for this particular library (public struct layout changes etc). Is this for the former?

0 likes
MANNY 2020-11-13 06:35:03

Hopefully you can make a video on hacking the game and watch

2 likes
Alejandro Alzate Sánchez 2020-11-18 23:02:28

If you know the existanse of memtest86.elf you know something about /boot

0 likes
John Duncan 2020-11-03 09:34:23

I remember writing an elf parser in a coffee shop when I was homeless. Good times.

3 likes
Replies (2)
Tanline666 - Commenter 2020-11-14 03:39:56

Are you ok now?

3 likes
John Duncan 2020-11-14 03:46:02

@Tanline666 - Commenter very ok.

2 likes
Dora Militia Katie Melody 2021-05-06 16:39:33

Elf is Also used in PS2

0 likes
Chapoly1305 2021-02-15 07:42:33

The video title is incorrect. Executable and Linkable Format, not extensible.

0 likes
Lawrence D’Oliveiro 2020-10-29 02:04:11

2:33 A.k.a “BSS”. That’s an acronym from the early days of Unix.

0 likes
saimon sam 2021-06-03 07:29:58

How can i thia encryption, pls full vedio needed and WITH script installing full vedio.pls pls upload it

0 likes
bachir abdelwahed 2021-01-10 09:51:16

I didn't understand the part of et_exec : it is doesn't support position independsnt executables? That is weird because I can compile any program without -no-pie and I can execute it on my system!

0 likes
Replies (1)
stacksmashing 2021-01-10 12:59:13

The type ET_EXEC only supports position dependent code. So when you compile with -no-pie the ELF file will be of type ET_EXEC. If you compile with PIE it will be ET_DYN.

0 likes
Lawrence D’Oliveiro 2020-10-29 02:30:11

13:17 Obviously done for alignment reasons.

0 likes
Szekeres Tamás 2021-02-23 21:02:54

My mind just blew up at the half time, it was too much information O_O

0 likes
Replies (1)
excited box 2021-02-27 21:22:23

Especially without explaining what things are. If I don't know what something does or is used for, it is pretty useless to know where in a file it is. It would have been better to make a series and tackle 1 part in each video. This video should have been split into at least 6 videos.

0 likes
rita li 2021-02-14 10:27:57

Elves terbuat dari apa sih ka?

0 likes
ch282 2021-02-14 15:30:07

these videos are interesting as derp

0 likes
Lucas Santana 2020-10-29 23:51:47

I was reading the Practical Binary Analysis by Dennis Andriesse when this video arrived...

1 like
Kangalioo 2021-02-19 23:30:07

0:08 well what is it, "executable" or "extendible"?

0 likes
Replies (1)
stacksmashing 2021-02-19 23:44:26

Yes!😄

It used to be extensible and now it’s executable and naturally between talking about it and making the thumbnail I got confused 😅

0 likes
_sivizius 2020-10-28 00:46:51

So, basically, its a messy context-sensitive grammar? Or is ELF actually Turing-complete?

0 likes
Replies (1)
Bon Bon 2020-11-02 13:52:07 (edited 2020-11-02 13:54:08 )

Didn't expect to find another pony here :) /)
As for your question: I don't think ELF files have anything to do with grammars. ELF is just a container for binary data. How those data are interpreted is up to the loaders that load and interpret them. So Turing-completeness doesn't quite apply here as well.

0 likes
ChaosMinecraft 2021-02-20 23:19:05 (edited 2021-02-20 23:19:31 )

Now stop there, an ps2 has one .ELF File for every game...

0 likes
microcolonel 2021-02-18 03:37:30

Too extensible, and waaay too much linking.

0 likes
Harel R 2020-11-06 18:03:09

So the sectors, which hold the code and data, are loaded to memory inside segments. But nevertheless those can be stripped and irrelevant in runtime. It sounds like there's some kind of contradiction.

0 likes
Bad Egg 2020-11-23 16:21:04

Me.Exe
Her.Elf
Impossible to compile :'v

0 likes
Clepco Tletah 2020-12-24 08:28:24

The last time I watched your videos you were ghidra ninja

0 likes
SumeaBizarro 2021-02-17 12:44:39

"Most BSD's and the playstation 4" is a little reduntant to say; since PS4 is in the category of "most BSD's" or, a BSD within "most BSD's" - so is PS3. As far as I understand, Playstation 2 is not, entirely at least, but still also utilized ELF as well and by logic while not the only format for executable software, Wii's compatibility with ELF should also stretch back to gamecube and be more usable on that platform.

Also most software as far as I (as a hobbyist, and user rather than developer) understand, are preferred to be in DOL format on these two "very different" (joke: they're not) systems. ELF is used but mainly for debugging or older homebrew and what short research showed the mainly used executable format of Wii and Gamecube is not even a cousin to ELF, but DOL can be derived out of an ELF, making it probably more a debugging option for software rather than main format like with PS2, PS3, PS4, PS5.....

0 likes
Anton 2021-05-18 14:53:46

It's not "Extensible", though. Why didn't you unabbreviated it correct?

0 likes
Replies (2)
stacksmashing 2021-05-18 14:58:45

Executable and Linkable Format (ELF, formerly named Extensible Linking Format),

0 likes
Anton 2021-05-18 15:16:37

@stacksmashing so, yeah, it was very long time ago. nobody calls it "Extensible" for at least 20 years already.

0 likes
Lawrence D’Oliveiro 2020-10-29 02:06:44

3:09 More than you ever wanted to know about shared libraries: https://akkadia.org/drepper/dsohowto.pdf

0 likes
steadyforge 2020-11-13 11:31:16

Hows the Nintendo game & watch coming along?

0 likes
TC royce 2020-11-04 16:43:45

Godsend

2 likes
kabalu 2021-02-18 19:45:54

hey, tell me more about the mafia

0 likes
Alperic27 2021-02-18 21:26:25

Not at all an ‘in depth’ ... it is basically a reading of the doc

0 likes
Pajeet Singh 2020-11-19 18:14:23

man elf

0 likes
Ashton Snapp 2021-02-12 18:54:44

E

0 likes