i386: Separate PROT_EXEC and PROT_WRITE

Also affects some arm and mips (via sharing i386-linux.elf-main.c)
	modified:   i386-linux.elf-entry.S
	modified:   i386-linux.elf-main.c

	also .h, .map, .dump
This commit is contained in:
John Reiser 2017-06-16 08:17:44 -07:00
parent a4c9b64224
commit d67bf16a08
11 changed files with 2178 additions and 2155 deletions

View File

@ -32,8 +32,8 @@
#define STUB_ARM_V4A_LINUX_ELF_FOLD_SIZE 2824
#define STUB_ARM_V4A_LINUX_ELF_FOLD_ADLER32 0x68c18fd3
#define STUB_ARM_V4A_LINUX_ELF_FOLD_CRC32 0xfd352a4c
#define STUB_ARM_V4A_LINUX_ELF_FOLD_ADLER32 0xe4f78fec
#define STUB_ARM_V4A_LINUX_ELF_FOLD_CRC32 0xded7c3f2
unsigned char stub_arm_v4a_linux_elf_fold[2824] = {
/* 0x0000 */ 127, 69, 76, 70, 1, 1, 1, 97, 0, 0, 0, 0, 0, 0, 0, 0,
@ -124,9 +124,9 @@ unsigned char stub_arm_v4a_linux_elf_fold[2824] = {
/* 0x0550 */ 5, 0,160,225, 4, 16,148,229,155,255,255,235, 4, 48,157,229,
/* 0x0560 */ 6, 0,148,232, 3, 32,130,224, 1, 16, 99,224, 6, 0,132,232,
/* 0x0570 */ 0, 48,148,229, 0, 0, 83,227,178,255,255, 26, 20,208,141,226,
/* 0x0580 */ 240,128,189,232, 85, 80, 88, 33,240, 79, 45,233, 1,144,160,225,
/* 0x0590 */ 176,193,217,225, 28, 16,145,229,188,226,217,225, 52,208, 77,226,
/* 0x05a0 */ 2, 0, 92,227, 1, 96,137,224, 20, 0,141,229, 16, 80,160, 3,
/* 0x0580 */ 240,128,189,232, 85, 80, 88, 33,240, 79, 45,233, 1,160,160,225,
/* 0x0590 */ 176,193,218,225, 28, 16,145,229,188,226,218,225, 52,208, 77,226,
/* 0x05a0 */ 2, 0, 92,227, 1, 96,138,224, 20, 0,141,229, 16, 80,160, 3,
/* 0x05b0 */ 0, 80,160, 19, 1,224, 78,226, 6, 16,160,225, 0, 0,224,227,
/* 0x05c0 */ 0,192,160,227, 16, 32,141,229, 12, 48,141,229, 13, 0, 0,234,
/* 0x05d0 */ 0, 48,145,229, 1, 0, 83,227, 8, 0, 0, 26, 20, 48,145,229,
@ -149,15 +149,15 @@ unsigned char stub_arm_v4a_linux_elf_fold[2824] = {
/* 0x06e0 */ 50, 67,160,225, 24,192,157,229, 24, 48, 21,229, 16, 16,157,229,
/* 0x06f0 */ 3,176,140,224, 11, 42,160,225, 16, 48, 21,229, 34, 42,160,225,
/* 0x0700 */ 0, 0, 81,227, 44, 48,141,229, 48,176,141,229, 2,128,131,224,
/* 0x0710 */ 7,160, 4,226, 11, 96, 98,224, 15, 0, 0, 10, 6, 0,160,225,
/* 0x0720 */ 8, 16,160,225, 2, 32,138,227, 16, 48,160,227,255,254,255,235,
/* 0x0710 */ 7,144, 4,226, 11, 96, 98,224, 15, 0, 0, 10, 6, 0,160,225,
/* 0x0720 */ 8, 16,160,225, 3, 32,160,227, 16, 48,160,227,255,254,255,235,
/* 0x0730 */ 0, 0, 86,225, 6, 0,160, 19, 20, 0, 0, 26, 92, 32,157,229,
/* 0x0740 */ 4, 48, 20,226, 2, 48,160, 17, 16, 0,157,229, 44, 16,141,226,
/* 0x0750 */ 20, 32,157,229, 52,255,255,235, 13, 0, 0,234, 28,192, 21,229,
/* 0x0760 */ 12,192, 98,224, 4,192,141,229, 20,192,157,229, 6, 0,160,225,
/* 0x0770 */ 8, 16,160,225, 10, 32,160,225, 18, 48,160,227, 0,192,141,229,
/* 0x0770 */ 8, 16,160,225, 9, 32,160,225, 18, 48,160,227, 0,192,141,229,
/* 0x0780 */ 223,254,255,235, 0, 0, 86,225, 1, 0, 0, 10, 8, 0,160,227,
/* 0x0790 */ 11,255,255,235, 0, 48,104,226, 3,122,160,225, 2, 0, 26,227,
/* 0x0790 */ 11,255,255,235, 0, 48,104,226, 3,122,160,225, 2, 0, 25,227,
/* 0x07a0 */ 39,122,160,225, 7, 0, 0, 10, 0, 0, 87,227, 5, 0, 0, 10,
/* 0x07b0 */ 8, 16,134,224, 7, 32,160,225, 0, 48,160,227, 1, 32, 82,226,
/* 0x07c0 */ 1, 48,193,228,251,255,255, 26, 16, 16,157,229, 0, 0, 81,227,
@ -169,18 +169,18 @@ unsigned char stub_arm_v4a_linux_elf_fold[2824] = {
/* 0x0820 */ 35, 58,160,225, 7, 0, 83,227, 56, 0, 0,154,252, 48,159,229,
/* 0x0830 */ 0, 0,132,229, 8, 16,132,226, 4, 0,160,225, 4, 48,132,229,
/* 0x0840 */ 172,254,255,235, 12, 0,157,229, 4, 32,160,225, 0, 16,160,227,
/* 0x0850 */ 211,254,255,235, 6, 0,160,225, 8, 16,160,225, 10, 32,160,225,
/* 0x0850 */ 211,254,255,235, 6, 0,160,225, 8, 16,160,225, 9, 32,160,225,
/* 0x0860 */ 162,254,255,235, 0, 0, 80,227, 10, 0,160, 19,199,255,255, 26,
/* 0x0870 */ 8,192,157,229, 7, 48,136,224, 12, 16,139,224, 3, 64,134,224,
/* 0x0880 */ 1, 0, 84,225, 7, 0, 0, 42, 1, 16,100,224, 10, 32,160,225,
/* 0x0880 */ 1, 0, 84,225, 7, 0, 0, 42, 1, 16,100,224, 9, 32,160,225,
/* 0x0890 */ 4, 0,160,225, 16, 48,160,227,164,254,255,235, 0, 0, 84,225,
/* 0x08a0 */ 9, 0,160, 19,185,255,255, 26, 28, 16,157,229, 1, 16,129,226,
/* 0x08b0 */ 28, 16,141,229, 32, 80,133,226,188, 50,217,225, 28, 32,157,229,
/* 0x08b0 */ 28, 16,141,229, 32, 80,133,226,188, 50,218,225, 28, 32,157,229,
/* 0x08c0 */ 3, 0, 82,225,109,255,255,186, 16, 48,157,229, 0, 0, 83,227,
/* 0x08d0 */ 5, 0, 0, 10,176, 49,217,225, 3, 0, 83,227, 32,192,157, 21,
/* 0x08d0 */ 5, 0, 0, 10,176, 49,218,225, 3, 0, 83,227, 32,192,157, 21,
/* 0x08e0 */ 40, 16,157, 21, 1, 0,140, 16,122,254,255, 27, 88, 32,157,229,
/* 0x08f0 */ 0, 0, 82,227, 24, 48,157, 21, 0, 48,130, 21, 24, 16,157,229,
/* 0x0900 */ 24, 0,153,229, 0, 0,129,224, 52,208,141,226,240,143,189,232,
/* 0x0900 */ 24, 0,154,229, 0, 0,129,224, 52,208,141,226,240,143,189,232,
/* 0x0910 */ 28, 48, 21,229, 0, 0, 83,227, 36,192,157, 5, 12, 48,129, 0,
/* 0x0920 */ 8, 64,131, 2,192,255,255, 10,201,255,255,234, 64, 98, 81,115,
/* 0x0930 */ 14,240,160,225,240, 69, 45,233, 12,208, 77,226, 44, 96,157,229,

View File

@ -32,8 +32,8 @@
#define STUB_ARM_V5A_LINUX_ELF_FOLD_SIZE 2980
#define STUB_ARM_V5A_LINUX_ELF_FOLD_ADLER32 0xf9dbd900
#define STUB_ARM_V5A_LINUX_ELF_FOLD_CRC32 0xb82a7d32
#define STUB_ARM_V5A_LINUX_ELF_FOLD_ADLER32 0x7680d919
#define STUB_ARM_V5A_LINUX_ELF_FOLD_CRC32 0x6a20f450
unsigned char stub_arm_v5a_linux_elf_fold[2980] = {
/* 0x0000 */ 127, 69, 76, 70, 1, 1, 1, 97, 0, 0, 0, 0, 0, 0, 0, 0,
@ -134,8 +134,8 @@ unsigned char stub_arm_v5a_linux_elf_fold[2980] = {
/* 0x05f0 */ 157,255,255,235, 4, 48,157,229, 6, 0,148,232, 3, 32,130,224,
/* 0x0600 */ 1, 16, 99,224, 6, 0,132,232, 0, 48,148,229, 0, 0, 83,227,
/* 0x0610 */ 180,255,255, 26, 20,208,141,226,240,128,189,232, 85, 80, 88, 33,
/* 0x0620 */ 240, 79, 45,233, 1,144,160,225,176,193,217,225, 28, 16,145,229,
/* 0x0630 */ 188,226,217,225, 52,208, 77,226, 2, 0, 92,227, 1, 96,137,224,
/* 0x0620 */ 240, 79, 45,233, 1,160,160,225,176,193,218,225, 28, 16,145,229,
/* 0x0630 */ 188,226,218,225, 52,208, 77,226, 2, 0, 92,227, 1, 96,138,224,
/* 0x0640 */ 20, 0,141,229, 16, 80,160, 3, 0, 80,160, 19, 1,224, 78,226,
/* 0x0650 */ 6, 16,160,225, 0, 0,224,227, 0,192,160,227, 16, 32,141,229,
/* 0x0660 */ 12, 48,141,229, 13, 0, 0,234, 0, 48,145,229, 1, 0, 83,227,
@ -158,16 +158,16 @@ unsigned char stub_arm_v5a_linux_elf_fold[2980] = {
/* 0x0770 */ 7, 48, 3,226, 3, 49,160,225, 50, 67,160,225, 24,192,157,229,
/* 0x0780 */ 24, 48, 21,229, 16, 16,157,229, 3,176,140,224, 16, 32, 21,229,
/* 0x0790 */ 11, 58,160,225, 35, 58,160,225, 0, 0, 81,227, 44, 32,141,229,
/* 0x07a0 */ 48,176,141,229, 3,128,130,224, 7,160, 4,226, 11, 96, 99,224,
/* 0x07b0 */ 15, 0, 0, 10, 6, 0,160,225, 8, 16,160,225, 2, 32,138,227,
/* 0x07a0 */ 48,176,141,229, 3,128,130,224, 7,144, 4,226, 11, 96, 99,224,
/* 0x07b0 */ 15, 0, 0, 10, 6, 0,160,225, 8, 16,160,225, 3, 32,160,227,
/* 0x07c0 */ 16, 48,160,227, 1,255,255,235, 0, 0, 86,225, 6, 0,160, 19,
/* 0x07d0 */ 20, 0, 0, 26, 92, 32,157,229, 4, 48, 20,226, 2, 48,160, 17,
/* 0x07e0 */ 16, 0,157,229, 44, 16,141,226, 20, 32,157,229, 54,255,255,235,
/* 0x07f0 */ 13, 0, 0,234, 28,192, 21,229, 6, 0,160,225, 12,192, 99,224,
/* 0x0800 */ 4,192,141,229, 20,192,157,229, 8, 16,160,225, 10, 32,160,225,
/* 0x0800 */ 4,192,141,229, 20,192,157,229, 8, 16,160,225, 9, 32,160,225,
/* 0x0810 */ 18, 48,160,227, 0,192,141,229,222,254,255,235, 0, 0, 86,225,
/* 0x0820 */ 1, 0, 0, 10, 8, 0,160,227, 13,255,255,235, 0, 48,104,226,
/* 0x0830 */ 3,122,160,225, 2, 0, 26,227, 39,122,160,225, 7, 0, 0, 10,
/* 0x0830 */ 3,122,160,225, 2, 0, 25,227, 39,122,160,225, 7, 0, 0, 10,
/* 0x0840 */ 0, 0, 87,227, 5, 0, 0, 10, 8, 16,134,224, 7, 32,160,225,
/* 0x0850 */ 0, 48,160,227, 1, 32, 82,226, 1, 48,193,228,251,255,255, 26,
/* 0x0860 */ 16, 16,157,229, 0, 0, 81,227, 38, 0, 0, 10,213,254,255,235,
@ -179,17 +179,17 @@ unsigned char stub_arm_v5a_linux_elf_fold[2980] = {
/* 0x08c0 */ 57, 0, 0,154, 0, 49,159,229, 0, 0,132,229, 8, 16,132,226,
/* 0x08d0 */ 4, 0,160,225, 4, 48,132,229,167,254,255,235, 12, 0,157,229,
/* 0x08e0 */ 4, 32,160,225, 0, 16,160,227,213,254,255,235, 6, 0,160,225,
/* 0x08f0 */ 8, 16,160,225, 10, 32,160,225,154,254,255,235, 0, 0, 80,227,
/* 0x08f0 */ 8, 16,160,225, 9, 32,160,225,154,254,255,235, 0, 0, 80,227,
/* 0x0900 */ 10, 0,160, 19,199,255,255, 26, 8,192,157,229, 7, 48,136,224,
/* 0x0910 */ 12, 16,139,224, 3, 64,134,224, 1, 0, 84,225, 7, 0, 0, 42,
/* 0x0920 */ 1, 16,100,224, 10, 32,160,225, 4, 0,160,225, 16, 48,160,227,
/* 0x0920 */ 1, 16,100,224, 9, 32,160,225, 4, 0,160,225, 16, 48,160,227,
/* 0x0930 */ 166,254,255,235, 0, 0, 84,225, 9, 0,160, 19,185,255,255, 26,
/* 0x0940 */ 28, 16,157,229, 32, 80,133,226, 1, 16,129,226, 28, 16,141,229,
/* 0x0950 */ 188, 50,217,225, 28, 32,157,229, 3, 0, 82,225,109,255,255,186,
/* 0x0960 */ 16, 48,157,229, 0, 0, 83,227, 6, 0, 0, 10,176, 49,217,225,
/* 0x0950 */ 188, 50,218,225, 28, 32,157,229, 3, 0, 82,225,109,255,255,186,
/* 0x0960 */ 16, 48,157,229, 0, 0, 83,227, 6, 0, 0, 10,176, 49,218,225,
/* 0x0970 */ 3, 0, 83,227, 3, 0, 0, 10, 32,192,157,229, 40, 16,157,229,
/* 0x0980 */ 1, 0,140,224,104,254,255,235, 88, 32,157,229, 24, 16,157,229,
/* 0x0990 */ 0, 0, 82,227, 24, 48,157, 21, 0, 48,130, 21, 24, 0,153,229,
/* 0x0990 */ 0, 0, 82,227, 24, 48,157, 21, 0, 48,130, 21, 24, 0,154,229,
/* 0x09a0 */ 0, 0,129,224, 52,208,141,226,240,143,189,232, 28, 48, 21,229,
/* 0x09b0 */ 0, 0, 83,227, 36,192,157, 5, 12, 48,129, 0, 8, 64,131, 2,
/* 0x09c0 */ 191,255,255, 10,200,255,255,234, 64, 98, 81,115, 14,240,160,225,

View File

@ -32,8 +32,8 @@
#define STUB_ARMEB_V4A_LINUX_ELF_FOLD_SIZE 2824
#define STUB_ARMEB_V4A_LINUX_ELF_FOLD_ADLER32 0x31d08fd5
#define STUB_ARMEB_V4A_LINUX_ELF_FOLD_CRC32 0x7af4ab60
#define STUB_ARMEB_V4A_LINUX_ELF_FOLD_ADLER32 0xae278fee
#define STUB_ARMEB_V4A_LINUX_ELF_FOLD_CRC32 0xdbda4341
unsigned char stub_armeb_v4a_linux_elf_fold[2824] = {
/* 0x0000 */ 127, 69, 76, 70, 1, 2, 1, 97, 0, 0, 0, 0, 0, 0, 0, 0,
@ -124,9 +124,9 @@ unsigned char stub_armeb_v4a_linux_elf_fold[2824] = {
/* 0x0550 */ 225,160, 0, 5,229,148, 16, 4,235,255,255,155,229,157, 48, 4,
/* 0x0560 */ 232,148, 0, 6,224,130, 32, 3,224, 99, 16, 1,232,132, 0, 6,
/* 0x0570 */ 229,148, 48, 0,227, 83, 0, 0, 26,255,255,178,226,141,208, 20,
/* 0x0580 */ 232,189,128,240, 33, 88, 80, 85,233, 45, 79,240,225,160,144, 1,
/* 0x0590 */ 225,217,193,176,229,145, 16, 28,225,217,226,188,226, 77,208, 52,
/* 0x05a0 */ 227, 92, 0, 2,224,137, 96, 1,229,141, 0, 20, 3,160, 80, 16,
/* 0x0580 */ 232,189,128,240, 33, 88, 80, 85,233, 45, 79,240,225,160,160, 1,
/* 0x0590 */ 225,218,193,176,229,145, 16, 28,225,218,226,188,226, 77,208, 52,
/* 0x05a0 */ 227, 92, 0, 2,224,138, 96, 1,229,141, 0, 20, 3,160, 80, 16,
/* 0x05b0 */ 19,160, 80, 0,226, 78,224, 1,225,160, 16, 6,227,224, 0, 0,
/* 0x05c0 */ 227,160,192, 0,229,141, 32, 16,229,141, 48, 12,234, 0, 0, 13,
/* 0x05d0 */ 229,145, 48, 0,227, 83, 0, 1, 26, 0, 0, 8,229,145, 48, 20,
@ -149,15 +149,15 @@ unsigned char stub_armeb_v4a_linux_elf_fold[2824] = {
/* 0x06e0 */ 225,160, 67, 50,229,157,192, 24,229, 21, 48, 24,229,157, 16, 16,
/* 0x06f0 */ 224,140,176, 3,225,160, 42, 11,229, 21, 48, 16,225,160, 42, 34,
/* 0x0700 */ 227, 81, 0, 0,229,141, 48, 44,229,141,176, 48,224,131,128, 2,
/* 0x0710 */ 226, 4,160, 7,224, 98, 96, 11, 10, 0, 0, 15,225,160, 0, 6,
/* 0x0720 */ 225,160, 16, 8,227,138, 32, 2,227,160, 48, 16,235,255,254,255,
/* 0x0710 */ 226, 4,144, 7,224, 98, 96, 11, 10, 0, 0, 15,225,160, 0, 6,
/* 0x0720 */ 225,160, 16, 8,227,160, 32, 3,227,160, 48, 16,235,255,254,255,
/* 0x0730 */ 225, 86, 0, 0, 19,160, 0, 6, 26, 0, 0, 20,229,157, 32, 92,
/* 0x0740 */ 226, 20, 48, 4, 17,160, 48, 2,229,157, 0, 16,226,141, 16, 44,
/* 0x0750 */ 229,157, 32, 20,235,255,255, 52,234, 0, 0, 13,229, 21,192, 28,
/* 0x0760 */ 224, 98,192, 12,229,141,192, 4,229,157,192, 20,225,160, 0, 6,
/* 0x0770 */ 225,160, 16, 8,225,160, 32, 10,227,160, 48, 18,229,141,192, 0,
/* 0x0770 */ 225,160, 16, 8,225,160, 32, 9,227,160, 48, 18,229,141,192, 0,
/* 0x0780 */ 235,255,254,223,225, 86, 0, 0, 10, 0, 0, 1,227,160, 0, 8,
/* 0x0790 */ 235,255,255, 11,226,104, 48, 0,225,160,122, 3,227, 26, 0, 2,
/* 0x0790 */ 235,255,255, 11,226,104, 48, 0,225,160,122, 3,227, 25, 0, 2,
/* 0x07a0 */ 225,160,122, 39, 10, 0, 0, 7,227, 87, 0, 0, 10, 0, 0, 5,
/* 0x07b0 */ 224,134, 16, 8,225,160, 32, 7,227,160, 48, 0,226, 82, 32, 1,
/* 0x07c0 */ 228,193, 48, 1, 26,255,255,251,229,157, 16, 16,227, 81, 0, 0,
@ -169,18 +169,18 @@ unsigned char stub_armeb_v4a_linux_elf_fold[2824] = {
/* 0x0820 */ 225,160, 58, 35,227, 83, 0, 7,154, 0, 0, 56,229,159, 48,252,
/* 0x0830 */ 229,132, 0, 0,226,132, 16, 8,225,160, 0, 4,229,132, 48, 4,
/* 0x0840 */ 235,255,254,172,229,157, 0, 12,225,160, 32, 4,227,160, 16, 0,
/* 0x0850 */ 235,255,254,211,225,160, 0, 6,225,160, 16, 8,225,160, 32, 10,
/* 0x0850 */ 235,255,254,211,225,160, 0, 6,225,160, 16, 8,225,160, 32, 9,
/* 0x0860 */ 235,255,254,162,227, 80, 0, 0, 19,160, 0, 10, 26,255,255,199,
/* 0x0870 */ 229,157,192, 8,224,136, 48, 7,224,139, 16, 12,224,134, 64, 3,
/* 0x0880 */ 225, 84, 0, 1, 42, 0, 0, 7,224,100, 16, 1,225,160, 32, 10,
/* 0x0880 */ 225, 84, 0, 1, 42, 0, 0, 7,224,100, 16, 1,225,160, 32, 9,
/* 0x0890 */ 225,160, 0, 4,227,160, 48, 16,235,255,254,164,225, 84, 0, 0,
/* 0x08a0 */ 19,160, 0, 9, 26,255,255,185,229,157, 16, 28,226,129, 16, 1,
/* 0x08b0 */ 229,141, 16, 28,226,133, 80, 32,225,217, 50,188,229,157, 32, 28,
/* 0x08b0 */ 229,141, 16, 28,226,133, 80, 32,225,218, 50,188,229,157, 32, 28,
/* 0x08c0 */ 225, 82, 0, 3,186,255,255,109,229,157, 48, 16,227, 83, 0, 0,
/* 0x08d0 */ 10, 0, 0, 5,225,217, 49,176,227, 83, 0, 3, 21,157,192, 32,
/* 0x08d0 */ 10, 0, 0, 5,225,218, 49,176,227, 83, 0, 3, 21,157,192, 32,
/* 0x08e0 */ 21,157, 16, 40, 16,140, 0, 1, 27,255,254,122,229,157, 32, 88,
/* 0x08f0 */ 227, 82, 0, 0, 21,157, 48, 24, 21,130, 48, 0,229,157, 16, 24,
/* 0x0900 */ 229,153, 0, 24,224,129, 0, 0,226,141,208, 52,232,189,143,240,
/* 0x0900 */ 229,154, 0, 24,224,129, 0, 0,226,141,208, 52,232,189,143,240,
/* 0x0910 */ 229, 21, 48, 28,227, 83, 0, 0, 5,157,192, 36, 0,129, 48, 12,
/* 0x0920 */ 2,131, 64, 8, 10,255,255,192,234,255,255,201,115, 81, 98, 64,
/* 0x0930 */ 225,160,240, 14,233, 45, 69,240,226, 77,208, 12,229,157, 96, 44,

File diff suppressed because it is too large Load Diff

View File

@ -1,5 +1,5 @@
/* i386-linux.elf-fold.h
created from i386-linux.elf-fold.bin, 1889 (0x761) bytes
created from i386-linux.elf-fold.bin, 1884 (0x75c) bytes
This file is part of the UPX executable compressor.
@ -31,17 +31,17 @@
*/
#define STUB_I386_LINUX_ELF_FOLD_SIZE 1889
#define STUB_I386_LINUX_ELF_FOLD_ADLER32 0x7a161b86
#define STUB_I386_LINUX_ELF_FOLD_CRC32 0xa866d0c0
#define STUB_I386_LINUX_ELF_FOLD_SIZE 1884
#define STUB_I386_LINUX_ELF_FOLD_ADLER32 0x2c5018f0
#define STUB_I386_LINUX_ELF_FOLD_CRC32 0x0a25f2a1
unsigned char stub_i386_linux_elf_fold[1889] = {
unsigned char stub_i386_linux_elf_fold[1884] = {
/* 0x0000 */ 127, 69, 76, 70, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0,
/* 0x0010 */ 2, 0, 3, 0, 1, 0, 0, 0,128, 16,192, 0, 52, 0, 0, 0,
/* 0x0020 */ 0, 0, 0, 0, 0, 0, 0, 0, 52, 0, 32, 0, 2, 0, 0, 0,
/* 0x0030 */ 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 16,192, 0,
/* 0x0040 */ 0, 16,192, 0, 97, 7, 0, 0,100, 7, 0, 0, 5, 0, 0, 0,
/* 0x0050 */ 0, 16, 0, 0, 1, 0, 0, 0, 97, 7, 0, 0, 0, 0, 0, 0,
/* 0x0040 */ 0, 16,192, 0, 92, 7, 0, 0, 92, 7, 0, 0, 5, 0, 0, 0,
/* 0x0050 */ 0, 16, 0, 0, 1, 0, 0, 0, 92, 7, 0, 0, 0, 0, 0, 0,
/* 0x0060 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
/* 0x0070 */ 0, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
/* 0x0080 */ 137,230,129,236, 0, 16, 0, 0,137,231,106, 8, 89,243,165, 85,
@ -55,7 +55,7 @@ unsigned char stub_i386_linux_elf_fold[1889] = {
/* 0x0100 */ 252,137, 56,131,231,252, 41,201,106, 5, 88,205,128,137, 69, 16,
/* 0x0110 */ 94, 90, 1,250,175,137,241,173, 41,225,193,233, 2,243,165,141,
/* 0x0120 */ 103, 4,137,215,252, 89, 93, 94, 88, 89,129,236, 0, 10, 0, 0,
/* 0x0130 */ 137,226, 81,139, 24,139, 72, 4,131,193, 12, 96, 71,232,167, 4,
/* 0x0130 */ 137,226, 81,139, 24,139, 72, 4,131,193, 12, 96, 71,232,162, 4,
/* 0x0140 */ 0, 0, 79,129,196, 36, 10, 0, 0,137, 68, 36, 12, 89, 87, 81,
/* 0x0150 */ 41,237,137,207,190, 2, 0, 0, 0,186, 1, 0, 0, 0,185, 0,
/* 0x0160 */ 16, 0, 0, 41,219,104,192, 0, 0, 0, 88,205,128, 91,106, 6,
@ -95,64 +95,63 @@ unsigned char stub_i386_linux_elf_fold[1889] = {
/* 0x0380 */ 0,129,227, 0,240,255,255,133,192,117, 22,106, 0,131,200, 34,
/* 0x0390 */ 106,255, 80,106, 0, 83, 86,232,237,253,255,255,131,196, 24,137,
/* 0x03a0 */ 194,141, 4, 26, 41,242,139,117,224,137, 85,200,137, 69,240,102,
/* 0x03b0 */ 131,126, 44, 0,199, 69,196, 0, 0, 0, 0, 15,132,238, 1, 0,
/* 0x03b0 */ 131,126, 44, 0,199, 69,196, 0, 0, 0, 0, 15,132,233, 1, 0,
/* 0x03c0 */ 0,131,125,220, 0,116, 32,139, 69,204,131, 56, 6,117, 24,139,
/* 0x03d0 */ 77,200,186, 3, 0, 0, 0, 3, 72, 8,139, 69,216,232, 1,255,
/* 0x03e0 */ 255,255,233,177, 1, 0, 0,139, 85,204,131, 58, 1, 15,133,165,
/* 0x03e0 */ 255,255,233,172, 1, 0, 0,139, 85,204,131, 58, 1, 15,133,160,
/* 0x03f0 */ 1, 0, 0,139, 74, 24,187, 64, 98, 81,115,137,214,139, 69,200,
/* 0x0400 */ 131,225, 7, 3, 70, 8,193,225, 2,139, 82, 16,211,235,137,217,
/* 0x0410 */ 137, 85,232,131,225, 7,137, 69,236,137, 77,192,139, 78, 20,137,
/* 0x0420 */ 198, 1,193,137, 77,188,137,193,129,225,255, 15, 0, 0, 41,206,
/* 0x0430 */ 131,125,220, 0,141, 60, 10,116, 69,106, 0,139, 69,192,106,255,
/* 0x0440 */ 106, 50,131,200, 2, 80,141, 71, 3, 80, 86,232, 57,253,255,255,
/* 0x0450 */ 131,196, 24, 57,198,116, 10,184, 6, 0, 0, 0,233, 25, 1, 0,
/* 0x0460 */ 0,128,227, 4,139, 69,208,117, 2, 49,192, 80,139, 69,220,255,
/* 0x0470 */ 117,228,141, 85,232,232,117,253,255,255, 88, 90,235, 41,139, 93,
/* 0x0480 */ 204,139, 67, 4, 41,200, 80,255,117,228,106, 18,255,117,192, 87,
/* 0x0490 */ 86,232,243,252,255,255,131,196, 24, 57,198,116, 10,184, 8, 0,
/* 0x04a0 */ 0, 0,233,211, 0, 0, 0,137,248,247,216, 37,255, 15, 0, 0,
/* 0x04b0 */ 246, 69,192, 2,137, 69,184,116, 18,131,125,184, 0,141, 4, 62,
/* 0x04c0 */ 116, 9,139, 77,184,198, 0, 0, 64,226,250,131,125,220, 0,116,
/* 0x04d0 */ 122,139, 85,204,131, 58, 1,117, 91,246, 66, 24, 1,116, 85,137,
/* 0x04e0 */ 209,139, 82, 20,139, 89, 8,139, 69,204,141, 12, 26, 3, 77,200,
/* 0x04f0 */ 59, 80, 16,117, 14,137,200,247,216, 37,255, 15, 0, 0,131,248,
/* 0x0500 */ 3,119, 17,139, 85,204,107, 69,200, 52,131,122, 4, 0,141, 76,
/* 0x0510 */ 3, 12,117, 32,139, 1, 61,205,128, 97,195,116, 6,199, 1,205,
/* 0x0520 */ 128, 97,195,133,201,116, 13,139, 69,216, 49,210,131,224,254,232,
/* 0x0530 */ 175,253,255,255,137,243,137,249,139, 85,192,106,125, 88,205,128,
/* 0x0540 */ 133,192,116, 7,184, 10, 0, 0, 0,235, 47,139, 85,184,141, 4,
/* 0x0550 */ 23,141, 28, 6, 59, 93,188,115, 38,106, 0,106,255,106, 50,255,
/* 0x0560 */ 117,192, 41, 93,188,255,117,188, 83,232, 27,252,255,255,131,196,
/* 0x0570 */ 24, 57,195,116, 35,184, 9, 0, 0, 0,232,102,252,255,255,131,
/* 0x0580 */ 125,220, 0,116, 19,141, 79, 3,129,225,255, 15, 0, 0,131,249,
/* 0x0590 */ 3,119, 5,106, 91, 88,205,128,139, 77,224,255, 69,196, 15,183,
/* 0x05a0 */ 65, 44,131, 69,204, 32, 57, 69,196, 15,140, 18,254,255,255,131,
/* 0x05b0 */ 125,220, 0,116, 18,139, 93,224,102,131,123, 16, 3,116, 8,139,
/* 0x05c0 */ 93,240,106, 45, 88,205,128,131,125,212, 0,116, 8,139, 69,200,
/* 0x05d0 */ 139,117,212,137, 6,139, 85,224,139, 82, 24, 1, 85,200,139, 69,
/* 0x05e0 */ 200,141,101,244, 91, 94, 95,201,195, 85,137,229, 87, 86, 83,131,
/* 0x05f0 */ 236, 28,199, 69,232, 0, 0, 0, 0,139, 69, 8,139,117, 16,137,
/* 0x0600 */ 69,236,139,125, 28,128, 62,235,139, 93, 32,117, 6,141, 86, 2,
/* 0x0610 */ 137, 85,232,106, 0,141, 85, 24,141, 69, 32, 86,232,206,251,255,
/* 0x0620 */ 255,139, 77, 40,139, 69, 12,186, 3, 0, 0, 0,137, 77,240, 3,
/* 0x0630 */ 79, 28,137, 69, 32,139, 69,236, 41, 93, 36,232,163,252,255,255,
/* 0x0640 */ 15,183, 79, 44,139, 69,236,186, 5, 0, 0, 0,141, 95, 52,232,
/* 0x0650 */ 143,252,255,255, 15,183, 79, 42,139, 69,236,186, 4, 0, 0, 0,
/* 0x0660 */ 232,126,252,255,255,102,131,127, 16, 3, 89, 88,117, 50,139, 77,
/* 0x0670 */ 240,102,199, 71, 16, 2, 0, 3, 79, 24,186, 9, 0, 0, 0,139,
/* 0x0680 */ 69,236,137, 79, 24,232, 89,252,255,255, 15,183, 79, 44,133,201,
/* 0x0690 */ 116, 14,139, 69,240, 1, 67, 8, 1, 67, 12,131,195, 32,226,245,
/* 0x06a0 */ 141, 77,240,137,250,255,117,232, 81,255,117,236,141, 69, 32, 80,
/* 0x06b0 */ 137,240,232, 71,252,255,255,186, 9, 0, 0, 0,137,193,137, 69,
/* 0x06c0 */ 228,139, 69,236,232, 26,252,255,255,102,139, 95, 44,131,196, 16,
/* 0x06d0 */ 49,201,102,133,219,141, 87, 52,116,124,131, 58, 3,117,108,139,
/* 0x06e0 */ 93,240, 49,201, 3, 90, 8,137,202,106, 5, 88,205,128,137,198,
/* 0x06f0 */ 133,246,184, 18, 0, 0, 0,120, 26,186, 0, 2, 0, 0,137,243,
/* 0x0700 */ 137,249,106, 3, 88,205,128, 61, 0, 2, 0, 0,116, 10,184, 19,
/* 0x0710 */ 0, 0, 0,232,205,250,255,255,141, 69,240,137,250,106, 0,137,
/* 0x0720 */ 243, 80,137,240,255,117,236,106, 0,232,208,251,255,255,139, 77,
/* 0x0730 */ 240,137, 69,228,139, 69,236,186, 7, 0, 0, 0,232,162,251,255,
/* 0x0740 */ 255,131,196, 16,106, 6, 88,205,128,235, 11, 65, 15,183,195,131,
/* 0x0750 */ 194, 32, 57,193,124,132,139, 69,228,141,101,244, 91, 94, 95,201,
/* 0x0760 */ 195
/* 0x0430 */ 131,125,220, 0,141, 60, 10,116, 64,106, 0,106,255,106, 50,141,
/* 0x0440 */ 71, 3,106, 3, 80, 86,232, 62,253,255,255,131,196, 24, 57,198,
/* 0x0450 */ 116, 10,184, 6, 0, 0, 0,233, 25, 1, 0, 0,128,227, 4,139,
/* 0x0460 */ 69,208,117, 2, 49,192, 80,139, 69,220,255,117,228,141, 85,232,
/* 0x0470 */ 232,122,253,255,255, 88, 90,235, 41,139, 93,204,139, 67, 4, 41,
/* 0x0480 */ 200, 80,255,117,228,106, 18,255,117,192, 87, 86,232,248,252,255,
/* 0x0490 */ 255,131,196, 24, 57,198,116, 10,184, 8, 0, 0, 0,233,211, 0,
/* 0x04a0 */ 0, 0,137,248,247,216, 37,255, 15, 0, 0,246, 69,192, 2,137,
/* 0x04b0 */ 69,184,116, 18,131,125,184, 0,141, 4, 62,116, 9,139, 77,184,
/* 0x04c0 */ 198, 0, 0, 64,226,250,131,125,220, 0,116,122,139, 85,204,131,
/* 0x04d0 */ 58, 1,117, 91,246, 66, 24, 1,116, 85,137,209,139, 82, 20,139,
/* 0x04e0 */ 89, 8,139, 69,204,141, 12, 26, 3, 77,200, 59, 80, 16,117, 14,
/* 0x04f0 */ 137,200,247,216, 37,255, 15, 0, 0,131,248, 3,119, 17,139, 85,
/* 0x0500 */ 204,107, 69,200, 52,131,122, 4, 0,141, 76, 3, 12,117, 32,139,
/* 0x0510 */ 1, 61,205,128, 97,195,116, 6,199, 1,205,128, 97,195,133,201,
/* 0x0520 */ 116, 13,139, 69,216, 49,210,131,224,254,232,180,253,255,255,137,
/* 0x0530 */ 243,137,249,139, 85,192,106,125, 88,205,128,133,192,116, 7,184,
/* 0x0540 */ 10, 0, 0, 0,235, 47,139, 85,184,141, 4, 23,141, 28, 6, 59,
/* 0x0550 */ 93,188,115, 38,106, 0,106,255,106, 50,255,117,192, 41, 93,188,
/* 0x0560 */ 255,117,188, 83,232, 32,252,255,255,131,196, 24, 57,195,116, 35,
/* 0x0570 */ 184, 9, 0, 0, 0,232,107,252,255,255,131,125,220, 0,116, 19,
/* 0x0580 */ 141, 79, 3,129,225,255, 15, 0, 0,131,249, 3,119, 5,106, 91,
/* 0x0590 */ 88,205,128,139, 77,224,255, 69,196, 15,183, 65, 44,131, 69,204,
/* 0x05a0 */ 32, 57, 69,196, 15,140, 23,254,255,255,131,125,220, 0,116, 18,
/* 0x05b0 */ 139, 93,224,102,131,123, 16, 3,116, 8,139, 93,240,106, 45, 88,
/* 0x05c0 */ 205,128,131,125,212, 0,116, 8,139, 69,200,139,117,212,137, 6,
/* 0x05d0 */ 139, 85,224,139, 82, 24, 1, 85,200,139, 69,200,141,101,244, 91,
/* 0x05e0 */ 94, 95,201,195, 85,137,229, 87, 86, 83,131,236, 28,199, 69,232,
/* 0x05f0 */ 0, 0, 0, 0,139, 69, 8,139,117, 16,137, 69,236,139,125, 28,
/* 0x0600 */ 128, 62,235,139, 93, 32,117, 6,141, 86, 2,137, 85,232,106, 0,
/* 0x0610 */ 141, 85, 24,141, 69, 32, 86,232,211,251,255,255,139, 77, 40,139,
/* 0x0620 */ 69, 12,186, 3, 0, 0, 0,137, 77,240, 3, 79, 28,137, 69, 32,
/* 0x0630 */ 139, 69,236, 41, 93, 36,232,168,252,255,255, 15,183, 79, 44,139,
/* 0x0640 */ 69,236,186, 5, 0, 0, 0,141, 95, 52,232,148,252,255,255, 15,
/* 0x0650 */ 183, 79, 42,139, 69,236,186, 4, 0, 0, 0,232,131,252,255,255,
/* 0x0660 */ 102,131,127, 16, 3, 89, 88,117, 50,139, 77,240,102,199, 71, 16,
/* 0x0670 */ 2, 0, 3, 79, 24,186, 9, 0, 0, 0,139, 69,236,137, 79, 24,
/* 0x0680 */ 232, 94,252,255,255, 15,183, 79, 44,133,201,116, 14,139, 69,240,
/* 0x0690 */ 1, 67, 8, 1, 67, 12,131,195, 32,226,245,141, 77,240,137,250,
/* 0x06a0 */ 255,117,232, 81,255,117,236,141, 69, 32, 80,137,240,232, 76,252,
/* 0x06b0 */ 255,255,186, 9, 0, 0, 0,137,193,137, 69,228,139, 69,236,232,
/* 0x06c0 */ 31,252,255,255,102,139, 95, 44,131,196, 16, 49,201,102,133,219,
/* 0x06d0 */ 141, 87, 52,116,124,131, 58, 3,117,108,139, 93,240, 49,201, 3,
/* 0x06e0 */ 90, 8,137,202,106, 5, 88,205,128,137,198,133,246,184, 18, 0,
/* 0x06f0 */ 0, 0,120, 26,186, 0, 2, 0, 0,137,243,137,249,106, 3, 88,
/* 0x0700 */ 205,128, 61, 0, 2, 0, 0,116, 10,184, 19, 0, 0, 0,232,210,
/* 0x0710 */ 250,255,255,141, 69,240,137,250,106, 0,137,243, 80,137,240,255,
/* 0x0720 */ 117,236,106, 0,232,213,251,255,255,139, 77,240,137, 69,228,139,
/* 0x0730 */ 69,236,186, 7, 0, 0, 0,232,167,251,255,255,131,196, 16,106,
/* 0x0740 */ 6, 88,205,128,235, 11, 65, 15,183,195,131,194, 32, 57,193,124,
/* 0x0750 */ 132,139, 69,228,141,101,244, 91, 94, 95,201,195
};

View File

@ -32,8 +32,8 @@
#define STUB_MIPS_R3000_LINUX_ELF_FOLD_SIZE 2808
#define STUB_MIPS_R3000_LINUX_ELF_FOLD_ADLER32 0x02b06699
#define STUB_MIPS_R3000_LINUX_ELF_FOLD_CRC32 0xad86f34a
#define STUB_MIPS_R3000_LINUX_ELF_FOLD_ADLER32 0xc8c565c1
#define STUB_MIPS_R3000_LINUX_ELF_FOLD_CRC32 0x4f945c79
unsigned char stub_mips_r3000_linux_elf_fold[2808] = {
/* 0x0000 */ 127, 69, 76, 70, 1, 2, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0,
@ -108,14 +108,14 @@ unsigned char stub_mips_r3000_linux_elf_fold[2808] = {
/* 0x0450 */ 175,176, 0, 0,175,191, 0, 4, 4, 17,255,242, 0,192,128, 33,
/* 0x0460 */ 16, 64, 0, 2, 0, 0, 0, 0,172, 80, 0, 4,143,191, 0, 4,
/* 0x0470 */ 143,176, 0, 0, 3,224, 0, 8, 39,189, 0, 8, 39,189,255,168,
/* 0x0480 */ 175,190, 0, 80,175,181, 0, 68,175,177, 0, 52,175,191, 0, 84,
/* 0x0490 */ 175,183, 0, 76,175,182, 0, 72,175,180, 0, 64,175,179, 0, 60,
/* 0x04a0 */ 175,178, 0, 56,175,176, 0, 48,140,162, 0, 28, 0,160,168, 33,
/* 0x0480 */ 175,190, 0, 80,175,180, 0, 64,175,177, 0, 52,175,191, 0, 84,
/* 0x0490 */ 175,183, 0, 76,175,182, 0, 72,175,181, 0, 68,175,179, 0, 60,
/* 0x04a0 */ 175,178, 0, 56,175,176, 0, 48,140,162, 0, 28, 0,160,160, 33,
/* 0x04b0 */ 175,164, 0, 28, 36, 5, 0, 6, 0,224, 32, 33,175,167, 0, 32,
/* 0x04c0 */ 0,192,240, 33,175,168, 0, 36,175,169, 0, 40, 4, 17,255,213,
/* 0x04d0 */ 2,162,136, 33, 20, 64, 0, 3, 0, 0, 0, 0, 16, 0, 0, 4,
/* 0x04d0 */ 2,130,136, 33, 20, 64, 0, 3, 0, 0, 0, 0, 16, 0, 0, 4,
/* 0x04e0 */ 52, 2,255,255,140, 66, 0, 4, 0, 0, 0, 0, 36, 66,255,255,
/* 0x04f0 */ 175,162, 0, 20,150,162, 0, 16,143,164, 0, 20,150,163, 0, 44,
/* 0x04f0 */ 175,162, 0, 20,150,130, 0, 16,143,164, 0, 20,150,131, 0, 44,
/* 0x0500 */ 56, 66, 0, 2, 44, 66, 0, 1, 0, 4, 40, 39, 0, 2, 57, 0,
/* 0x0510 */ 36, 99,255,255, 2, 32, 64, 33, 36, 4,255,255, 0, 0, 72, 33,
/* 0x0520 */ 16, 0, 0, 19, 36, 10, 0, 1,141, 2, 0, 0, 0, 0, 0, 0,
@ -136,8 +136,8 @@ unsigned char stub_mips_r3000_linux_elf_fold[2808] = {
/* 0x0610 */ 142, 35, 0, 24, 2,226,176, 33, 60, 2,115, 81, 0, 3, 24,128,
/* 0x0620 */ 52, 66, 98, 64, 0, 98,144, 6,143,163, 0, 20,142, 36, 0, 16,
/* 0x0630 */ 2,195, 16, 36,175,164, 0, 0, 0,130,152, 33,142, 36, 0, 20,
/* 0x0640 */ 175,182, 0, 4, 50, 84, 0, 7,175,164, 0, 24, 19,192, 0, 27,
/* 0x0650 */ 2,194,128, 35, 2, 0, 32, 33, 2, 96, 40, 33, 54,134, 0, 2,
/* 0x0640 */ 175,182, 0, 4, 50, 85, 0, 7,175,164, 0, 24, 19,192, 0, 27,
/* 0x0650 */ 2,194,128, 35, 2, 0, 32, 33, 2, 96, 40, 33, 36, 6, 0, 3,
/* 0x0660 */ 36, 7, 8, 18, 36, 8,255,255, 4, 17,254,205, 0, 0, 72, 33,
/* 0x0670 */ 18, 2, 0, 6, 50, 66, 0, 4, 36, 4, 0,127, 4, 17,254,207,
/* 0x0680 */ 36, 2, 15,161, 16, 0,255,255, 0, 0, 0, 0, 16, 64, 0, 4,
@ -145,10 +145,10 @@ unsigned char stub_mips_r3000_linux_elf_fold[2808] = {
/* 0x06a0 */ 0, 0, 56, 33,143,166, 0, 28, 3,192, 32, 33, 4, 17,254,231,
/* 0x06b0 */ 3,160, 40, 33, 16, 0, 0, 16, 0, 0, 0, 0,142, 41, 0, 4,
/* 0x06c0 */ 143,168, 0, 28, 2, 0, 32, 33, 1, 34, 72, 35, 2, 96, 40, 33,
/* 0x06d0 */ 2,128, 48, 33, 4, 17,254,178, 36, 7, 0, 18, 18, 2, 0, 6,
/* 0x06d0 */ 2,160, 48, 33, 4, 17,254,178, 36, 7, 0, 18, 18, 2, 0, 6,
/* 0x06e0 */ 36, 4, 0,127, 36, 2, 15,161, 4, 17,254,180, 0, 0, 0, 0,
/* 0x06f0 */ 16, 0,255,255, 0, 0, 0, 0,143,164, 0, 20, 0, 19, 16, 35,
/* 0x0700 */ 50,131, 0, 2, 16, 96, 0, 8, 0, 68,144, 36, 18, 64, 0, 6,
/* 0x0700 */ 50,163, 0, 2, 16, 96, 0, 8, 0, 68,144, 36, 18, 64, 0, 6,
/* 0x0710 */ 2, 64, 16, 33, 2, 19, 24, 33, 36, 66,255,255,160, 96, 0, 0,
/* 0x0720 */ 20, 64,255,253, 36, 99, 0, 1, 19,192, 0, 43, 36, 2, 0, 1,
/* 0x0730 */ 142, 35, 0, 0, 0, 0, 0, 0, 20, 98, 0, 28, 2, 0, 32, 33,
@ -159,21 +159,21 @@ unsigned char stub_mips_r3000_linux_elf_fold[2808] = {
/* 0x0780 */ 2, 0, 32, 33, 36, 2, 0, 12,172,194, 0, 0, 60, 2, 3, 32,
/* 0x0790 */ 52, 66, 0, 8,143,164, 0, 32,172,194, 0, 4,172,192, 0, 8,
/* 0x07a0 */ 4, 17,255, 42, 0, 0, 40, 33, 2, 0, 32, 33, 2, 96, 40, 33,
/* 0x07b0 */ 2,128, 48, 33, 4, 17,254,129, 36, 2, 16, 29, 16, 64, 0, 6,
/* 0x07b0 */ 2,160, 48, 33, 4, 17,254,129, 36, 2, 16, 29, 16, 64, 0, 6,
/* 0x07c0 */ 36, 4, 0,127, 36, 2, 15,161, 4, 17,254,124, 0, 0, 0, 0,
/* 0x07d0 */ 16, 0,255,255, 0, 0, 0, 0,143,164, 0, 24, 2,114, 16, 33,
/* 0x07e0 */ 2,196, 40, 33, 2, 2,128, 33, 2, 5, 16, 43, 16, 64, 0, 14,
/* 0x07f0 */ 0,176, 40, 35, 2,128, 48, 33, 2, 0, 32, 33, 36, 7, 8, 18,
/* 0x07f0 */ 0,176, 40, 35, 2,160, 48, 33, 2, 0, 32, 33, 36, 7, 8, 18,
/* 0x0800 */ 36, 8,255,255, 4, 17,254,102, 0, 0, 72, 33, 18, 2, 0, 6,
/* 0x0810 */ 36, 4, 0,127, 36, 2, 15,161, 4, 17,254,104, 0, 0, 0, 0,
/* 0x0820 */ 16, 0,255,255, 0, 0, 0, 0,143,162, 0, 16, 38, 49, 0, 32,
/* 0x0830 */ 36, 66, 0, 1,175,162, 0, 16,150,162, 0, 44,143,163, 0, 16,
/* 0x0830 */ 36, 66, 0, 1,175,162, 0, 16,150,130, 0, 44,143,163, 0, 16,
/* 0x0840 */ 0, 0, 0, 0, 0, 98, 16, 42, 20, 64,255, 95, 0, 0, 0, 0,
/* 0x0850 */ 19,192, 0, 11, 36, 2, 0, 3,150,163, 0, 16, 0, 0, 0, 0,
/* 0x0850 */ 19,192, 0, 11, 36, 2, 0, 3,150,131, 0, 16, 0, 0, 0, 0,
/* 0x0860 */ 16, 98, 0, 7, 0, 0, 0, 0,143,162, 0, 12,143,163, 0, 8,
/* 0x0870 */ 0, 0, 0, 0, 0, 67, 32, 33, 4, 17,254, 80, 36, 2, 15,205,
/* 0x0880 */ 143,164, 0, 36, 0, 0, 0, 0, 16,128, 0, 2, 0, 0, 0, 0,
/* 0x0890 */ 172,151, 0, 0,142,162, 0, 24,143,191, 0, 84, 2,226, 16, 33,
/* 0x0890 */ 172,151, 0, 0,142,130, 0, 24,143,191, 0, 84, 2,226, 16, 33,
/* 0x08a0 */ 143,190, 0, 80,143,183, 0, 76,143,182, 0, 72,143,181, 0, 68,
/* 0x08b0 */ 143,180, 0, 64,143,179, 0, 60,143,178, 0, 56,143,177, 0, 52,
/* 0x08c0 */ 143,176, 0, 48, 3,224, 0, 8, 39,189, 0, 88, 39,189,255,200,

View File

@ -32,8 +32,8 @@
#define STUB_MIPSEL_R3000_LINUX_ELF_FOLD_SIZE 2808
#define STUB_MIPSEL_R3000_LINUX_ELF_FOLD_ADLER32 0x99cd6698
#define STUB_MIPSEL_R3000_LINUX_ELF_FOLD_CRC32 0x7eb8dddc
#define STUB_MIPSEL_R3000_LINUX_ELF_FOLD_ADLER32 0x60e165c0
#define STUB_MIPSEL_R3000_LINUX_ELF_FOLD_CRC32 0xd3ea03c9
unsigned char stub_mipsel_r3000_linux_elf_fold[2808] = {
/* 0x0000 */ 127, 69, 76, 70, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0,
@ -108,14 +108,14 @@ unsigned char stub_mipsel_r3000_linux_elf_fold[2808] = {
/* 0x0450 */ 0, 0,176,175, 4, 0,191,175,242,255, 17, 4, 33,128,192, 0,
/* 0x0460 */ 2, 0, 64, 16, 0, 0, 0, 0, 4, 0, 80,172, 4, 0,191,143,
/* 0x0470 */ 0, 0,176,143, 8, 0,224, 3, 8, 0,189, 39,168,255,189, 39,
/* 0x0480 */ 80, 0,190,175, 68, 0,181,175, 52, 0,177,175, 84, 0,191,175,
/* 0x0490 */ 76, 0,183,175, 72, 0,182,175, 64, 0,180,175, 60, 0,179,175,
/* 0x04a0 */ 56, 0,178,175, 48, 0,176,175, 28, 0,162,140, 33,168,160, 0,
/* 0x0480 */ 80, 0,190,175, 64, 0,180,175, 52, 0,177,175, 84, 0,191,175,
/* 0x0490 */ 76, 0,183,175, 72, 0,182,175, 68, 0,181,175, 60, 0,179,175,
/* 0x04a0 */ 56, 0,178,175, 48, 0,176,175, 28, 0,162,140, 33,160,160, 0,
/* 0x04b0 */ 28, 0,164,175, 6, 0, 5, 36, 33, 32,224, 0, 32, 0,167,175,
/* 0x04c0 */ 33,240,192, 0, 36, 0,168,175, 40, 0,169,175,213,255, 17, 4,
/* 0x04d0 */ 33,136,162, 2, 3, 0, 64, 20, 0, 0, 0, 0, 4, 0, 0, 16,
/* 0x04d0 */ 33,136,130, 2, 3, 0, 64, 20, 0, 0, 0, 0, 4, 0, 0, 16,
/* 0x04e0 */ 255,255, 2, 52, 4, 0, 66,140, 0, 0, 0, 0,255,255, 66, 36,
/* 0x04f0 */ 20, 0,162,175, 16, 0,162,150, 20, 0,164,143, 44, 0,163,150,
/* 0x04f0 */ 20, 0,162,175, 16, 0,130,150, 20, 0,164,143, 44, 0,131,150,
/* 0x0500 */ 2, 0, 66, 56, 1, 0, 66, 44, 39, 40, 4, 0, 0, 57, 2, 0,
/* 0x0510 */ 255,255, 99, 36, 33, 64, 32, 2,255,255, 4, 36, 33, 72, 0, 0,
/* 0x0520 */ 19, 0, 0, 16, 1, 0, 10, 36, 0, 0, 2,141, 0, 0, 0, 0,
@ -136,8 +136,8 @@ unsigned char stub_mipsel_r3000_linux_elf_fold[2808] = {
/* 0x0610 */ 24, 0, 35,142, 33,176,226, 2, 81,115, 2, 60,128, 24, 3, 0,
/* 0x0620 */ 64, 98, 66, 52, 6,144, 98, 0, 20, 0,163,143, 16, 0, 36,142,
/* 0x0630 */ 36, 16,195, 2, 0, 0,164,175, 33,152,130, 0, 20, 0, 36,142,
/* 0x0640 */ 4, 0,182,175, 7, 0, 84, 50, 24, 0,164,175, 27, 0,192, 19,
/* 0x0650 */ 35,128,194, 2, 33, 32, 0, 2, 33, 40, 96, 2, 2, 0,134, 54,
/* 0x0640 */ 4, 0,182,175, 7, 0, 85, 50, 24, 0,164,175, 27, 0,192, 19,
/* 0x0650 */ 35,128,194, 2, 33, 32, 0, 2, 33, 40, 96, 2, 3, 0, 6, 36,
/* 0x0660 */ 18, 8, 7, 36,255,255, 8, 36,205,254, 17, 4, 33, 72, 0, 0,
/* 0x0670 */ 6, 0, 2, 18, 4, 0, 66, 50,127, 0, 4, 36,207,254, 17, 4,
/* 0x0680 */ 161, 15, 2, 36,255,255, 0, 16, 0, 0, 0, 0, 4, 0, 64, 16,
@ -145,10 +145,10 @@ unsigned char stub_mipsel_r3000_linux_elf_fold[2808] = {
/* 0x06a0 */ 33, 56, 0, 0, 28, 0,166,143, 33, 32,192, 3,231,254, 17, 4,
/* 0x06b0 */ 33, 40,160, 3, 16, 0, 0, 16, 0, 0, 0, 0, 4, 0, 41,142,
/* 0x06c0 */ 28, 0,168,143, 33, 32, 0, 2, 35, 72, 34, 1, 33, 40, 96, 2,
/* 0x06d0 */ 33, 48,128, 2,178,254, 17, 4, 18, 0, 7, 36, 6, 0, 2, 18,
/* 0x06d0 */ 33, 48,160, 2,178,254, 17, 4, 18, 0, 7, 36, 6, 0, 2, 18,
/* 0x06e0 */ 127, 0, 4, 36,161, 15, 2, 36,180,254, 17, 4, 0, 0, 0, 0,
/* 0x06f0 */ 255,255, 0, 16, 0, 0, 0, 0, 20, 0,164,143, 35, 16, 19, 0,
/* 0x0700 */ 2, 0,131, 50, 8, 0, 96, 16, 36,144, 68, 0, 6, 0, 64, 18,
/* 0x0700 */ 2, 0,163, 50, 8, 0, 96, 16, 36,144, 68, 0, 6, 0, 64, 18,
/* 0x0710 */ 33, 16, 64, 2, 33, 24, 19, 2,255,255, 66, 36, 0, 0, 96,160,
/* 0x0720 */ 253,255, 64, 20, 1, 0, 99, 36, 43, 0,192, 19, 1, 0, 2, 36,
/* 0x0730 */ 0, 0, 35,142, 0, 0, 0, 0, 28, 0, 98, 20, 33, 32, 0, 2,
@ -159,21 +159,21 @@ unsigned char stub_mipsel_r3000_linux_elf_fold[2808] = {
/* 0x0780 */ 33, 32, 0, 2, 12, 0, 2, 36, 0, 0,194,172, 32, 3, 2, 60,
/* 0x0790 */ 8, 0, 66, 52, 32, 0,164,143, 4, 0,194,172, 8, 0,192,172,
/* 0x07a0 */ 42,255, 17, 4, 33, 40, 0, 0, 33, 32, 0, 2, 33, 40, 96, 2,
/* 0x07b0 */ 33, 48,128, 2,129,254, 17, 4, 29, 16, 2, 36, 6, 0, 64, 16,
/* 0x07b0 */ 33, 48,160, 2,129,254, 17, 4, 29, 16, 2, 36, 6, 0, 64, 16,
/* 0x07c0 */ 127, 0, 4, 36,161, 15, 2, 36,124,254, 17, 4, 0, 0, 0, 0,
/* 0x07d0 */ 255,255, 0, 16, 0, 0, 0, 0, 24, 0,164,143, 33, 16,114, 2,
/* 0x07e0 */ 33, 40,196, 2, 33,128, 2, 2, 43, 16, 5, 2, 14, 0, 64, 16,
/* 0x07f0 */ 35, 40,176, 0, 33, 48,128, 2, 33, 32, 0, 2, 18, 8, 7, 36,
/* 0x07f0 */ 35, 40,176, 0, 33, 48,160, 2, 33, 32, 0, 2, 18, 8, 7, 36,
/* 0x0800 */ 255,255, 8, 36,102,254, 17, 4, 33, 72, 0, 0, 6, 0, 2, 18,
/* 0x0810 */ 127, 0, 4, 36,161, 15, 2, 36,104,254, 17, 4, 0, 0, 0, 0,
/* 0x0820 */ 255,255, 0, 16, 0, 0, 0, 0, 16, 0,162,143, 32, 0, 49, 38,
/* 0x0830 */ 1, 0, 66, 36, 16, 0,162,175, 44, 0,162,150, 16, 0,163,143,
/* 0x0830 */ 1, 0, 66, 36, 16, 0,162,175, 44, 0,130,150, 16, 0,163,143,
/* 0x0840 */ 0, 0, 0, 0, 42, 16, 98, 0, 95,255, 64, 20, 0, 0, 0, 0,
/* 0x0850 */ 11, 0,192, 19, 3, 0, 2, 36, 16, 0,163,150, 0, 0, 0, 0,
/* 0x0850 */ 11, 0,192, 19, 3, 0, 2, 36, 16, 0,131,150, 0, 0, 0, 0,
/* 0x0860 */ 7, 0, 98, 16, 0, 0, 0, 0, 12, 0,162,143, 8, 0,163,143,
/* 0x0870 */ 0, 0, 0, 0, 33, 32, 67, 0, 80,254, 17, 4,205, 15, 2, 36,
/* 0x0880 */ 36, 0,164,143, 0, 0, 0, 0, 2, 0,128, 16, 0, 0, 0, 0,
/* 0x0890 */ 0, 0,151,172, 24, 0,162,142, 84, 0,191,143, 33, 16,226, 2,
/* 0x0890 */ 0, 0,151,172, 24, 0,130,142, 84, 0,191,143, 33, 16,226, 2,
/* 0x08a0 */ 80, 0,190,143, 76, 0,183,143, 72, 0,182,143, 68, 0,181,143,
/* 0x08b0 */ 64, 0,180,143, 60, 0,179,143, 56, 0,178,143, 52, 0,177,143,
/* 0x08c0 */ 48, 0,176,143, 8, 0,224, 3, 88, 0,189, 39,200,255,189, 39,

View File

@ -130,6 +130,7 @@ section LEXEC020
#define PAGE_SHIFT 12
#define PAGE_SIZE ( 1 << PAGE_SHIFT)
#define PAGE_MASK (~0 << PAGE_SHIFT)
#define MAP_FIXED 0x10
#define MAP_PRIVATE 0x02
@ -138,6 +139,7 @@ section LEXEC020
#define PROT_WRITE 2
#define PROT_EXEC 4
#define __NR_mmap 90
#define __NR_mprotect 125
#define szElf32_Ehdr 0x34
#define p_memsz 5*4
@ -151,7 +153,7 @@ msg_SELinux:
pop edx // length
call L71
L70:
.ascii "PROT_EXEC|PROT_WRITE failed.\n"
.ascii "mmap failed.\n"
L71:
pop ecx // message text
push 2; pop ebx // fd stderr
@ -191,7 +193,7 @@ section LEXECEXE // in: eax= roundup(PAGE_SIZE, hi(.text))
push 0 // offset
push -1 // *BSD demands -1==fd for mmap(,,,MAP_ANON,,)
push MAP_FIXED | MAP_PRIVATE | MAP_ANONYMOUS
push PROT_READ | PROT_WRITE | PROT_EXEC
push PROT_READ | PROT_WRITE
push [esi] // length {fold_begin}.sz_unc
push eax // destination
mov ebx, esp // address of parameter vector for __NR_mmap
@ -203,6 +205,7 @@ section LEXECEXE // in: eax= roundup(PAGE_SIZE, hi(.text))
sub ecx,edx // - &Elf32_Ehdr
mov [4*4 + esp],ecx // LENU
xchg eax,edx // edx= new fold_begin
push ebp // P_12 old f_exp (also new f_exp)
section LEXECDYN // in: eax= roundup(PAGE_SIZE, hi(.text))
// VDSO might be at [eax]; if so, then erase AT_SYSINFO and AT_SYSINFO_EHDR.
@ -247,7 +250,7 @@ AT_SYSINFO_EHDR=33
push 0 // offset
push -1 // *BSD demands -1==fd for mmap(,,,MAP_ANON,,)
push MAP_FIXED | MAP_PRIVATE | MAP_ANONYMOUS
push PROT_READ | PROT_WRITE | PROT_EXEC
push PROT_READ | PROT_WRITE
push edi // length
push eax // destination
mov ebx, esp // address of parameter vector for __NR_mmap
@ -264,6 +267,7 @@ AT_SYSINFO_EHDR=33
xchg eax, ebx // %ebx= &Elf32_Ehdr of this program
// Copy to new pages
push ebp // P_11 old f_exp
sub edi,[esi] // - {fold_begin}.sz_unc
lea ecx,[3+ edi] // len
push edi; mov edi,edx // dst
@ -272,15 +276,20 @@ AT_SYSINFO_EHDR=33
add ebp,edx
mov ebx,edx // reloc &Elf32_Ehdr
shr ecx,2; rep movsd
mov edx,edi // new &fold_begin
pop esi
pop edi
pop eax // P_11
sub edi,offset eof // edi= sz_pack2
push edi // LENX
push eax // P_12 old f_exp (has PROT_EXEC)
section LEXEC025 // entry edx= new fold_begin; esi= &{fold_begin}.b_info
push edx // P_10 &retaddr= fold_begin
lodsd; push eax // {fold_begin}.sz_unc (maximum dstlen for lzma)
lodsd // eax= {fold_begin}.sz_unc
push eax; push edx // P_13 params for mprotect
push eax // {fold_begin}.sz_unc (maximum dstlen for lzma)
mov ecx,esp // save &dstlen
push eax // space for 5th param
push ecx // &dstlen
@ -290,9 +299,23 @@ section LEXEC025 // entry edx= new fold_begin; esi= &{fold_begin}.b_info
lodsd // last 4 bytes of b_info
mov [4*3 + esp],eax
push esi // &compressed_data
call ebp // decompress(&src, srclen, &dst, &dstlen, b_info.misc)
call [9*4 + esp] // old_f_exp(&src, srclen, &dst, &dstlen, b_info.misc)
add esp, 0+(5+1)*4 // args to decompress
ret // P_10 &destination
pop ebx; pop ecx // P_13 fold_begin, .sz_unc
sub ebx,ebp // extend down to new f_exp
add ecx,ebx // len(fold_begin) + len(new f_exp)
mov ebx,ebp // start at new f_exp
mov eax,ebx // base
and eax,~PAGE_MASK // fragment on low end
sub ebx,eax // round down to page boundary
add ecx,eax // increase length
push PROT_READ | PROT_EXEC; pop edx
push __NR_mprotect; pop eax; int 0x80
ret 4*1 // P_10 jmp; P_12 toss
main:
pop ebp // &decompress
call unfold

View File

@ -636,14 +636,14 @@ do_xmap(int const fdi, Elf32_Ehdr const *const ehdr, Extent *const xi,
# define LEN_OVER 0
#endif /*}*/
if (xi) {
if (xi) { // compresed source: mprotect(,,prot) later
if (addr != mmap_privanon(addr, LEN_OVER + mlen,
prot | PROT_WRITE, MAP_FIXED) )
PROT_WRITE | PROT_READ, MAP_FIXED) )
err_exit(6);
unpackExtent(xi, &xo, (f_expand *)fdi,
((PROT_EXEC & prot) ? f_unf : 0) );
}
else {
else { // PT_INTERP
if (addr != mmap(addr, mlen, prot, MAP_FIXED | MAP_PRIVATE,
fdi, phdr->p_offset - frag) )
err_exit(8);

View File

@ -169,10 +169,10 @@ Idx Name Size VMA LMA File off Algn Flags
164 ctok32.30 0000000a 00000000 00000000 00001aa8 2**0 CONTENTS, RELOC, READONLY
165 ctok32.40 00000005 00000000 00000000 00001ab2 2**0 CONTENTS, RELOC, READONLY
166 LEXEC017 00000002 00000000 00000000 00001ab7 2**0 CONTENTS, READONLY
167 LEXEC020 0000004e 00000000 00000000 00001ab9 2**0 CONTENTS, READONLY
168 LEXECEXE 00000032 00000000 00000000 00001b07 2**0 CONTENTS, RELOC, READONLY
169 LEXECDYN 00000084 00000000 00000000 00001b39 2**0 CONTENTS, RELOC, READONLY
170 LEXEC025 00000020 00000000 00000000 00001bbd 2**0 CONTENTS, RELOC, READONLY
167 LEXEC020 0000003e 00000000 00000000 00001ab9 2**0 CONTENTS, READONLY
168 LEXECEXE 00000033 00000000 00000000 00001af7 2**0 CONTENTS, RELOC, READONLY
169 LEXECDYN 00000087 00000000 00000000 00001b2a 2**0 CONTENTS, RELOC, READONLY
170 LEXEC025 00000041 00000000 00000000 00001bb1 2**0 CONTENTS, RELOC, READONLY
SYMBOL TABLE:
00000000 l d N2BSMA10 00000000 N2BSMA10
00000000 l d N2BFAS11 00000000 N2BFAS11
@ -668,10 +668,10 @@ OFFSET TYPE VALUE
RELOCATION RECORDS FOR [LEXECDYN]:
OFFSET TYPE VALUE
00000031 R_386_32 LEXEC025
0000007f R_386_32 LEXEC025
00000081 R_386_32 LEXEC025
00000051 R_386_PC32 LEXEC020
RELOCATION RECORDS FOR [LEXEC025]:
OFFSET TYPE VALUE
00000018 R_386_PC32 LEXEC020
0000001c R_386_32 O_BINFO
00000039 R_386_PC32 LEXEC020
0000003d R_386_32 O_BINFO

View File

@ -9,24 +9,23 @@ Linker script and memory map
TARGET(elf32-i386)
0x0000000000c01080 . = ((0xc01000 + SIZEOF_HEADERS) + 0xc)
.text 0x0000000000c01080 0x6e4
.text 0x0000000000c01080 0x6dc
*(.text)
.text 0x0000000000c01080 0x138 tmp/i386-linux.elf-fold.o
0x0000000000c01189 mmap
.text 0x0000000000c011b8 0x5a9 tmp/i386-linux.elf-main.o
0x0000000000c015e9 upx_main
.text 0x0000000000c011b8 0x5a4 tmp/i386-linux.elf-main.o
0x0000000000c015e4 upx_main
*(.data)
*fill* 0x0000000000c01761 0x3 00
.data 0x0000000000c01764 0x0 tmp/i386-linux.elf-fold.o
.data 0x0000000000c01764 0x0 tmp/i386-linux.elf-main.o
.data 0x0000000000c0175c 0x0 tmp/i386-linux.elf-fold.o
.data 0x0000000000c0175c 0x0 tmp/i386-linux.elf-main.o
.data
.bss 0x0000000000c01764 0x0
.bss 0x0000000000c01764 0x0 tmp/i386-linux.elf-fold.o
.bss 0x0000000000c01764 0x0 tmp/i386-linux.elf-main.o
.bss 0x0000000000c0175c 0x0
.bss 0x0000000000c0175c 0x0 tmp/i386-linux.elf-fold.o
.bss 0x0000000000c0175c 0x0 tmp/i386-linux.elf-main.o
.rel.dyn 0x0000000000c01764 0x0
.rel.dyn 0x0000000000c0175c 0x0
.rel.text 0x0000000000000000 0x0 tmp/i386-linux.elf-fold.o
LOAD tmp/i386-linux.elf-fold.o
LOAD tmp/i386-linux.elf-main.o