-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Add Shadow Stack support for a simple app #505
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
mariasfiraiala
wants to merge
9
commits into
unikraft:staging
Choose a base branch
from
mariasfiraiala:staging
base: staging
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Conversation
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
Signed-off-by: Maria Sfiraiala <maria.sfiraiala@gmail.com>
Signed-off-by: Maria Sfiraiala <maria.sfiraiala@gmail.com>
Signed-off-by: Maria Sfiraiala <maria.sfiraiala@gmail.com>
Signed-off-by: Maria Sfiraiala <maria.sfiraiala@gmail.com>
Signed-off-by: Maria Sfiraiala <maria.sfiraiala@gmail.com>
…h clang (#6) Signed-off-by: Maria Sfiraiala <maria.sfiraiala@gmail.com>
Signed-off-by: Maria Sfiraiala <maria.sfiraiala@gmail.com>
08d9bda
to
37890b5
Compare
Signed-off-by: Maria Sfiraiala <maria.sfiraiala@gmail.com>
Signed-off-by: Maria Sfiraiala <maria.sfiraiala@gmail.com>
875d156
to
fe3b625
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
arch/arm64
gsoc22
Google Summer of Code 2022 Project
lang/c
Issues or PRs to do with C/C++
lifecycle/active
Indicates that an issue or PR is actively being worked on by a contributor.
priority/low
topic/booting
Topics pertaining to the boot process
topic/build
Topics to do with the build system
topic/mm
Topics pertaining to memory management
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.
Prerequisite checklist
checkpatch.pl
on your commit series before opening this PR;Base target
AArch64
KVM
Additional configuration
You'll need to update the
Makefile.uk
of your app by adding this (let our app behelloworld
for the sake of simplicity)Shadow Stack support comes with
clang
as a compiler, you'll have to build the app accordingly.Build using
You'll need the gcc cross-compiling toolchain installed. Get it from here.
Also, make sure to have erratum options disabled when using
menuconfig
(Architecture Selection
->Arm8 Compatible
->Workaround for [...] erratum
).What's more, you'll have to configure the
Custom cross-compiler LLVM target
too (Build Options
->Custom cross-compiler LLVM target
); just writeaarch64-none-elf
and you should be good to go.Description of changes
This PR aims to demonstrate how the Shadow Stack support will behave.
It brings minor changes in order to make possible the compilation with
clang
, as this security mechanism is supported byclang
andgcc-12
.Further changes were made in
boot.c
in order to initialize the Shadow Stack.Future changes will bring better performance by changing the memory allocator to a Unikraft based one and by integrating the constructor in the Unikraft constructor table.
For Proof of Concept and other information, refer this.