[WIP] Introduce aarch64-unknown-linux-pauthtest target#154759
Draft
jchlanda wants to merge 7 commits intorust-lang:mainfrom
Draft
[WIP] Introduce aarch64-unknown-linux-pauthtest target#154759jchlanda wants to merge 7 commits intorust-lang:mainfrom
jchlanda wants to merge 7 commits intorust-lang:mainfrom
Conversation
This comment has been minimized.
This comment has been minimized.
88b623e to
3b3fcce
Compare
This comment has been minimized.
This comment has been minimized.
3b3fcce to
e33dbf3
Compare
This comment has been minimized.
This comment has been minimized.
e33dbf3 to
9e48aaa
Compare
This comment has been minimized.
This comment has been minimized.
9e48aaa to
4468c36
Compare
This comment has been minimized.
This comment has been minimized.
4468c36 to
c9fe7d6
Compare
This comment has been minimized.
This comment has been minimized.
c9fe7d6 to
7ecdaa6
Compare
This comment has been minimized.
This comment has been minimized.
7ecdaa6 to
65007e0
Compare
This comment has been minimized.
This comment has been minimized.
65007e0 to
566b1b6
Compare
This comment has been minimized.
This comment has been minimized.
`const_ptr_auth` wraps aroudn `LLVMRustConstPtrAuth`, which provides a way to decorate a function pointer in `ConstPtrAuth`.
Allow PAC metadata to be passed to `get_fn_addr` and related API changes.
The set of supported attributes is: function * "aarch64-jump-table-hardening" * "ptrauth-auth-traps" * "ptrauth-calls" * "ptrauth-indirect-gotos" * "ptrauth-returns" module * "ptrauth-elf-got" * "ptrauth-sign-personality"
Also add flag for ELF-GOT signing.
Also: * update tests to force dynamic library when targetting pauthtest * various test fixes * introduce end-to-end tests for pauthtest (in run-make)
566b1b6 to
dcb181c
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR introduces
aarch64-unknown-linux-pauthtesttarget, that enablesPointer Authentication Code (PAC) support in Rust on AArch64 ELF based Linux
systems using a pauthtest ABI (provided by LLVM) and pauthtest-enabled sysroot
with custom musl, serving as a reference libc implementation.
Supported features include:
(corresponds to
-fptrauth-callsincluded in pauthtest ABI as defined inLLVM)
address after restoring from stack for non-leaf functions (corresponds to
-fptrauth-returns)(corresponds to
-fptrauth-auth-traps)pauthtest ABI (corresponding to
-fptrauth-init-fini,-fptrauth-init-fini-address-discrimination)pauthtest ABI (corresponding to
-faarch64-jump-table-hardening,-fptrauth-indirect-gotos)-Z pauth_enable_elf_got, off bydefault)
Please note that efforts were made to split the work into individual commits
that encapsulate different areas of the code; however, the commits are not
atomic and cannot be built or tested in isolation.
Useful links: