mirror of
https://github.com/GrapheneOS/hardened_malloc.git
synced 2025-05-24 17:01:21 -04:00
linux: make use of mseal(2)
Instead of protecting the global read-only data structure after startup via the read-only flag, which can be reverted, use the in Linux 6.10 introduced irreversible syscall mseal(2).
This commit is contained in:
parent
749640c274
commit
96836f463b
3 changed files with 24 additions and 0 deletions
1
memory.h
1
memory.h
|
@ -19,6 +19,7 @@ bool memory_unmap(void *ptr, size_t size);
|
|||
bool memory_protect_ro(void *ptr, size_t size);
|
||||
bool memory_protect_rw(void *ptr, size_t size);
|
||||
bool memory_protect_rw_metadata(void *ptr, size_t size);
|
||||
bool memory_protect_seal(void *ptr, size_t size);
|
||||
#ifdef HAVE_COMPATIBLE_MREMAP
|
||||
bool memory_remap(void *old, size_t old_size, size_t new_size);
|
||||
bool memory_remap_fixed(void *old, size_t old_size, void *new, size_t new_size);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue