If someone with decent C experience is interested in working on github.com/HardenedBSD/ha (HardenedBSD: Support multiple userland heap implementations), let me know. I can help you once you are at the point that you're building HardenedBSD and can make modifications to the libc.
Conversation
Can message me on IRC (strcat on freenode and oftc) and I'd be glad to help with it. Dropping it in as a replacement for jemalloc should be very easy. This is the entirety of the work for Android in Bionic: github.com/GrapheneOS/pla other than integrating the extra API extensions.
1
2
7
It needs internal porting to support FreeBSD/ too. It will be integrated upstream into github.com/GrapheneOS/har once someone is building it and identifying / resolving portability issues like needing to disable mremap usage. It already supports Bionic / musl / glibc.
Replying to
It would also be nice to set up the build system integration to have it as the internal malloc implementation in , rather than the current support for interposition via dynamic linking. Can be built as a static lib and linked into musl just like the approach for Bionic.
1
2
I can also provide some guidance on other libc hardening work including implementing production-oriented cross-DSO CFI (unlike compiler-rt), cross-DSO SafeStack, various smaller things like read-only-after-init data / setjmp mangling / internal function pointer protection, etc.
3
