Commit Graph

77 Commits

Author SHA1 Message Date
Markus F.X.J. Oberhumer 90b1817e92 Undef PAGE_{MASK,SIZE} in conf.h.
committer: mfx <mfx> 1143454717 +0000
2006-03-27 10:18:37 +00:00
John Reiser f95e171e11 Workaround linux-2.6.14 binfmt_elf.c: SIGKILL if (0==.p_memsz) on a page boundary.
p_lx_elf.cpp p_lx_exc.cpp

committer: jreiser <jreiser> 1143057770 +0000
2006-03-22 20:02:50 +00:00
Markus F.X.J. Oberhumer 1810440355 Added __attribute__((__sentinel__)) to Packer::addLoader(). This is
a new gcc-4.1 feature.

committer: mfx <mfx> 1142035833 +0000
2006-03-11 00:10:33 +00:00
John Reiser 366a708f3a Generalize to more than 2 PT_LOAD using find_LOAD_gap; needed for linux/ElfAMD.
Also simplifies, and applies to both ::pack and ::unpack.
	p_lx_elf.cpp p_lx_elf.h

committer: jreiser <jreiser> 1141348876 +0000
2006-03-03 01:21:16 +00:00
John Reiser b389abd99f PackLinuxElf64amd::getCompressionMethods allows both nrv2b and nrv2e
committer: jreiser <jreiser> 1141326792 +0000
2006-03-02 19:13:12 +00:00
John Reiser 268e322e1c Extra parameter for compressWithFilters and packExtent,
to fix 2-pass problem with --brute on linux/elf386.
Only one decompression method is allowed, chosen by
smallest output for .text; but Elf headers come first.
	packer.cpp packer.h p_unix.cpp p_unix.h p_lx_elf.cpp

committer: jreiser <jreiser> 1140241030 +0000
2006-02-18 05:37:10 +00:00
Markus F.X.J. Oberhumer 8b7ebcf040 Enter 2006.
committer: mfx <mfx> 1139778883 +0000
2006-02-12 21:14:43 +00:00
Markus F.X.J. Oberhumer 51ac5172f5 #undef PAGE_{MASK,SIZE} to fix build problems on some machines.
committer: mfx <mfx> 1139743226 +0000
2006-02-12 11:20:26 +00:00
John Reiser ce33ffb62a handle compressed executables larger than 3MB on Elf64amd
committer: jreiser <jreiser> 1131833508 +0000
2005-11-12 22:11:48 +00:00
John Reiser 75bba319de tuning, and prepare for large executables (>3MB compressed)
p_lx_elf.cpp stub/a_lx_elf64.c stub/amd_d_nrv2e.S
	stub/fold_elf64amd.S stub/l_lx_elf64amd.S

committer: jreiser <jreiser> 1131824655 +0000
2005-11-12 19:44:15 +00:00
John Reiser f78e9261f3 Do initLoader() properly, instead of relying on the amount of stack space
that is in use when ::buildLinuxLoader is called.

committer: jreiser <jreiser> 1131597922 +0000
2005-11-10 04:45:22 +00:00
John Reiser 6737a3ae09 PackLinuxElf64amd
p_lx_elf.h p_lx_elf.cpp packmast.cpp

committer: jreiser <jreiser> 1131570778 +0000
2005-11-09 21:12:58 +00:00
John Reiser 0c328372b5 Allow __uClibc_main and __uClibc_start_main like __libc_start_main.
committer: jreiser <jreiser> 1127269046 +0000
2005-09-21 02:17:26 +00:00
John Reiser 3f7b642c7d Linux i386 allow compression of position-independent main executables (gcc -pie).
p_elf.h p_lx_elf.cpp p_lx_elf.h p_lx_exc.cpp
	stub/fold_elf86.asm stub/fold_elf86.h stub/l_lx_elf.c
	stub/l_lx_elf86.asm stub/l_lx_elf86.h stub/l_lx_elf86.lds
	stub/linux.hh

committer: jreiser <jreiser> 1126886896 +0000
2005-09-16 16:08:16 +00:00
Markus F.X.J. Oberhumer 6b7c7f755c Avoid warnings about unused vars.
committer: mfx <mfx> 1119613814 +0000
2005-06-24 11:50:14 +00:00
John Reiser d339ee3135 PackLinuxElf32::unpack forgot several get_native32()
committer: jreiser <jreiser> 1114229735 +0000
2005-04-23 04:15:35 +00:00
John Reiser 14b0527e79 fix compiler waring
committer: jreiser <jreiser> 1108941316 +0000
2005-02-20 23:15:16 +00:00
John Reiser 664a82e7c9 Start re-organizing the packing of Elf, by making Elf32 come first,
with Big endian and Little endian derived from it.
I386 still uses the old way, but PowerPC (both Linux and Darwin [Mac])
use the new way.
	p_elf.h p_lx_elf.cpp p_lx_elf.h p_lx_exc.cpp p_lx_exc.h
	p_unix.cpp p_unix.h p_vmlinx.cpp p_vmlinx.h p_vmlinz.cpp

committer: jreiser <jreiser> 1108940224 +0000
2005-02-20 22:57:04 +00:00
Markus F.X.J. Oberhumer 18ef55ac14 Final updates for upx-1.91.
committer: mfx <mfx> 1088566877 +0000
2004-06-30 03:41:17 +00:00
John Reiser 1555be40b7 fix alignment of loader after packing multiple blocks
p_lx_elf.h p_lx_elf.cpp

committer: jreiser <jreiser> 1080880623 +0000
2004-04-02 04:37:03 +00:00
Markus F.X.J. Oberhumer 5f87e9891b Enter 2004.
committer: mfx <mfx> 1074623868 +0000
2004-01-20 18:37:48 +00:00
Markus F.X.J. Oberhumer 97153e8e09 Compile fixes for PGI C++.
committer: mfx <mfx> 1071917829 +0000
2003-12-20 10:57:09 +00:00
Markus F.X.J. Oberhumer e387c6bc56 Portability updates.
committer: mfx <mfx> 1042930101 +0000
2003-01-18 22:48:21 +00:00
Markus F.X.J. Oberhumer 8f25c72085 Consistently use const Class &' instead of Class const &'.
committer: mfx <mfx> 1042741665 +0000
2003-01-16 18:27:45 +00:00
Markus F.X.J. Oberhumer 2162a01848 Enter 2003.
committer: mfx <mfx> 1042478199 +0000
2003-01-13 17:16:39 +00:00
John Reiser 12c6cd8021 Comment on current state of stub/fold* vs decompress, and independent unfilter.
p_lx_elf.cpp p_lx_exc.cpp

committer: jreiser <jreiser> 1037072124 +0000
2002-11-12 03:35:24 +00:00
Markus F.X.J. Oberhumer 7802257700 Portability fixes.
committer: mfx <mfx> 1037058393 +0000
2002-11-11 23:46:33 +00:00
Markus F.X.J. Oberhumer d7e795a731 Set blocksize in canPack().
committer: mfx <mfx> 1036984678 +0000
2002-11-11 03:17:58 +00:00
Markus F.X.J. Oberhumer f66d8f98c9 Changed year to 2002.
committer: mfx <mfx> 1036971635 +0000
2002-11-10 23:40:35 +00:00
Markus F.X.J. Oberhumer a94a3e9741 If testOverlappingDecompression() fails, just treat the block as
non-compressible.

committer: mfx <mfx> 1036971145 +0000
2002-11-10 23:32:25 +00:00
John Reiser 5ac2eed3d9 ::unpackExtent() honors per-block filter if newer 12-byte b_info
committer: jreiser <jreiser> 1036876078 +0000
2002-11-09 21:07:58 +00:00
John Reiser 7cbf7af6e8 cleanup ui pass count
committer: jreiser <jreiser> 1036816411 +0000
2002-11-09 04:33:31 +00:00
John Reiser 7f69f5937a be gentler, use throwAlreadyPackedByUPX()
committer: jreiser <jreiser> 1036784004 +0000
2002-11-08 19:33:24 +00:00
John Reiser e0ad859eef pack1() re-allocates ibuf after setting blocksize
committer: jreiser <jreiser> 1036733697 +0000
2002-11-08 05:34:57 +00:00
Markus F.X.J. Oberhumer 565360a3f2 Cleanups.
committer: mfx <mfx> 1034942507 +0000
2002-10-18 12:01:47 +00:00
John Reiser 69cec874a1 checkPatch() resets
p_lx_elf.cpp p_lx_exc.cpp p_unix.cpp

committer: jreiser <jreiser> 1034906580 +0000
2002-10-18 02:03:00 +00:00
John Reiser a9bb95fefd prefer filters 0x49,0x46 until problems with 0x2Y and 0x3Y are diagnosed
committer: jreiser <jreiser> 1034794465 +0000
2002-10-16 18:54:25 +00:00
Markus F.X.J. Oberhumer 05db38225a Disabled the untested filters for now.
committer: mfx <mfx> 1034617837 +0000
2002-10-14 17:50:37 +00:00
John Reiser 124cdfda37 new option "--ptinterp" for linux/elf386 compressing PT_INTERP file
p_lx_elf.cpp options.h main.cpp

committer: jreiser <jreiser> 1032629299 +0000
2002-09-21 17:28:19 +00:00
Markus F.X.J. Oberhumer 9b079b371d Resynced with upx 1.2 branch.
committer: mfx <mfx> 1031577224 +0000
2002-09-09 13:13:44 +00:00
Markus F.X.J. Oberhumer 666e8c2f2f Big re-sync with UPX 1.2 branch.
committer: mfx <mfx> 1026835258 +0000
2002-07-16 16:00:58 +00:00
John Reiser ead8daf26c beware PT_LOAD.p_filesz==0
committer: jreiser <jreiser> 1009776680 +0000
2001-12-31 05:31:20 +00:00
John Reiser a63b02ab69 make "upx -d" decompression backward compatible to 8-byte b_info
p_lx_elf.h p_lx_elf.cpp p_unix.cpp

committer: jreiser <jreiser> 981752402 +0000
2001-02-09 21:00:02 +00:00
John Reiser 2ff824e631 get rid of PT_DYNAMIC: not worth the space; instead, use "upx -d" then ldd
p_lx_exc.h p_lx_elf.cpp p_lx_exc.cpp p_lx_sh.cpp
	stub/l_lx_elf.c stub/l_lx_elf86.lds stub/fold_elf86.asm

committer: jreiser <jreiser> 981747384 +0000
2001-02-09 19:36:24 +00:00
John Reiser e866b2231f move b_len from PackHeader to PackUnix
packer.h p_unix.h p_unix.cpp p_lx_elf.cpp p_lx_exc.cpp

committer: jreiser <jreiser> 981741734 +0000
2001-02-09 18:02:14 +00:00
Markus F.X.J. Oberhumer 3ba4cd5919 Avoid a compiler warning.
committer: mfx <mfx> 981585719 +0000
2001-02-07 22:41:59 +00:00
John Reiser 40fddf1715 Put upx stub loader at high end of ELF output file on linux,
and allow for block-by-block specification of filter and parameters.
	linker.cpp linker.h mem.cpp mem.h p_elf.h
	p_lx_elf.cpp p_lx_elf.h
	p_lx_exc.cpp p_lx_exc.h
	p_lx_sh.cpp  p_lx_sh.h
	p_unix.cpp p_unix.h
	packer.cpp packer.h
	stub/fold_elf86.asm stub/fold_exec86.asm stub/fold_sh86.asm
	stub/l_lx_elf.c  stub/l_lx_elf86.asm  stub/l_lx_elf86.lds
	stub/l_lx_exec.c stub/l_lx_exec86.asm stub/l_lx_exec86.lds
	stub/l_lx_sh.c   stub/l_lx_sh86.asm   stub/l_lx_sh86.lds
	stub/linux.hh

committer: jreiser <jreiser> 981084316 +0000
2001-02-02 03:25:16 +00:00
John Reiser df9db96bd1 filters for unix(linux)
Modified Files:
	filteri.cpp filter/ctojr.h linker.cpp linker.h mem.cpp mem.h
	p_lx_elf.cpp p_lx_elf.h
	p_lx_exc.cpp p_lx_exc.h
	p_lx_sh.cpp  p_lx_sh.h
	p_unix.cpp packer.cpp packer.h packhead.cpp
	stub/Makefile    stub/macros.ash
	stub/l_lx_elf.c  stub/l_lx_elf86.asm  stub/l_lx_elf86.lds
	stub/l_lx_exec.c stub/l_lx_exec86.asm stub/l_lx_exec86.lds
	                 stub/l_lx_sh86.asm   stub/l_lx_sh86.lds
Added Files:
	filter/ctok.h
	stub/fold_elf86.asm stub/fold_exec86.asm stub/fold_sh86.asm

committer: jreiser <jreiser> 979796725 +0000
2001-01-18 05:45:25 +00:00
Markus F.X.J. Oberhumer d8baf6d1e8 Added PackUnix::writePackHeader().
committer: mfx <mfx> 979754833 +0000
2001-01-17 18:07:13 +00:00
John Reiser ce1b58d293 filters for linux/elf386;
filter.cpp filter.h p_lx_elf.cpp p_lx_elf.h filter/ctojr.h
	stub/l_lx_elf.c stub/l_lx_elf86.asm

committer: jreiser <jreiser> 978846586 +0000
2001-01-07 05:49:46 +00:00