I'm Sergei Bratis. This is Rebecca Shapiro, who did all the work. I am a research assistant professor at Dartmouth. She is a PhD candidate in our lab. And, you know, for who we are, well, you know, we're here from the frozen north, the northern Appalachia, and it's a live free or die state. And this talk will be, as Travis just brilliantly introduced it, about the deep magic that is being used everywhere whenever a program runs and is severely underappreciated as any deep magic is. So what we're going to show you is that there is enough power in just the linker loader to be borrowed to write in the ELF metadata, just in ELF metadata, not malformed or anything, any program you might care to write, any transformation of your process memory, any transformation of your runtime that you care to do, which is to say it's Turing complete, it's got loops, and Bex built it. The interesting thing about this is, besides illustrating a philosophical principle on the ELF, which I will expound profusely in just a few moments, it happens before memory protections are set, and it doesn't care about ASLR at all. Because this is the linker loader, this is the thing that finds the dynamic symbols. It's the keeper of the names. And ASLR is nothing to it. So with that in mind, you know, I'm sure you can find some interesting, obfuscation, offensive, defensive uses of this thing. We're going to talk about the general mechanism, and what it teaches us about what our operating systems really are. Because this is what hacking is about. There is the computer as taught and programmed, and then there is a computer as it exists, really. We find that computer through exploiting it. If your system has not been exploited, then you can use it. You don't understand it. And exploits these days are no less than programs running on the target. They come in encoded as crafted data, although there are other delivery methods, but this is the most common. And they reliably cause the target to run a computation that it was never intended to run. It happens to do that by leveraging a bug, an error, a feature, these are known as primitives, and there is a brilliant introduction in FRAC 61, Article 6, by JP, that talks about this particular one, primitive, which looks like a really weird assembly instruction. AAB, A4, BMO, right? Four bytes, almost anywhere. And if you're familiar with format strings, percent n is that thing that you can leverage to cause the internals of the print formatter converter to do a computation for you that was never, ever expected and can be quite a nasty surprise to the owner of the system. So, in the slide deck on the discs, on the CDs that you got, I have a rather wordy set of slides. I have slides explaining why this is interesting. And then, of course, just a couple of hours before the con, I got this great idea. Hey, there'd be people who like HP Lovecraft here. Possibly. OK. So, weird machines. I'm going to talk about this term that got coined when I was giving a talk at Felix Lindner's Rikiri T-Lab's workshop. And, you know, that, I absolutely love this picture. This is what 20th century warfare was supposed to be in, you know, in the eyes of the artist from the 19th century. So talk about weird machines, cyber war. Probably our ideas of cyber war are going to be just as accurate. But coming back to what is the real computer that is in front of you? What is the real system as opposed to what is the model of it? We discover that with exploits. And then you ask yourself, well, what are exploits? Are they data or code? It's interesting. Exploits are, of course, proofs that your machine is capable of a computation that you have not foreseen. It's approved by construction, by shell dropping. You can't really argue with a root shell. To put it simply. It's a code. Fx. But exploits show up as inputs, but they run on the target. So what the hell is up with that? Is this a von Neumann machine or some strange Harvard architecture machine or maybe Miskatonic University of Arkham kind of an architecture? So an exploit is a weird stored data program running on the target. And if you think about your code as this. . . . . Lovecraftian entity that you just summoned up to work on your data building your mystic pyramid. This is actually Sotath. He is the gate. He holds the key. He is the key. So ... . . . . . . . . . . . . . . . So, yeah, we're not summoning anything in this editorial. . . . . . . . . . . . . . . . neither can Dartmouth. So this is your code. Its tentacles reach into your memory and fiddle with bits of data, pulling it up, pulling it down, rearranging them. And this is how you, you know, you build the computation that you want. But if you look carefully enough and this is how people think of their code, oh, there is code, there is data. But if you have a bunch of little octopi-like things, each with a small number of tentacles, working on a very small piece of your data that you control, and if some of them are interesting in that they present a bug or a feature or a primitive, then you can build a machine out of them by manipulating this metadata. To this machine, your metadata is byte code. The primitives themselves are the little implementations of that byte code. And this has been the hacker folklore of advanced exploitation since at least 2000. I take absolutely no claim except to naming it and dragging it out as a sort of a coherent body of folklore. If you don't take my word for it, look at Halberd Flake's talk. Which he gave at Infiltrate last year. Where have we seen that? Well, this is of course how virtual machines work. A virtual machine has this byte code and you implement those little byte codes. And the only difference between a weird machine that is what runs your exploit, the collection of your primitives that pass the control and data flow through some areas of memory that you control. Is that for a virtual machine, your byte code is usually contiguous. For a weird machine, it's not. So that tape is really broken. And so think of your target that does anything interesting as this rich dancing, singing, milk giving, wooly pig. Right? And it's also a code running pig. If you can, if there is enough complexity in the target, how is this for author's Clark of Fourth Law. Any complex enough memory reading writing program is indistinguishable from a virtual machine on its data, as long as you can craft the data. Input data for a complex enough program is indistinguishable from byte code. For the pieces of the grand monster that you manage to decompose, unwind the tentacles, etc. And so it's like if you take any of these tentacles of the monster and isolate which memory locations are serving for your implicit flows. And so the bit of philosophy is this. Code doesn't work on data. Data runs on code. Input strings run on your parser. As the tentacles reach down, there is strange bubblings in the monster, in the old one. And this state, the state changes that you create in it are your expected computation, are your exploit. You can make it explode. You can make it build not a mystic pyramid but something more useful, such as a root shell. Packets run on your TCP IP stack. Packets are little programs that run on your TCP IP stack. The changes in the state of the stack are what you're after. Heap metadata runs on the heap manager. Format strings run on the print. And ELF metadata runs on your runtime linker loader, which Bex is now going to present. So think of this entire process and this entire folklore as bringing the idea that you're programming weird machines when you're exploiting something and this is all over the place, really. This is the art of boring code and chaining up the primitives and creating, setting up, instantiating and programming weird machines. We're showing you a weird machine that's there and that's well formed. When it någonting, I don't mean shut out old machines. I mean leftover machine. choices to build it. The less disk shaping it, the less dirt. And the more data needed it, the less transparency. But ultimately work properly, that changes. We see would love to see its users for more interesting purposes with that bex will take you through the wonderful world of elf thank you sergey a magic forest so i'm just going to try there's a lot of information i want to give you um not enough time so i might end up skipping um but i really just want you to get an idea of what's going on and you can continue if you're interested look at the code i'll post a link um let's start off you know talking about the elves um what's point what it is point uh the linker and loader and so forth look at some private work um and try to give you enough background so you can understand how we're using these primitives and getting something that really works um outside of what you would normally do with elf metadata and hopefully you'll like hopefully you'll from the uh philosophical reverie that i did so what basically the point of elf is just how the different components of the gcc tool chain communicate um you have the assembler static linker and so forth but in the end there's a metadata that's structured so that each component knows how to act on on its input um how to lay it out how to compose it and so forth and mostly i'm looking at the runtime loader and that's all that's all i care about um there is a lot of information as in these alt files and i'm not using all of them not constructing crafting most of it it's but i'm looking with symbols um relocation entries and so forth um well that's pretty much all i'm working with and the dynamic uh linking information there's a dynamic table that helps tell the runtime loader where everything is um and that is what i work with for for the gcc tool chain and so forth um and i'm looking at the runtime loader and that's where this tool uh set i'm making or i'm calling a tool set and just to give you some idea of how many different sections are there in elf file each one with its own function in constructing the runtime in the modern binary more than 30 yes so all data and or code metadata so forth is contained in elf sections um except the section headers themselves and the segment headers themselves um typically there's one section header and then there's another section header per section and the header just helps you look up where in the file it's the section is supposed to be understand its permissions in memory um read write execute um where it should be loaded and so forth um and most sections contain either metadata and as a table um of the same type of metadata in a single section um null terminated strings for the string table mixed data uh something statically uh allocated um and and and and and and and and and and and and and and and the code itself which is called text and there are a couple sections i'm focusing on for this talk uh they are the most useful in trying to craft metadata and get some extra computation out of the runtime loader and first with the symbol table it symbol tables uh provide um information on all um variables all um functions and so forth so you know where it's located some times there's a value sometimes there's but there's other information on the size how to look it up for the for the linker um and then here's just some example symbols there is one that's a variable standard in and has a preset value um second one is a function also has some value in there and then the definition so this is the structure itself there's um a point a name which is actually a pointer into the string table there is some um a function and then there's a function which is a um some information about it uh value and size and uh if i may and think of this data as something that the dynamic linker loader eats and uh finds you the right library loads the right library and uh connects up the little stub that your call uh goes to uh in the procedure linkage table through the global offset table and uh through a little um uh this little stub the dynamic linker gets called finds uh the uh symbol and loads the symbol into memory and uh if uh since the lookup is actually by name there is a little hash table involved in that and it just jumps around that hash table until it finds the match so that it knows uh what symbol um is uh there uh to be loaded now the thing about this is that the complexity of these operations is pretty damn high and it starts resembling your uh lovecraftian old one or that woolly singing mill giving pig and so the question is should we manipulate that data what can we get? And I'm not really talking about buffer overflows. Assume that it's perfectly legal. It's just that some of those offsets are going to be pointing at other structures. And think of my own grandpa in the process. By creating this assortment of interlinked data, you can actually drive this thing into insanity or into executing any given program. So I will continue. As we like to say, however, the ELF metadata is just in our vision in the way we see it. It's the static linker's love letter to the runtime loader. So for relocation tables this is information from not only the runtime loader but the runtime linker. And it the rel is the data. And it's the data that's being sent to the runtime The first one I listed is for the runtime loader exclusively and every entry in its process during load time. And the second one is for the dynamic linker, the PLT. And that's processed as needed at runtime. Information contained in these entries include offset, where you are eventually writing the output of this operation and usually you calculate some sort of address, write it in. Info includes the symbol that if there's a symbol that the entry works with, it's a symbol number. Also the type of relocation entry is there. And then for AMD64, there's also addendum which allows you to, depending on the type of relocation entry, add another value into the final computation. Now imagine, this is the thing that keeps the ASLR working. So you've got this code that you've compiled and you're about to load at this address. Which is in the ELF file. But this is not where you want to load it. You want to randomize that base or you can't load the library at that address because another library is taking that up in the process's virtual address space. And so what you need and what you are getting out of this mechanism is a little automaton that goes and patches your binary code or data based on these data structures. So you look at this. You see a useful auxiliary mechanism for relocating data, moving it around in memory. When we look at this, we see this strange creature that touches, you know, lifts up those relocation entries and writes other things in memory. And by the way, we're inspired in this by the locreate, by scape. So look it up in uninformed number six. That's awesome. So again, what you see is a machine that you can program by crafting those relocation entries. Not making them illegal or anything. Just driving that engine to do something more. So two other sections that are interesting are the global offset table and the procedure linkage table. And the global offset table is merely a table of addresses. It's used by the linker to look up any LinkedIn functions that you do not know or exactly they reside until runtime. It also contains a pointer to the linker function that's actually invoked during linking, runtime linking. And this link map structure that contains everything you really need or the linker needs to perform the linking about for each. And there is one structure for each library for each. There's the ELF object. That is there. There is a link map structure. The PLT contains instructions that just work in tandem with the GOT to invoke the fixup function if needed or to invoke the function itself if it's been patched. Bex, I think you might want to actually start explaining those symbols. It's a global offset. This is a global offset table, obviously. You probably got the relocation table before. Which is hard. Which is that one. It's been so long. There's a procedure being linked to another procedure. Oh, yes. This is a procedure linkage table. Exactly. Okay. Shall we go on? Yes. And this dynamic table, which contains all the information needed by the runtime loader. And there's basically a tag that says what the value is. And I will ‑‑ these are a bunch of ones that we use. Okay. Let's see if we can find them in our work. Yeah. Remember, these are things that point at other things. These are offsets of strings in symbol tables. These are offsets into library files where that symbol live. These are offsets into a section where things need to be patched on relocation. Now imagine them having a great family. I'm going to continue. Yes. This might ‑‑ all this information is in the headers themselves. But there's a separate table that has a copy of this information just for the linker. And the dynamic linker and runtime loader, in the end, after it's loaded, only work with this table right here. So if it ever needs to know where the relocation entries are, it looks at the value of DT Rella and it knows the size, symbol, location of the symbol table, the location of the GOT, and anything else that's needed for cleaning. And that's what we call a clean execution in the runtime loading and linking stage. So just to give you an example of what happens during loading and linking, suppose we call exec on ping. What happens in the kernel is there's initial setup of the address space where we have the executable mapped. We have the loader itself mapped and a stack. And an entry point is set to invoke this loader. And so now in user space, the loader takes over and starts sending up more things. It looks at the needed libraries. It builds in a heap, stack ‑‑ oh, the stack was already there. And then it sets the entry point to the executable. And that is ‑‑ in that part, that's all we are working with in that part of the process. And you'll see that red is execute only, yellow is read only, green is read right, which is important to us. And each library has its own address space for the read only, read right, executable code. And this is an actual memory layout of ping. I took out some parts to fit on the screen. And the stack is at the bottom. You can't see, but it's on the slide. It's just hanging off the bottom. So going back to this, let's zoom in to the executable. And the nice thing is that the executable is a little bit smaller. Normally during run time ‑‑ sorry, normally during execution, even if you have ASLR, you have to actually put in extra compilation options to get the executable itself to be mapped in a different location. But I haven't really run into that. Even with ping, which is something that set UID root, the executable is always mapped to the same spot, at least in Ubuntu, that version that I was working with. So if we zoom in and see what's there. All these sections I was talking about are mapped in. Some in read, execute only space. Some in read only. And global offset table and data, so forth, in read right. And then something to note is the dynamic table itself. During the relocation process, I have found that I can write to it. I haven't actually looked to see at what point it's read only. But after everything is set up, this dynamic table is read only. So in our perspective, we are interested in these entries that we see, the symbol table, the relocation entries and so forth. And the DGOT we're interested in, which is actually writable. But then there's also the metadata, these link map structures, which is actually part of the linker loader memory and heap. And so these link map structures have, is what we end up working with to do what we need. This is not the entire structure definition, just things that we end up working with. It contains the base address of where the library is loaded. It actually contains pointers to the dynamic table entries that we're interested in. It contains a bit to say whether or not it's been relocated before. And some other things that we end up working with. Just to get this code, this engine working as something that's Turing complete. But I won't go into details. And then also, since every ELF object that's loaded has its own structure, it's in a doubly linked list. And so there's next and previous pointers in each link map structure. And that's how, they're ordered in how symbols should be looked up. So there are fun ways to craft ELF metadata. And may have a lot of fun ways to do that. And in fact, 61.8, as we used it to inject object files. You can intercept library calls to run injected code. And so there's been work by Cesar Mayhem in that. Resident in attacker built library. So you can inject code into a library and get that loaded either by playing with some environmental variables LD preload. Or you can play with the ELF structure. And put another entry in the dynamic table. And this is the point. You do not understand those structures until you make them do something interesting. Then you actually know what the code behind them. What that automaton is doing when it's getting that data. And so cheating the ELF by the GRUG. I totally recommend. This is a classic. That explained this for the first time. And this was for the longest time. This is a detailed excursion into how these things really work. And so Locreate is an inspiring worker. Helped inspire what we did. It actually uses relocation entries to pack and unpack binaries. And we're kind of taking that a step further by just using relocation entries to act as code itself. Or to have an effect. Some sort of Turing complete machine running in just runtime loading. But Locreate is a patcher. So it can go. It ran over code. And transformed the code. Because hey. If we're rewriting bytes. We need not rewrite just addresses. We can rewrite opcodes and immediate as well. And so how is that for an obfuscator. The obfuscator packer. Unpacker. But let's build something bigger with loops and branches. However in the tool chain we're working with. The text section is actually not writable. By the time. The relocation entries are processed. So he was working with PE. And it worked. So here's our warning. I actually am proud to take a little side note off of this. Yesterday I got it working with ASLR. With when the libraries and the stack were randomized. But this is specific to our architecture that we're using. AMD 64. On Ubuntu. There's no reason that it won't work on others. But the details are specific to this. So first. We're going to do a little bit of a demo. So first off. We need our symbol table. And relocation entries. In a place that we can read write. Normally it's in read only. So we inject it using the RC toolkit. Right there. Below the data. And there's space there. And it's a great toolkit. And takes care of any rewrite. Updating the headers for us. So for the relocation entries that are used. There's lots of them. And we only need three. There's copy. And basically what it does is. It acts as a mem copy. And you provide. You give it a symbol. And the symbol value is treated as a pointer. Where to copy from. The symbol is also. You get the size of how much to copy. And then you copy to the offset. Specified in the relocation entry. There's another version. Where you give a symbol. And an offset. With a value in the symbol. And copies that over into the offset. And it adds an addend. If there's one. And the base of the library. Since we're working in executable. The base is always zero. Unless it's actually randomized. It's mapped to the. Well it's actually not zero. It's I believe like 40,000. But yeah. If this doesn't look like bytecode to you. Then I must have confused everyone. Yeah. I'm not sure about anyone else. And then so the last one. Relative where it doesn't use a symbol. It's just addend plus a base. If there's one. And you write it into the offset. Specified in the entry. So we have arithmetic. Close. We do have arithmetic. That's very straightforward. Another thing we use. Is these indirect functions. That are supported by the runtime loader. And these are special types of. Symbols. In which the value of the symbol. Is actually some function. That runs. And whatever is returned. Gets written into the offset. And we found it useful. Because you need branching. Normally here I'd have the video. But a lot of you saw it already. Many, many years ago. You don't want to hear me sing. So what did we do? We decided to find the simplest. Most annoying. Programming language. To work with. And implement that in these relocation entries. So traditionally there's eight instructions. There's a notion of a tape. And a pointer into this tape. And you can write increment decrement values. And test and branch and output byte. So you have standard out. Or printf or whatnot. Or you can read in a byte. Get char. But we actually are not. Worrying about those two. And I can imagine implementing it. But that's not in our version. So as an example. If we do plus angle bracket minus. So we increment byte at the pointer. We move the pointer. Then we decrement the byte. This is what happens. We increment the byte. The tape pointer. It gets moved. We decrement. And it's fairly straightforward. It's just really hard to write anything useful in. Because that's hello world. You know. Think of it as the Turing machine. But more fun. Or more tingling in your brain. Fun. Fun. You know. So this is sort of the process. Of compiling brain fuck into elf metadata. You have an executable. That you specify. You have your brain fuck source. And there is some configuration that you need to do. And I've automated it as much as possible. You run. You invoke this compiler. And you get just another executable. And that's it. You hand it to the loader. So first of all. You write your exploit in brain fuck. Okay. Actually you can compile to brain fuck from C. Or your favorite functional language. I feel like we'll hit some limits though. On size. It's not the. We can do better. We can optimize. Oh my god. It's full of symbols. Well it's full of relocation entries. So this is the configuration. There's a lot of stuff we collect. At compile time automatically. And so the. From the dynamic table actually. So the address that they got. In theory. You can get some sort of ROP gadget. That returns zero. So it's not. We don't have it done automatically. But you can imagine if it exists. And the location of memory. Of some other things in the dynamic table. And then data collected at run time. Using everything else. Is the base address of lib C. The loader. And a stack location. Which that's new. We found there's the auxiliary vector. Which is basically. Well the loader's love note. To the executable itself. With all its arguments. Environmental variables. Etc. And so I can get to the loader. I can read this value. And get some offsets. Yeah isn't this nifty. Not only the executable knows. How to call the loader from its stubs. Obviously it needs to. But there is a pointer back as well. So I am not giving you the full setup. You need to read the code for that. I'm trying to simplify things. But to the basics of what you need. For a brain fuck. There's more you need. If you wanted to execute cleanly. And then have. Your executable itself complete. There you need more than just this. And I put a little note at the end. So for the symbol table. We inject a couple symbols. The address. There's one that holds the address of the tape head. Or wherever the tape head is pointing at. The copy of the tape head value. And address. Of. Oh yes. An address of this symbol. The copy of the tape head value. That we need. So that we can do some copy operations. So observe. The tape is now this. The tape. Is now spread through. The elf metadata. But that's okay. Because you see an RTLD. I see a bytecode interpreter. The last symbol is just the ROP gadget that we need. Something that returns zero. An address of that. And for the relocation entries. We actually have. We have some setup that's needed. So we can clean up. And so we can find all these libraries. Base addresses of libraries. And then we have all the instructions. Then we have some cleanup instructions. And I'm calling them instructions. They're just relocation entries. That do something useful. And then some cleaning. And then the originals. So we can actually have the executable. Execute after we do whatever we want. So this is how the tape pointer looks. To us. The tape head is pointing at. And a copy. And just as a note. Anything on the tape needs to be in read-writable memory. And yes. And not just the tape though. The relocation symbols as well. Because we edit them on the fly. But luckily this is the case. Because the memory protections. The bulk of the memory protections. Get set up later. So we need. We need two instructions. I'm sorry. Two instructions. Movement of the tape pointer. And I'll show this little demo. That's not a demo. It's a animation. So first we get. We calculate. We have the offset of tape pointer value. Basically the next symbol down. And then we have. So we can start writing to it. And copy it over. We have. so the symbol of the T pointer sorry what we do is the T pointer is a pointer to the symbol we read that out and we end up using good morning me so yes what happens here is since we control the relocation sections and we're using them as tape we have to embed the brain fog interpreter with all of six it's brain fog constructions into the pieces of code that work on the tape luckily we can craft those entries luckily we can craft those entries to point out at other entries so that we can start building loops and branches so instead of actually giving you a step-by-step since we're low on time i'm going to just point out some interesting things so in addition to subtraction we end up having to rewrite one of the relocation entries to get this done to do unconditional branches we've realized that when the uh... relocation entries are processed it actually steps through this link map structure and goes to the previous one and move to the previous one so what we need to do is set the previous to our current so we can start processing relocation entries in ourselves again so we have go to yes this is the primitive this is the implementation of the bytecode that we are uh... creating and uh... the fact that uh... a particular pointer is not going to be able to do that is pointing and uh... then is being followed to the next primitive enables us to do looping and so we have to do some extra work to make sure it loops again because after the first time memory permissions are set uh... it doesn't try to relocate twice and there's yeah that sets some permissions so we can't rewrite ourselves again uh... but we use this little chunk right here to end up clearing out this relocated bit so it will process itself again later which is very nice and so we have loops and we also need to rewrite uh... some of the relocation the dynamic table entries to point to where it should go next and the new size of the relocation entries that we're processing but again the functionality is helpfully already there yes this is what the relocator actually does all of itself so to do conditional branches we use the um... indirect function symbol and the interesting part is this shindex if it's one it treats it as an indirect function if it's zero it treats it as a whatever values in that symbol is just a value so we end up doing it is telling that to overwrite this end um... which basically end is where the relocation entries stopping process so we can either set it to zero so the next time the loop executes it stops or we can set it, it ends up being something way bigger than any of the relocation entries, and it will keep on going, and we can fix everything up in the end. And so we have branches. We have an instruction that behaves differently whether it reads a zero or a non-zero. So to get actual details of how we do it, I look at the code. It's on GitHub. I'm going to skip the demo because I want to move to something a little more practical. We injected a backdoor into ping. And so by doing this, we don't use the brain fuck. We actually create our own primitives to start following pointers. At a known place is a pointer to the link mech structure of the executable, and from there, we can start finding where the libraries are. And from there, we can figure out what addresses to write into the global offset table so when the functions are invoked, it invokes what we want instead of what the linker tells it to since there's a value there. And so what happens is we rewrite the symbol over and over and update the value through these relocation entries and how they work with the symbol. And what we end up getting, we can get the base address once we get where the link map structure is itself. And from there, we can find any function in the library that we're linking. And so I do want to demo this. And this is the version of ping that I have. It has this interesting argument, this type. And I actually have, the way we work this is we tell staircase comp to exec instead. And that's how we can get a shell. And we also need to tell it not to set UID back. Ping is set UID root. And then eventually drops privileges. We can trick it into not dropping privileges. So your output is all of your memory space in the process. And you can rewrite it any way you like. So why not rewrite it to give yourself root when a particular option is invoked? So instead of giving a live demo, because I'm a bumbling idiot when it comes to typing, here is a video pre-recorded demo. And you can't read it, but that's fine. So I'm just showing that there's this type that we're playing with. And we're going to do that. We end up, oh, so first we compiled our new relocations entries into there. And we set UID ping. So, because it needs to be set UID. And when you run it normally, this is running at double pace. I don't know why. I must have changed something. So let me pause for a moment. So let me pause. So ping works normally with the new relocation entries. Or at least you can ping normally. There's probably some other things that might. Break. But you can ping normally. But when you put in dash T and then we just give it backdoor dot T dot shell, it just invokes bash without any arguments. It's just otherwise you get crap in there because we are not using it properly. But what happens is once you evoke it with this, suddenly it calls exec on backdoor dot shell. And we prevented the root privileges from being dropped. And now you have a root shell. And we go on to just show that there is no difference in the code itself. And since it's in double time for some reason, maybe we'll have time to see this. There are differences because there's different sizes. We injected metadata. So SHAs are different. But the code itself is not. We only eject metadata. And I am going to probably. Not let this finish running. I'm going to skip ahead a little bit. So I can show you. Yeah, you'll trust us that if you dump out anything that could be disassembled and compare the disassemblies, they are exactly the same. The only difference in all of the program compiled to rewrite your memory at runtime is in the ELF. So there's difference in. So the left side is our injected version. The version of ping with the injected entries. And the right side is the original. And so. The. The original entries are still there. Ping still executes. But before all of them are our injected ones. And the same goes with the symbol table. But we inject our symbols after the original symbols. Because everything is referenced from the beginning of the symbol table. And we don't want to mess with the linking that it needs. Let's get out of full screen. F11, of course. So that's sort of everything in a nutshell. Again, I suggest going to our website. But I need to thank Sergey for leading this. And Sean, who's my actual thesis advisor at the moment. For putting up with me not doing the work he wants me to do. And Greg Q for doing a lot of great work. And the RSA toolkit for allowing me to inject relocation entries. Mayhem, Skippy. And then the noun project. Where I got all these cool little things. Thank you. Thank you. Thank you.