From 9d703608e9fae3fdb9d99a1424ed94045394d046 Mon Sep 17 00:00:00 2001 From: inference Date: Mon, 12 Jun 2023 17:39:13 +0100 Subject: [PATCH] Update GrapheneOS hardened_malloc documentation from version 0.0.0.3 to 0.0.0.7. --- security/hardened_malloc.adoc | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/security/hardened_malloc.adoc b/security/hardened_malloc.adoc index 2f77bcb..d60be7b 100644 --- a/security/hardened_malloc.adoc +++ b/security/hardened_malloc.adoc @@ -1,9 +1,9 @@ = GrapheneOS hardened_malloc -Version: 0.0.0.3 +Version: 0.0.0.7 -This documentation contains the instructions to use +This documentation contains instructions to use https://github.com/GrapheneOS/hardened_malloc[GrapheneOS' hardened_malloc] memory allocator as the system's default memory allocator. These instructions apply to both musl and glibc C libraries on Unix-based and Unix-like systems. @@ -27,9 +27,10 @@ of guard pages. `make ` `CONFIG_N_ARENA=n` can be adjusted to increase parallel performance at the expense of memory usage, -or decrease memory usage at the expense of parallel performance, where `n` is an integer. For -low-memory systems, `VARIANT=light` can be used to compile the light variant of hardened_malloc, -which sacrifices some security for much less memory usage. +or decrease memory usage at the expense of parallel performance, where `n` is an integer; higher +values prefer parallel performance, lower values prefer lower memory usage. For low-memory systems, +`VARIANT=light` can be used to compile the light variant of hardened_malloc, which sacrifices some +security for much less memory usage. == Copy Compiled hardened_malloc Library @@ -37,5 +38,6 @@ which sacrifices some security for much less memory usage. == Set System to Preload hardened_malloc on Boot -musl-based systems: Add `export LD_PRELOAD=` to `/etc/environment` + +musl-based systems: Add `export LD_PRELOAD=""` to `/etc/environment` + + + glibc-based systems: Add `` to `/etc/ld.so.preload`