This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH v3 08/16] elf: Enable relro for static build


On 18/12/19 3:17 am, Adhemerval Zanella wrote:
> Changes from previous version:
> 
>   - The tests were removed and instead I will use the ones proposed
>     by Florian's patch 'elf: Add tests for working RELRO protection'
>     [1].  I also plan to send additional coverage for '.data.rel.ro'
>     which trigger failures for the static case on both partial and
>     full relro which is fixed by this patch once the patch is
>     upstream.
> 
> --
> 
> The code is similar to the one at elf/dl-reloc.c, where it checks for
> the l_relro_size from the link_map (obtained from PT_GNU_RELRO header
> from program headers) and calls_dl_protected_relro.
> 
> Checked on x86_64-linux-gnu, i686-linux-gnu, powerpc64le-linux-gnu,
> aarch64-linux-gnu, s390x-linux-gnu, and sparc64-linux-gnu.  I also
> check with --enable-static pie on x86_64-linux-gnu, i686-linux-gnu,
> and aarch64-linux-gnu which seems the only architectures where
> static PIE is actually working (as per 9d7a3741c9e, on
> arm-linux-gnueabihf, powerpc64{le}-linux-gnu, and s390x-linux-gnu
> I am seeing runtime issues not related to my patch).
> 
> [1] https://sourceware.org/ml/libc-alpha/2019-10/msg00059.html
> ---
>  elf/dl-support.c | 18 ++++++++++++++----
>  1 file changed, 14 insertions(+), 4 deletions(-)
> 

OK.

Reviewed-by: Siddhesh Poyarekar <siddhesh@sourceware.org>


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]