Option --unmap-all-pages completely avoids /proc/self/exe

https://github.com/upx/upx/issues/749
This commit is contained in:
John Reiser
2024-06-18 10:18:32 -07:00
committed by Markus F.X.J. Oberhumer
parent 3b36dce5c2
commit de8de9c0f0
67 changed files with 10710 additions and 10443 deletions
+44 -43
View File
@@ -9,62 +9,63 @@ Linker script and memory map
TARGET(elf64-powerpcle)
0x00000000001000bc . = ((0x100000 + SIZEOF_HEADERS) + 0xc)
.text 0x00000000001000bc 0xc3c
.text 0x00000000001000bc 0xc80
*(.text)
.text 0x00000000001000bc 0x348 tmp/powerpc64le-linux.elf-fold.o
0x00000000001000bc get_page_mask
0x0000000000100394 mmap
0x00000000001003ac Pprotect
0x00000000001003ac mprotect
0x00000000001003c4 exit
0x00000000001003cc brk
0x00000000001003d4 readlink
0x00000000001003dc read
0x00000000001003e4 open
0x00000000001003ec close
0x00000000001003f4 munmap
0x00000000001003fc my_bkpt
.text 0x0000000000100404 0x8f4 tmp/powerpc64le-linux.elf-main.o
.text 0x00000000001000bc 0x38c tmp/powerpc64le-linux.elf-fold.o
0x00000000001000cc get_page_mask
0x00000000001000e4 Pprotect
0x00000000001000e4 mprotect
0x00000000001003e8 mmap
0x0000000000100400 exit
0x0000000000100408 brk
0x0000000000100410 readlink
0x0000000000100418 write
0x0000000000100420 read
0x0000000000100428 open
0x0000000000100430 close
0x0000000000100438 munmap
0x0000000000100440 my_bkpt
.text 0x0000000000100448 0x8f4 tmp/powerpc64le-linux.elf-main.o
*(.data)
.data 0x0000000000100cf8 0x0 tmp/powerpc64le-linux.elf-fold.o
.data 0x0000000000100cf8 0x0 tmp/powerpc64le-linux.elf-main.o
.data 0x0000000000100d3c 0x0 tmp/powerpc64le-linux.elf-fold.o
.data 0x0000000000100d3c 0x0 tmp/powerpc64le-linux.elf-main.o
.sfpr 0x0000000000100cf8 0xa4
.sfpr 0x0000000000100cf8 0xa4 linker stubs
0x0000000000100cf8 _savegpr0_14
0x0000000000100d20 _savegpr0_24
0x0000000000100d30 _savegpr0_28
0x0000000000100d48 _restgpr0_14
0x0000000000100d70 _restgpr0_24
0x0000000000100d80 _restgpr0_28
.sfpr 0x0000000000100d3c 0xa4
.sfpr 0x0000000000100d3c 0xa4 linker stubs
0x0000000000100d3c _savegpr0_14
0x0000000000100d64 _savegpr0_24
0x0000000000100d74 _savegpr0_28
0x0000000000100d8c _restgpr0_14
0x0000000000100db4 _restgpr0_24
0x0000000000100dc4 _restgpr0_28
.glink 0x0000000000100da0 0x0
.glink 0x0000000000100da0 0x0 linker stubs
.glink 0x0000000000100de0 0x0
.glink 0x0000000000100de0 0x0 linker stubs
.eh_frame 0x0000000000100d9c 0x0
.eh_frame 0x0000000000100d9c 0x0 linker stubs
.eh_frame 0x0000000000100de0 0x0
.eh_frame 0x0000000000100de0 0x0 linker stubs
.rela.dyn 0x0000000000100da0 0x0
.rela.iplt 0x0000000000100da0 0x0 linker stubs
.rela.dyn 0x0000000000100de0 0x0
.rela.iplt 0x0000000000100de0 0x0 linker stubs
.data
LOAD tmp/powerpc64le-linux.elf-fold.o
LOAD tmp/powerpc64le-linux.elf-main.o
OUTPUT(tmp/powerpc64le-linux.elf-fold.bin elf64-powerpcle)
.branch_lt 0x0000000000100da0 0x0
.branch_lt 0x0000000000100da0 0x0 linker stubs
.branch_lt 0x0000000000100de0 0x0
.branch_lt 0x0000000000100de0 0x0 linker stubs
.toc 0x0000000000100da0 0x0
.toc 0x0000000000100da0 0x0 tmp/powerpc64le-linux.elf-main.o
.toc 0x0000000000100de0 0x0
.toc 0x0000000000100de0 0x0 tmp/powerpc64le-linux.elf-main.o
.opd 0x0000000000100da0 0x58
.opd 0x0000000000100da0 0x58 tmp/powerpc64le-linux.elf-main.o
0x0000000000100de0 upx_main
.opd 0x0000000000100de0 0x58
.opd 0x0000000000100de0 0x58 tmp/powerpc64le-linux.elf-main.o
0x0000000000100e20 upx_main
.iplt 0x0000000000100df8 0x0
.iplt 0x0000000000100df8 0x0 linker stubs
.iplt 0x0000000000100e38 0x0
.iplt 0x0000000000100e38 0x0 linker stubs
.bss 0x0000000000100df8 0x0
.bss 0x0000000000100df8 0x0 tmp/powerpc64le-linux.elf-fold.o
.bss 0x0000000000100df8 0x0 tmp/powerpc64le-linux.elf-main.o
.bss 0x0000000000100e38 0x0
.bss 0x0000000000100e38 0x0 tmp/powerpc64le-linux.elf-fold.o
.bss 0x0000000000100e38 0x0 tmp/powerpc64le-linux.elf-main.o