Allow more bytes for Mach_headers in /usr/lib/dyld on MacOS 13
Fixes initial complaint (HelloUPX4) in https://github.com/upx/upx/issues/612 modified: stub/amd64-darwin.macho-fold.h modified: stub/arm64-darwin.macho-fold.h modified: stub/src/amd64-darwin.macho-fold.S modified: stub/src/amd64-darwin.macho-main.c modified: stub/tmp/amd64-darwin.macho-fold.map modified: stub/tmp/arm64-darwin.macho-fold.map
This commit is contained in:
committed by
Markus F.X.J. Oberhumer
parent
43019c744c
commit
1bebe53cef
+35
-34
@@ -72,7 +72,7 @@ LOAD tmp/amd64-darwin.macho-main.o
|
||||
.plt
|
||||
*(.plt)
|
||||
|
||||
.text 0x0000000008048000 0x938
|
||||
.text 0x0000000008048000 0x997
|
||||
*(.text .stub .text.* .gnu.linkonce.t.*)
|
||||
.text 0x0000000008048000 0x1d0 tmp/amd64-darwin.macho-fold.o
|
||||
0x00000000080480b8 munmap
|
||||
@@ -86,17 +86,18 @@ LOAD tmp/amd64-darwin.macho-main.o
|
||||
0x00000000080480c4 open
|
||||
0x00000000080480b4 mprotect
|
||||
0x00000000080480c0 close
|
||||
.text 0x00000000080481d0 0x768 tmp/amd64-darwin.macho-main.o
|
||||
0x0000000008048369 do_xmap
|
||||
0x00000000080487a4 upx_main
|
||||
.text 0x00000000080481d0 0x7c7 tmp/amd64-darwin.macho-main.o
|
||||
0x00000000080483c8 do_xmap
|
||||
0x0000000008048369 my_bkpt
|
||||
0x0000000008048803 upx_main
|
||||
*(.text.*personality*)
|
||||
*(.gnu.warning)
|
||||
|
||||
.fini
|
||||
*(.fini)
|
||||
0x0000000008048938 PROVIDE (__etext, .)
|
||||
0x0000000008048938 PROVIDE (_etext, .)
|
||||
0x0000000008048938 PROVIDE (etext, .)
|
||||
0x0000000008048997 PROVIDE (__etext, .)
|
||||
0x0000000008048997 PROVIDE (_etext, .)
|
||||
0x0000000008048997 PROVIDE (etext, .)
|
||||
|
||||
.rodata
|
||||
*(.rodata .rodata.* .gnu.linkonce.r.*)
|
||||
@@ -112,8 +113,8 @@ LOAD tmp/amd64-darwin.macho-main.o
|
||||
|
||||
.gcc_except_table
|
||||
*(.gcc_except_table .gcc_except_table.*)
|
||||
0x0000000008048938 . = (ALIGN (0x1000) - ((0x1000 - .) & 0xfff))
|
||||
0x0000000008049938 . = (0x1000 DATA_SEGMENT_ALIGN 0x1000)
|
||||
0x0000000008048997 . = (ALIGN (0x1000) - ((0x1000 - .) & 0xfff))
|
||||
0x0000000008049997 . = (0x1000 DATA_SEGMENT_ALIGN 0x1000)
|
||||
|
||||
.eh_frame
|
||||
*(.eh_frame)
|
||||
@@ -128,22 +129,22 @@ LOAD tmp/amd64-darwin.macho-main.o
|
||||
*(.tbss .tbss.* .gnu.linkonce.tb.*)
|
||||
*(.tcommon)
|
||||
|
||||
.preinit_array 0x0000000008049938 0x0
|
||||
0x0000000008049938 PROVIDE (__preinit_array_start, .)
|
||||
.preinit_array 0x0000000008049997 0x0
|
||||
0x0000000008049997 PROVIDE (__preinit_array_start, .)
|
||||
*(.preinit_array)
|
||||
0x0000000008049938 PROVIDE (__preinit_array_end, .)
|
||||
0x0000000008049997 PROVIDE (__preinit_array_end, .)
|
||||
|
||||
.init_array 0x0000000008049938 0x0
|
||||
0x0000000008049938 PROVIDE (__init_array_start, .)
|
||||
.init_array 0x0000000008049997 0x0
|
||||
0x0000000008049997 PROVIDE (__init_array_start, .)
|
||||
*(SORT(.init_array.*))
|
||||
*(.init_array)
|
||||
0x0000000008049938 PROVIDE (__init_array_end, .)
|
||||
0x0000000008049997 PROVIDE (__init_array_end, .)
|
||||
|
||||
.fini_array 0x0000000008049938 0x0
|
||||
0x0000000008049938 PROVIDE (__fini_array_start, .)
|
||||
.fini_array 0x0000000008049997 0x0
|
||||
0x0000000008049997 PROVIDE (__fini_array_start, .)
|
||||
*(.fini_array)
|
||||
*(SORT(.fini_array.*))
|
||||
0x0000000008049938 PROVIDE (__fini_array_end, .)
|
||||
0x0000000008049997 PROVIDE (__fini_array_end, .)
|
||||
|
||||
.ctors
|
||||
*crtbegin*.o(.ctors)
|
||||
@@ -169,35 +170,35 @@ LOAD tmp/amd64-darwin.macho-main.o
|
||||
|
||||
.got
|
||||
*(.got)
|
||||
0x0000000008049938 . = (. DATA_SEGMENT_RELRO_END 0xc)
|
||||
0x0000000008049997 . = (. DATA_SEGMENT_RELRO_END 0xc)
|
||||
|
||||
.got.plt
|
||||
*(.got.plt)
|
||||
|
||||
.data 0x0000000008049938 0x0
|
||||
.data 0x0000000008049998 0x0
|
||||
*(.data .data.* .gnu.linkonce.d.*)
|
||||
.data 0x0000000008049938 0x0 tmp/amd64-darwin.macho-fold.o
|
||||
.data 0x0000000008049938 0x0 tmp/amd64-darwin.macho-main.o
|
||||
.data 0x0000000008049998 0x0 tmp/amd64-darwin.macho-fold.o
|
||||
.data 0x0000000008049998 0x0 tmp/amd64-darwin.macho-main.o
|
||||
*(.gnu.linkonce.d.*personality*)
|
||||
|
||||
.data1
|
||||
*(.data1)
|
||||
0x0000000008049938 _edata = .
|
||||
0x0000000008049938 PROVIDE (edata, .)
|
||||
0x0000000008049938 __bss_start = .
|
||||
0x0000000008049998 _edata = .
|
||||
0x0000000008049998 PROVIDE (edata, .)
|
||||
0x0000000008049998 __bss_start = .
|
||||
|
||||
.bss 0x0000000008049938 0x0
|
||||
.bss 0x0000000008049998 0x0
|
||||
*(.dynbss)
|
||||
*(.bss .bss.* .gnu.linkonce.b.*)
|
||||
.bss 0x0000000008049938 0x0 tmp/amd64-darwin.macho-fold.o
|
||||
.bss 0x0000000008049938 0x0 tmp/amd64-darwin.macho-main.o
|
||||
.bss 0x0000000008049998 0x0 tmp/amd64-darwin.macho-fold.o
|
||||
.bss 0x0000000008049998 0x0 tmp/amd64-darwin.macho-main.o
|
||||
*(COMMON)
|
||||
0x0000000008049938 . = ALIGN ((. != 0x0)?0x4:0x1)
|
||||
0x0000000008049938 . = ALIGN (0x4)
|
||||
0x0000000008049938 . = ALIGN (0x4)
|
||||
0x0000000008049938 _end = .
|
||||
0x0000000008049938 PROVIDE (end, .)
|
||||
0x0000000008049938 . = DATA_SEGMENT_END (.)
|
||||
0x0000000008049998 . = ALIGN ((. != 0x0)?0x4:0x1)
|
||||
0x0000000008049998 . = ALIGN (0x4)
|
||||
0x0000000008049998 . = ALIGN (0x4)
|
||||
0x0000000008049998 _end = .
|
||||
0x0000000008049998 PROVIDE (end, .)
|
||||
0x0000000008049998 . = DATA_SEGMENT_END (.)
|
||||
|
||||
.stab
|
||||
*(.stab)
|
||||
|
||||
+47
-46
@@ -67,7 +67,7 @@ LOAD tmp/arm64-darwin.macho-main.o
|
||||
*(.iplt)
|
||||
.iplt 0x0000000000400080 0x0 tmp/arm64-darwin.macho-fold.o
|
||||
|
||||
.text 0x0000000000400078 0x984
|
||||
.text 0x0000000000400078 0x9d0
|
||||
*(.text.unlikely .text.*_unlikely .text.unlikely.*)
|
||||
*(.text.exit .text.exit.*)
|
||||
*(.text.startup .text.startup.*)
|
||||
@@ -87,16 +87,17 @@ LOAD tmp/arm64-darwin.macho-main.o
|
||||
0x000000000040018c mmap
|
||||
0x0000000000400198 pread
|
||||
0x00000000004001a4 bswap
|
||||
.text 0x00000000004001d0 0x82c tmp/arm64-darwin.macho-main.o
|
||||
0x000000000040037c do_xmap
|
||||
0x0000000000400820 upx_main
|
||||
.text 0x00000000004001d0 0x878 tmp/arm64-darwin.macho-main.o
|
||||
0x000000000040037c my_bkpt
|
||||
0x00000000004003c8 do_xmap
|
||||
0x000000000040086c upx_main
|
||||
*(.gnu.warning)
|
||||
|
||||
.fini
|
||||
*(SORT(.fini))
|
||||
0x00000000004009fc PROVIDE (__etext, .)
|
||||
0x00000000004009fc PROVIDE (_etext, .)
|
||||
0x00000000004009fc PROVIDE (etext, .)
|
||||
0x0000000000400a48 PROVIDE (__etext, .)
|
||||
0x0000000000400a48 PROVIDE (_etext, .)
|
||||
0x0000000000400a48 PROVIDE (etext, .)
|
||||
|
||||
.rodata
|
||||
*(.rodata .rodata.* .gnu.linkonce.r.*)
|
||||
@@ -107,18 +108,18 @@ LOAD tmp/arm64-darwin.macho-main.o
|
||||
.eh_frame_hdr
|
||||
*(.eh_frame_hdr)
|
||||
|
||||
.eh_frame 0x0000000000400a00 0x118
|
||||
.eh_frame 0x0000000000400a48 0x130
|
||||
*(.eh_frame)
|
||||
.eh_frame 0x0000000000400a00 0x118 tmp/arm64-darwin.macho-main.o
|
||||
0x108 (size before relaxing)
|
||||
.eh_frame 0x0000000000400a48 0x130 tmp/arm64-darwin.macho-main.o
|
||||
0x120 (size before relaxing)
|
||||
|
||||
.gcc_except_table
|
||||
*(.gcc_except_table .gcc_except_table.*)
|
||||
|
||||
.exception_ranges
|
||||
*(.exception_ranges .exception_ranges*)
|
||||
0x0000000000400b18 . = (ALIGN (0x10000) - ((0x10000 - .) & 0xffff))
|
||||
0x0000000000410b18 . = DATA_SEGMENT_ALIGN (0x10000, 0x1000)
|
||||
0x0000000000400b78 . = (ALIGN (0x10000) - ((0x10000 - .) & 0xffff))
|
||||
0x0000000000410b78 . = DATA_SEGMENT_ALIGN (0x10000, 0x1000)
|
||||
|
||||
.eh_frame
|
||||
*(.eh_frame)
|
||||
@@ -136,22 +137,22 @@ LOAD tmp/arm64-darwin.macho-main.o
|
||||
*(.tbss .tbss.* .gnu.linkonce.tb.*)
|
||||
*(.tcommon)
|
||||
|
||||
.preinit_array 0x0000000000410b18 0x0
|
||||
0x0000000000410b18 PROVIDE (__preinit_array_start, .)
|
||||
.preinit_array 0x0000000000410b78 0x0
|
||||
0x0000000000410b78 PROVIDE (__preinit_array_start, .)
|
||||
*(.preinit_array)
|
||||
0x0000000000410b18 PROVIDE (__preinit_array_end, .)
|
||||
0x0000000000410b78 PROVIDE (__preinit_array_end, .)
|
||||
|
||||
.init_array 0x0000000000410b18 0x0
|
||||
0x0000000000410b18 PROVIDE (__init_array_start, .)
|
||||
.init_array 0x0000000000410b78 0x0
|
||||
0x0000000000410b78 PROVIDE (__init_array_start, .)
|
||||
*(SORT(.init_array.*))
|
||||
*(.init_array)
|
||||
0x0000000000410b18 PROVIDE (__init_array_end, .)
|
||||
0x0000000000410b78 PROVIDE (__init_array_end, .)
|
||||
|
||||
.fini_array 0x0000000000410b18 0x0
|
||||
0x0000000000410b18 PROVIDE (__fini_array_start, .)
|
||||
.fini_array 0x0000000000410b78 0x0
|
||||
0x0000000000410b78 PROVIDE (__fini_array_start, .)
|
||||
*(SORT(.fini_array.*))
|
||||
*(.fini_array)
|
||||
0x0000000000410b18 PROVIDE (__fini_array_end, .)
|
||||
0x0000000000410b78 PROVIDE (__fini_array_end, .)
|
||||
|
||||
.ctors
|
||||
*crtbegin.o(.ctors)
|
||||
@@ -180,43 +181,43 @@ LOAD tmp/arm64-darwin.macho-main.o
|
||||
.got
|
||||
*(.got)
|
||||
*(.igot)
|
||||
0x0000000000410b18 . = DATA_SEGMENT_RELRO_END (., 0x18)
|
||||
0x0000000000410b78 . = DATA_SEGMENT_RELRO_END (., 0x18)
|
||||
|
||||
.got.plt 0x0000000000410b18 0x0
|
||||
.got.plt 0x0000000000410b78 0x0
|
||||
*(.got.plt)
|
||||
*(.igot.plt)
|
||||
.igot.plt 0x0000000000410b18 0x0 tmp/arm64-darwin.macho-fold.o
|
||||
.igot.plt 0x0000000000410b78 0x0 tmp/arm64-darwin.macho-fold.o
|
||||
|
||||
.data 0x0000000000410b18 0x0
|
||||
0x0000000000410b18 PROVIDE (__data_start, .)
|
||||
.data 0x0000000000410b78 0x0
|
||||
0x0000000000410b78 PROVIDE (__data_start, .)
|
||||
*(.data .data.* .gnu.linkonce.d.*)
|
||||
.data 0x0000000000410b18 0x0 tmp/arm64-darwin.macho-fold.o
|
||||
.data 0x0000000000410b18 0x0 tmp/arm64-darwin.macho-main.o
|
||||
.data 0x0000000000410b78 0x0 tmp/arm64-darwin.macho-fold.o
|
||||
.data 0x0000000000410b78 0x0 tmp/arm64-darwin.macho-main.o
|
||||
|
||||
.data1
|
||||
*(.data1)
|
||||
0x0000000000410b18 _edata = .
|
||||
0x0000000000410b18 PROVIDE (edata, .)
|
||||
0x0000000000410b18 . = .
|
||||
0x0000000000410b18 __bss_start = .
|
||||
0x0000000000410b18 __bss_start__ = .
|
||||
0x0000000000410b78 _edata = .
|
||||
0x0000000000410b78 PROVIDE (edata, .)
|
||||
0x0000000000410b78 . = .
|
||||
0x0000000000410b78 __bss_start = .
|
||||
0x0000000000410b78 __bss_start__ = .
|
||||
|
||||
.bss 0x0000000000410b18 0x0
|
||||
.bss 0x0000000000410b78 0x0
|
||||
*(.dynbss)
|
||||
*(.bss .bss.* .gnu.linkonce.b.*)
|
||||
.bss 0x0000000000410b18 0x0 tmp/arm64-darwin.macho-fold.o
|
||||
.bss 0x0000000000410b18 0x0 tmp/arm64-darwin.macho-main.o
|
||||
.bss 0x0000000000410b78 0x0 tmp/arm64-darwin.macho-fold.o
|
||||
.bss 0x0000000000410b78 0x0 tmp/arm64-darwin.macho-main.o
|
||||
*(COMMON)
|
||||
0x0000000000410b18 . = ALIGN ((. != 0x0)?0x8:0x1)
|
||||
0x0000000000410b18 _bss_end__ = .
|
||||
0x0000000000410b18 __bss_end__ = .
|
||||
0x0000000000410b18 . = ALIGN (0x8)
|
||||
0x0000000000410b18 . = SEGMENT_START ("ldata-segment", .)
|
||||
0x0000000000410b18 . = ALIGN (0x8)
|
||||
0x0000000000410b18 __end__ = .
|
||||
0x0000000000410b18 _end = .
|
||||
0x0000000000410b18 PROVIDE (end, .)
|
||||
0x0000000000410b18 . = DATA_SEGMENT_END (.)
|
||||
0x0000000000410b78 . = ALIGN ((. != 0x0)?0x8:0x1)
|
||||
0x0000000000410b78 _bss_end__ = .
|
||||
0x0000000000410b78 __bss_end__ = .
|
||||
0x0000000000410b78 . = ALIGN (0x8)
|
||||
0x0000000000410b78 . = SEGMENT_START ("ldata-segment", .)
|
||||
0x0000000000410b78 . = ALIGN (0x8)
|
||||
0x0000000000410b78 __end__ = .
|
||||
0x0000000000410b78 _end = .
|
||||
0x0000000000410b78 PROVIDE (end, .)
|
||||
0x0000000000410b78 . = DATA_SEGMENT_END (.)
|
||||
|
||||
.stab
|
||||
*(.stab)
|
||||
|
||||
Reference in New Issue
Block a user