/scs-inline-asm-runtime.c Secret
Created
July 7, 2022 08:10
Constructor used for Shadow Stack on AArch64
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
void __attribute__ ((constructor)) __attribute__((no_sanitize("shadow-call-stack"))) setup_x18() | |
{ | |
void *shadow = malloc(16384); | |
__asm __volatile ( "mov x18, %0" : : "r" (shadow) ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment