Technical notes on Linux kernel internals, kernel hardening, memory safety, and low-level systems programming.
I use this section to develop longer articles from source reading, experiments, and small systems projects. Drafts are published when the structure is useful, even if the final article is still being refined.
Current drafts
Type Isolation in Kernel Allocators: Linux SLUB vs XNU Zones
A draft comparing Linux SLUB and XNU’s zone allocator through the question of allocator type isolation.
The article currently focuses on:
- why Linux SLUB can merge compatible caches
- how XNU zones keep allocation domains separate
- what these choices mean for memory use and hardening
- how cross-cache attacks relate to allocator behavior
- Linux hardening mechanisms such as
SLAB_NEVER_MERGE,RANDOM_KMALLOC_CACHES, and proposedSLAB_VIRTUAL
Status: in progress.
A Small RAII Wrapper for POSIX File Descriptors in C++17
A draft explaining the design of a small C++17 RAII wrapper for POSIX file descriptors.
The article currently focuses on:
- what a file descriptor represents in Linux
- why raw descriptor ownership is easy to get wrong
- move-only ownership
- safe cleanup
close()semanticsO_CLOEXECreset(),release(), duplication, and swap
Status: in progress.