Files
clang-p2996/lld/test/ELF/Inputs/relocation-copy-relro.s
Peter Collingbourne feb6629d6d ELF: Reserve space for copy relocations of read-only symbols in relro.
When reserving copy relocation space for a shared symbol, scan the DSO's
program headers to see if the symbol is in a read-only segment. If so,
reserve space for that symbol in a new synthetic section named .bss.rel.ro
which will be covered by the relro program header.

This fixes the security issue disclosed on the binutils mailing list at:
https://sourceware.org/ml/libc-alpha/2016-12/msg00914.html

Differential Revision: https://reviews.llvm.org/D28272

llvm-svn: 291524
2017-01-10 01:21:50 +00:00

14 lines
142 B
ArmAsm

.rodata
.globl a
.size a, 4
.type a, @object
a:
.word 1
.section .data.rel.ro,"aw",%progbits
.globl b
.size b, 4
.type b, @object
b:
.word 2