Articles tagged #rust
A new website for 2020
Hi everyone. Has it been two months since I last posted something? Yes it has!
That seems like a nice round duration, so let’s break the silence with a few announcements.
I have a new website
If everything goes well, you’re on it right now.
Does it feel okay? Take a minute to accustom yourself to your new surroundings. Identify potential sources of fresh water. Gather some supplies with which to fashion a makeshift shelter.
Thread-local storage
Welcome back and thanks for joining us for the reads notes… the thirteenth installment of our series on ELF files, what they are, what they can do, what does the dynamic linker do to them, and how can we do it ourselves.
I’ve been pretty successfully avoiding talking about TLS so far (no, not that one) but I guess we’ve reached a point where it cannot be delayed any further, so.
A no_std Rust binary
In Part 11, we spent some time clarifying mechanisms we had previously glossed over: how variables and functions from other ELF objects were accessed at runtime.
We saw that doing so “proper” required the cooperation of the compiler, the assembler, the linker, and the dynamic loader. We also learned that the mechanism for functions was actually quite complicated! And sorta clever!
More ELF relocations
In our last installment of
“Making our own executable packer”, we did some code cleanups. We got rid of
a bunch of unsafe code, and found a way to represent memory-mapped data
structures safely.
But that article was merely a break in our otherwise colorful saga of “trying
to get as many executables to run with our own dynamic loader”. The last thing
we got running was the ifunc-nolibc program.
Safer memory-mapped structures
Welcome back to the “Making our own executable packer” series, where digressions are our bread and butter.
Last time, we implemented indirect functions in a no-libc C program. Of course, we got lost on the way and accidentally implemented a couple of useful elk-powered GDB functions - with only the minimal required amount of Python code.
The article got pretty long, and we could use a nice distraction. And I have just the thing! A little while ago, a member of the Rust compiler team stumbled upon this series and gave me some feedback.
GDB scripting and Indirect functions
Working with strings in Rust
There’s a question that always comes up when people pick up the
Rust programming language: why are there two
string types? Why is there String, and &str?
My Declarative Memory Management article answers the question partially, but there is a lot more to say about it, so let’s run a few experiments and see if we can conjure up a thorough defense of Rust’s approach over, say, C’s.
Dynamic symbol resolution
Go back to the homepage.