[PATCH 09/15] De-PLTize __stack_chk_fail internal calls within libc.so.
Florian Weimer
fweimer@redhat.com
Wed Dec 21 15:05:00 GMT 2016
On 12/19/2016 12:15 PM, Nix wrote:
> From: Adhemerval Zanella <adhemerval.zanella@linaro.org>
>
> We use the same assembler-macro trick we use to de-PLTize
> compiler-generated libcalls to memcpy and memset to redirect
> __stack_chk_fail to __stack_chk_fail_local.
>
> v5: New.
> v6: Only do it within the shared library: with __stack_chk_fail_local
> in libc_pic.a now we don't need to worry about calls from inside
> other routines in libc_nonshared.a any more.
> v8: Merge #ifdef blocks.
> v10: Use STACK_PROTECTOR_LEVEL to avoid renaming in files where
> stack-protection is suppressed.
>
> * sysdeps/generic/symbol-hacks.h [STACK_PROTECTOR_LEVEL &&
> STACK_PROTECTOR_LEVEL > 0] (__stack_chk_fail): Add internal alias.
I'm going to fold this into the previous commit.
Thanks,
Florian
More information about the Libc-alpha
mailing list