glibc/sysdeps/unix
Adhemerval Zanella 5624d626db linux: Add support for PT_GNU_MUTABLE
The section mark a memory region that should not be sealed if
GNU_PROPERTY_MEMORY_SEAL attribute is present.  PT_GNU_MUTABLE
section names start with ".gnu.mutable" and are maximum page
aligned and have a size of maximum page size.

For instance the code:

  #define GNU_MUTABLE_SECTION_NAME       ".gnu.mutable"

  unsigned char mutable_array1[64]
    __attribute__ ((section (GNU_MUTABLE_SECTION_NAME)))
       = { 0 };
  unsigned char mutable_array2[32]
    __attribute__ ((section (GNU_MUTABLE_SECTION_NAME)))
       = { 0 };

places both 'mutable_array1' and 'mutable_array2' on a page
aligned memory region in a size of a page (the alignment and size
can be change with -Wl,-z,max-page-size= linker option).

The linker sets the alignment and size to make it easier to
loader to avoid sealing the area (since mseal only work on
multiple of page size areas), and to simplify the userland
process to change protection of either seal the area after
initialization.
2025-03-07 08:46:49 -03:00
..
alpha Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
arm Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
bsd Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
i386 Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
inet
mips Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
powerpc Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
sh Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
sysv/linux linux: Add support for PT_GNU_MUTABLE 2025-03-07 08:46:49 -03:00
x86_64 Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
Implies
Makefile Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
confstr.h
get_child_max.c Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
getlogin.c Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
getlogin_r.c Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
getpagesize.c Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
grantpt.c Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
ifreq.c Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
make-syscalls.sh
setxid.h
sockatmark.c Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
syscall-template.S Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
syscall.S Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00
syscalls.list
sysdep.h Update copyright dates with scripts/update-copyrights 2025-01-01 11:22:09 -08:00