diff options
author | Szabolcs Nagy <szabolcs.nagy@arm.com> | 2020-12-01 10:13:18 +0000 |
---|---|---|
committer | Szabolcs Nagy <szabolcs.nagy@arm.com> | 2020-12-02 08:48:08 +0000 |
commit | 924e11d5169890a0c78e745467844eea922d5f98 (patch) | |
tree | ed7bfd067593ba56ea76be6c89cd8569baaffdc9 /sysdeps/s390/s390-64/multiarch | |
parent | a05a7f7505d44109533d17e151f6ae88d688b1e8 (diff) | |
download | glibc-nsz/btifix-v3.tar.gz glibc-nsz/btifix-v3.tar.xz glibc-nsz/btifix-v3.zip |
aarch64: Use mmap to add PROT_BTI instead of mprotect [BZ #26831] nsz/btifix-v3
Re-mmap executable segments if possible instead of using mprotect to add PROT_BTI. This allows using BTI protection with security policies that prevent mprotect with PROT_EXEC. If the fd of the ELF module is not available because it was kernel mapped then mprotect is used and failures are ignored. To protect the main executable even when mprotect is filtered the linux kernel will have to be changed to add PROT_BTI to it. The delayed failure reporting is mainly needed because currently _dl_process_gnu_properties does not propagate failures such that the required cleanups happen. Using the link_map_machine struct for error propagation is not ideal, but this seemed to be the least intrusive solution. Fixes bug 26831.
Diffstat (limited to 'sysdeps/s390/s390-64/multiarch')
0 files changed, 0 insertions, 0 deletions