From 17f47d3c0a10ef48f5db83f9ffc776cd65e94eb9 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sun, 4 Sep 2016 19:05:31 -0700 Subject: [PATCH 01/29] p_mach*: Try for MacOSX 10.12 "Sierra" with UUID, XHDR. --- src/p_mach.cpp | 96 ++++++++++++++++++++++++++++++++++------------- src/p_mach.h | 76 +++++++++++++++++++++++++++++++++++-- src/p_mach_enum.h | 9 ++++- 3 files changed, 149 insertions(+), 32 deletions(-) diff --git a/src/p_mach.cpp b/src/p_mach.cpp index 716a86e4..7aa17f6c 100644 --- a/src/p_mach.cpp +++ b/src/p_mach.cpp @@ -100,6 +100,9 @@ PackMachBase::PackMachBase(InputFile *f, unsigned cputype, unsigned filetype, { MachClass::compileTimeAssertions(); bele = N_BELE_CTP::getRTP((const BeLePolicy*) NULL); + memset(&cmdUUID, 0, sizeof(cmdUUID)); + memset(&cmdSRCVER, 0, sizeof(cmdSRCVER)); + memset(&cmdVERMIN, 0, sizeof(cmdVERMIN)); } template @@ -574,9 +577,10 @@ void PackMachPPC32::pack4(OutputFile *fo, Filter &ft) // append PackHeader overlay_offset = sizeof(mhdro) + sizeof(segZERO) + sizeof(segXHDR) + sizeof(secXHDR) + sizeof(segTEXT) + sizeof(secTEXT) + + sizeof(cmdUUID) + sizeof(segLINK) + sizeof(threado) + sizeof(linfo); if (my_filetype==Mach_header::MH_EXECUTE) { - overlay_offset += sizeof(uuid_cmd) + sizeof(linkitem); + overlay_offset += sizeof(linkitem); } super::pack4(fo, ft); @@ -588,7 +592,7 @@ void PackMachPPC32::pack4(OutputFile *fo, Filter &ft) // append PackHeader secTEXT.size = segTEXT.filesize - secTEXT.offset; secXHDR.offset = overlay_offset - sizeof(linfo); if (my_filetype==Mach_header::MH_EXECUTE) { - secXHDR.offset -= sizeof(uuid_cmd) + sizeof(linkitem); + secXHDR.offset -= sizeof(linkitem); } secXHDR.addr += secXHDR.offset; unsigned foff1 = (PAGE_MASK & (~PAGE_MASK + segTEXT.filesize)); @@ -603,10 +607,10 @@ void PackMachPPC32::pack4(OutputFile *fo, Filter &ft) // append PackHeader fo->rewrite(&secXHDR, sizeof(secXHDR)); fo->rewrite(&segTEXT, sizeof(segTEXT)); fo->rewrite(&secTEXT, sizeof(secTEXT)); + fo->rewrite(&cmdUUID, sizeof(cmdUUID)); fo->rewrite(&segLINK, sizeof(segLINK)); fo->rewrite(&threado, sizeof(threado)); if (my_filetype==Mach_header::MH_EXECUTE) { - fo->rewrite(&uuid_cmd, sizeof(uuid_cmd)); fo->rewrite(&linkitem, sizeof(linkitem)); } fo->rewrite(&linfo, sizeof(linfo)); @@ -618,9 +622,10 @@ void PackMachPPC64LE::pack4(OutputFile *fo, Filter &ft) // append PackHeader overlay_offset = sizeof(mhdro) + sizeof(segZERO) + sizeof(segXHDR) + sizeof(secXHDR) + sizeof(segTEXT) + sizeof(secTEXT) + + sizeof(cmdUUID) + sizeof(segLINK) + sizeof(threado) + sizeof(linfo); if (my_filetype==Mach_header::MH_EXECUTE) { - overlay_offset += sizeof(uuid_cmd) + sizeof(linkitem); + overlay_offset += sizeof(linkitem); } super::pack4(fo, ft); @@ -632,7 +637,7 @@ void PackMachPPC64LE::pack4(OutputFile *fo, Filter &ft) // append PackHeader secTEXT.size = segTEXT.filesize - secTEXT.offset; secXHDR.offset = overlay_offset - sizeof(linfo); if (my_filetype==Mach_header::MH_EXECUTE) { - secXHDR.offset -= sizeof(uuid_cmd) + sizeof(linkitem); + secXHDR.offset -= sizeof(linkitem); } secXHDR.addr += secXHDR.offset; unsigned foff1 = (PAGE_MASK & (~PAGE_MASK + segTEXT.filesize)); @@ -647,10 +652,10 @@ void PackMachPPC64LE::pack4(OutputFile *fo, Filter &ft) // append PackHeader fo->rewrite(&secXHDR, sizeof(secXHDR)); fo->rewrite(&segTEXT, sizeof(segTEXT)); fo->rewrite(&secTEXT, sizeof(secTEXT)); + fo->rewrite(&cmdUUID, sizeof(cmdUUID)); fo->rewrite(&segLINK, sizeof(segLINK)); fo->rewrite(&threado, sizeof(threado)); if (my_filetype==Mach_header::MH_EXECUTE) { - fo->rewrite(&uuid_cmd, sizeof(uuid_cmd)); fo->rewrite(&linkitem, sizeof(linkitem)); } fo->rewrite(&linfo, sizeof(linfo)); @@ -666,9 +671,10 @@ void PackMachI386::pack4(OutputFile *fo, Filter &ft) // append PackHeader overlay_offset = sizeof(mhdro) + sizeof(segZERO) + sizeof(segXHDR) + sizeof(secXHDR) + sizeof(segTEXT) + sizeof(secTEXT) + + sizeof(cmdUUID) + sizeof(segLINK) + sizeof(threado) + sizeof(linfo); if (my_filetype==Mach_header::MH_EXECUTE) { - overlay_offset += sizeof(uuid_cmd) + sizeof(linkitem); + overlay_offset += sizeof(linkitem); } super::pack4(fo, ft); @@ -680,7 +686,7 @@ void PackMachI386::pack4(OutputFile *fo, Filter &ft) // append PackHeader secTEXT.size = segTEXT.filesize - secTEXT.offset; secXHDR.offset = overlay_offset - sizeof(linfo); if (my_filetype==Mach_header::MH_EXECUTE) { - secXHDR.offset -= sizeof(uuid_cmd) + sizeof(linkitem); + secXHDR.offset -= sizeof(linkitem); } secXHDR.addr += secXHDR.offset; unsigned foff1 = (PAGE_MASK & (~PAGE_MASK + segTEXT.filesize)); @@ -695,10 +701,10 @@ void PackMachI386::pack4(OutputFile *fo, Filter &ft) // append PackHeader fo->rewrite(&secXHDR, sizeof(secXHDR)); fo->rewrite(&segTEXT, sizeof(segTEXT)); fo->rewrite(&secTEXT, sizeof(secTEXT)); + fo->rewrite(&cmdUUID, sizeof(cmdUUID)); fo->rewrite(&segLINK, sizeof(segLINK)); fo->rewrite(&threado, sizeof(threado)); if (my_filetype==Mach_header::MH_EXECUTE) { - fo->rewrite(&uuid_cmd, sizeof(uuid_cmd)); fo->rewrite(&linkitem, sizeof(linkitem)); } fo->rewrite(&linfo, sizeof(linfo)); @@ -706,13 +712,18 @@ void PackMachI386::pack4(OutputFile *fo, Filter &ft) // append PackHeader void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader { + N_Mach::Mach_main_command cmdMAIN; // offset of p_info in compressed file overlay_offset = sizeof(mhdro) + sizeof(segZERO) + sizeof(segXHDR) + sizeof(secXHDR) + sizeof(segTEXT) + sizeof(secTEXT) - + sizeof(segLINK) + sizeof(threado) + sizeof(linfo); + + sizeof(cmdUUID) + sizeof(cmdSRCVER) + sizeof(cmdVERMIN) + sizeof(cmdMAIN) + + sizeof(N_Mach::Mach_dyld_info_only_command) + sizeof(Mach_dysymtab_command) + + sizeof(N_Mach::Mach_load_dylinker_command) + sizeof(N_Mach::Mach_load_dylib_command) + + sizeof(N_Mach::Mach_function_starts_command) + sizeof(N_Mach::Mach_data_in_code_command) + + sizeof(linfo); if (my_filetype==Mach_header::MH_EXECUTE) { - overlay_offset += sizeof(uuid_cmd) + sizeof(linkitem); + overlay_offset += sizeof(linkitem); } super::pack4(fo, ft); @@ -724,7 +735,7 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader secTEXT.size = segTEXT.filesize - secTEXT.offset; secXHDR.offset = overlay_offset - sizeof(linfo); if (my_filetype==Mach_header::MH_EXECUTE) { - secXHDR.offset -= sizeof(uuid_cmd) + sizeof(linkitem); + secXHDR.offset -= sizeof(linkitem); } secXHDR.addr += secXHDR.offset; unsigned foff1 = (PAGE_MASK & (~PAGE_MASK + segTEXT.filesize)); @@ -739,10 +750,10 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader fo->rewrite(&secXHDR, sizeof(secXHDR)); fo->rewrite(&segTEXT, sizeof(segTEXT)); fo->rewrite(&secTEXT, sizeof(secTEXT)); + fo->rewrite(&cmdUUID, sizeof(cmdUUID)); fo->rewrite(&segLINK, sizeof(segLINK)); fo->rewrite(&threado, sizeof(threado)); if (my_filetype==Mach_header::MH_EXECUTE) { - fo->rewrite(&uuid_cmd, sizeof(uuid_cmd)); fo->rewrite(&linkitem, sizeof(linkitem)); } fo->rewrite(&linfo, sizeof(linfo)); @@ -754,9 +765,10 @@ void PackMachARMEL::pack4(OutputFile *fo, Filter &ft) // append PackHeader overlay_offset = sizeof(mhdro) + sizeof(segZERO) + sizeof(segXHDR) + sizeof(secXHDR) + sizeof(segTEXT) + sizeof(secTEXT) + + sizeof(cmdUUID) + sizeof(segLINK) + sizeof(threado) + sizeof(linfo); if (my_filetype==Mach_header::MH_EXECUTE) { - overlay_offset += sizeof(uuid_cmd) + sizeof(linkitem); + overlay_offset += sizeof(linkitem); } super::pack4(fo, ft); @@ -768,7 +780,7 @@ void PackMachARMEL::pack4(OutputFile *fo, Filter &ft) // append PackHeader secTEXT.size = segTEXT.filesize - secTEXT.offset; secXHDR.offset = overlay_offset - sizeof(linfo); if (my_filetype==Mach_header::MH_EXECUTE) { - secXHDR.offset -= sizeof(uuid_cmd) + sizeof(linkitem); + secXHDR.offset -= sizeof(linkitem); } secXHDR.addr += secXHDR.offset; unsigned foff1 = (PAGE_MASK & (~PAGE_MASK + segTEXT.filesize)); @@ -783,10 +795,10 @@ void PackMachARMEL::pack4(OutputFile *fo, Filter &ft) // append PackHeader fo->rewrite(&secXHDR, sizeof(secXHDR)); fo->rewrite(&segTEXT, sizeof(segTEXT)); fo->rewrite(&secTEXT, sizeof(secTEXT)); + fo->rewrite(&cmdUUID, sizeof(cmdUUID)); fo->rewrite(&segLINK, sizeof(segLINK)); fo->rewrite(&threado, sizeof(threado)); if (my_filetype==Mach_header::MH_EXECUTE) { - fo->rewrite(&uuid_cmd, sizeof(uuid_cmd)); fo->rewrite(&linkitem, sizeof(linkitem)); } fo->rewrite(&linfo, sizeof(linfo)); @@ -798,9 +810,10 @@ void PackMachARM64EL::pack4(OutputFile *fo, Filter &ft) // append PackHeader overlay_offset = sizeof(mhdro) + sizeof(segZERO) + sizeof(segXHDR) + sizeof(secXHDR) + sizeof(segTEXT) + sizeof(secTEXT) + + sizeof(cmdUUID) + sizeof(segLINK) + sizeof(threado) + sizeof(linfo); if (my_filetype==Mach_header::MH_EXECUTE) { - overlay_offset += sizeof(uuid_cmd) + sizeof(linkitem); + overlay_offset += sizeof(linkitem); } super::pack4(fo, ft); @@ -812,7 +825,7 @@ void PackMachARM64EL::pack4(OutputFile *fo, Filter &ft) // append PackHeader secTEXT.size = segTEXT.filesize - secTEXT.offset; secXHDR.offset = overlay_offset - sizeof(linfo); if (my_filetype==Mach_header::MH_EXECUTE) { - secXHDR.offset -= sizeof(uuid_cmd) + sizeof(linkitem); + secXHDR.offset -= sizeof(linkitem); } secXHDR.addr += secXHDR.offset; unsigned foff1 = (PAGE_MASK & (~PAGE_MASK + segTEXT.filesize)); @@ -827,10 +840,10 @@ void PackMachARM64EL::pack4(OutputFile *fo, Filter &ft) // append PackHeader fo->rewrite(&secXHDR, sizeof(secXHDR)); fo->rewrite(&segTEXT, sizeof(segTEXT)); fo->rewrite(&secTEXT, sizeof(secTEXT)); + fo->rewrite(&cmdUUID, sizeof(cmdUUID)); fo->rewrite(&segLINK, sizeof(segLINK)); fo->rewrite(&threado, sizeof(threado)); if (my_filetype==Mach_header::MH_EXECUTE) { - fo->rewrite(&uuid_cmd, sizeof(uuid_cmd)); fo->rewrite(&linkitem, sizeof(linkitem)); } fo->rewrite(&linfo, sizeof(linfo)); @@ -1421,11 +1434,12 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e unsigned const lc_seg = lc_segment[sizeof(Addr)>>3]; mhdro = mhdri; if (my_filetype==Mach_header::MH_EXECUTE) { - mhdro.ncmds = 5; // __ZERO, __XHDR, __TEXT, __LINKEDIT, THREAD_STATE + mhdro.ncmds = 6; // __ZERO, __XHDR, __TEXT, UUID, __LINKEDIT, THREAD_STATE mhdro.sizeofcmds = sizeof(segZERO) + sizeof(segXHDR) + sizeof(secXHDR) - + sizeof(segTEXT) + sizeof(secTEXT) + sizeof(segLINK) + - my_thread_command_size /* + sizeof(uuid_cmd) + sizeof(linkitem) */ ; + + sizeof(segTEXT) + sizeof(secTEXT) + + sizeof(cmdUUID) + + sizeof(segLINK) + my_thread_command_size /* + sizeof(linkitem) */ ; mhdro.flags = Mach_header::MH_NOUNDEFS | Mach_header::MH_DYLDLINK; } fo->write(&mhdro, sizeof(mhdro)); @@ -1435,6 +1449,11 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e segZERO.cmdsize = sizeof(segZERO); strncpy((char *)segZERO.segname, "__PAGEZERO", sizeof(segZERO.segname)); segZERO.vmsize = PAGE_SIZE; + if (sizeof(segZERO.vmsize) == 8 + && mhdro.filetype == Mach_header::MH_EXECUTE + && mhdro.cputype == Mach_header::CPU_TYPE_X86_64) { + segZERO.vmsize <<= 20; // (1ul<<32) + } segTEXT.cmd = lc_seg; segTEXT.cmdsize = sizeof(segTEXT) + sizeof(secTEXT); @@ -1453,10 +1472,13 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e segTEXT.vmsize = 0; // adjust later segTEXT.fileoff = 0; segTEXT.filesize = 0; // adjust later - segTEXT.initprot = segTEXT.maxprot = + segTEXT.maxprot = Mach_segment_command::VM_PROT_READ | Mach_segment_command::VM_PROT_WRITE | Mach_segment_command::VM_PROT_EXECUTE; + segTEXT.initprot = + Mach_segment_command::VM_PROT_READ | + Mach_segment_command::VM_PROT_EXECUTE; segTEXT.nsects = 1; // secTEXT segTEXT.flags = 0; @@ -1464,9 +1486,12 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e strncpy((char *)secTEXT.sectname, "__text", sizeof(secTEXT.sectname)); memcpy(secTEXT.segname, segTEXT.segname, sizeof(secTEXT.segname)); secTEXT.align = 2; // (1<<2) ==> 4 + secTEXT.flags = Mach_section_command::S_REGULAR + | Mach_section_command::S_ATTR_SOME_INSTRUCTIONS + | Mach_section_command::S_ATTR_PURE_INSTRUCTIONS; segXHDR = segTEXT; - segXHDR.vmaddr = PAGE_SIZE; + segXHDR.vmaddr = segZERO.vmsize; segXHDR.vmsize = PAGE_SIZE; segXHDR.filesize = PAGE_SIZE; strncpy((char *)segXHDR.segname, "__XHDR", sizeof(segXHDR.segname)); @@ -1474,7 +1499,7 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e memset(&secXHDR, 0, sizeof(secXHDR)); strncpy((char *)secXHDR.sectname, "__xhdr", sizeof(secXHDR.sectname)); memcpy(secXHDR.segname, segXHDR.segname, sizeof(secXHDR.segname)); - secXHDR.addr = PAGE_SIZE; + secXHDR.addr = segXHDR.vmaddr; secXHDR.size = 0; // empty so far secXHDR.align = 2; // (1<<2) ==> 4 @@ -1491,10 +1516,9 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e fo->write(&secXHDR, sizeof(secXHDR)); fo->write(&segTEXT, sizeof(segTEXT)); fo->write(&secTEXT, sizeof(secTEXT)); + fo->write(&cmdUUID, sizeof(cmdUUID)); fo->write(&segLINK, sizeof(segLINK)); pack1_setup_threado(fo); - memset(&uuid_cmd, 0, sizeof(uuid_cmd)); - fo->write(&uuid_cmd, sizeof(uuid_cmd)); memset(&linkitem, 0, sizeof(linkitem)); fo->write(&linkitem, sizeof(linkitem)); } @@ -1666,6 +1690,24 @@ bool PackMachBase::canPack() unsigned char const *ptr = (unsigned char const *)rawmseg; for (unsigned j= 0; j < ncmds; ++j) { msegcmd[j] = *(Mach_segment_command const *)ptr; + switch (((Mach_uuid_command const *)ptr)->cmd) { + default: break; + case Mach_segment_command::LC_UUID: { + memcpy(&cmdUUID, ptr, sizeof(cmdUUID)); // remember the UUID + // Set output UUID to be 1 more than the input UUID. + for (unsigned k = 0; k < sizeof(cmdUUID.uuid); ++k) { + if (0 != ++cmdUUID.uuid[k]) { // no Carry + break; + } + } + } break; + case Mach_segment_command::LC_VERSION_MIN_MACOSX: { + memcpy(&cmdVERMIN, ptr, sizeof(cmdVERMIN)); + } break; + case Mach_segment_command::LC_SOURCE_VERSION: { + memcpy(&cmdSRCVER, ptr, sizeof(cmdSRCVER)); + } break; + } if (((Mach_segment_command const *)ptr)->cmd == lc_rout) { o_routines_cmd = (const char *)ptr - (const char *)rawmseg; prev_init_address = diff --git a/src/p_mach.h b/src/p_mach.h index d56c96e0..350c03c0 100644 --- a/src/p_mach.h +++ b/src/p_mach.h @@ -283,11 +283,79 @@ template __packed_struct(Mach_uuid_command) typedef typename TMachITypes::Word Word; - Word cmd; - Word cmdsize; + Word cmd; // LC_UUID + Word cmdsize; // 24 unsigned char uuid[16]; __packed_struct_end() +typedef struct { + uint32_t cmd; // LC_MAIN; MH_EXECUTE only + uint32_t cmdsize; // 24 + uint64_t entryoff; // file offset of main() [expected in __TEXT] + uint64_t stacksize; // non-default initial stack size +} Mach_main_command; + +typedef struct { + uint32_t cmd; // LC_SOURCE_VERSION + uint32_t cmdsize; // 16 + uint32_t long version; +} Mach_source_version_command; + +typedef struct { + uint32_t cmd; // LC_VERSION_MIN_MACOSX + uint32_t cmdsize; // 16 + uint32_t version; // X.Y.Z ==> xxxx.yy.zz + uint32_t sdk; // X.Y.Z ==> xxxx.yy.zz +} Mach_version_min_command; + +typedef struct { + uint32_t cmd; // LC_DYLD_INFO_ONLY + uint32_t cmdsize; // 48 + uint32_t rebase_off; + uint32_t rebase_size; + uint32_t bind_off; + uint32_t bind_size; + uint32_t weak_bind_off; + uint32_t weak_bind_size; + uint32_t lazy_bind_off; + uint32_t lazy_bind_size; + uint32_t export_off; + uint32_t export_size; +} Mach_dyld_info_only_command; + +typedef struct { + uint32_t cmd; + uint32_t cmdsize; + uint32_t name; +} Mach_load_dylinker_command; + +typedef struct { + uint32_t name; /* library's path name */ + uint32_t timestamp; /* library's build time stamp */ + uint32_t current_version; /* library's current version number */ + uint32_t compatibility_version; /* library's compatibility vers number*/ +} Mach_dylib; + +typedef struct { + uint32_t cmd; + uint32_t cmdsize; + Mach_dylib dylib; +} Mach_load_dylib_command; + +typedef struct { + uint32_t cmd; + uint32_t cmdsize; + uint32_t dataoff; + uint32_t datasize; +} Mach_function_starts_command; + +typedef struct { + uint32_t cmd; + uint32_t cmdsize; + uint32_t dataoff; + uint32_t datasize; +} Mach_data_in_code_command; + template __packed_struct(Mach_ppc_thread_state) typedef typename TMachITypes::Addr Addr; @@ -650,7 +718,9 @@ protected: Mach_section_command secTEXT; Mach_segment_command segLINK; Mach_linkedit_data_command linkitem; - Mach_uuid_command uuid_cmd; + Mach_uuid_command cmdUUID; // copied from input, then incremented + N_Mach::Mach_source_version_command cmdSRCVER; // copied from input + N_Mach::Mach_version_min_command cmdVERMIN; // copied from input __packed_struct(b_info) // 12-byte header before each compressed block TE32 sz_unc; // uncompressed_size diff --git a/src/p_mach_enum.h b/src/p_mach_enum.h index 95e1bfac..4c3577f8 100644 --- a/src/p_mach_enum.h +++ b/src/p_mach_enum.h @@ -58,13 +58,16 @@ }; enum { // flags MH_NOUNDEFS = 1, - MH_DYLDLINK = 4 /* code signing demands this */ + MH_DYLDLINK = 4, /* code signing demands this */ + MH_TWOLEVEL = 0x80, + MH_PIE = 0x200000 }; #endif /*}*/ #ifdef WANT_MACH_SEGMENT_ENUM /*{*/ #undef WANT_MACH_SEGMENT_ENUM enum { // cmd + LC_REQ_DYLD = 0x80000000, // OR'ed ==> must not ignore LC_SEGMENT = 0x1, LC_SYMTAB = 0x2, LC_THREAD = 0x4, @@ -85,10 +88,12 @@ LC_LAZY_LOAD_DYLIB= 0x20, LC_ENCRYPTION_INFO= 0x21, LC_DYLD_INFO = 0x22, // compressed dyld information (10.6.x) + LC_DYLD_INFO_ONLY = (0x22|LC_REQ_DYLD), LC_VERSION_MIN_MACOSX= 0x24, LC_FUNCTION_STARTS= 0x26, + LC_MAIN = (0x28|LC_REQ_DYLD), LC_DATA_IN_CODE = 0x29, - LC_REQ_DYLD = 0x80000000 // OR'ed ==> must not ignore + LC_SOURCE_VERSION = 0x2a, }; enum { // maxprot VM_PROT_READ = 1, From 98b428a8bef03b4cfa9a630e10525d511cabf4d5 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Mon, 5 Sep 2016 20:32:52 -0700 Subject: [PATCH 02/29] Fix compiler warning --- src/stub/src/amd64-darwin.macho-main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/stub/src/amd64-darwin.macho-main.c b/src/stub/src/amd64-darwin.macho-main.c index 00121080..663aaded 100644 --- a/src/stub/src/amd64-darwin.macho-main.c +++ b/src/stub/src/amd64-darwin.macho-main.c @@ -538,7 +538,7 @@ ERR_LAB else if (xi) { // cleanup if decompressor overrun crosses page boundary mlen = ~PAGE_MASK & (3+ mlen); if (mlen<=3) { // page fragment was overrun buffer only - munmap(addr, mlen); + munmap((char *)addr, mlen); } } } From 1197beaa13a7c0e0dcc12585bf66e511e87a67cc Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Mon, 5 Sep 2016 20:36:07 -0700 Subject: [PATCH 03/29] ElfLinker::init() zero length implies 0x4000 blank bytes --- src/linker.cpp | 26 ++++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/src/linker.cpp b/src/linker.cpp index 4da776f5..9160d7fb 100644 --- a/src/linker.cpp +++ b/src/linker.cpp @@ -184,23 +184,25 @@ void ElfLinker::init(const void *pdata_v, int plen) } input[inputlen] = 0; // NUL terminate - output = new upx_byte[inputlen]; + output = new upx_byte[inputlen ? inputlen : 0x4000]; outputlen = 0; - int pos = find(input, inputlen, "Sections:\n", 10); - assert(pos != -1); - char *psections = (char *) input + pos; + if ((int)strlen("Sections:\n" "SYMBOL TABLE:\n" "RELOCATION RECORDS FOR ") < inputlen) { + int pos = find(input, inputlen, "Sections:\n", 10); + assert(pos != -1); + char *psections = (char *) input + pos; - char *psymbols = strstr(psections, "SYMBOL TABLE:\n"); - assert(psymbols != NULL); + char *psymbols = strstr(psections, "SYMBOL TABLE:\n"); + assert(psymbols != NULL); - char *prelocs = strstr(psymbols, "RELOCATION RECORDS FOR "); - assert(prelocs != NULL); + char *prelocs = strstr(psymbols, "RELOCATION RECORDS FOR "); + assert(prelocs != NULL); - preprocessSections(psections, psymbols); - preprocessSymbols(psymbols, prelocs); - preprocessRelocations(prelocs, (char*) input + inputlen); - addLoader("*UND*"); + preprocessSections(psections, psymbols); + preprocessSymbols(psymbols, prelocs); + preprocessRelocations(prelocs, (char*) input + inputlen); + addLoader("*UND*"); + } } void ElfLinker::preprocessSections(char *start, char *end) From 16d6124bb4f5ea2189802ce450e29a88aac3141d Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Mon, 5 Sep 2016 20:37:23 -0700 Subject: [PATCH 04/29] amd64-darwin.macho-upxmain for stub on Mac OS X 10.12 "Sierra" --- src/p_mach.cpp | 23 +- src/p_mach_enum.h | 3 +- src/stub/Makefile | 4 + src/stub/amd64-darwin.macho-upxmain.h | 608 ++++++++++++++++++++ src/stub/src/amd64-darwin.macho-upxmain.c | 663 ++++++++++++++++++++++ 5 files changed, 1296 insertions(+), 5 deletions(-) create mode 100644 src/stub/amd64-darwin.macho-upxmain.h create mode 100644 src/stub/src/amd64-darwin.macho-upxmain.c diff --git a/src/p_mach.cpp b/src/p_mach.cpp index 7aa17f6c..aa9dc411 100644 --- a/src/p_mach.cpp +++ b/src/p_mach.cpp @@ -53,6 +53,8 @@ static const #include "stub/arm-darwin.macho-entry.h" static const #include "stub/arm-darwin.macho-fold.h" +static const +#include "stub/amd64-darwin.macho-upxmain.h" static const #include "stub/arm64-darwin.macho-entry.h" @@ -455,9 +457,17 @@ PackMachI386::buildLoader(const Filter *ft) void PackMachAMD64::buildLoader(const Filter *ft) { - buildMachLoader( - stub_amd64_darwin_macho_entry, sizeof(stub_amd64_darwin_macho_entry), - stub_amd64_darwin_macho_fold, sizeof(stub_amd64_darwin_macho_fold), ft ); + if (my_filetype==Mach_header::MH_EXECUTE) { + initLoader(NULL, 0); + linker->addSection("UPXMAIN", stub_amd64_darwin_macho_upxmain_exe, + sizeof(stub_amd64_darwin_macho_upxmain_exe), 0); + addLoader("UPXMAIN", NULL); + } + else { + buildMachLoader( + stub_amd64_darwin_macho_entry, sizeof(stub_amd64_darwin_macho_entry), + stub_amd64_darwin_macho_fold, sizeof(stub_amd64_darwin_macho_fold), ft ); + } } void @@ -1689,7 +1699,12 @@ bool PackMachBase::canPack() msegcmd = new Mach_segment_command[ncmds]; unsigned char const *ptr = (unsigned char const *)rawmseg; for (unsigned j= 0; j < ncmds; ++j) { - msegcmd[j] = *(Mach_segment_command const *)ptr; + if (lc_seg == *(unsigned const *)ptr) { + msegcmd[j] = *(Mach_segment_command const *)ptr; + } + else { + memcpy(&msegcmd[j], ptr, 2*sizeof(unsigned)); // cmd and size + } switch (((Mach_uuid_command const *)ptr)->cmd) { default: break; case Mach_segment_command::LC_UUID: { diff --git a/src/p_mach_enum.h b/src/p_mach_enum.h index 4c3577f8..5107a9c2 100644 --- a/src/p_mach_enum.h +++ b/src/p_mach_enum.h @@ -59,8 +59,9 @@ enum { // flags MH_NOUNDEFS = 1, MH_DYLDLINK = 4, /* code signing demands this */ + MH_BINDATLOAD = 0x8, // DT_BIND_NOW MH_TWOLEVEL = 0x80, - MH_PIE = 0x200000 + MH_PIE = 0x200000 // ASLR }; #endif /*}*/ diff --git a/src/stub/Makefile b/src/stub/Makefile index dc5a528c..ed202544 100644 --- a/src/stub/Makefile +++ b/src/stub/Makefile @@ -51,6 +51,7 @@ ifndef STUBS STUBS += amd64-darwin.dylib-entry.h STUBS += amd64-darwin.macho-entry.h STUBS += amd64-darwin.macho-fold.h +STUBS += amd64-darwin.macho-upxmain.h STUBS += amd64-linux.elf-entry.h STUBS += amd64-linux.elf-fold.h STUBS += amd64-linux.kernel.vmlinux-head.h @@ -313,6 +314,9 @@ amd64-darwin.macho-fold.h : tmp/$$T.o tmp/amd64-darwin.macho-main.o chmod a-x tmp/$T.bin $(call tc,bin2h) tmp/$T.bin $@ +amd64-darwin.macho-upxmain.h: amd64-darwin.macho-upxmain.exe + $(call tc,bin2h) $< $@ + tmp/amd64-darwin.macho-fold.o : $(srcdir)/src/$$T.S $(call tc,gcc) -c $< -o $@ $(call tc,f-objstrip,$@) diff --git a/src/stub/amd64-darwin.macho-upxmain.h b/src/stub/amd64-darwin.macho-upxmain.h new file mode 100644 index 00000000..b84577cd --- /dev/null +++ b/src/stub/amd64-darwin.macho-upxmain.h @@ -0,0 +1,608 @@ +/* amd64-darwin.macho-upxmain.h + created from amd64-darwin.macho-upxmain.exe, 9092 (0x2384) bytes + + This file is part of the UPX executable compressor. + + Copyright (C) 1996-2015 Markus Franz Xaver Johannes Oberhumer + Copyright (C) 1996-2015 Laszlo Molnar + Copyright (C) 2000-2015 John F. Reiser + All Rights Reserved. + + UPX and the UCL library are free software; you can redistribute them + and/or modify them under the terms of the GNU General Public License as + published by the Free Software Foundation; either version 2 of + the License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; see the file COPYING. + If not, write to the Free Software Foundation, Inc., + 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + + Markus F.X.J. Oberhumer Laszlo Molnar + + + John F. Reiser + + */ + + +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_SIZE 9092 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x9ab36775 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0xbd632719 + +unsigned char stub_amd64_darwin_macho_upxmain_exe[9092] = { +/* 0x0000 */ 207,250,237,254, 7, 0, 0, 1, 3, 0, 0,128, 2, 0, 0, 0, +/* 0x0010 */ 15, 0, 0, 0, 0, 5, 0, 0,133, 0, 32, 0, 0, 0, 0, 0, +/* 0x0020 */ 25, 0, 0, 0, 72, 0, 0, 0, 95, 95, 80, 65, 71, 69, 90, 69, +/* 0x0030 */ 82, 79, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0040 */ 0, 0,255,255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0050 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0060 */ 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0,136, 1, 0, 0, +/* 0x0070 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0080 */ 0, 0,255,255, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, +/* 0x0090 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, +/* 0x00a0 */ 7, 0, 0, 0, 5, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, +/* 0x00b0 */ 95, 95,116,101,120,116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x00c0 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x00d0 */ 240, 7,255,255, 0, 0, 0, 0, 19, 7, 0, 0, 0, 0, 0, 0, +/* 0x00e0 */ 240, 7, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x00f0 */ 0, 4, 0,128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0100 */ 95, 95,115,116,117, 98,115, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0110 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0120 */ 4, 15,255,255, 0, 0, 0, 0, 54, 0, 0, 0, 0, 0, 0, 0, +/* 0x0130 */ 4, 15, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0140 */ 8, 4, 0,128, 0, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, +/* 0x0150 */ 95, 95,115,116,117, 98, 95,104,101,108,112,101,114, 0, 0, 0, +/* 0x0160 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0170 */ 60, 15,255,255, 0, 0, 0, 0,106, 0, 0, 0, 0, 0, 0, 0, +/* 0x0180 */ 60, 15, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0190 */ 0, 4, 0,128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x01a0 */ 95, 95,117,110,119,105,110,100, 95,105,110,102,111, 0, 0, 0, +/* 0x01b0 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x01c0 */ 168, 15,255,255, 0, 0, 0, 0, 80, 0, 0, 0, 0, 0, 0, 0, +/* 0x01d0 */ 168, 15, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x01e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x01f0 */ 25, 0, 0, 0,136, 1, 0, 0, 95, 95, 68, 65, 84, 65, 0, 0, +/* 0x0200 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16,255,255, 0, 0, 0, 0, +/* 0x0210 */ 0, 16, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, +/* 0x0220 */ 0, 16, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 3, 0, 0, 0, +/* 0x0230 */ 4, 0, 0, 0, 0, 0, 0, 0, 95, 95,110,108, 95,115,121,109, +/* 0x0240 */ 98,111,108, 95,112,116,114, 0, 95, 95, 68, 65, 84, 65, 0, 0, +/* 0x0250 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16,255,255, 0, 0, 0, 0, +/* 0x0260 */ 16, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 3, 0, 0, 0, +/* 0x0270 */ 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 9, 0, 0, 0, +/* 0x0280 */ 0, 0, 0, 0, 0, 0, 0, 0, 95, 95,103,111,116, 0, 0, 0, +/* 0x0290 */ 0, 0, 0, 0, 0, 0, 0, 0, 95, 95, 68, 65, 84, 65, 0, 0, +/* 0x02a0 */ 0, 0, 0, 0, 0, 0, 0, 0, 16, 16,255,255, 0, 0, 0, 0, +/* 0x02b0 */ 8, 0, 0, 0, 0, 0, 0, 0, 16, 16, 0, 0, 3, 0, 0, 0, +/* 0x02c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 11, 0, 0, 0, +/* 0x02d0 */ 0, 0, 0, 0, 0, 0, 0, 0, 95, 95,108, 97, 95,115,121,109, +/* 0x02e0 */ 98,111,108, 95,112,116,114, 0, 95, 95, 68, 65, 84, 65, 0, 0, +/* 0x02f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 24, 16,255,255, 0, 0, 0, 0, +/* 0x0300 */ 72, 0, 0, 0, 0, 0, 0, 0, 24, 16, 0, 0, 3, 0, 0, 0, +/* 0x0310 */ 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 0, 0, 0, +/* 0x0320 */ 0, 0, 0, 0, 0, 0, 0, 0, 95, 95, 99,111,109,109,111,110, +/* 0x0330 */ 0, 0, 0, 0, 0, 0, 0, 0, 95, 95, 68, 65, 84, 65, 0, 0, +/* 0x0340 */ 0, 0, 0, 0, 0, 0, 0, 0, 96, 16,255,255, 0, 0, 0, 0, +/* 0x0350 */ 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, +/* 0x0360 */ 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, +/* 0x0370 */ 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0, 72, 0, 0, 0, +/* 0x0380 */ 95, 95, 76, 73, 78, 75, 69, 68, 73, 84, 0, 0, 0, 0, 0, 0, +/* 0x0390 */ 0, 32,255,255, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, +/* 0x03a0 */ 0, 32, 0, 0, 0, 0, 0, 0,132, 3, 0, 0, 0, 0, 0, 0, +/* 0x03b0 */ 7, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x03c0 */ 34, 0, 0,128, 48, 0, 0, 0, 0, 32, 0, 0, 8, 0, 0, 0, +/* 0x03d0 */ 8, 32, 0, 0, 56, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x03e0 */ 64, 32, 0, 0,136, 0, 0, 0,200, 32, 0, 0, 96, 0, 0, 0, +/* 0x03f0 */ 2, 0, 0, 0, 24, 0, 0, 0, 56, 33, 0, 0, 19, 0, 0, 0, +/* 0x0400 */ 188, 34, 0, 0,200, 0, 0, 0, 11, 0, 0, 0, 80, 0, 0, 0, +/* 0x0410 */ 0, 0, 0, 0, 2, 0, 0, 0, 2, 0, 0, 0, 6, 0, 0, 0, +/* 0x0420 */ 8, 0, 0, 0, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0430 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0440 */ 104, 34, 0, 0, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0450 */ 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 32, 0, 0, 0, +/* 0x0460 */ 12, 0, 0, 0, 47,117,115,114, 47,108,105, 98, 47,100,121,108, +/* 0x0470 */ 100, 0, 0, 0, 0, 0, 0, 0, 27, 0, 0, 0, 24, 0, 0, 0, +/* 0x0480 */ 23, 55,189, 7,110,207, 57, 27,146, 38,212,221,128, 33, 19, 11, +/* 0x0490 */ 36, 0, 0, 0, 16, 0, 0, 0, 0, 12, 10, 0, 0, 12, 10, 0, +/* 0x04a0 */ 42, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x04b0 */ 40, 0, 0,128, 24, 0, 0, 0,128, 14, 0, 0, 0, 0, 0, 0, +/* 0x04c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 56, 0, 0, 0, +/* 0x04d0 */ 24, 0, 0, 0, 2, 0, 0, 0, 0, 0,214, 4, 0, 0, 1, 0, +/* 0x04e0 */ 47,117,115,114, 47,108,105, 98, 47,108,105, 98, 83,121,115,116, +/* 0x04f0 */ 101,109, 46, 66, 46,100,121,108,105, 98, 0, 0, 0, 0, 0, 0, +/* 0x0500 */ 38, 0, 0, 0, 16, 0, 0, 0, 40, 33, 0, 0, 16, 0, 0, 0, +/* 0x0510 */ 41, 0, 0, 0, 16, 0, 0, 0, 56, 33, 0, 0, 0, 0, 0, 0, +/* 0x0520 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0530 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0540 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0550 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0560 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0570 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0580 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0590 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x05a0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x05b0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x05c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x05d0 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85, 65, 84, 83, 72,131,236, +/* 0x0800 */ 72, 77,137,204, 76,137,195, 72,137, 77,152, 73,137,213, 76,139, +/* 0x0810 */ 125, 16, 72,137,117,208, 72,141, 71, 24, 72,137, 69,200, 72,139, +/* 0x0820 */ 69,208, 72,131,192,232, 72,137, 69,192, 76,137,109,184,139, 71, +/* 0x0830 */ 24, 72,137, 69,176, 72,139, 69,192, 72,139, 77,200, 72,137, 77, +/* 0x0840 */ 168, 72,137, 69,160, 69, 49,246, 72,141,125,192, 72,141,117,176, +/* 0x0850 */ 49,201, 72,137,218,232, 38, 1, 0, 0, 76,137, 36, 36, 72,141, +/* 0x0860 */ 85,160,190, 0, 0, 0, 0,185,255,255,255,255, 76,137,239, 77, +/* 0x0870 */ 137,248, 73,137,217,232,198, 3, 0, 0, 72,137,195, 65,139, 77, +/* 0x0880 */ 16,133,201, 15,132,228, 0, 0, 0, 73,141, 69, 32, 15, 31, 0, +/* 0x0890 */ 131, 56, 14,116, 19, 65,255,198,139, 80, 4, 72, 1,208, 65, 57, +/* 0x08a0 */ 206,114,237,233,197, 0, 0, 0,139,120, 8, 72, 1,199, 49,246, +/* 0x08b0 */ 49,210,232,119, 6, 0, 0, 65,137,199, 69,133,255, 72,139, 93, +/* 0x08c0 */ 152,120,119, 69, 49,228, 49,201, 68,137,255, 76,137,238, 72,137, +/* 0x08d0 */ 218,232, 94, 6, 0, 0, 72, 57,216,117, 95, 77,141,117, 8, 65, +/* 0x08e0 */ 139, 69, 0, 61,190,186,254,202,116, 7, 61,202,254,186,190,117, +/* 0x08f0 */ 83, 65,139, 69, 4, 49,201,133,192, 76,137,242,116, 70,102,144, +/* 0x0900 */ 129, 58, 7, 0, 0, 1,116, 24,255,193, 72,131,194, 20, 57,193, +/* 0x0910 */ 114,238,235, 48,102,102,102, 46, 15, 31,132, 0, 0, 0, 0, 0, +/* 0x0920 */ 68,139, 98, 8, 68,137,255, 76,137,238, 72,137,218, 68,137,225, +/* 0x0930 */ 232,255, 5, 0, 0, 72, 57,216,116,165,191,127, 0, 0, 0,232, +/* 0x0940 */ 210, 5, 0, 0, 72,199, 4, 36, 0, 0, 0, 0, 49,210, 69, 49, +/* 0x0950 */ 192, 69, 49,201, 76,137,239, 68,137,230, 68,137,249,232,222, 2, +/* 0x0960 */ 0, 0, 72,137,195, 68,137,255,232,163, 5, 0, 0, 72,137,216, +/* 0x0970 */ 72,131,196, 72, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195,144, +/* 0x0980 */ 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, +/* 0x0990 */ 40, 72,137, 77,184, 72,137, 85,176, 73,137,244, 73,137,255, 73, +/* 0x09a0 */ 131, 60, 36, 0, 15,132,103, 2, 0, 0,102, 15, 31, 68, 0, 0, +/* 0x09b0 */ 73,139, 7, 72,131,248, 11, 15,134,109, 2, 0, 0, 73,139, 87, +/* 0x09c0 */ 8,138, 10,136, 77,200,138, 74, 1,136, 77,201,138, 74, 2,136, +/* 0x09d0 */ 77,202,138, 74, 3,136, 77,203,138, 74, 4,136, 77,204,138, 74, +/* 0x09e0 */ 5,136, 77,205,138, 74, 6,136, 77,206,138, 74, 7,136, 77,207, +/* 0x09f0 */ 138, 74, 8,136, 77,208,138, 74, 9,136, 77,209,138, 74, 10,136, +/* 0x0a00 */ 77,210,138, 74, 11,136, 77,211, 72,141,122, 12, 73,137,127, 8, +/* 0x0a10 */ 72,131,192,244, 73,137, 7, 68,139,117,200, 68,139,109,204, 77, +/* 0x0a20 */ 133,246, 15,132,219, 1, 0, 0, 65,141, 77,255, 68, 57,241, 15, +/* 0x0a30 */ 131,235, 1, 0, 0, 77, 59, 52, 36, 15,135,225, 1, 0, 0, 69, +/* 0x0a40 */ 57,245,115, 92, 68,137,117,196, 73,139, 84, 36, 8,139, 93,208, +/* 0x0a50 */ 68, 15,182,195, 68,137,238, 72,141, 77,196,255, 85,176,133,192, +/* 0x0a60 */ 15,133,186, 1, 0, 0, 68, 57,117,196, 15,133,176, 1, 0, 0, +/* 0x0a70 */ 72,131,125,184, 0,116, 28, 15,182,199,102,133,192,116, 20,193, +/* 0x0a80 */ 235, 16, 15,183,200, 73,139,124, 36, 8, 15,182,211, 68,137,246, +/* 0x0a90 */ 255, 85,184, 77, 1,111, 8, 77, 41, 47,233, 73, 1, 0, 0,144, +/* 0x0aa0 */ 76, 57,232, 15,130,129, 1, 0, 0, 69,133,237, 15,132, 41, 1, +/* 0x0ab0 */ 0, 0, 73,139,116, 36, 8, 65,131,253, 32,114, 51, 69,137,232, +/* 0x0ac0 */ 65,131,224, 31, 69, 57,197,116, 39, 74,141, 68, 42, 11, 72, 57, +/* 0x0ad0 */ 198, 15,135,151, 0, 0, 0, 74,141, 68, 46,255, 72, 57,199, 15, +/* 0x0ae0 */ 135,137, 0, 0, 0,102,102, 46, 15, 31,132, 0, 0, 0, 0, 0, +/* 0x0af0 */ 76,137,232, 72,137,241, 72,141, 80,255,168, 7,116, 36,137,198, +/* 0x0b00 */ 131,230, 7, 72,247,222,102, 46, 15, 31,132, 0, 0, 0, 0, 0, +/* 0x0b10 */ 72,255,200,138, 31,136, 25, 72,255,199, 72,255,193, 72,255,198, +/* 0x0b20 */ 117,238, 72,131,250, 7, 15,130,164, 0, 0, 0, 15, 31, 64, 0, +/* 0x0b30 */ 138, 23,136, 17,138, 87, 1,136, 81, 1,138, 87, 2,136, 81, 2, +/* 0x0b40 */ 138, 87, 3,136, 81, 3,138, 87, 4,136, 81, 4,138, 87, 5,136, +/* 0x0b50 */ 81, 5,138, 87, 6,136, 81, 6, 72,131,192,248,138, 87, 7, 72, +/* 0x0b60 */ 141,127, 8,136, 81, 7, 72,141, 73, 8,117,196,235, 98, 76,137, +/* 0x0b70 */ 235, 76, 41,195, 76,137,232, 72, 41,216, 72,141, 12, 30, 72, 1, +/* 0x0b80 */ 223, 72,131,194, 28, 72,131,198, 16, 69,137,233, 65,131,225, 31, +/* 0x0b90 */ 76,137,235, 76, 41,203,102, 46, 15, 31,132, 0, 0, 0, 0, 0, +/* 0x0ba0 */ 15, 16, 66,240, 15, 16, 10, 15, 17, 70,240, 15, 17, 14, 72,131, +/* 0x0bb0 */ 194, 32, 72,131,198, 32, 72,131,195,224,117,228, 69,133,192, 15, +/* 0x0bc0 */ 133, 49,255,255,255,102,102, 46, 15, 31,132, 0, 0, 0, 0, 0, +/* 0x0bd0 */ 73,139, 7, 73,139,127, 8, 68,139,117,200, 76, 1,239, 73,137, +/* 0x0be0 */ 127, 8, 76, 41,232, 73,137, 7, 68,137,240, 73, 1, 68, 36, 8, +/* 0x0bf0 */ 73,139, 12, 36, 72, 41,193, 73,137, 12, 36, 15,133,175,253,255, +/* 0x0c00 */ 255,235, 14, 72,133,192,117, 24, 65,129,253, 85, 80, 88, 33,117, +/* 0x0c10 */ 15, 72,131,196, 40, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195, +/* 0x0c20 */ 191,127, 0, 0, 0,232,236, 2, 0, 0,191,127, 0, 0, 0,232, +/* 0x0c30 */ 226, 2, 0, 0,102,102,102, 46, 15, 31,132, 0, 0, 0, 0, 0, +/* 0x0c40 */ 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, +/* 0x0c50 */ 104, 76,137, 77,128, 76,137,133,120,255,255,255,137, 77,156, 72, +/* 0x0c60 */ 137, 85,192, 72,137,125,168,139, 71, 16, 49,219,133,192,185, 0, +/* 0x0c70 */ 0, 0, 0, 72,137, 77,160, 15,132,221, 1, 0, 0, 72,139, 77, +/* 0x0c80 */ 168, 76,141,113, 32, 72,131,125,192, 0, 15,149,193, 15,182,201, +/* 0x0c90 */ 72,141, 12, 73, 72,137, 77,144,137,241, 72,137, 77,136, 49,201, +/* 0x0ca0 */ 72,137, 77,160,102,102,102, 46, 15, 31,132, 0, 0, 0, 0, 0, +/* 0x0cb0 */ 73,139, 22, 72,137,209, 72,193,233, 32,131,250, 25, 15,133, 45, +/* 0x0cc0 */ 1, 0, 0, 73,139, 86, 32, 72,133,210, 15,132,123, 1, 0, 0, +/* 0x0cd0 */ 72,137, 85,176, 73,139, 70, 48, 72,137, 69,200, 77,139,126, 24, +/* 0x0ce0 */ 76,137,125,184, 76,137,125,208, 69,137,252, 65,129,228,255, 15, +/* 0x0cf0 */ 0, 0, 77, 41,231, 73, 1,196,116, 76, 72,139, 77,144, 73,141, +/* 0x0d00 */ 52, 12, 72,133,192,185, 18, 0, 0, 0,186, 18, 16, 0, 0, 15, +/* 0x0d10 */ 68,202, 72,131,125,192, 0, 15, 69,202, 72,131,248, 1, 69, 25, +/* 0x0d20 */ 192, 68, 11, 69,156, 69,139, 78, 40, 72,139, 69,136, 65, 1,193, +/* 0x0d30 */ 186, 3, 0, 0, 0, 76,137,255,232,223, 1, 0, 0, 73, 57,199, +/* 0x0d40 */ 15,133, 39, 1, 0, 0, 72,131,125,192, 0,116, 45, 73,131,126, +/* 0x0d50 */ 48, 0,116, 38, 73,131,126, 40, 0,117, 10, 72,139,133,120,255, +/* 0x0d60 */ 255,255, 76,137, 56, 72,139,125,192, 72,141,117,200, 72,139, 85, +/* 0x0d70 */ 128, 72,139, 77, 16,232, 6,252,255,255, 69,137,229, 65,247,221, +/* 0x0d80 */ 73,129,229,255, 15, 0, 0,116, 12, 75,141, 60, 39, 76,137,238, +/* 0x0d90 */ 232,111, 1, 0, 0, 77,133,228,116, 23, 65,139, 86, 60, 76,137, +/* 0x0da0 */ 255, 76,137,230,232,121, 1, 0, 0,133,192, 15,133,188, 0, 0, +/* 0x0db0 */ 0, 72,139, 69,184, 72, 3, 69,176, 77, 1,229, 77, 1,239, 73, +/* 0x0dc0 */ 57,199,115, 78, 77,133,255,116,119, 72,137,198, 76, 41,254, 65, +/* 0x0dd0 */ 139, 86, 60,185, 18, 16, 0, 0, 65,184,255,255,255,255, 69, 49, +/* 0x0de0 */ 201, 76,137,255,232, 51, 1, 0, 0, 73, 57,199,116, 82,235,125, +/* 0x0df0 */ 131,226,254,131,250, 4,117, 83, 72,186, 4, 0, 0, 0, 42, 0, +/* 0x0e00 */ 0, 0, 73, 57, 86, 8,117, 67, 73,141, 86, 16, 72,137, 85,160, +/* 0x0e10 */ 235, 57, 72,131,125,192, 0,116, 39, 65,131,196, 3, 65,129,228, +/* 0x0e20 */ 255, 15, 0, 0, 73,131,252, 3,119, 22, 76,137,255, 76,137,230, +/* 0x0e30 */ 232,243, 0, 0, 0,102,102, 46, 15, 31,132, 0, 0, 0, 0, 0, +/* 0x0e40 */ 65,139, 78, 4, 72,139, 69,168,139, 64, 16,255,195,137,201, 73, +/* 0x0e50 */ 1,206, 57,195, 15,130, 86,254,255,255, 72,139, 69,160, 72,131, +/* 0x0e60 */ 196,104, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195,191,127, 0, +/* 0x0e70 */ 0, 0,232,159, 0, 0, 0,102, 15, 31,132, 0, 0, 0, 0, 0, +/* 0x0e80 */ 85, 72,137,229, 65, 86, 83, 72,129,236, 32, 8, 0, 0, 76,139, +/* 0x0e90 */ 53,123, 1, 0, 0, 77,139, 54, 76,137,117,232,191,248,255,254, +/* 0x0ea0 */ 255, 72,139, 55, 72,131,199, 8, 72, 41,247, 72,141, 5,174, 1, +/* 0x0eb0 */ 0, 0, 76,139, 0, 72,141, 5,172, 1, 0, 0, 76,139, 8, 72, +/* 0x0ec0 */ 141,157,216,247,255,255, 72,137, 28, 36, 72,141,149,224,247,255, +/* 0x0ed0 */ 255,185, 0, 8, 0, 0,232, 21,249,255,255, 72,141, 13,142, 1, +/* 0x0ee0 */ 0, 0, 72,137,199, 72,137,222,255, 17, 76, 59,117,232,117, 14, +/* 0x0ef0 */ 49,192, 72,129,196, 32, 8, 0, 0, 91, 65, 94, 93,195,232, 7, +/* 0x0f00 */ 0, 0, 0,144,255, 37, 14, 1, 0, 0,255, 37, 16, 1, 0, 0, +/* 0x0f10 */ 255, 37, 18, 1, 0, 0,255, 37, 20, 1, 0, 0,255, 37, 22, 1, +/* 0x0f20 */ 0, 0,255, 37, 24, 1, 0, 0,255, 37, 26, 1, 0, 0,255, 37, +/* 0x0f30 */ 28, 1, 0, 0,255, 37, 30, 1, 0, 0, 0, 0, 76,141, 29,197, +/* 0x0f40 */ 0, 0, 0, 65, 83,255, 37,181, 0, 0, 0,144,104, 0, 0, 0, +/* 0x0f50 */ 0,233,230,255,255,255,104, 15, 0, 0, 0,233,220,255,255,255, +/* 0x0f60 */ 104, 39, 0, 0, 0,233,210,255,255,255,104, 52, 0, 0, 0,233, +/* 0x0f70 */ 200,255,255,255,104, 64, 0, 0, 0,233,190,255,255,255,104, 76, +/* 0x0f80 */ 0, 0, 0,233,180,255,255,255,104, 92, 0, 0, 0,233,170,255, +/* 0x0f90 */ 255,255,104,106, 0, 0, 0,233,160,255,255,255,104,118, 0, 0, +/* 0x0fa0 */ 0,233,150,255,255,255, 0, 0, 1, 0, 0, 0, 28, 0, 0, 0, +/* 0x0fb0 */ 0, 0, 0, 0, 28, 0, 0, 0, 0, 0, 0, 0, 28, 0, 0, 0, +/* 0x0fc0 */ 2, 0, 0, 0,240, 7, 0, 0, 52, 0, 0, 0, 52, 0, 0, 0, +/* 0x0fd0 */ 4, 15, 0, 0, 0, 0, 0, 0, 52, 0, 0, 0, 3, 0, 0, 0, +/* 0x0fe0 */ 12, 0, 2, 0, 20, 0, 2, 0, 0, 0, 0, 1,144, 6, 0, 0, +/* 0x0ff0 */ 33, 0, 2, 1,209, 88, 5, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x1000 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x1010 */ 0, 0, 0, 0, 0, 0, 0, 0, 76, 15,255,255, 0, 0, 0, 0, +/* 0x1020 */ 86, 15,255,255, 0, 0, 0, 0, 96, 15,255,255, 0, 0, 0, 0, +/* 0x1030 */ 106, 15,255,255, 0, 0, 0, 0,116, 15,255,255, 0, 0, 0, 0, +/* 0x1040 */ 126, 15,255,255, 0, 0, 0, 0,136, 15,255,255, 0, 0, 0, 0, +/* 0x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 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x1f60 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x1f70 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x1f80 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x1f90 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x1fa0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x1fb0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x1fc0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x1fd0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x1fe0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x1ff0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x2000 */ 17, 34, 24, 89, 0, 0, 0, 0, 17, 64, 95, 95, 95,115,116, 97, +/* 0x2010 */ 99,107, 95, 99,104,107, 95,103,117, 97,114,100, 0, 81,114, 16, +/* 0x2020 */ 144, 64,100,121,108,100, 95,115,116,117, 98, 95, 98,105,110,100, +/* 0x2030 */ 101,114, 0,128,232,255,255,255,255,255,255,255,255, 1,144, 0, +/* 0x2040 */ 114, 24, 17, 64, 95, 95, 95, 98,122,101,114,111, 0,144, 0,114, +/* 0x2050 */ 32, 17, 64, 95, 95, 95,115,116, 97, 99,107, 95, 99,104,107, 95, +/* 0x2060 */ 102, 97,105,108, 0,144, 0,114, 40, 17, 64, 95, 99,108,111,115, +/* 0x2070 */ 101, 0,144, 0,114, 48, 17, 64, 95,101,120,105,116, 0,144, 0, +/* 0x2080 */ 114, 56, 17, 64, 95,109,109, 97,112, 0,144, 0,114, 64, 17, 64, +/* 0x2090 */ 95,109,112,114,111,116,101, 99,116, 0,144, 0,114, 72, 17, 64, +/* 0x20a0 */ 95,109,117,110,109, 97,112, 0,144, 0,114, 80, 17, 64, 95,111, +/* 0x20b0 */ 112,101,110, 0,144, 0,114, 88, 17, 64, 95,112,114,101, 97,100, +/* 0x20c0 */ 0,144, 0, 0, 0, 0, 0, 0, 0, 1, 95, 0, 5, 0, 5, 95, +/* 0x20d0 */ 109,104, 95,101,120,101, 99,117,116,101, 95,104,101, 97,100,101, +/* 0x20e0 */ 114, 0, 55,117,112,120, 95,109, 97,105,110, 0, 59,109, 97,105, +/* 0x20f0 */ 110, 0, 64,102, 95, 0, 69,108, 97,117,110, 99,104, 0, 91, 2, +/* 0x2100 */ 0, 0, 0, 3, 0,240, 15, 0, 3, 0,128, 29, 0, 0, 2,101, +/* 0x2110 */ 120,112, 0, 81,117,110,102, 0, 86, 3, 0,224, 32, 0, 3, 0, +/* 0x2120 */ 232, 32, 0, 3, 0,240, 32, 0,240, 15,144, 3,192, 5,192, 4, +/* 0x2130 */ 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 14, 1, 0, 0, +/* 0x2140 */ 128, 9,255,255, 0, 0, 0, 0, 16, 0, 0, 0, 14, 1, 0, 0, +/* 0x2150 */ 64, 12,255,255, 0, 0, 0, 0, 25, 0, 0, 0, 15, 1, 16, 0, +/* 0x2160 */ 0, 0,255,255, 0, 0, 0, 0, 45, 0, 0, 0, 15, 8, 0, 0, +/* 0x2170 */ 96, 16,255,255, 0, 0, 0, 0, 52, 0, 0, 0, 15, 8, 0, 0, +/* 0x2180 */ 104, 16,255,255, 0, 0, 0, 0, 59, 0, 0, 0, 15, 8, 0, 0, +/* 0x2190 */ 112, 16,255,255, 0, 0, 0, 0, 67, 0, 0, 0, 15, 1, 0,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 16, 0, 0, 0, 17, 0, 0, 0, 32, 0, 95,117, +/* 0x22c0 */ 110,112, 97, 99,107, 69,120,116,101,110,116, 0, 95,100,111, 95, +/* 0x22d0 */ 120,109, 97,112, 0, 95, 95,109,104, 95,101,120,101, 99,117,116, +/* 0x22e0 */ 101, 95,104,101, 97,100,101,114, 0, 95,102, 95,101,120,112, 0, +/* 0x22f0 */ 95,102, 95,117,110,102, 0, 95,108, 97,117,110, 99,104, 0, 95, +/* 0x2300 */ 109, 97,105,110, 0, 95,117,112,120, 95,109, 97,105,110, 0, 95, +/* 0x2310 */ 95, 95, 98,122,101,114,111, 0, 95, 95, 95,115,116, 97, 99,107, +/* 0x2320 */ 95, 99,104,107, 95,102, 97,105,108, 0, 95, 95, 95,115,116, 97, +/* 0x2330 */ 99,107, 95, 99,104,107, 95,103,117, 97,114,100, 0, 95, 99,108, +/* 0x2340 */ 111,115,101, 0, 95,101,120,105,116, 0, 95,109,109, 97,112, 0, +/* 0x2350 */ 95,109,112,114,111,116,101, 99,116, 0, 95,109,117,110,109, 97, +/* 0x2360 */ 112, 0, 95,111,112,101,110, 0, 95,112,114,101, 97,100, 0,100, +/* 0x2370 */ 121,108,100, 95,115,116,117, 98, 95, 98,105,110,100,101,114, 0, +/* 0x2380 */ 0, 0, 0, 0 +}; diff --git a/src/stub/src/amd64-darwin.macho-upxmain.c b/src/stub/src/amd64-darwin.macho-upxmain.c new file mode 100644 index 00000000..9b2a5520 --- /dev/null +++ b/src/stub/src/amd64-darwin.macho-upxmain.c @@ -0,0 +1,663 @@ +/* amd64-darwin.macho-upxmain.c -- loader hack for Mach-o AMD64 + + This file is part of the UPX executable compressor. + + Copyright (C) 1996-2015 Markus Franz Xaver Johannes Oberhumer + Copyright (C) 1996-2015 Laszlo Molnar + Copyright (C) 2000-2015 John F. Reiser + All Rights Reserved. + + UPX and the UCL library are free software; you can redistribute them + and/or modify them under the terms of the GNU General Public License as + published by the Free Software Foundation; either version 2 of + the License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; see the file COPYING. + If not, write to the Free Software Foundation, Inc., + 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + + Markus F.X.J. Oberhumer Laszlo Molnar + + + John F. Reiser + + */ + + +#include "include/darwin.h" + +#ifndef DEBUG /*{*/ +#define DEBUG 0 +#endif /*}*/ + +/************************************************************************* +// configuration section +**************************************************************************/ + +// In order to make it much easier to move this code at runtime and execute +// it at an address different from it load address: there must be no +// static data, and no string constants. + +#if !DEBUG /*{*/ +#define DPRINTF(a) /* empty: no debug drivel */ +#define DEBUG_STRCON(name, value) /* empty */ +#else /*}{ DEBUG */ +extern int write(int, void const *, size_t); +#if 0 +#include "stdarg.h" +#else +#define va_arg __builtin_va_arg +#define va_end __builtin_va_end +#define va_list __builtin_va_list +#define va_start __builtin_va_start +#endif + +#if defined(__i386__) || defined(__x86_64__) /*{*/ +#define PIC_STRING(value, var) \ + __asm__ __volatile__ ( \ + "call 0f; .asciz \"" value "\"; \ + 0: pop %0;" : "=r"(var) : \ + ) +#elif defined(__arm__) /*}{*/ +#define PIC_STRING(value, var) \ + __asm__ __volatile__ ( \ + "mov %0,pc; b 0f; \ + .asciz \"" value "\"; .balign 4; \ + 0: " : "=r"(var) \ + ) +#elif defined(__mips__) /*}{*/ +#define PIC_STRING(value, var) \ + __asm__ __volatile__ ( \ + ".set noreorder; bal 0f; move %0,$31; .set reorder; \ + .asciz \"" value "\"; .balign 4; \ + 0: " \ + : "=r"(var) : : "ra" \ + ) +#endif /*}*/ + + +#define DEBUG_STRCON(name, strcon) \ + static char const *name(void) { \ + register char const *rv; PIC_STRING(strcon, rv); \ + return rv; \ + } + + +#ifdef __arm__ /*{*/ +extern unsigned div10(unsigned); +#else /*}{*/ +static unsigned +div10(unsigned x) +{ + return x / 10u; +} +#endif /*}*/ + +static int +unsimal(unsigned x, char *ptr, int n) +{ + if (10<=x) { + unsigned const q = div10(x); + x -= 10 * q; + n = unsimal(q, ptr, n); + } + ptr[n] = '0' + x; + return 1+ n; +} + +static int +decimal(int x, char *ptr, int n) +{ + if (x < 0) { + x = -x; + ptr[n++] = '-'; + } + return unsimal(x, ptr, n); +} + +DEBUG_STRCON(STR_hex, "0123456789abcdef"); + +static int +heximal(unsigned long x, char *ptr, int n) +{ + if (16<=x) { + n = heximal(x>>4, ptr, n); + x &= 0xf; + } + ptr[n] = STR_hex()[x]; + return 1+ n; +} + + +#define DPRINTF(a) dprintf a + +static int +dprintf(char const *fmt, ...) +{ + char c; + int n= 0; + char *ptr; + char buf[20]; + va_list va; va_start(va, fmt); + ptr= &buf[0]; + while (0!=(c= *fmt++)) if ('%'!=c) goto literal; + else switch (c= *fmt++) { + default: { +literal: + n+= write(2, fmt-1, 1); + } break; + case 0: goto done; /* early */ + case 'u': { + n+= write(2, buf, unsimal(va_arg(va, unsigned), buf, 0)); + } break; + case 'd': { + n+= write(2, buf, decimal(va_arg(va, int), buf, 0)); + } break; + case 'p': { + buf[0] = '0'; + buf[1] = 'x'; + n+= write(2, buf, heximal((unsigned long)va_arg(va, void *), buf, 2)); + } break; + case 'x': { + buf[0] = '0'; + buf[1] = 'x'; + n+= write(2, buf, heximal(va_arg(va, int), buf, 2)); + } break; + } +done: + va_end(va); + return n; +} +#endif /*}*/ + + +/************************************************************************* +// "file" util +**************************************************************************/ + +typedef struct { + size_t size; // must be first to match size[0] uncompressed size + void *buf; +} Extent; + +DEBUG_STRCON(STR_xread, "xread %%p(%%x %%p) %%p %%x\\n") +DEBUG_STRCON(STR_xreadfail, "xreadfail %%p(%%x %%p) %%p %%x\\n") + +static void +xread(Extent *x, void *buf, size_t count) +{ + unsigned char *p=x->buf, *q=buf; + size_t j; + DPRINTF((STR_xread(), x, x->size, x->buf, buf, count)); + if (x->size < count) { + DPRINTF((STR_xreadfail(), x, x->size, x->buf, buf, count)); + exit(127); + } + for (j = count; 0!=j--; ++p, ++q) { + *q = *p; + } + x->buf += count; + x->size -= count; +} + + +/************************************************************************* +// util +**************************************************************************/ + +#if 1 //{ save space +#define ERR_LAB error: exit(127); +#define err_exit(a) goto error +#else //}{ save debugging time +#define ERR_LAB /*empty*/ +DEBUG_STRCON(STR_exit, "err_exit %%x\\n"); + +static void +err_exit(int a) +{ + DPRINTF((STR_exit(), a)); + (void)a; // debugging convenience + exit(127); +} +#endif //} + + +/************************************************************************* +// UPX & NRV stuff +**************************************************************************/ + +struct l_info { // 12-byte trailer for loader (after macho headers) + unsigned l_checksum; + unsigned l_magic; // UPX_MAGIC_LE32 + unsigned short l_lsize; + unsigned char l_version; + unsigned char l_format; +}; +struct p_info { // 12-byte packed program header + unsigned p_progid; + unsigned p_filesize; + unsigned p_blocksize; +}; + +struct b_info { // 12-byte header before each compressed block + unsigned sz_unc; // uncompressed_size + unsigned sz_cpr; // compressed_size + unsigned char b_method; // compression algorithm + unsigned char b_ftid; // filter id + unsigned char b_cto8; // filter parameter + unsigned char b_unused; +}; + +typedef void f_unfilter( + nrv_byte *, // also addvalue + nrv_uint, + unsigned cto8, // junk in high 24 bits + unsigned ftid +); +typedef int f_expand( + const nrv_byte *, nrv_uint, + nrv_byte *, nrv_uint *, unsigned ); + +DEBUG_STRCON(STR_unpackExtent, + "unpackExtent in=%%p(%%x %%p) out=%%p(%%x %%p) %%p %%p\\n"); +DEBUG_STRCON(STR_err5, "sz_cpr=%%x sz_unc=%%x xo->size=%%x\\n"); + +static void +unpackExtent( + Extent *const xi, // input + Extent *const xo, // output + f_expand *const f_decompress, + f_unfilter *f_unf +) +{ + DPRINTF((STR_unpackExtent(), + xi, xi->size, xi->buf, xo, xo->size, xo->buf, f_decompress, f_unf)); + while (xo->size) { + struct b_info h; + // Note: if h.sz_unc == h.sz_cpr then the block was not + // compressible and is stored in its uncompressed form. + + // Read and check block sizes. + xread(xi, (unsigned char *)&h, sizeof(h)); + if (h.sz_unc == 0) { // uncompressed size 0 -> EOF + if (h.sz_cpr != UPX_MAGIC_LE32) // h.sz_cpr must be h->magic + err_exit(2); + if (xi->size != 0) // all bytes must be written + err_exit(3); + break; + } + if (h.sz_cpr <= 0) { + err_exit(4); +ERR_LAB + } + if (h.sz_cpr > h.sz_unc + || h.sz_unc > xo->size ) { + DPRINTF((STR_err5(), h.sz_cpr, h.sz_unc, xo->size)); + err_exit(5); + } + // Now we have: + // assert(h.sz_cpr <= h.sz_unc); + // assert(h.sz_unc > 0 && h.sz_unc <= blocksize); + // assert(h.sz_cpr > 0 && h.sz_cpr <= blocksize); + + if (h.sz_cpr < h.sz_unc) { // Decompress block + nrv_uint out_len = h.sz_unc; // EOF for lzma + int const j = (*f_decompress)(xi->buf, h.sz_cpr, + xo->buf, &out_len, h.b_method); + if (j != 0 || out_len != (nrv_uint)h.sz_unc) + err_exit(7); + if (h.b_ftid!=0 && f_unf) { // have filter + (*f_unf)(xo->buf, out_len, h.b_cto8, h.b_ftid); + } + xi->buf += h.sz_cpr; + xi->size -= h.sz_cpr; + } + else { // copy literal block + xread(xi, xo->buf, h.sz_cpr); + } + xo->buf += h.sz_unc; + xo->size -= h.sz_unc; + } +} + +static void +upx_bzero(unsigned char *p, size_t len) +{ + if (len) do { + *p++= 0; + } while (--len); +} +#define bzero upx_bzero + + +// The PF_* and PROT_* bits are {1,2,4}; the conversion table fits in 32 bits. +#define REP8(x) \ + ((x)|((x)<<4)|((x)<<8)|((x)<<12)|((x)<<16)|((x)<<20)|((x)<<24)|((x)<<28)) +#define EXP8(y) \ + ((1&(y)) ? 0xf0f0f0f0 : (2&(y)) ? 0xff00ff00 : (4&(y)) ? 0xffff0000 : 0) +#define PF_TO_PROT(pf) \ + ((PROT_READ|PROT_WRITE|PROT_EXEC) & ( \ + ( (REP8(PROT_EXEC ) & EXP8(PF_X)) \ + |(REP8(PROT_READ ) & EXP8(PF_R)) \ + |(REP8(PROT_WRITE) & EXP8(PF_W)) \ + ) >> ((pf & (PF_R|PF_W|PF_X))<<2) )) + +typedef struct { + unsigned magic; + unsigned nfat_arch; +} Fat_header; +typedef struct { + unsigned cputype; + unsigned cpusubtype; + unsigned offset; + unsigned size; + unsigned align; /* shift count (log base 2) */ +} Fat_arch; + enum e8 { + FAT_MAGIC = 0xcafebabe, + FAT_CIGAM = 0xbebafeca + }; + enum e9 { + CPU_TYPE_I386 = 7, + CPU_TYPE_AMD64 = 0x01000007, + CPU_TYPE_ARM = 12, + CPU_TYPE_POWERPC = 0x00000012, + CPU_TYPE_POWERPC64 = 0x01000012 + }; + +typedef struct { + unsigned magic; + unsigned cputype; + unsigned cpysubtype; + unsigned filetype; + unsigned ncmds; + unsigned sizeofcmds; + unsigned flags; + unsigned reserved; +} Mach_header64; + enum e0 { + MH_MAGIC = 0xfeedface, + MH_MAGIC64 = 1+0xfeedface + }; + enum e2 { + MH_EXECUTE = 2 + }; + enum e3 { + MH_NOUNDEFS = 1 + }; + +typedef struct { + unsigned cmd; + unsigned cmdsize; +} Mach_load_command; + enum e4 { + LC_SEGMENT = 0x1, + LC_SEGMENT_64 = 0x19, + LC_THREAD = 0x4, + LC_UNIXTHREAD = 0x5, + LC_LOAD_DYLINKER = 0xe + }; + +typedef struct { + unsigned cmd; + unsigned cmdsize; + char segname[16]; + uint64_t vmaddr; + uint64_t vmsize; + uint64_t fileoff; + uint64_t filesize; + unsigned maxprot; + unsigned initprot; + unsigned nsects; + unsigned flags; +} Mach_segment_command; + enum e5 { + VM_PROT_READ = 1, + VM_PROT_WRITE = 2, + VM_PROT_EXECUTE = 4 + }; + +typedef struct { + uint64_t rax, rbx, rcx, rdx; + uint64_t rdi, rsi, rbp, rsp; + uint64_t r8, r9, r10, r11; + uint64_t r12, r13, r14, r15; + uint64_t rip, rflags; + uint64_t cs, fs, gs; +} Mach_AMD64_thread_state; + +typedef struct { + unsigned cmd; /* LC_THREAD or LC_UNIXTHREAD */ + unsigned cmdsize; /* total size of this command */ + unsigned flavor; + unsigned count; /* sizeof(following_thread_state)/4 */ + Mach_AMD64_thread_state state; +} Mach_thread_command; + enum e6 { + AMD64_THREAD_STATE = 4 // x86_THREAD_STATE64 + }; + enum e7 { + AMD64_THREAD_STATE_COUNT = sizeof(Mach_AMD64_thread_state)/4 + }; + +typedef union { + unsigned offset; /* from start of load command to string */ +} Mach_lc_str; + +#define MAP_FIXED 0x10 +#define MAP_PRIVATE 0x02 +#define MAP_ANON 0x1000 +//#define MAP_ANON 0x20 // x86 DEBUG ONLY +#define PROT_READ 1 +#define PROT_WRITE 2 +#define PROT_EXEC 4 +#define MAP_ANON_FD -1 + +extern void *mmap(void *, size_t, unsigned, unsigned, int, off_t); +ssize_t pread(int, void *, size_t, off_t); +#define bswap(a,b) /*EMPTY*/ +//extern void bswap(void *, unsigned); + +DEBUG_STRCON(STR_mmap, + "mmap addr=%%p len=%%p prot=%%x flags=%%x fd=%%d off=%%p\\n"); +DEBUG_STRCON(STR_do_xmap, + "do_xmap fdi=%%x mhdr=%%p xi=%%p(%%x %%p) f_unf=%%p\\n") + +static Mach_AMD64_thread_state const * +do_xmap( + Mach_header64 const *const mhdr, + off_t const fat_offset, + Extent *const xi, + int const fdi, + Mach_header64 **mhdrpp, + f_expand *const f_decompress, + f_unfilter *const f_unf +) +{ + Mach_segment_command const *sc = (Mach_segment_command const *)(1+ mhdr); + Mach_AMD64_thread_state const *entry = 0; + unsigned j; + + DPRINTF((STR_do_xmap(), + fdi, mhdr, xi, (xi? xi->size: 0), (xi? xi->buf: 0), f_unf)); + + for ( j=0; j < mhdr->ncmds; ++j, + (sc = (Mach_segment_command const *)(sc->cmdsize + (void const *)sc)) + ) if (LC_SEGMENT_64==sc->cmd && sc->vmsize!=0) { + Extent xo; + size_t mlen = xo.size = sc->filesize; + unsigned char *addr = xo.buf = (unsigned char *)sc->vmaddr; + unsigned char *haddr = sc->vmsize + addr; + size_t frag = (int)(uint64_t)addr &~ PAGE_MASK; + addr -= frag; + mlen += frag; + + if (0!=mlen) { + // Decompressor can overrun the destination by 3 bytes. [x86 only] + size_t const mlen3 = mlen + (xi ? 3 : 0); + unsigned const prot = VM_PROT_READ | VM_PROT_WRITE; + unsigned const flags = MAP_FIXED | MAP_PRIVATE | + ((xi || 0==sc->filesize) ? MAP_ANON : 0); + int const fdm = ((0==sc->filesize) ? MAP_ANON_FD : fdi); + off_t const offset = sc->fileoff + fat_offset; + + DPRINTF((STR_mmap(), addr, mlen3, prot, flags, fdm, offset)); + if (addr != mmap(addr, mlen3, prot, flags, fdm, offset)) { + err_exit(8); + } + } + if (xi && 0!=sc->filesize) { + if (0==sc->fileoff /*&& 0!=mhdrpp*/) { + *mhdrpp = (Mach_header64 *)(void *)addr; + } + unpackExtent(xi, &xo, f_decompress, f_unf); + } + /*bzero(addr, frag);*/ // fragment at lo end + frag = (-mlen) &~ PAGE_MASK; // distance to next page boundary + bzero(mlen+addr, frag); // fragment at hi end + if (0!=mlen && 0!=mprotect(addr, mlen, sc->initprot)) { + err_exit(10); +ERR_LAB + } + addr += mlen + frag; /* page boundary on hi end */ + if ( +#if defined(SIMULATE_ON_DEBIAN_EABI4) /*{*/ + 0!=addr && +#endif /*}*/ + addr < haddr) { // need pages for .bss + if (0!=addr && addr != mmap(addr, haddr - addr, sc->initprot, + MAP_FIXED | MAP_PRIVATE | MAP_ANON, MAP_ANON_FD, 0 ) ) { + err_exit(9); + } + } + else if (xi) { // cleanup if decompressor overrun crosses page boundary + mlen = ~PAGE_MASK & (3+ mlen); + if (mlen<=3) { // page fragment was overrun buffer only + munmap((char *)addr, mlen); + } + } + } + else if (LC_UNIXTHREAD==sc->cmd || LC_THREAD==sc->cmd) { + Mach_thread_command const *const thrc = (Mach_thread_command const *)sc; + if (AMD64_THREAD_STATE ==thrc->flavor + && AMD64_THREAD_STATE_COUNT==thrc->count ) { + entry = &thrc->state; + } + } + return entry; +} + + +/************************************************************************* +// upx_main - called by our entry code +// +**************************************************************************/ + +DEBUG_STRCON(STR_upx_main, + "upx_main szc=%%x f_dec=%%p f_unf=%%p " + " xo=%%p(%%x %%p) xi=%%p(%%x %%p) mhdrpp=%%p\\n") + +Mach_AMD64_thread_state const * +upx_main( + struct l_info const *const li, + size_t volatile sz_compressed, // total length + Mach_header64 *const mhdr, // temp char[sz_mhdr] for decompressing + size_t const sz_mhdr, + f_expand *const f_decompress, + f_unfilter *const f_unf, + Mach_header64 **const mhdrpp // Out: *mhdrpp= &real Mach_header64 +) +{ + Mach_AMD64_thread_state const *entry; + off_t fat_offset = 0; + Extent xi, xo, xi0; + xi.buf = CONST_CAST(unsigned char *, 1+ (struct p_info const *)(1+ li)); // &b_info + xi.size = sz_compressed - (sizeof(struct l_info) + sizeof(struct p_info)); + xo.buf = (unsigned char *)mhdr; + xo.size = ((struct b_info const *)(void const *)xi.buf)->sz_unc; + xi0 = xi; + + DPRINTF((STR_upx_main(), + sz_compressed, f_decompress, f_unf, &xo, xo.size, xo.buf, + &xi, xi.size, xi.buf, mhdrpp)); + + // Uncompress Macho headers + unpackExtent(&xi, &xo, f_decompress, 0); // never filtered? + + entry = do_xmap(mhdr, fat_offset, &xi0, MAP_ANON_FD, mhdrpp, f_decompress, f_unf); + + { // Map dyld dynamic loader + Mach_load_command const *lc = (Mach_load_command const *)(1+ mhdr); + unsigned j; + + for (j=0; j < mhdr->ncmds; ++j, + (lc = (Mach_load_command const *)(lc->cmdsize + (void const *)lc)) + ) if (LC_LOAD_DYLINKER==lc->cmd) { + char const *const dyld_name = ((Mach_lc_str const *)(1+ lc))->offset + + (char const *)lc; + int const fdi = open(dyld_name, O_RDONLY, 0); + if (0 > fdi) { + err_exit(18); + } +fat: + if ((ssize_t)sz_mhdr!=pread(fdi, (void *)mhdr, sz_mhdr, fat_offset)) { +ERR_LAB + err_exit(19); + } + switch (mhdr->magic) { + case MH_MAGIC: break; + case MH_MAGIC64: break; + case FAT_CIGAM: + case FAT_MAGIC: { + // stupid Apple: waste code and a page fault on EVERY execve + Fat_header *const fh = (Fat_header *)mhdr; + Fat_arch *fa = (Fat_arch *)(1+ fh); + bswap(fh, sizeof(*fh) + (fh->nfat_arch>>24)*sizeof(*fa)); + for (j= 0; j < fh->nfat_arch; ++j, ++fa) { + if (CPU_TYPE_AMD64==fa->cputype) { + fat_offset= fa->offset; + goto fat; + } + } + } break; + } // switch + entry = do_xmap(mhdr, fat_offset, 0, fdi, 0, 0, 0); + close(fdi); + break; + } + } + + return entry; +} + +f_expand *f_exp; +f_unfilter *f_unf; +void (*launch)(void const *, Mach_header64 **); + +// Build on Mac OS X: +// gcc -o amd64-darwin.macho-upxmain.exe \ +// -fPIC amd64-darwin.macho-upxmain.c -Wl,-pagezero_size,0xffff0000 +int +main(int argc, char *argv[]) +{ + Mach_header64 *mhdrp; + unsigned long const base = 0xffff0000ul; + size_t const len = *(size_t *)(base - sizeof(size_t)); + void const *const ptr = (void const *)(base - len); + char mhdr[2048]; + void const *entry = upx_main((struct l_info const *)ptr, len, + (Mach_header64 *)&mhdr, sizeof(mhdr), + f_exp, f_unf, &mhdrp); + launch(entry, &mhdrp); + return 0; +} + +/* +vi:ts=4:et:nowrap +*/ From ee06ce1148e2ce485b32460b8afab450840c48fe Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sat, 10 Sep 2016 14:57:27 -0700 Subject: [PATCH 05/29] generic Mach_command --- src/p_mach.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/p_mach.h b/src/p_mach.h index 350c03c0..33f83271 100644 --- a/src/p_mach.h +++ b/src/p_mach.h @@ -47,6 +47,11 @@ __packed_struct(Mach_fat_arch) BE32 align; /* shift count; log base 2 */ __packed_struct_end() +typedef struct { + uint32_t cmd; + uint32_t cmdsize; + uint32_t data[2]; // because cmdsize >= 16 +} Mach_command; // generic prefix /************************************************************************* // Mach Mach Object executable; all structures are target-endian From 83e0aaa51125dfc51ae731d4f2f492fa2fd216c8 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sat, 10 Sep 2016 14:59:23 -0700 Subject: [PATCH 06/29] sections AMD64BXX, MACH_UNC for MacOSX 10.12 --- src/stub/src/amd64-darwin.macho-entry.S | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/stub/src/amd64-darwin.macho-entry.S b/src/stub/src/amd64-darwin.macho-entry.S index d4f96d62..2f2af821 100644 --- a/src/stub/src/amd64-darwin.macho-entry.S +++ b/src/stub/src/amd64-darwin.macho-entry.S @@ -40,12 +40,18 @@ // see glibc/sysdeps/amd64/elf/start.S **************************************************************************/ + section AMD64BXX +0: .word 9f - 0b +#include "arch/amd64/bxx.S" +9: + section MACHMAINX _start: .globl _start // int3 call main // push &decompress ret_main: + section MACH_UNC /* Returns 0 on success; non-zero on failure. */ decompress: // (uchar const *src, size_t lsrc, uchar *dst, u32 &ldst, uint method) @@ -136,7 +142,7 @@ copy4: movl %edx,(%rdi); leaq 4(%rdi),%rdi; jnc copy4 addl $4,len; movb (%rax),%dl; jz copy0 copy1: - incq %rax; movb %dl,(%rdi); subl $1,len + addq $1,%rax; movb %dl,(%rdi); subl $1,len movb (%rax),%dl leaq 1(%rdi),%rdi; jnz copy1 copy0: From 15d62f7b966f71ef088904406b6437b91dbc2878 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sat, 10 Sep 2016 15:00:28 -0700 Subject: [PATCH 07/29] Mach_main_command LC_MAIN --- src/stub/src/amd64-darwin.macho-main.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/stub/src/amd64-darwin.macho-main.c b/src/stub/src/amd64-darwin.macho-main.c index 663aaded..18c4471f 100644 --- a/src/stub/src/amd64-darwin.macho-main.c +++ b/src/stub/src/amd64-darwin.macho-main.c @@ -423,6 +423,13 @@ typedef struct { VM_PROT_EXECUTE = 4 }; +typedef struct { + uint32_t cmd; // LC_MAIN; MH_EXECUTE only + uint32_t cmdsize; // 24 + uint64_t entryoff; // file offset of main() [expected in __TEXT] + uint64_t stacksize; // non-default initial stack size +} Mach_main_command; + typedef struct { uint64_t rax, rbx, rcx, rdx; uint64_t rdi, rsi, rbp, rsp; From 3fefaa73620b95fe10e59eb78fd1a1ab8a1a7620 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sat, 10 Sep 2016 15:02:13 -0700 Subject: [PATCH 08/29] revamp MH_EXECUTE: try to meet expectations of MacOSX 10.12 Sierra changed src/p_mach.cpp changed src/stub/src/amd64-darwin.macho-upxmain.c --- src/p_mach.cpp | 214 ++++++++++++++++++---- src/stub/src/amd64-darwin.macho-upxmain.c | 106 ++++++++--- 2 files changed, 261 insertions(+), 59 deletions(-) diff --git a/src/p_mach.cpp b/src/p_mach.cpp index aa9dc411..eb7a50ae 100644 --- a/src/p_mach.cpp +++ b/src/p_mach.cpp @@ -328,7 +328,13 @@ void PackMachI386::addStubEntrySections(Filter const *ft) void PackMachAMD64::addStubEntrySections(Filter const * /*ft*/) { - addLoader("MACHMAINX", NULL); + if (my_filetype!=Mach_header::MH_EXECUTE) { + addLoader("MACHMAINX", NULL); + } + else { + addLoader("AMD64BXX", NULL); + } + addLoader("MACH_UNC", NULL); //addLoader(getDecompressorSections(), NULL); addLoader( ( M_IS_NRV2E(ph.method) ? "NRV_HEAD,NRV2E,NRV_TAIL" @@ -338,7 +344,10 @@ void PackMachAMD64::addStubEntrySections(Filter const * /*ft*/) : NULL), NULL); if (hasLoaderSection("CFLUSH")) addLoader("CFLUSH"); - addLoader("MACHMAINY,IDENTSTR,+40,MACHMAINZ,FOLDEXEC", NULL); + addLoader("MACHMAINY,IDENTSTR,+40,MACHMAINZ", NULL); + if (my_filetype!=Mach_header::MH_EXECUTE) { + addLoader("FOLDEXEC", NULL); + } } void PackMachARMEL::addStubEntrySections(Filter const * /*ft*/) @@ -457,11 +466,29 @@ PackMachI386::buildLoader(const Filter *ft) void PackMachAMD64::buildLoader(const Filter *ft) { - if (my_filetype==Mach_header::MH_EXECUTE) { + if (0 && my_filetype==Mach_header::MH_EXECUTE) { initLoader(NULL, 0); - linker->addSection("UPXMAIN", stub_amd64_darwin_macho_upxmain_exe, - sizeof(stub_amd64_darwin_macho_upxmain_exe), 0); - addLoader("UPXMAIN", NULL); + addStubEntrySections(ft); + + defineSymbols(ft); + relocateLoader(); +if (0) { + Mach_command const *ptr1 = (Mach_command const *)(1+ + (Mach_header const *)stub_amd64_darwin_macho_upxmain_exe); + for (unsigned j = 0; j < mhdro.ncmds; ++j, + ptr1 = (Mach_command const *)(ptr1->cmdsize + (char const *)ptr1)) + switch (ptr1->cmd) { + case Mach_segment_command::LC_SEGMENT_64: { + Mach_segment_command const *const segptr = (Mach_segment_command const *)ptr1; + if (!strcmp("__TEXT", segptr->segname)) { + Mach_section_command const *const secptr = (Mach_section_command const *)(1+ segptr); + linker->addSection("UPXMAIN", &stub_amd64_darwin_macho_upxmain_exe[secptr->offset], + secptr->size, 0); + addLoader("UPXMAIN", NULL); + } + } break; + } // end switch +} } else { buildMachLoader( @@ -748,25 +775,115 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader secXHDR.offset -= sizeof(linkitem); } secXHDR.addr += secXHDR.offset; - unsigned foff1 = (PAGE_MASK & (~PAGE_MASK + segTEXT.filesize)); - if (foff1 < segTEXT.vmsize) - foff1 += PAGE_SIZE; // codesign disallows overhang - segLINK.fileoff = foff1; - segLINK.vmaddr = segTEXT.vmaddr + foff1; - fo->seek(foff1 - 1, SEEK_SET); fo->write("", 1); - fo->seek(sizeof(mhdro), SEEK_SET); - fo->rewrite(&segZERO, sizeof(segZERO)); - fo->rewrite(&segXHDR, sizeof(segXHDR)); - fo->rewrite(&secXHDR, sizeof(secXHDR)); - fo->rewrite(&segTEXT, sizeof(segTEXT)); - fo->rewrite(&secTEXT, sizeof(secTEXT)); - fo->rewrite(&cmdUUID, sizeof(cmdUUID)); - fo->rewrite(&segLINK, sizeof(segLINK)); - fo->rewrite(&threado, sizeof(threado)); - if (my_filetype==Mach_header::MH_EXECUTE) { - fo->rewrite(&linkitem, sizeof(linkitem)); + unsigned offLINK = (PAGE_MASK & (~PAGE_MASK + segTEXT.filesize)); + if (offLINK < segTEXT.vmsize) + offLINK += PAGE_SIZE; // codesign disallows overhang + segLINK.fileoff = offLINK; + segLINK.vmaddr = segTEXT.vmaddr + offLINK; + if (0) { + fo->seek(offLINK - 1, SEEK_SET); fo->write("", 1); + fo->seek(sizeof(mhdro), SEEK_SET); + fo->rewrite(&segZERO, sizeof(segZERO)); + fo->rewrite(&segXHDR, sizeof(segXHDR)); + fo->rewrite(&secXHDR, sizeof(secXHDR)); + fo->rewrite(&segTEXT, sizeof(segTEXT)); + fo->rewrite(&secTEXT, sizeof(secTEXT)); + fo->rewrite(&cmdUUID, sizeof(cmdUUID)); + fo->rewrite(&segLINK, sizeof(segLINK)); + fo->rewrite(&threado, sizeof(threado)); + if (my_filetype==Mach_header::MH_EXECUTE) { + fo->rewrite(&linkitem, sizeof(linkitem)); + } + fo->rewrite(&linfo, sizeof(linfo)); + } + if (my_filetype == Mach_header::MH_EXECUTE) { + unsigned cmdsize = mhdro.sizeofcmds - sizeof(segXHDR); + Mach_header const *const ptr0 = (Mach_header const *)stub_amd64_darwin_macho_upxmain_exe; + Mach_command const *ptr1 = (Mach_command const *)(1+ ptr0); + unsigned delta = 0; + for (unsigned j = 0; j < mhdro.ncmds -1; ++j, + (cmdsize -= ptr1->cmdsize), + ptr1 = (Mach_command const *)(ptr1->cmdsize + (char const *)ptr1)) + switch (ptr1->cmd) { + case Mach_segment_command::LC_SEGMENT_64: { + Mach_segment_command const *const segptr = (Mach_segment_command const *)ptr1; + if (!strcmp("__TEXT", segptr->segname)) { + Mach_section_command const *const secptr = (Mach_section_command const *)(1+ segptr); + memcpy(&secTEXT, secptr, sizeof(secTEXT)); + secTEXT.align = 0; + unsigned const d = getLoaderSize(); + secTEXT.addr -= d; + secTEXT.size += d; + secTEXT.offset -= d; + fo->seek((char const *)secptr - (char const *)ptr0, SEEK_SET); + fo->rewrite(&secTEXT, sizeof(secTEXT)); + fo->seek(secTEXT.offset, SEEK_SET); + fo->rewrite(getLoader(), d); + fo->seek(0, SEEK_END); + } + if (!strcmp("__LINKEDIT", ((Mach_segment_command const *)ptr1)->segname)) { + memcpy(&segLINK, segptr, sizeof(segLINK)); + delta = offLINK - segLINK.fileoff; // relocation constant + + // Mach_command __LINKEDIT + // The contents remain the same, but at a different offset in the file + fo->seek(offLINK, SEEK_SET); + fo->write(&stub_amd64_darwin_macho_upxmain_exe[segLINK.fileoff], segLINK.filesize); + + // Update the __LINKEDIT header + segLINK.vmaddr += delta; + segLINK.fileoff = offLINK; + fo->seek((char const *)ptr1 - (char const *)ptr0, SEEK_SET); + fo->rewrite(&segLINK, sizeof(segLINK)); + + // Mach_segment_command for new segXHDR + segXHDR.cmdsize = sizeof(segXHDR); + segXHDR.nsects = 0; + fo->rewrite(&segXHDR, sizeof(segXHDR)); + } + } break; + case Mach_segment_command::LC_DYLD_INFO_ONLY: { + N_Mach::Mach_dyld_info_only_command blk; memcpy(&blk, ptr1, sizeof(blk)); + if (blk.rebase_off) blk.rebase_off += delta; + if (blk.bind_off) blk.bind_off += delta; + if (blk.lazy_bind_off) blk.lazy_bind_off += delta; + if (blk.export_off) blk.export_off += delta; + fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); + fo->rewrite(&blk, sizeof(blk)); + } break; + case Mach_segment_command::LC_SYMTAB: { + Mach_symtab_command blk; memcpy(&blk, ptr1, sizeof(blk)); + if (blk.symoff) blk.symoff += delta; + if (blk.stroff) blk.stroff += delta; + fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); + fo->rewrite(&blk, sizeof(blk)); + } break; + case Mach_segment_command::LC_DYSYMTAB: { + Mach_dysymtab_command blk; memcpy(&blk, ptr1, sizeof(blk)); + if (blk.tocoff) blk.tocoff += delta; + if (blk.modtaboff) blk.modtaboff += delta; + if (blk.extrefsymoff) blk.extrefsymoff += delta; + if (blk.indirectsymoff) blk.indirectsymoff += delta; + if (blk.extreloff) blk.extreloff += delta; + if (blk.locreloff) blk.locreloff += delta; + fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); + fo->rewrite(&blk, sizeof(blk)); + } break; + case Mach_segment_command::LC_FUNCTION_STARTS: { + N_Mach::Mach_function_starts_command blk; memcpy(&blk, ptr1, sizeof(blk)); + if (blk.dataoff) blk.dataoff += delta; + fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); + fo->rewrite(&blk, sizeof(blk)); + } break; + case Mach_segment_command::LC_DATA_IN_CODE: { + N_Mach::Mach_data_in_code_command blk; memcpy(&blk, ptr1, sizeof(blk)); + if (blk.dataoff) blk.dataoff += delta; + fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); + fo->rewrite(&blk, sizeof(blk)); + } break; + } // end switch + fo->seek(0, SEEK_END); } - fo->rewrite(&linfo, sizeof(linfo)); } void PackMachARMEL::pack4(OutputFile *fo, Filter &ft) // append PackHeader @@ -1444,13 +1561,10 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e unsigned const lc_seg = lc_segment[sizeof(Addr)>>3]; mhdro = mhdri; if (my_filetype==Mach_header::MH_EXECUTE) { - mhdro.ncmds = 6; // __ZERO, __XHDR, __TEXT, UUID, __LINKEDIT, THREAD_STATE - mhdro.sizeofcmds = sizeof(segZERO) - + sizeof(segXHDR) + sizeof(secXHDR) - + sizeof(segTEXT) + sizeof(secTEXT) - + sizeof(cmdUUID) - + sizeof(segLINK) + my_thread_command_size /* + sizeof(linkitem) */ ; - mhdro.flags = Mach_header::MH_NOUNDEFS | Mach_header::MH_DYLDLINK; + memcpy(&mhdro, stub_amd64_darwin_macho_upxmain_exe, sizeof(mhdro)); + mhdro.ncmds += 1; // we add LC_SEGMENT{,_64} for UPX_DATA + mhdro.sizeofcmds += sizeof(segXHDR); + mhdro.flags &= ~Mach_header::MH_PIE; // we require fixed address } fo->write(&mhdro, sizeof(mhdro)); @@ -1501,13 +1615,15 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e | Mach_section_command::S_ATTR_PURE_INSTRUCTIONS; segXHDR = segTEXT; + segXHDR.cmdsize = sizeof(segXHDR) + sizeof(secXHDR); segXHDR.vmaddr = segZERO.vmsize; segXHDR.vmsize = PAGE_SIZE; segXHDR.filesize = PAGE_SIZE; - strncpy((char *)segXHDR.segname, "__XHDR", sizeof(segXHDR.segname)); + segXHDR.nsects = 1; + strncpy((char *)segXHDR.segname, "UPX_DATA", sizeof(segXHDR.segname)); memset(&secXHDR, 0, sizeof(secXHDR)); - strncpy((char *)secXHDR.sectname, "__xhdr", sizeof(secXHDR.sectname)); + strncpy((char *)secXHDR.sectname, "upx_data", sizeof(secXHDR.sectname)); memcpy(secXHDR.segname, segXHDR.segname, sizeof(secXHDR.segname)); secXHDR.addr = segXHDR.vmaddr; secXHDR.size = 0; // empty so far @@ -1520,7 +1636,33 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e segLINK.initprot = Mach_segment_command::VM_PROT_READ; // Adjust later: .vmaddr .vmsize .fileoff .filesize - if (my_filetype==Mach_header::MH_EXECUTE) { + if (my_filetype == Mach_header::MH_EXECUTE) { + unsigned cmdsize = mhdro.sizeofcmds - sizeof(segXHDR); + Mach_header const *const ptr0 = (Mach_header const *)stub_amd64_darwin_macho_upxmain_exe; + Mach_command const *ptr1 = (Mach_command const *)(1+ ptr0); + for (unsigned j = 0; j < mhdro.ncmds -1; ++j, + (cmdsize -= ptr1->cmdsize), + ptr1 = (Mach_command const *)(ptr1->cmdsize + (char const *)ptr1)) { + Mach_segment_command const *const segptr = (Mach_segment_command const *)ptr1; + if (lc_seg == ptr1->cmd && !strcmp("__LINKEDIT", segptr->segname)) { + // Mach_command before __LINKEDIT + fo->write((1+ ptr0), (char const *)ptr1 - (char const *)(1+ ptr0)); + // Mach_command __LINKEDIT + fo->write(segptr, segptr->cmdsize); + // LC_SEGMENT_64 for payload; steal space from -Wl,-headerpadsize + segXHDR.cmdsize = sizeof(segXHDR); + segXHDR.nsects = 0; + fo->write(&segXHDR, sizeof(segXHDR)); + // Mach_command after __LINKEDIT + fo->write(ptr1->cmdsize + (char const *)ptr1, cmdsize - ptr1->cmdsize); + // Contents before __LINKEDIT; put non-headers at same offset in file + unsigned pos = sizeof(mhdro) + mhdro.sizeofcmds; // includes sizeof(segXHDR) + fo->write(&stub_amd64_darwin_macho_upxmain_exe[pos], segptr->fileoff - pos); + break; + } + } + } + else { // not MH_EXECUTE; thus MH_DYLIB fo->write(&segZERO, sizeof(segZERO)); fo->write(&segXHDR, sizeof(segXHDR)); fo->write(&secXHDR, sizeof(secXHDR)); @@ -1531,8 +1673,6 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e pack1_setup_threado(fo); memset(&linkitem, 0, sizeof(linkitem)); fo->write(&linkitem, sizeof(linkitem)); - } - if (my_filetype==Mach_header::MH_DYLIB) { fo->write(rawmseg, mhdri.sizeofcmds); } sz_mach_headers = fo->getBytesWritten(); @@ -1608,7 +1748,7 @@ void PackMachBase::unpack(OutputFile *fo) unsigned char const *ptr = (unsigned char const *)(1+mhdr); for (unsigned j= 0; j < ncmds; ++j) { memcpy(&msegcmd[j], ptr, umin(sizeof(Mach_segment_command), - ((Mach_segment_command const *)ptr)->cmdsize)); + ((Mach_command const *)ptr)->cmdsize)); ptr += (unsigned) ((Mach_segment_command const *)ptr)->cmdsize; if ((unsigned)(ptr - (unsigned char const *)mhdr) > ph.u_len) { throwCantUnpack("cmdsize"); diff --git a/src/stub/src/amd64-darwin.macho-upxmain.c b/src/stub/src/amd64-darwin.macho-upxmain.c index 9b2a5520..7b9892e2 100644 --- a/src/stub/src/amd64-darwin.macho-upxmain.c +++ b/src/stub/src/amd64-darwin.macho-upxmain.c @@ -29,7 +29,8 @@ */ - +#include +#include #include "include/darwin.h" #ifndef DEBUG /*{*/ @@ -135,10 +136,10 @@ heximal(unsigned long x, char *ptr, int n) } -#define DPRINTF(a) dprintf a +#define DPRINTF(a) my_printf a static int -dprintf(char const *fmt, ...) +my_printf(char const *fmt, ...) { char c; int n= 0; @@ -397,11 +398,13 @@ typedef struct { unsigned cmdsize; } Mach_load_command; enum e4 { + LC_REQ_DYLD = 0x80000000, // OR'ed ==> must not ignore LC_SEGMENT = 0x1, LC_SEGMENT_64 = 0x19, LC_THREAD = 0x4, LC_UNIXTHREAD = 0x5, - LC_LOAD_DYLINKER = 0xe + LC_LOAD_DYLINKER = 0xe, + LC_MAIN = (0x28|LC_REQ_DYLD) }; typedef struct { @@ -423,6 +426,27 @@ typedef struct { VM_PROT_EXECUTE = 4 }; +typedef struct { + char sectname[16]; + char segname[16]; + uint64_t addr; /* memory address */ + uint64_t size; /* size in bytes */ + unsigned offset; /* file offset */ + unsigned align; /* power of 2 */ + unsigned reloff; /* file offset of relocation entries */ + unsigned nreloc; /* number of relocation entries */ + unsigned flags; /* section type and attributes */ + unsigned reserved1; /* for offset or index */ + unsigned reserved2; /* for count or sizeof */ +} Mach_section_command; + +typedef struct { + uint32_t cmd; // LC_MAIN; MH_EXECUTE only + uint32_t cmdsize; // 24 + uint64_t entryoff; // file offset of main() [expected in __TEXT] + uint64_t stacksize; // non-default initial stack size +} Mach_main_command; + typedef struct { uint64_t rax, rbx, rcx, rdx; uint64_t rdi, rsi, rbp, rsp; @@ -469,7 +493,7 @@ DEBUG_STRCON(STR_mmap, DEBUG_STRCON(STR_do_xmap, "do_xmap fdi=%%x mhdr=%%p xi=%%p(%%x %%p) f_unf=%%p\\n") -static Mach_AMD64_thread_state const * +static uint64_t // entry address do_xmap( Mach_header64 const *const mhdr, off_t const fat_offset, @@ -481,7 +505,8 @@ do_xmap( ) { Mach_segment_command const *sc = (Mach_segment_command const *)(1+ mhdr); - Mach_AMD64_thread_state const *entry = 0; + Mach_segment_command const *segTEXT = 0; + uint64_t entry = 0; unsigned j; DPRINTF((STR_do_xmap(), @@ -514,6 +539,7 @@ do_xmap( } if (xi && 0!=sc->filesize) { if (0==sc->fileoff /*&& 0!=mhdrpp*/) { + segTEXT = sc; *mhdrpp = (Mach_header64 *)(void *)addr; } unpackExtent(xi, &xo, f_decompress, f_unf); @@ -547,13 +573,18 @@ ERR_LAB Mach_thread_command const *const thrc = (Mach_thread_command const *)sc; if (AMD64_THREAD_STATE ==thrc->flavor && AMD64_THREAD_STATE_COUNT==thrc->count ) { - entry = &thrc->state; + entry = thrc->rip; + } + else if (LC_MAIN==sc->cmd) { + entry = ((Mach_main_command const *)sc)->entryoff; + if (segTEXT->fileoff <= entry && entry < segTEXT->filesize) { + entry += segTEXT->vmaddr; } + // XXX FIXME TODO: if entry not in segTEXT } return entry; } - /************************************************************************* // upx_main - called by our entry code // @@ -563,7 +594,7 @@ DEBUG_STRCON(STR_upx_main, "upx_main szc=%%x f_dec=%%p f_unf=%%p " " xo=%%p(%%x %%p) xi=%%p(%%x %%p) mhdrpp=%%p\\n") -Mach_AMD64_thread_state const * +uint64_t // entry address upx_main( struct l_info const *const li, size_t volatile sz_compressed, // total length @@ -574,7 +605,7 @@ upx_main( Mach_header64 **const mhdrpp // Out: *mhdrpp= &real Mach_header64 ) { - Mach_AMD64_thread_state const *entry; + uint64_t entry; off_t fat_offset = 0; Extent xi, xo, xi0; xi.buf = CONST_CAST(unsigned char *, 1+ (struct p_info const *)(1+ li)); // &b_info @@ -636,25 +667,56 @@ ERR_LAB return entry; } -f_expand *f_exp; -f_unfilter *f_unf; -void (*launch)(void const *, Mach_header64 **); +typedef struct { + uint32_t cmd; + uint32_t cmdsize; + uint32_t data[2]; // because cmdsize >= 16 +} Mach_command; // generic prefix -// Build on Mac OS X: -// gcc -o amd64-darwin.macho-upxmain.exe \ -// -fPIC amd64-darwin.macho-upxmain.c -Wl,-pagezero_size,0xffff0000 +// +// Build on Mac OS X: (where gcc is really clang) +// gcc -o amd64-darwin.macho-upxmain.exe -fno-stack-protector \ +// -Os -fPIC amd64-darwin.macho-upxmain.c -Wl,-pagezero_size,0xffff0000 \ +// -Wl,-no_pie -Wl,-no_uuid -Wl,-no_function_starts -Wl,-headerpad,0x400 int main(int argc, char *argv[]) { Mach_header64 *mhdrp; - unsigned long const base = 0xffff0000ul; - size_t const len = *(size_t *)(base - sizeof(size_t)); - void const *const ptr = (void const *)(base - len); + Mach_header64 const *mhdr0 = (Mach_header64 const *)((~0ul<<16) & (unsigned long)&main); + Mach_command const *ptr = (Mach_command const *)(1+ mhdr0); + f_unfilter *f_unf; + f_expand *f_exp; + unsigned char const *payload; + size_t paysize; + + unsigned j; + for (j=0; j < mhdr0->ncmds; ++j, + ptr = (Mach_command const *)(ptr->cmdsize + (char const *)ptr)) + if (LC_SEGMENT_64==ptr->cmd) { + Mach_segment_command const *const segptr = (Mach_segment_command const *)ptr; +//fprintf(stderr, "ptr=%p segptr=%p\n", ptr, segptr); + if ((long)0x0000545845545f5ful == *(long const *)segptr->segname) { // "__TEXT" + Mach_section_command const *const secptr = (Mach_section_command const *)(1+ segptr); + //if ((long)0x0000747865745f5ful == *(long const *)secptr->sectname) { // "__text" + f_unf = (f_unfilter *)(sizeof(unsigned short) + secptr->addr); + f_exp = (f_expand *)((char const *)f_unf + ((unsigned short *)f_unf)[-1]); +//fprintf(stderr, "f_unf=%p f_exp=%p\n", f_unf, f_exp); + //} + } + if ((long)0x415441445f585055ul == *(long const *)segptr->segname) { // "UPX_DATA" + payload = (unsigned char const *)(segptr->vmaddr); + paysize = segptr->filesize; +//fprintf(stderr, "payload=%p paysize=%lu\n", payload, paysize); + } + } char mhdr[2048]; - void const *entry = upx_main((struct l_info const *)ptr, len, - (Mach_header64 *)&mhdr, sizeof(mhdr), +//fprintf(stderr, "call upx_main(payload=%p paysize=%lu mhdr=%p f_exp=%p f_unf=%p mhdrp@%p)\n", +//payload, paysize, mhdr, f_exp, f_unf, &mhdrp); + uint64_t entry = upx_main((struct l_info const *)payload, paysize, + (Mach_header64 *)mhdr, sizeof(mhdr), f_exp, f_unf, &mhdrp); - launch(entry, &mhdrp); +//fprintf(stderr, "return to launch\n"); + //launch(entry, &mhdrp); return 0; } From 1334d544f73bf2b85bd908ff6fdca43c1882d027 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sat, 10 Sep 2016 15:03:04 -0700 Subject: [PATCH 09/29] stubtools 20160902 --- src/stub/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/stub/Makefile b/src/stub/Makefile index ed202544..4aa719a9 100644 --- a/src/stub/Makefile +++ b/src/stub/Makefile @@ -155,7 +155,7 @@ endif all.targets ?= .upx-stubtools-stamp tmp/.tmp-stamp .all-stamp all: $$(all.targets) .upx-stubtools-stamp: $(MAKEFILE_LIST) - upx-stubtools-check-version 20130920 + upx-stubtools-check-version 20160902 @echo "timestamp" > $@ %/.tmp-stamp: @mkdir -p $(dir $@) From 89df7451ef16266249ce44f6d0c8c9f4122c2409 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sat, 10 Sep 2016 15:03:55 -0700 Subject: [PATCH 10/29] Rebuild stubs changed src/stub/amd64-darwin.macho-entry.h changed src/stub/amd64-darwin.macho-upxmain.h changed src/stub/tmp/amd64-darwin.macho-entry.bin.dump --- src/stub/amd64-darwin.macho-entry.h | 1165 +++++++++-------- src/stub/amd64-darwin.macho-upxmain.h | 439 +++---- .../tmp/amd64-darwin.macho-entry.bin.dump | 28 +- 3 files changed, 827 insertions(+), 805 deletions(-) diff --git a/src/stub/amd64-darwin.macho-entry.h b/src/stub/amd64-darwin.macho-entry.h index 675fc93b..b415a5a1 100644 --- a/src/stub/amd64-darwin.macho-entry.h +++ b/src/stub/amd64-darwin.macho-entry.h @@ -1,5 +1,5 @@ /* amd64-darwin.macho-entry.h - created from amd64-darwin.macho-entry.bin, 9066 (0x236a) bytes + created from amd64-darwin.macho-entry.bin, 9467 (0x24fb) bytes This file is part of the UPX executable compressor. @@ -31,576 +31,601 @@ */ -#define STUB_AMD64_DARWIN_MACHO_ENTRY_SIZE 9066 -#define STUB_AMD64_DARWIN_MACHO_ENTRY_ADLER32 0xf6d72f36 -#define STUB_AMD64_DARWIN_MACHO_ENTRY_CRC32 0x61c1174a +#define STUB_AMD64_DARWIN_MACHO_ENTRY_SIZE 9467 +#define STUB_AMD64_DARWIN_MACHO_ENTRY_ADLER32 0x77b69279 +#define STUB_AMD64_DARWIN_MACHO_ENTRY_CRC32 0x1e1a6ac8 -unsigned char stub_amd64_darwin_macho_entry[9066] = { +unsigned char stub_amd64_darwin_macho_entry[9467] = { /* 0x0000 */ 127, 69, 76, 70, 2, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0010 */ 1, 0, 62, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0020 */ 0, 0, 0, 0, 0, 0, 0, 0,248, 23, 0, 0, 0, 0, 0, 0, -/* 0x0030 */ 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 64, 0, 21, 0, 18, 0, -/* 0x0040 */ 232, 0, 0, 0, 0, 85, 83, 81, 82, 72, 1,254, 86, 72,137,254, -/* 0x0050 */ 72,137,215, 49,219, 49,201, 72,131,205,255,232, 80, 0, 0, 0, -/* 0x0060 */ 1,219,116, 2,243,195,139, 30, 72,131,238,252, 17,219,138, 22, -/* 0x0070 */ 243,195, 72,141, 4, 47,131,249, 5,138, 16,118, 33, 72,131,253, -/* 0x0080 */ 252,119, 27,131,233, 4,139, 16, 72,131,192, 4,131,233, 4,137, -/* 0x0090 */ 23, 72,141,127, 4,115,239,131,193, 4,138, 16,116, 16, 72,255, -/* 0x00a0 */ 192,136, 23,131,233, 1,138, 16, 72,141,127, 1,117,240,243,195, -/* 0x00b0 */ 252, 65, 91, 65,128,248, 8,116, 13,233,172, 0, 0, 0, 72,255, -/* 0x00c0 */ 198,136, 23, 72,255,199,138, 22, 1,219,117, 10,139, 30, 72,131, -/* 0x00d0 */ 238,252, 17,219,138, 22,114,230,141, 65, 1,235, 7,255,200, 65, -/* 0x00e0 */ 255,211, 17,192, 65,255,211, 17,192, 1,219,117, 10,139, 30, 72, -/* 0x00f0 */ 131,238,252, 17,219,138, 22,115,228,131,232, 3,114, 29,193,224, -/* 0x0100 */ 8, 15,182,210, 9,208, 72,255,198,131,240,255, 15,132, 0, 0, -/* 0x0110 */ 0, 0,209,248, 72, 99,232,114, 56,235, 14, 1,219,117, 8,139, -/* 0x0120 */ 30, 72,131,238,252, 17,219,114, 40,255,193, 1,219,117, 8,139, -/* 0x0130 */ 30, 72,131,238,252, 17,219,114, 24, 65,255,211, 17,201, 1,219, -/* 0x0140 */ 117, 8,139, 30, 72,131,238,252, 17,219,115,237,131,193, 2,235, -/* 0x0150 */ 5, 65,255,211, 17,201, 72,129,253, 0,251,255,255,131,209, 2, -/* 0x0160 */ 232, 0, 0, 0, 0,233, 92,255,255,255, 65,128,248, 5,116, 13, -/* 0x0170 */ 233,147, 0, 0, 0, 72,255,198,136, 23, 72,255,199,138, 22, 1, -/* 0x0180 */ 219,117, 10,139, 30, 72,131,238,252, 17,219,138, 22,114,230,141, -/* 0x0190 */ 65, 1,235, 7,255,200, 65,255,211, 17,192, 65,255,211, 17,192, -/* 0x01a0 */ 1,219,117, 10,139, 30, 72,131,238,252, 17,219,138, 22,115,228, -/* 0x01b0 */ 131,232, 3,114, 27,193,224, 8, 15,182,210, 9,208, 72,255,198, -/* 0x01c0 */ 131,240,255, 15,132, 0, 0, 0, 0,209,248, 72, 99,232,235, 3, -/* 0x01d0 */ 65,255,211, 17,201, 65,255,211, 17,201,117, 24,255,193, 65,255, -/* 0x01e0 */ 211, 17,201, 1,219,117, 8,139, 30, 72,131,238,252, 17,219,115, -/* 0x01f0 */ 237,131,193, 2, 72,129,253, 0,251,255,255,131,209, 1,232, 0, -/* 0x0200 */ 0, 0, 0,233,117,255,255,255, 65,128,248, 2,116, 13,233,133, -/* 0x0210 */ 0, 0, 0, 72,255,198,136, 23, 72,255,199,138, 22, 1,219,117, -/* 0x0220 */ 10,139, 30, 72,131,238,252, 17,219,138, 22,114,230,141, 65, 1, -/* 0x0230 */ 65,255,211, 17,192, 1,219,117, 10,139, 30, 72,131,238,252, 17, -/* 0x0240 */ 219,138, 22,115,235,131,232, 3,114, 23,193,224, 8, 15,182,210, -/* 0x0250 */ 9,208, 72,255,198,131,240,255, 15,132, 0, 0, 0, 0, 72, 99, -/* 0x0260 */ 232,141, 65, 1, 65,255,211, 17,201, 65,255,211, 17,201,117, 24, -/* 0x0270 */ 137,193,131,192, 2, 65,255,211, 17,201, 1,219,117, 8,139, 30, -/* 0x0280 */ 72,131,238,252, 17,219,115,237, 72,129,253, 0,243,255,255, 17, -/* 0x0290 */ 193,232, 0, 0, 0, 0,235,131, 65,128,248, 14, 15,133, 0, 0, -/* 0x02a0 */ 0, 0, 85, 72,137,229, 68,139, 9, 73,137,208, 72,137,242, 72, -/* 0x02b0 */ 141,119, 2, 86,138, 7,255,202,136,193, 36, 7,192,233, 3, 72, -/* 0x02c0 */ 199,195, 0,253,255,255, 72,211,227,136,193, 72,141,156, 92,136, -/* 0x02d0 */ 241,255,255, 72,131,227,192,106, 0, 72, 57,220,117,249, 83, 72, -/* 0x02e0 */ 141,123, 8,138, 78,255,255,202,136, 71, 2,136,200,192,233, 4, -/* 0x02f0 */ 136, 79, 1, 36, 15,136, 7, 72,141, 79,252, 80, 65, 87, 72,141, -/* 0x0300 */ 71, 4, 69, 49,255, 65, 86, 65,190, 1, 0, 0, 0, 65, 85, 69, -/* 0x0310 */ 49,237, 65, 84, 85, 83, 72,137, 76, 36,240, 72,137, 68, 36,216, -/* 0x0320 */ 184, 1, 0, 0, 0, 72,137,116, 36,248, 76,137, 68, 36,232,137, -/* 0x0330 */ 195, 68,137, 76, 36,228, 15,182, 79, 2,211,227,137,217, 72,139, -/* 0x0340 */ 92, 36, 56,255,201,137, 76, 36,212, 15,182, 79, 1,211,224, 72, -/* 0x0350 */ 139, 76, 36,240,255,200,137, 68, 36,208, 15,182, 7,199, 1, 0, -/* 0x0360 */ 0, 0, 0,199, 68, 36,200, 0, 0, 0, 0,199, 68, 36,196, 1, -/* 0x0370 */ 0, 0, 0,199, 68, 36,192, 1, 0, 0, 0,199, 68, 36,188, 1, -/* 0x0380 */ 0, 0, 0,199, 3, 0, 0, 0, 0,137, 68, 36,204, 15,182, 79, -/* 0x0390 */ 1, 1,193,184, 0, 3, 0, 0,211,224, 49,201,141,184, 54, 7, -/* 0x03a0 */ 0, 0, 65, 57,255,115, 19, 72,139, 92, 36,216,137,200,255,193, -/* 0x03b0 */ 57,249,102,199, 4, 67, 0, 4,235,235, 72,139,124, 36,248,137, -/* 0x03c0 */ 208, 69, 49,210, 65,131,203,255, 49,210, 73,137,252, 73, 1,196, -/* 0x03d0 */ 76, 57,231, 15,132,239, 8, 0, 0, 15,182, 7, 65,193,226, 8, -/* 0x03e0 */ 255,194, 72,255,199, 65, 9,194,131,250, 4,126,227, 68, 59,124, -/* 0x03f0 */ 36,228, 15,131,218, 8, 0, 0,139, 68, 36,212, 72, 99, 92, 36, -/* 0x0400 */ 200, 72,139, 84, 36,216, 68, 33,248,137, 68, 36,184, 72, 99,108, -/* 0x0410 */ 36,184, 72,137,216, 72,193,224, 4, 72, 1,232, 65,129,251,255, -/* 0x0420 */ 255,255, 0, 76,141, 12, 66,119, 26, 76, 57,231, 15,132,150, 8, -/* 0x0430 */ 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, -/* 0x0440 */ 65, 9,194, 65, 15,183, 17, 68,137,216,193,232, 11, 15,183,202, -/* 0x0450 */ 15,175,193, 65, 57,194, 15,131,197, 1, 0, 0, 65,137,195,184, -/* 0x0460 */ 0, 8, 0, 0, 72,139, 92, 36,216, 41,200, 15,182, 76, 36,204, -/* 0x0470 */ 190, 1, 0, 0, 0,193,248, 5,141, 4, 2, 65, 15,182,213,102, -/* 0x0480 */ 65,137, 1,139, 68, 36,208, 68, 33,248,211,224,185, 8, 0, 0, -/* 0x0490 */ 0, 43, 76, 36,204,211,250, 1,208,105,192, 0, 3, 0, 0,131, -/* 0x04a0 */ 124, 36,200, 6,137,192, 76,141,140, 67,108, 14, 0, 0, 15,142, -/* 0x04b0 */ 184, 0, 0, 0, 72,139, 84, 36,232, 68,137,248, 68, 41,240, 15, -/* 0x04c0 */ 182, 44, 2, 1,237, 72, 99,214,137,235,129,227, 0, 1, 0, 0, -/* 0x04d0 */ 65,129,251,255,255,255, 0, 72, 99,195, 73,141, 4, 65, 76,141, -/* 0x04e0 */ 4, 80,119, 26, 76, 57,231, 15,132,219, 7, 0, 0, 15,182, 7, -/* 0x04f0 */ 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, 65, 15, -/* 0x0500 */ 183,144, 0, 2, 0, 0, 68,137,216,193,232, 11, 15,183,202, 15, -/* 0x0510 */ 175,193, 65, 57,194,115, 32, 65,137,195,184, 0, 8, 0, 0, 1, -/* 0x0520 */ 246, 41,200,193,248, 5,133,219,141, 4, 2,102, 65,137,128, 0, -/* 0x0530 */ 2, 0, 0,116, 33,235, 45, 65, 41,195, 65, 41,194,137,208,102, -/* 0x0540 */ 193,232, 5,141,116, 54, 1,102, 41,194,133,219,102, 65,137,144, -/* 0x0550 */ 0, 2, 0, 0,116, 14,129,254,255, 0, 0, 0, 15,142, 97,255, -/* 0x0560 */ 255,255,235,120,129,254,255, 0, 0, 0,127,112, 72, 99,198, 65, -/* 0x0570 */ 129,251,255,255,255, 0, 77,141, 4, 65,119, 26, 76, 57,231, 15, -/* 0x0580 */ 132, 67, 7, 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, -/* 0x0590 */ 72,255,199, 65, 9,194, 65, 15,183, 16, 68,137,216,193,232, 11, -/* 0x05a0 */ 15,183,202, 15,175,193, 65, 57,194,115, 24, 65,137,195,184, 0, -/* 0x05b0 */ 8, 0, 0, 1,246, 41,200,193,248, 5,141, 4, 2,102, 65,137, -/* 0x05c0 */ 0,235,161, 65, 41,195, 65, 41,194,137,208,102,193,232, 5,141, -/* 0x05d0 */ 116, 54, 1,102, 41,194,102, 65,137, 16,235,136, 72,139, 76, 36, -/* 0x05e0 */ 232, 68,137,248, 65,255,199, 65,137,245, 64,136, 52, 1,131,124, -/* 0x05f0 */ 36,200, 3,127, 13,199, 68, 36,200, 0, 0, 0, 0,233,166, 6, -/* 0x0600 */ 0, 0,139, 84, 36,200,139, 68, 36,200,131,234, 3,131,232, 6, -/* 0x0610 */ 131,124, 36,200, 9, 15, 79,208,137, 84, 36,200,233,135, 6, 0, -/* 0x0620 */ 0, 65, 41,195, 65, 41,194,137,208,102,193,232, 5,102, 41,194, -/* 0x0630 */ 72,139, 68, 36,216, 65,129,251,255,255,255, 0,102, 65,137, 17, -/* 0x0640 */ 72,141, 52, 88,119, 26, 76, 57,231, 15,132,121, 6, 0, 0, 15, -/* 0x0650 */ 182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, -/* 0x0660 */ 15,183,150,128, 1, 0, 0, 68,137,216,193,232, 11, 15,183,202, -/* 0x0670 */ 15,175,193, 65, 57,194,115, 78, 65,137,195,184, 0, 8, 0, 0, -/* 0x0680 */ 76,139, 76, 36,216, 41,200,139, 76, 36,196, 68,137,116, 36,196, -/* 0x0690 */ 193,248, 5,141, 4, 2,139, 84, 36,192,137, 76, 36,192,102,137, -/* 0x06a0 */ 134,128, 1, 0, 0, 49,192,131,124, 36,200, 6,137, 84, 36,188, -/* 0x06b0 */ 15,159,192, 73,129,193,100, 6, 0, 0,141, 4, 64,137, 68, 36, -/* 0x06c0 */ 200,233, 84, 2, 0, 0, 65, 41,195, 65, 41,194,137,208,102,193, -/* 0x06d0 */ 232, 5,102, 41,194, 65,129,251,255,255,255, 0,102,137,150,128, -/* 0x06e0 */ 1, 0, 0,119, 26, 76, 57,231, 15,132,218, 5, 0, 0, 15,182, -/* 0x06f0 */ 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, 15, -/* 0x0700 */ 183,150,152, 1, 0, 0, 68,137,216,193,232, 11, 15,183,202, 15, -/* 0x0710 */ 175,193, 65, 57,194, 15,131,208, 0, 0, 0, 65,184, 0, 8, 0, -/* 0x0720 */ 0, 65,137,195, 72,193,227, 5, 68,137,192, 41,200,193,248, 5, -/* 0x0730 */ 141, 4, 2,102,137,134,152, 1, 0, 0, 72,139, 68, 36,216, 72, -/* 0x0740 */ 1,216, 65,129,251,255,255,255, 0, 72,141, 52,104,119, 26, 76, -/* 0x0750 */ 57,231, 15,132,112, 5, 0, 0, 15,182, 7, 65,193,226, 8, 65, -/* 0x0760 */ 193,227, 8, 72,255,199, 65, 9,194, 15,183,150,224, 1, 0, 0, -/* 0x0770 */ 68,137,216,193,232, 11, 15,183,202, 15,175,193, 65, 57,194,115, -/* 0x0780 */ 79, 65, 41,200, 65,137,195, 65,193,248, 5, 69,133,255, 66,141, -/* 0x0790 */ 4, 2,102,137,134,224, 1, 0, 0, 15,132, 41, 5, 0, 0, 49, -/* 0x07a0 */ 192,131,124, 36,200, 6, 72,139, 92, 36,232, 15,159,192,141, 68, -/* 0x07b0 */ 0, 9,137, 68, 36,200, 68,137,248, 68, 41,240, 68, 15,182, 44, -/* 0x07c0 */ 3, 68,137,248, 65,255,199, 68,136, 44, 3,233,216, 4, 0, 0, -/* 0x07d0 */ 65, 41,195, 65, 41,194,137,208,102,193,232, 5,102, 41,194,102, -/* 0x07e0 */ 137,150,224, 1, 0, 0,233, 17, 1, 0, 0, 65, 41,195, 65, 41, -/* 0x07f0 */ 194,137,208,102,193,232, 5,102, 41,194, 65,129,251,255,255,255, -/* 0x0800 */ 0,102,137,150,152, 1, 0, 0,119, 26, 76, 57,231, 15,132,181, -/* 0x0810 */ 4, 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72,255, -/* 0x0820 */ 199, 65, 9,194, 15,183,150,176, 1, 0, 0, 68,137,216,193,232, -/* 0x0830 */ 11, 15,183,202, 15,175,193, 65, 57,194,115, 32, 65,137,195,184, -/* 0x0840 */ 0, 8, 0, 0, 41,200,193,248, 5,141, 4, 2,102,137,134,176, -/* 0x0850 */ 1, 0, 0,139, 68, 36,196,233,152, 0, 0, 0, 65, 41,195, 65, -/* 0x0860 */ 41,194,137,208,102,193,232, 5,102, 41,194, 65,129,251,255,255, -/* 0x0870 */ 255, 0,102,137,150,176, 1, 0, 0,119, 26, 76, 57,231, 15,132, -/* 0x0880 */ 68, 4, 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72, -/* 0x0890 */ 255,199, 65, 9,194, 15,183,150,200, 1, 0, 0, 68,137,216,193, -/* 0x08a0 */ 232, 11, 15,183,202, 15,175,193, 65, 57,194,115, 29, 65,137,195, -/* 0x08b0 */ 184, 0, 8, 0, 0, 41,200,193,248, 5,141, 4, 2,102,137,134, -/* 0x08c0 */ 200, 1, 0, 0,139, 68, 36,192,235, 34, 65, 41,195, 65, 41,194, -/* 0x08d0 */ 137,208,102,193,232, 5,102, 41,194,139, 68, 36,188,102,137,150, -/* 0x08e0 */ 200, 1, 0, 0,139, 84, 36,192,137, 84, 36,188,139, 76, 36,196, -/* 0x08f0 */ 137, 76, 36,192, 68,137,116, 36,196, 65,137,198, 49,192,131,124, -/* 0x0900 */ 36,200, 6, 76,139, 76, 36,216, 15,159,192, 73,129,193,104, 10, -/* 0x0910 */ 0, 0,141, 68, 64, 8,137, 68, 36,200, 65,129,251,255,255,255, -/* 0x0920 */ 0,119, 26, 76, 57,231, 15,132,156, 3, 0, 0, 15,182, 7, 65, -/* 0x0930 */ 193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, 65, 15,183, -/* 0x0940 */ 17, 68,137,216,193,232, 11, 15,183,202, 15,175,193, 65, 57,194, -/* 0x0950 */ 115, 39, 65,137,195,184, 0, 8, 0, 0, 69, 49,237, 41,200,193, -/* 0x0960 */ 248, 5,141, 4, 2,102, 65,137, 1, 72, 99, 68, 36,184, 72,193, -/* 0x0970 */ 224, 4, 77,141, 68, 1, 4,235,120, 65, 41,195, 65, 41,194,137, -/* 0x0980 */ 208,102,193,232, 5,102, 41,194, 65,129,251,255,255,255, 0,102, -/* 0x0990 */ 65,137, 17,119, 26, 76, 57,231, 15,132, 42, 3, 0, 0, 15,182, -/* 0x09a0 */ 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, 65, -/* 0x09b0 */ 15,183, 81, 2, 68,137,216,193,232, 11, 15,183,202, 15,175,193, -/* 0x09c0 */ 65, 57,194,115, 52, 65,137,195,184, 0, 8, 0, 0, 65,189, 8, -/* 0x09d0 */ 0, 0, 0, 41,200,193,248, 5,141, 4, 2,102, 65,137, 65, 2, -/* 0x09e0 */ 72, 99, 68, 36,184, 72,193,224, 4, 77,141,132, 1, 4, 1, 0, -/* 0x09f0 */ 0, 65,185, 3, 0, 0, 0,235, 39, 65, 41,195, 65, 41,194,137, -/* 0x0a00 */ 208,102,193,232, 5, 77,141,129, 4, 2, 0, 0, 65,189, 16, 0, -/* 0x0a10 */ 0, 0,102, 41,194,102, 65,137, 81, 2, 65,185, 8, 0, 0, 0, -/* 0x0a20 */ 68,137,203,189, 1, 0, 0, 0, 72, 99,197, 65,129,251,255,255, -/* 0x0a30 */ 255, 0, 73,141, 52, 64,119, 26, 76, 57,231, 15,132,135, 2, 0, -/* 0x0a40 */ 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, -/* 0x0a50 */ 9,194, 15,183, 14, 68,137,216,193,232, 11, 15,183,209, 15,175, -/* 0x0a60 */ 194, 65, 57,194,115, 23, 65,137,195,184, 0, 8, 0, 0, 1,237, -/* 0x0a70 */ 41,208,193,248, 5,141, 4, 1,102,137, 6,235, 22, 65, 41,195, -/* 0x0a80 */ 65, 41,194,137,200,102,193,232, 5,141,108, 45, 1,102, 41,193, -/* 0x0a90 */ 102,137, 14,255,203,117,145,184, 1, 0, 0, 0, 68,137,201,211, -/* 0x0aa0 */ 224, 41,197, 68, 1,237,131,124, 36,200, 3, 15,143,194, 1, 0, -/* 0x0ab0 */ 0,131, 68, 36,200, 7,184, 3, 0, 0, 0,131,253, 4, 15, 76, -/* 0x0ac0 */ 197, 72,139, 92, 36,216, 65,184, 1, 0, 0, 0, 72,152, 72,193, -/* 0x0ad0 */ 224, 7, 76,141,140, 3, 96, 3, 0, 0,187, 6, 0, 0, 0, 73, -/* 0x0ae0 */ 99,192, 65,129,251,255,255,255, 0, 73,141, 52, 65,119, 26, 76, -/* 0x0af0 */ 57,231, 15,132,208, 1, 0, 0, 15,182, 7, 65,193,226, 8, 65, -/* 0x0b00 */ 193,227, 8, 72,255,199, 65, 9,194, 15,183, 22, 68,137,216,193, -/* 0x0b10 */ 232, 11, 15,183,202, 15,175,193, 65, 57,194,115, 24, 65,137,195, -/* 0x0b20 */ 184, 0, 8, 0, 0, 69, 1,192, 41,200,193,248, 5,141, 4, 2, -/* 0x0b30 */ 102,137, 6,235, 23, 65, 41,195, 65, 41,194,137,208,102,193,232, -/* 0x0b40 */ 5, 71,141, 68, 0, 1,102, 41,194,102,137, 22,255,203,117,143, -/* 0x0b50 */ 65,131,232, 64, 65,131,248, 3, 69,137,198, 15,142, 13, 1, 0, -/* 0x0b60 */ 0, 65,131,230, 1, 68,137,192,209,248, 65,131,206, 2, 65,131, -/* 0x0b70 */ 248, 13,141,112,255,127, 35,137,241, 72,139, 92, 36,216, 73, 99, -/* 0x0b80 */ 192, 65,211,230, 72, 1,192, 68,137,242, 72,141, 20, 83, 72, 41, -/* 0x0b90 */ 194, 76,141,138, 94, 5, 0, 0,235, 81,141,112,251, 65,129,251, -/* 0x0ba0 */ 255,255,255, 0,119, 26, 76, 57,231, 15,132, 25, 1, 0, 0, 15, -/* 0x0bb0 */ 182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, -/* 0x0bc0 */ 65,209,235, 69, 1,246, 69, 57,218,114, 7, 69, 41,218, 65,131, -/* 0x0bd0 */ 206, 1,255,206,117,199, 76,139, 76, 36,216, 65,193,230, 4,190, -/* 0x0be0 */ 4, 0, 0, 0, 73,129,193, 68, 6, 0, 0, 65,189, 1, 0, 0, -/* 0x0bf0 */ 0,187, 1, 0, 0, 0, 72, 99,195, 65,129,251,255,255,255, 0, -/* 0x0c00 */ 77,141, 4, 65,119, 26, 76, 57,231, 15,132,185, 0, 0, 0, 15, -/* 0x0c10 */ 182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, -/* 0x0c20 */ 65, 15,183, 16, 68,137,216,193,232, 11, 15,183,202, 15,175,193, -/* 0x0c30 */ 65, 57,194,115, 24, 65,137,195,184, 0, 8, 0, 0, 1,219, 41, -/* 0x0c40 */ 200,193,248, 5,141, 4, 2,102, 65,137, 0,235, 26, 65, 41,195, -/* 0x0c50 */ 65, 41,194,137,208,102,193,232, 5,141, 92, 27, 1, 69, 9,238, -/* 0x0c60 */ 102, 41,194,102, 65,137, 16, 69, 1,237,255,206,117,136, 65,255, -/* 0x0c70 */ 198,116, 64,131,197, 2, 69, 57,254,119, 77, 72,139, 84, 36,232, -/* 0x0c80 */ 68,137,248, 68, 41,240, 68, 15,182, 44, 2, 68,137,248, 65,255, -/* 0x0c90 */ 199,255,205, 68,136, 44, 2, 15,149,194, 49,192, 68, 59,124, 36, -/* 0x0ca0 */ 228, 15,146,192,133,194,117,211, 68, 59,124, 36,228, 15,130, 69, -/* 0x0cb0 */ 247,255,255, 65,129,251,255,255,255, 0,119, 22, 76, 57,231,184, -/* 0x0cc0 */ 1, 0, 0, 0,116, 35,235, 7,184, 1, 0, 0, 0,235, 26, 72, -/* 0x0cd0 */ 255,199,137,248, 43, 68, 36,248, 72,139, 76, 36,240, 72,139, 92, -/* 0x0ce0 */ 36, 56,137, 1, 68,137, 59, 49,192, 91, 93, 65, 92, 65, 93, 65, -/* 0x0cf0 */ 94, 65, 95, 65, 87, 72,141, 71, 4, 69, 49,255, 65, 86, 65,190, -/* 0x0d00 */ 1, 0, 0, 0, 65, 85, 69, 49,237, 65, 84, 85, 83, 72,137, 76, -/* 0x0d10 */ 36,240, 72,137, 68, 36,216,184, 1, 0, 0, 0, 72,137,116, 36, -/* 0x0d20 */ 248, 76,137, 68, 36,232,137,195, 68,137, 76, 36,228, 15,182, 79, -/* 0x0d30 */ 2,211,227,137,217, 72,139, 92, 36, 56,255,201,137, 76, 36,212, -/* 0x0d40 */ 15,182, 79, 1,211,224, 72,139, 76, 36,240,255,200,137, 68, 36, -/* 0x0d50 */ 208, 15,182, 7,199, 1, 0, 0, 0, 0,199, 68, 36,200, 0, 0, -/* 0x0d60 */ 0, 0,199, 68, 36,196, 1, 0, 0, 0,199, 68, 36,192, 1, 0, -/* 0x0d70 */ 0, 0,199, 68, 36,188, 1, 0, 0, 0,199, 3, 0, 0, 0, 0, -/* 0x0d80 */ 137, 68, 36,204, 15,182, 79, 1, 1,193,184, 0, 3, 0, 0,211, -/* 0x0d90 */ 224, 49,201,141,184, 54, 7, 0, 0, 65, 57,255,115, 19, 72,139, -/* 0x0da0 */ 92, 36,216,137,200,255,193, 57,249,102,199, 4, 67, 0, 4,235, -/* 0x0db0 */ 235, 72,139,124, 36,248,137,208, 69, 49,210, 65,131,203,255, 49, -/* 0x0dc0 */ 210, 73,137,252, 73, 1,196, 76, 57,231, 15,132,239, 8, 0, 0, -/* 0x0dd0 */ 15,182, 7, 65,193,226, 8,255,194, 72,255,199, 65, 9,194,131, -/* 0x0de0 */ 250, 4,126,227, 68, 59,124, 36,228, 15,131,218, 8, 0, 0,139, -/* 0x0df0 */ 68, 36,212, 72, 99, 92, 36,200, 72,139, 84, 36,216, 68, 33,248, -/* 0x0e00 */ 137, 68, 36,184, 72, 99,108, 36,184, 72,137,216, 72,193,224, 4, -/* 0x0e10 */ 72, 1,232, 65,129,251,255,255,255, 0, 76,141, 12, 66,119, 26, -/* 0x0e20 */ 76, 57,231, 15,132,150, 8, 0, 0, 15,182, 7, 65,193,226, 8, -/* 0x0e30 */ 65,193,227, 8, 72,255,199, 65, 9,194, 65, 15,183, 17, 68,137, -/* 0x0e40 */ 216,193,232, 11, 15,183,202, 15,175,193, 65, 57,194, 15,131,197, -/* 0x0e50 */ 1, 0, 0, 65,137,195,184, 0, 8, 0, 0, 72,139, 92, 36,216, -/* 0x0e60 */ 41,200, 15,182, 76, 36,204,190, 1, 0, 0, 0,193,248, 5,141, -/* 0x0e70 */ 4, 2, 65, 15,182,213,102, 65,137, 1,139, 68, 36,208, 68, 33, -/* 0x0e80 */ 248,211,224,185, 8, 0, 0, 0, 43, 76, 36,204,211,250, 1,208, -/* 0x0e90 */ 105,192, 0, 3, 0, 0,131,124, 36,200, 6,137,192, 76,141,140, -/* 0x0ea0 */ 67,108, 14, 0, 0, 15,142,184, 0, 0, 0, 72,139, 84, 36,232, -/* 0x0eb0 */ 68,137,248, 68, 41,240, 15,182, 44, 2, 1,237, 72, 99,214,137, -/* 0x0ec0 */ 235,129,227, 0, 1, 0, 0, 65,129,251,255,255,255, 0, 72, 99, -/* 0x0ed0 */ 195, 73,141, 4, 65, 76,141, 4, 80,119, 26, 76, 57,231, 15,132, -/* 0x0ee0 */ 219, 7, 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72, -/* 0x0ef0 */ 255,199, 65, 9,194, 65, 15,183,144, 0, 2, 0, 0, 68,137,216, -/* 0x0f00 */ 193,232, 11, 15,183,202, 15,175,193, 65, 57,194,115, 32, 65,137, -/* 0x0f10 */ 195,184, 0, 8, 0, 0, 1,246, 41,200,193,248, 5,133,219,141, -/* 0x0f20 */ 4, 2,102, 65,137,128, 0, 2, 0, 0,116, 33,235, 45, 65, 41, -/* 0x0f30 */ 195, 65, 41,194,137,208,102,193,232, 5,141,116, 54, 1,102, 41, -/* 0x0f40 */ 194,133,219,102, 65,137,144, 0, 2, 0, 0,116, 14,129,254,255, -/* 0x0f50 */ 0, 0, 0, 15,142, 97,255,255,255,235,120,129,254,255, 0, 0, -/* 0x0f60 */ 0,127,112, 72, 99,198, 65,129,251,255,255,255, 0, 77,141, 4, -/* 0x0f70 */ 65,119, 26, 76, 57,231, 15,132, 67, 7, 0, 0, 15,182, 7, 65, -/* 0x0f80 */ 193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, 65, 15,183, -/* 0x0f90 */ 16, 68,137,216,193,232, 11, 15,183,202, 15,175,193, 65, 57,194, -/* 0x0fa0 */ 115, 24, 65,137,195,184, 0, 8, 0, 0, 1,246, 41,200,193,248, -/* 0x0fb0 */ 5,141, 4, 2,102, 65,137, 0,235,161, 65, 41,195, 65, 41,194, -/* 0x0fc0 */ 137,208,102,193,232, 5,141,116, 54, 1,102, 41,194,102, 65,137, -/* 0x0fd0 */ 16,235,136, 72,139, 76, 36,232, 68,137,248, 65,255,199, 65,137, -/* 0x0fe0 */ 245, 64,136, 52, 1,131,124, 36,200, 3,127, 13,199, 68, 36,200, -/* 0x0ff0 */ 0, 0, 0, 0,233,166, 6, 0, 0,139, 84, 36,200,139, 68, 36, -/* 0x1000 */ 200,131,234, 3,131,232, 6,131,124, 36,200, 9, 15, 79,208,137, -/* 0x1010 */ 84, 36,200,233,135, 6, 0, 0, 65, 41,195, 65, 41,194,137,208, -/* 0x1020 */ 102,193,232, 5,102, 41,194, 72,139, 68, 36,216, 65,129,251,255, -/* 0x1030 */ 255,255, 0,102, 65,137, 17, 72,141, 52, 88,119, 26, 76, 57,231, -/* 0x1040 */ 15,132,121, 6, 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, -/* 0x1050 */ 8, 72,255,199, 65, 9,194, 15,183,150,128, 1, 0, 0, 68,137, -/* 0x1060 */ 216,193,232, 11, 15,183,202, 15,175,193, 65, 57,194,115, 78, 65, -/* 0x1070 */ 137,195,184, 0, 8, 0, 0, 76,139, 76, 36,216, 41,200,139, 76, -/* 0x1080 */ 36,196, 68,137,116, 36,196,193,248, 5,141, 4, 2,139, 84, 36, -/* 0x1090 */ 192,137, 76, 36,192,102,137,134,128, 1, 0, 0, 49,192,131,124, -/* 0x10a0 */ 36,200, 6,137, 84, 36,188, 15,159,192, 73,129,193,100, 6, 0, -/* 0x10b0 */ 0,141, 4, 64,137, 68, 36,200,233, 84, 2, 0, 0, 65, 41,195, -/* 0x10c0 */ 65, 41,194,137,208,102,193,232, 5,102, 41,194, 65,129,251,255, -/* 0x10d0 */ 255,255, 0,102,137,150,128, 1, 0, 0,119, 26, 76, 57,231, 15, -/* 0x10e0 */ 132,218, 5, 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, -/* 0x10f0 */ 72,255,199, 65, 9,194, 15,183,150,152, 1, 0, 0, 68,137,216, -/* 0x1100 */ 193,232, 11, 15,183,202, 15,175,193, 65, 57,194, 15,131,208, 0, -/* 0x1110 */ 0, 0, 65,184, 0, 8, 0, 0, 65,137,195, 72,193,227, 5, 68, -/* 0x1120 */ 137,192, 41,200,193,248, 5,141, 4, 2,102,137,134,152, 1, 0, -/* 0x1130 */ 0, 72,139, 68, 36,216, 72, 1,216, 65,129,251,255,255,255, 0, -/* 0x1140 */ 72,141, 52,104,119, 26, 76, 57,231, 15,132,112, 5, 0, 0, 15, -/* 0x1150 */ 182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, -/* 0x1160 */ 15,183,150,224, 1, 0, 0, 68,137,216,193,232, 11, 15,183,202, -/* 0x1170 */ 15,175,193, 65, 57,194,115, 79, 65, 41,200, 65,137,195, 65,193, -/* 0x1180 */ 248, 5, 69,133,255, 66,141, 4, 2,102,137,134,224, 1, 0, 0, -/* 0x1190 */ 15,132, 41, 5, 0, 0, 49,192,131,124, 36,200, 6, 72,139, 92, -/* 0x11a0 */ 36,232, 15,159,192,141, 68, 0, 9,137, 68, 36,200, 68,137,248, -/* 0x11b0 */ 68, 41,240, 68, 15,182, 44, 3, 68,137,248, 65,255,199, 68,136, -/* 0x11c0 */ 44, 3,233,216, 4, 0, 0, 65, 41,195, 65, 41,194,137,208,102, -/* 0x11d0 */ 193,232, 5,102, 41,194,102,137,150,224, 1, 0, 0,233, 17, 1, -/* 0x11e0 */ 0, 0, 65, 41,195, 65, 41,194,137,208,102,193,232, 5,102, 41, -/* 0x11f0 */ 194, 65,129,251,255,255,255, 0,102,137,150,152, 1, 0, 0,119, -/* 0x1200 */ 26, 76, 57,231, 15,132,181, 4, 0, 0, 15,182, 7, 65,193,226, -/* 0x1210 */ 8, 65,193,227, 8, 72,255,199, 65, 9,194, 15,183,150,176, 1, -/* 0x1220 */ 0, 0, 68,137,216,193,232, 11, 15,183,202, 15,175,193, 65, 57, -/* 0x1230 */ 194,115, 32, 65,137,195,184, 0, 8, 0, 0, 41,200,193,248, 5, -/* 0x1240 */ 141, 4, 2,102,137,134,176, 1, 0, 0,139, 68, 36,196,233,152, -/* 0x1250 */ 0, 0, 0, 65, 41,195, 65, 41,194,137,208,102,193,232, 5,102, -/* 0x1260 */ 41,194, 65,129,251,255,255,255, 0,102,137,150,176, 1, 0, 0, -/* 0x1270 */ 119, 26, 76, 57,231, 15,132, 68, 4, 0, 0, 15,182, 7, 65,193, -/* 0x1280 */ 226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, 15,183,150,200, -/* 0x1290 */ 1, 0, 0, 68,137,216,193,232, 11, 15,183,202, 15,175,193, 65, -/* 0x12a0 */ 57,194,115, 29, 65,137,195,184, 0, 8, 0, 0, 41,200,193,248, -/* 0x12b0 */ 5,141, 4, 2,102,137,134,200, 1, 0, 0,139, 68, 36,192,235, -/* 0x12c0 */ 34, 65, 41,195, 65, 41,194,137,208,102,193,232, 5,102, 41,194, -/* 0x12d0 */ 139, 68, 36,188,102,137,150,200, 1, 0, 0,139, 84, 36,192,137, -/* 0x12e0 */ 84, 36,188,139, 76, 36,196,137, 76, 36,192, 68,137,116, 36,196, -/* 0x12f0 */ 65,137,198, 49,192,131,124, 36,200, 6, 76,139, 76, 36,216, 15, -/* 0x1300 */ 159,192, 73,129,193,104, 10, 0, 0,141, 68, 64, 8,137, 68, 36, -/* 0x1310 */ 200, 65,129,251,255,255,255, 0,119, 26, 76, 57,231, 15,132,156, -/* 0x1320 */ 3, 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72,255, -/* 0x1330 */ 199, 65, 9,194, 65, 15,183, 17, 68,137,216,193,232, 11, 15,183, -/* 0x1340 */ 202, 15,175,193, 65, 57,194,115, 39, 65,137,195,184, 0, 8, 0, -/* 0x1350 */ 0, 69, 49,237, 41,200,193,248, 5,141, 4, 2,102, 65,137, 1, -/* 0x1360 */ 72, 99, 68, 36,184, 72,193,224, 4, 77,141, 68, 1, 4,235,120, -/* 0x1370 */ 65, 41,195, 65, 41,194,137,208,102,193,232, 5,102, 41,194, 65, -/* 0x1380 */ 129,251,255,255,255, 0,102, 65,137, 17,119, 26, 76, 57,231, 15, -/* 0x1390 */ 132, 42, 3, 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, -/* 0x13a0 */ 72,255,199, 65, 9,194, 65, 15,183, 81, 2, 68,137,216,193,232, -/* 0x13b0 */ 11, 15,183,202, 15,175,193, 65, 57,194,115, 52, 65,137,195,184, -/* 0x13c0 */ 0, 8, 0, 0, 65,189, 8, 0, 0, 0, 41,200,193,248, 5,141, -/* 0x13d0 */ 4, 2,102, 65,137, 65, 2, 72, 99, 68, 36,184, 72,193,224, 4, -/* 0x13e0 */ 77,141,132, 1, 4, 1, 0, 0, 65,185, 3, 0, 0, 0,235, 39, -/* 0x13f0 */ 65, 41,195, 65, 41,194,137,208,102,193,232, 5, 77,141,129, 4, -/* 0x1400 */ 2, 0, 0, 65,189, 16, 0, 0, 0,102, 41,194,102, 65,137, 81, -/* 0x1410 */ 2, 65,185, 8, 0, 0, 0, 68,137,203,189, 1, 0, 0, 0, 72, -/* 0x1420 */ 99,197, 65,129,251,255,255,255, 0, 73,141, 52, 64,119, 26, 76, -/* 0x1430 */ 57,231, 15,132,135, 2, 0, 0, 15,182, 7, 65,193,226, 8, 65, -/* 0x1440 */ 193,227, 8, 72,255,199, 65, 9,194, 15,183, 14, 68,137,216,193, -/* 0x1450 */ 232, 11, 15,183,209, 15,175,194, 65, 57,194,115, 23, 65,137,195, -/* 0x1460 */ 184, 0, 8, 0, 0, 1,237, 41,208,193,248, 5,141, 4, 1,102, -/* 0x1470 */ 137, 6,235, 22, 65, 41,195, 65, 41,194,137,200,102,193,232, 5, -/* 0x1480 */ 141,108, 45, 1,102, 41,193,102,137, 14,255,203,117,145,184, 1, -/* 0x1490 */ 0, 0, 0, 68,137,201,211,224, 41,197, 68, 1,237,131,124, 36, -/* 0x14a0 */ 200, 3, 15,143,194, 1, 0, 0,131, 68, 36,200, 7,184, 3, 0, -/* 0x14b0 */ 0, 0,131,253, 4, 15, 76,197, 72,139, 92, 36,216, 65,184, 1, -/* 0x14c0 */ 0, 0, 0, 72,152, 72,193,224, 7, 76,141,140, 3, 96, 3, 0, -/* 0x14d0 */ 0,187, 6, 0, 0, 0, 73, 99,192, 65,129,251,255,255,255, 0, -/* 0x14e0 */ 73,141, 52, 65,119, 26, 76, 57,231, 15,132,208, 1, 0, 0, 15, -/* 0x14f0 */ 182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, -/* 0x1500 */ 15,183, 22, 68,137,216,193,232, 11, 15,183,202, 15,175,193, 65, -/* 0x1510 */ 57,194,115, 24, 65,137,195,184, 0, 8, 0, 0, 69, 1,192, 41, -/* 0x1520 */ 200,193,248, 5,141, 4, 2,102,137, 6,235, 23, 65, 41,195, 65, -/* 0x1530 */ 41,194,137,208,102,193,232, 5, 71,141, 68, 0, 1,102, 41,194, -/* 0x1540 */ 102,137, 22,255,203,117,143, 65,131,232, 64, 65,131,248, 3, 69, -/* 0x1550 */ 137,198, 15,142, 13, 1, 0, 0, 65,131,230, 1, 68,137,192,209, -/* 0x1560 */ 248, 65,131,206, 2, 65,131,248, 13,141,112,255,127, 35,137,241, -/* 0x1570 */ 72,139, 92, 36,216, 73, 99,192, 65,211,230, 72, 1,192, 68,137, -/* 0x1580 */ 242, 72,141, 20, 83, 72, 41,194, 76,141,138, 94, 5, 0, 0,235, -/* 0x1590 */ 81,141,112,251, 65,129,251,255,255,255, 0,119, 26, 76, 57,231, -/* 0x15a0 */ 15,132, 25, 1, 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, -/* 0x15b0 */ 8, 72,255,199, 65, 9,194, 65,209,235, 69, 1,246, 69, 57,218, -/* 0x15c0 */ 114, 7, 69, 41,218, 65,131,206, 1,255,206,117,199, 76,139, 76, -/* 0x15d0 */ 36,216, 65,193,230, 4,190, 4, 0, 0, 0, 73,129,193, 68, 6, -/* 0x15e0 */ 0, 0, 65,189, 1, 0, 0, 0,187, 1, 0, 0, 0, 72, 99,195, -/* 0x15f0 */ 65,129,251,255,255,255, 0, 77,141, 4, 65,119, 26, 76, 57,231, -/* 0x1600 */ 15,132,185, 0, 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, -/* 0x1610 */ 8, 72,255,199, 65, 9,194, 65, 15,183, 16, 68,137,216,193,232, -/* 0x1620 */ 11, 15,183,202, 15,175,193, 65, 57,194,115, 24, 65,137,195,184, -/* 0x1630 */ 0, 8, 0, 0, 1,219, 41,200,193,248, 5,141, 4, 2,102, 65, -/* 0x1640 */ 137, 0,235, 26, 65, 41,195, 65, 41,194,137,208,102,193,232, 5, -/* 0x1650 */ 141, 92, 27, 1, 69, 9,238,102, 41,194,102, 65,137, 16, 69, 1, -/* 0x1660 */ 237,255,206,117,136, 65,255,198,116, 64,131,197, 2, 69, 57,254, -/* 0x1670 */ 119, 77, 72,139, 84, 36,232, 68,137,248, 68, 41,240, 68, 15,182, -/* 0x1680 */ 44, 2, 68,137,248, 65,255,199,255,205, 68,136, 44, 2, 15,149, -/* 0x1690 */ 194, 49,192, 68, 59,124, 36,228, 15,146,192,133,194,117,211, 68, -/* 0x16a0 */ 59,124, 36,228, 15,130, 69,247,255,255, 65,129,251,255,255,255, -/* 0x16b0 */ 0,119, 22, 76, 57,231,184, 1, 0, 0, 0,116, 35,235, 7,184, -/* 0x16c0 */ 1, 0, 0, 0,235, 26, 72,255,199,137,248, 43, 68, 36,248, 72, -/* 0x16d0 */ 139, 76, 36,240, 72,139, 92, 36, 56,137, 1, 68,137, 59, 49,192, -/* 0x16e0 */ 91, 93, 65, 92, 65, 93, 65, 94, 65, 95, 72,139,117,248, 72,139, -/* 0x16f0 */ 125, 16,139, 75, 4, 72, 1,206,139, 19, 72, 1,215,201, 89, 72, -/* 0x1700 */ 137,240, 72, 41,200, 90, 72, 41,215, 89,137, 57, 91, 93,195, 91, -/* 0x1710 */ 139, 75, 4, 72,141,116, 25, 11,139, 59, 72,141,188, 31,203, 0, -/* 0x1720 */ 0, 0,253,243,164, 72,141,147,128, 0, 0, 0, 72,137,222, 72, -/* 0x1730 */ 141,127, 1, 82,252,173, 80, 72,137,225,173, 80,173, 68, 15,182, -/* 0x1740 */ 192, 94,255,213, 89, 72,141, 93,247,195, 93,232,191,255,255,255, -/* 0x1750 */ 102,105,108,101, 32,102,111,114,109, 97,116, 32,101,108,102, 54, -/* 0x1760 */ 52, 45,120, 56, 54, 45, 54, 52, 10, 10, 83,101, 99,116,105,111, -/* 0x1770 */ 110,115, 58, 10, 73,100,120, 32, 78, 97,109,101, 32, 32, 32, 32, -/* 0x1780 */ 32, 32, 32, 32, 32, 32, 83,105,122,101, 32, 32, 32, 32, 32, 32, -/* 0x1790 */ 86, 77, 65, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, -/* 0x17a0 */ 32, 32, 76, 77, 65, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, -/* 0x17b0 */ 32, 32, 32, 32, 70,105,108,101, 32,111,102,102, 32, 32, 65,108, -/* 0x17c0 */ 103,110, 32, 32, 70,108, 97,103,115, 10, 32, 32, 48, 32, 77, 65, -/* 0x17d0 */ 67, 72, 77, 65, 73, 78, 88, 32, 32, 32, 32, 32, 48, 48, 48, 48, -/* 0x17e0 */ 48, 48, 48,100, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x17f0 */ 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1800 */ 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, -/* 0x1810 */ 52, 48, 32, 32, 50, 42, 42, 48, 32, 32, 67, 79, 78, 84, 69, 78, -/* 0x1820 */ 84, 83, 44, 32, 82, 69, 76, 79, 67, 44, 32, 82, 69, 65, 68, 79, -/* 0x1830 */ 78, 76, 89, 10, 32, 32, 49, 32, 78, 82, 86, 95, 72, 69, 65, 68, -/* 0x1840 */ 32, 32, 32, 32, 32, 32, 48, 48, 48, 48, 48, 48, 54, 54, 32, 32, -/* 0x1850 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1860 */ 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1870 */ 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, 52,100, 32, 32, 50, 42, -/* 0x1880 */ 42, 48, 32, 32, 67, 79, 78, 84, 69, 78, 84, 83, 44, 32, 82, 69, -/* 0x1890 */ 65, 68, 79, 78, 76, 89, 10, 32, 32, 50, 32, 78, 82, 86, 50, 69, -/* 0x18a0 */ 32, 32, 32, 32, 32, 32, 32, 32, 32, 48, 48, 48, 48, 48, 48, 98, -/* 0x18b0 */ 55, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x18c0 */ 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x18d0 */ 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, 98, 51, 32, -/* 0x18e0 */ 32, 50, 42, 42, 48, 32, 32, 67, 79, 78, 84, 69, 78, 84, 83, 44, -/* 0x18f0 */ 32, 82, 69, 76, 79, 67, 44, 32, 82, 69, 65, 68, 79, 78, 76, 89, -/* 0x1900 */ 10, 32, 32, 51, 32, 78, 82, 86, 50, 68, 32, 32, 32, 32, 32, 32, -/* 0x1910 */ 32, 32, 32, 48, 48, 48, 48, 48, 48, 57,101, 32, 32, 48, 48, 48, -/* 0x1920 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, -/* 0x1930 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, -/* 0x1940 */ 32, 48, 48, 48, 48, 48, 49, 54, 97, 32, 32, 50, 42, 42, 48, 32, -/* 0x1950 */ 32, 67, 79, 78, 84, 69, 78, 84, 83, 44, 32, 82, 69, 76, 79, 67, -/* 0x1960 */ 44, 32, 82, 69, 65, 68, 79, 78, 76, 89, 10, 32, 32, 52, 32, 78, -/* 0x1970 */ 82, 86, 50, 66, 32, 32, 32, 32, 32, 32, 32, 32, 32, 48, 48, 48, -/* 0x1980 */ 48, 48, 48, 57, 48, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1990 */ 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, 48, -/* 0x19a0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, -/* 0x19b0 */ 50, 48, 56, 32, 32, 50, 42, 42, 48, 32, 32, 67, 79, 78, 84, 69, -/* 0x19c0 */ 78, 84, 83, 44, 32, 82, 69, 76, 79, 67, 44, 32, 82, 69, 65, 68, -/* 0x19d0 */ 79, 78, 76, 89, 10, 32, 32, 53, 32, 76, 90, 77, 65, 95, 69, 76, -/* 0x19e0 */ 70, 48, 48, 32, 32, 32, 32, 48, 48, 48, 48, 48, 48, 54, 52, 32, -/* 0x19f0 */ 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1a00 */ 48, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1a10 */ 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 50, 57, 56, 32, 32, 50, -/* 0x1a20 */ 42, 42, 48, 32, 32, 67, 79, 78, 84, 69, 78, 84, 83, 44, 32, 82, -/* 0x1a30 */ 69, 76, 79, 67, 44, 32, 82, 69, 65, 68, 79, 78, 76, 89, 10, 32, -/* 0x1a40 */ 32, 54, 32, 76, 90, 77, 65, 95, 68, 69, 67, 49, 48, 32, 32, 32, -/* 0x1a50 */ 32, 48, 48, 48, 48, 48, 57,102, 55, 32, 32, 48, 48, 48, 48, 48, -/* 0x1a60 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, -/* 0x1a70 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, -/* 0x1a80 */ 48, 48, 48, 48, 50,102, 99, 32, 32, 50, 42, 42, 48, 32, 32, 67, -/* 0x1a90 */ 79, 78, 84, 69, 78, 84, 83, 44, 32, 82, 69, 65, 68, 79, 78, 76, -/* 0x1aa0 */ 89, 10, 32, 32, 55, 32, 76, 90, 77, 65, 95, 68, 69, 67, 50, 48, -/* 0x1ab0 */ 32, 32, 32, 32, 48, 48, 48, 48, 48, 57,102, 55, 32, 32, 48, 48, -/* 0x1ac0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, -/* 0x1ad0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1ae0 */ 32, 32, 48, 48, 48, 48, 48, 99,102, 51, 32, 32, 50, 42, 42, 48, -/* 0x1af0 */ 32, 32, 67, 79, 78, 84, 69, 78, 84, 83, 44, 32, 82, 69, 65, 68, -/* 0x1b00 */ 79, 78, 76, 89, 10, 32, 32, 56, 32, 76, 90, 77, 65, 95, 68, 69, -/* 0x1b10 */ 67, 51, 48, 32, 32, 32, 32, 48, 48, 48, 48, 48, 48, 49, 52, 32, -/* 0x1b20 */ 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1b30 */ 48, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1b40 */ 48, 48, 48, 32, 32, 48, 48, 48, 48, 49, 54,101, 97, 32, 32, 50, -/* 0x1b50 */ 42, 42, 48, 32, 32, 67, 79, 78, 84, 69, 78, 84, 83, 44, 32, 82, -/* 0x1b60 */ 69, 65, 68, 79, 78, 76, 89, 10, 32, 32, 57, 32, 78, 82, 86, 95, -/* 0x1b70 */ 84, 65, 73, 76, 32, 32, 32, 32, 32, 32, 48, 48, 48, 48, 48, 48, -/* 0x1b80 */ 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1b90 */ 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1ba0 */ 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 49, 54,102,101, -/* 0x1bb0 */ 32, 32, 50, 42, 42, 48, 32, 32, 67, 79, 78, 84, 69, 78, 84, 83, -/* 0x1bc0 */ 44, 32, 82, 69, 65, 68, 79, 78, 76, 89, 10, 32, 49, 48, 32, 77, -/* 0x1bd0 */ 65, 67, 72, 77, 65, 73, 78, 89, 32, 32, 32, 32, 32, 48, 48, 48, -/* 0x1be0 */ 48, 48, 48, 49, 49, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1bf0 */ 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, 48, -/* 0x1c00 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 49, -/* 0x1c10 */ 54,102,101, 32, 32, 50, 42, 42, 48, 32, 32, 67, 79, 78, 84, 69, -/* 0x1c20 */ 78, 84, 83, 44, 32, 82, 69, 65, 68, 79, 78, 76, 89, 10, 32, 49, -/* 0x1c30 */ 49, 32, 77, 65, 67, 72, 77, 65, 73, 78, 90, 32, 32, 32, 32, 32, -/* 0x1c40 */ 48, 48, 48, 48, 48, 48, 52, 49, 32, 32, 48, 48, 48, 48, 48, 48, -/* 0x1c50 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, -/* 0x1c60 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, -/* 0x1c70 */ 48, 48, 49, 55, 48,102, 32, 32, 50, 42, 42, 48, 32, 32, 67, 79, -/* 0x1c80 */ 78, 84, 69, 78, 84, 83, 44, 32, 82, 69, 65, 68, 79, 78, 76, 89, -/* 0x1c90 */ 10, 83, 89, 77, 66, 79, 76, 32, 84, 65, 66, 76, 69, 58, 10, 48, -/* 0x1ca0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, -/* 0x1cb0 */ 108, 32, 32, 32, 32,100, 32, 32, 78, 82, 86, 95, 72, 69, 65, 68, -/* 0x1cc0 */ 9, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1cd0 */ 48, 32, 78, 82, 86, 95, 72, 69, 65, 68, 10, 48, 48, 48, 48, 48, -/* 0x1ce0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, -/* 0x1cf0 */ 32,100, 32, 32, 76, 90, 77, 65, 95, 68, 69, 67, 51, 48, 9, 48, -/* 0x1d00 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, -/* 0x1d10 */ 76, 90, 77, 65, 95, 68, 69, 67, 51, 48, 10, 48, 48, 48, 48, 48, -/* 0x1d20 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, -/* 0x1d30 */ 32,100, 32, 32, 77, 65, 67, 72, 77, 65, 73, 78, 89, 9, 48, 48, -/* 0x1d40 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 77, -/* 0x1d50 */ 65, 67, 72, 77, 65, 73, 78, 89, 10, 48, 48, 48, 48, 48, 48, 48, -/* 0x1d60 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, -/* 0x1d70 */ 32, 32, 77, 65, 67, 72, 77, 65, 73, 78, 90, 9, 48, 48, 48, 48, -/* 0x1d80 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 77, 65, 67, -/* 0x1d90 */ 72, 77, 65, 73, 78, 90, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1da0 */ 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, 32, 32, -/* 0x1db0 */ 77, 65, 67, 72, 77, 65, 73, 78, 88, 9, 48, 48, 48, 48, 48, 48, -/* 0x1dc0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 77, 65, 67, 72, 77, -/* 0x1dd0 */ 65, 73, 78, 88, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1de0 */ 48, 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, 32, 32, 78, 82, -/* 0x1df0 */ 86, 50, 69, 9, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1e00 */ 48, 48, 48, 48, 32, 78, 82, 86, 50, 69, 10, 48, 48, 48, 48, 48, -/* 0x1e10 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, -/* 0x1e20 */ 32,100, 32, 32, 78, 82, 86, 50, 68, 9, 48, 48, 48, 48, 48, 48, -/* 0x1e30 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 78, 82, 86, 50, 68, -/* 0x1e40 */ 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1e50 */ 48, 32,108, 32, 32, 32, 32,100, 32, 32, 78, 82, 86, 50, 66, 9, -/* 0x1e60 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1e70 */ 32, 78, 82, 86, 50, 66, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1e80 */ 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, 32, 32, -/* 0x1e90 */ 76, 90, 77, 65, 95, 69, 76, 70, 48, 48, 9, 48, 48, 48, 48, 48, -/* 0x1ea0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 76, 90, 77, 65, -/* 0x1eb0 */ 95, 69, 76, 70, 48, 48, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1ec0 */ 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, 32, 32, -/* 0x1ed0 */ 76, 90, 77, 65, 95, 68, 69, 67, 49, 48, 9, 48, 48, 48, 48, 48, -/* 0x1ee0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 76, 90, 77, 65, -/* 0x1ef0 */ 95, 68, 69, 67, 49, 48, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1f00 */ 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, 32, 32, -/* 0x1f10 */ 76, 90, 77, 65, 95, 68, 69, 67, 50, 48, 9, 48, 48, 48, 48, 48, -/* 0x1f20 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 76, 90, 77, 65, -/* 0x1f30 */ 95, 68, 69, 67, 50, 48, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1f40 */ 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, 32, 32, -/* 0x1f50 */ 78, 82, 86, 95, 84, 65, 73, 76, 9, 48, 48, 48, 48, 48, 48, 48, -/* 0x1f60 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 78, 82, 86, 95, 84, 65, -/* 0x1f70 */ 73, 76, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1f80 */ 48, 48, 48, 32,103, 32, 32, 32, 32, 32, 32, 32, 77, 65, 67, 72, -/* 0x1f90 */ 77, 65, 73, 78, 88, 9, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1fa0 */ 48, 48, 48, 48, 48, 48, 32, 95,115,116, 97,114,116, 10, 48, 48, -/* 0x1fb0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 49, 49, 32,103, -/* 0x1fc0 */ 32, 32, 32, 32, 32, 32, 32, 77, 65, 67, 72, 77, 65, 73, 78, 89, -/* 0x1fd0 */ 9, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x1fe0 */ 48, 32,101,110,100, 95,100,101, 99,111,109,112,114,101,115,115, -/* 0x1ff0 */ 10, 10, 82, 69, 76, 79, 67, 65, 84, 73, 79, 78, 32, 82, 69, 67, -/* 0x2000 */ 79, 82, 68, 83, 32, 70, 79, 82, 32, 91, 77, 65, 67, 72, 77, 65, -/* 0x2010 */ 73, 78, 88, 93, 58, 10, 79, 70, 70, 83, 69, 84, 32, 32, 32, 32, -/* 0x2020 */ 32, 32, 32, 32, 32, 32, 32, 84, 89, 80, 69, 32, 32, 32, 32, 32, -/* 0x2030 */ 32, 32, 32, 32, 32, 32, 32, 32, 32, 86, 65, 76, 85, 69, 10, 48, -/* 0x2040 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 49, 32, -/* 0x2050 */ 82, 95, 88, 56, 54, 95, 54, 52, 95, 80, 67, 51, 50, 32, 32, 32, -/* 0x2060 */ 32, 32, 77, 65, 67, 72, 77, 65, 73, 78, 90, 43, 48,120, 48, 48, -/* 0x2070 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 51, 55, 10, 10, -/* 0x2080 */ 82, 69, 76, 79, 67, 65, 84, 73, 79, 78, 32, 82, 69, 67, 79, 82, -/* 0x2090 */ 68, 83, 32, 70, 79, 82, 32, 91, 78, 82, 86, 50, 69, 93, 58, 10, -/* 0x20a0 */ 79, 70, 70, 83, 69, 84, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, -/* 0x20b0 */ 32, 84, 89, 80, 69, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, -/* 0x20c0 */ 32, 32, 32, 86, 65, 76, 85, 69, 10, 48, 48, 48, 48, 48, 48, 48, -/* 0x20d0 */ 48, 48, 48, 48, 48, 48, 48, 97,101, 32, 82, 95, 88, 56, 54, 95, -/* 0x20e0 */ 54, 52, 95, 80, 67, 51, 50, 32, 32, 32, 32, 32, 78, 82, 86, 95, -/* 0x20f0 */ 72, 69, 65, 68, 43, 48,120, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x2100 */ 48, 48, 48, 48, 48, 50, 49, 10, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x2110 */ 48, 48, 48, 48, 48, 48, 53, 98, 32, 82, 95, 88, 56, 54, 95, 54, -/* 0x2120 */ 52, 95, 80, 67, 51, 50, 32, 32, 32, 32, 32, 77, 65, 67, 72, 77, -/* 0x2130 */ 65, 73, 78, 89, 43, 48,120,102,102,102,102,102,102,102,102,102, -/* 0x2140 */ 102,102,102,102,102,102, 99, 10, 10, 82, 69, 76, 79, 67, 65, 84, -/* 0x2150 */ 73, 79, 78, 32, 82, 69, 67, 79, 82, 68, 83, 32, 70, 79, 82, 32, -/* 0x2160 */ 91, 78, 82, 86, 50, 68, 93, 58, 10, 79, 70, 70, 83, 69, 84, 32, -/* 0x2170 */ 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 84, 89, 80, 69, 32, 32, -/* 0x2180 */ 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 86, 65, 76, 85, -/* 0x2190 */ 69, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, -/* 0x21a0 */ 57, 53, 32, 82, 95, 88, 56, 54, 95, 54, 52, 95, 80, 67, 51, 50, -/* 0x21b0 */ 32, 32, 32, 32, 32, 78, 82, 86, 95, 72, 69, 65, 68, 43, 48,120, -/* 0x21c0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 50, 49, -/* 0x21d0 */ 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 53, -/* 0x21e0 */ 98, 32, 82, 95, 88, 56, 54, 95, 54, 52, 95, 80, 67, 51, 50, 32, -/* 0x21f0 */ 32, 32, 32, 32, 77, 65, 67, 72, 77, 65, 73, 78, 89, 43, 48,120, -/* 0x2200 */ 102,102,102,102,102,102,102,102,102,102,102,102,102,102,102, 99, -/* 0x2210 */ 10, 10, 82, 69, 76, 79, 67, 65, 84, 73, 79, 78, 32, 82, 69, 67, -/* 0x2220 */ 79, 82, 68, 83, 32, 70, 79, 82, 32, 91, 78, 82, 86, 50, 66, 93, -/* 0x2230 */ 58, 10, 79, 70, 70, 83, 69, 84, 32, 32, 32, 32, 32, 32, 32, 32, -/* 0x2240 */ 32, 32, 32, 84, 89, 80, 69, 32, 32, 32, 32, 32, 32, 32, 32, 32, -/* 0x2250 */ 32, 32, 32, 32, 32, 86, 65, 76, 85, 69, 10, 48, 48, 48, 48, 48, -/* 0x2260 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 56, 97, 32, 82, 95, 88, 56, -/* 0x2270 */ 54, 95, 54, 52, 95, 80, 67, 51, 50, 32, 32, 32, 32, 32, 78, 82, -/* 0x2280 */ 86, 95, 72, 69, 65, 68, 43, 48,120, 48, 48, 48, 48, 48, 48, 48, -/* 0x2290 */ 48, 48, 48, 48, 48, 48, 48, 50, 49, 10, 48, 48, 48, 48, 48, 48, -/* 0x22a0 */ 48, 48, 48, 48, 48, 48, 48, 48, 53, 50, 32, 82, 95, 88, 56, 54, -/* 0x22b0 */ 95, 54, 52, 95, 80, 67, 51, 50, 32, 32, 32, 32, 32, 77, 65, 67, -/* 0x22c0 */ 72, 77, 65, 73, 78, 89, 43, 48,120,102,102,102,102,102,102,102, -/* 0x22d0 */ 102,102,102,102,102,102,102,102, 99, 10, 10, 82, 69, 76, 79, 67, -/* 0x22e0 */ 65, 84, 73, 79, 78, 32, 82, 69, 67, 79, 82, 68, 83, 32, 70, 79, -/* 0x22f0 */ 82, 32, 91, 76, 90, 77, 65, 95, 69, 76, 70, 48, 48, 93, 58, 10, -/* 0x2300 */ 79, 70, 70, 83, 69, 84, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, -/* 0x2310 */ 32, 84, 89, 80, 69, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, -/* 0x2320 */ 32, 32, 32, 86, 65, 76, 85, 69, 10, 48, 48, 48, 48, 48, 48, 48, -/* 0x2330 */ 48, 48, 48, 48, 48, 48, 48, 48, 54, 32, 82, 95, 88, 56, 54, 95, -/* 0x2340 */ 54, 52, 95, 80, 67, 51, 50, 32, 32, 32, 32, 32, 76, 90, 77, 65, -/* 0x2350 */ 95, 68, 69, 67, 51, 48, 43, 48,120, 48, 48, 48, 48, 48, 48, 48, -/* 0x2360 */ 48, 48, 48, 48, 48, 48, 48, 49, 48, 10 +/* 0x0020 */ 0, 0, 0, 0, 0, 0, 0, 0, 88, 24, 0, 0, 0, 0, 0, 0, +/* 0x0030 */ 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 64, 0, 23, 0, 20, 0, +/* 0x0040 */ 82, 0,131,249, 73,117, 74, 72,137,241, 72,137,254,235, 44,138, +/* 0x0050 */ 7, 72,131,199, 1, 60,128,114, 10, 60,143,119, 6,128,127,254, +/* 0x0060 */ 15,116, 6, 44,232, 60, 1,119, 35, 56, 23,117, 31,139, 7, 37, +/* 0x0070 */ 0,255,255,255, 15,200, 41,248, 1,240,171, 72,131,233, 4,138, +/* 0x0080 */ 7, 72,131,199, 1, 72,255,201,117,217,235, 5, 72,255,201,117, +/* 0x0090 */ 190,195,232, 0, 0, 0, 0, 85, 83, 81, 82, 72, 1,254, 86, 72, +/* 0x00a0 */ 137,254, 72,137,215, 49,219, 49,201, 72,131,205,255,232, 81, 0, +/* 0x00b0 */ 0, 0, 1,219,116, 2,243,195,139, 30, 72,131,238,252, 17,219, +/* 0x00c0 */ 138, 22,243,195, 72,141, 4, 47,131,249, 5,138, 16,118, 33, 72, +/* 0x00d0 */ 131,253,252,119, 27,131,233, 4,139, 16, 72,131,192, 4,131,233, +/* 0x00e0 */ 4,137, 23, 72,141,127, 4,115,239,131,193, 4,138, 16,116, 17, +/* 0x00f0 */ 72,131,192, 1,136, 23,131,233, 1,138, 16, 72,141,127, 1,117, +/* 0x0100 */ 239,243,195,252, 65, 91, 65,128,248, 8,116, 13,233,172, 0, 0, +/* 0x0110 */ 0, 72,255,198,136, 23, 72,255,199,138, 22, 1,219,117, 10,139, +/* 0x0120 */ 30, 72,131,238,252, 17,219,138, 22,114,230,141, 65, 1,235, 7, +/* 0x0130 */ 255,200, 65,255,211, 17,192, 65,255,211, 17,192, 1,219,117, 10, +/* 0x0140 */ 139, 30, 72,131,238,252, 17,219,138, 22,115,228,131,232, 3,114, +/* 0x0150 */ 29,193,224, 8, 15,182,210, 9,208, 72,255,198,131,240,255, 15, +/* 0x0160 */ 132, 0, 0, 0, 0,209,248, 72, 99,232,114, 56,235, 14, 1,219, +/* 0x0170 */ 117, 8,139, 30, 72,131,238,252, 17,219,114, 40,255,193, 1,219, +/* 0x0180 */ 117, 8,139, 30, 72,131,238,252, 17,219,114, 24, 65,255,211, 17, +/* 0x0190 */ 201, 1,219,117, 8,139, 30, 72,131,238,252, 17,219,115,237,131, +/* 0x01a0 */ 193, 2,235, 5, 65,255,211, 17,201, 72,129,253, 0,251,255,255, +/* 0x01b0 */ 131,209, 2,232, 0, 0, 0, 0,233, 92,255,255,255, 65,128,248, +/* 0x01c0 */ 5,116, 13,233,147, 0, 0, 0, 72,255,198,136, 23, 72,255,199, +/* 0x01d0 */ 138, 22, 1,219,117, 10,139, 30, 72,131,238,252, 17,219,138, 22, +/* 0x01e0 */ 114,230,141, 65, 1,235, 7,255,200, 65,255,211, 17,192, 65,255, +/* 0x01f0 */ 211, 17,192, 1,219,117, 10,139, 30, 72,131,238,252, 17,219,138, +/* 0x0200 */ 22,115,228,131,232, 3,114, 27,193,224, 8, 15,182,210, 9,208, +/* 0x0210 */ 72,255,198,131,240,255, 15,132, 0, 0, 0, 0,209,248, 72, 99, +/* 0x0220 */ 232,235, 3, 65,255,211, 17,201, 65,255,211, 17,201,117, 24,255, +/* 0x0230 */ 193, 65,255,211, 17,201, 1,219,117, 8,139, 30, 72,131,238,252, +/* 0x0240 */ 17,219,115,237,131,193, 2, 72,129,253, 0,251,255,255,131,209, +/* 0x0250 */ 1,232, 0, 0, 0, 0,233,117,255,255,255, 65,128,248, 2,116, +/* 0x0260 */ 13,233,133, 0, 0, 0, 72,255,198,136, 23, 72,255,199,138, 22, +/* 0x0270 */ 1,219,117, 10,139, 30, 72,131,238,252, 17,219,138, 22,114,230, +/* 0x0280 */ 141, 65, 1, 65,255,211, 17,192, 1,219,117, 10,139, 30, 72,131, +/* 0x0290 */ 238,252, 17,219,138, 22,115,235,131,232, 3,114, 23,193,224, 8, +/* 0x02a0 */ 15,182,210, 9,208, 72,255,198,131,240,255, 15,132, 0, 0, 0, +/* 0x02b0 */ 0, 72, 99,232,141, 65, 1, 65,255,211, 17,201, 65,255,211, 17, +/* 0x02c0 */ 201,117, 24,137,193,131,192, 2, 65,255,211, 17,201, 1,219,117, +/* 0x02d0 */ 8,139, 30, 72,131,238,252, 17,219,115,237, 72,129,253, 0,243, +/* 0x02e0 */ 255,255, 17,193,232, 0, 0, 0, 0,235,131, 65,128,248, 14, 15, +/* 0x02f0 */ 133, 0, 0, 0, 0, 85, 72,137,229, 68,139, 9, 73,137,208, 72, +/* 0x0300 */ 137,242, 72,141,119, 2, 86,138, 7,255,202,136,193, 36, 7,192, +/* 0x0310 */ 233, 3, 72,199,195, 0,253,255,255, 72,211,227,136,193, 72,141, +/* 0x0320 */ 156, 92,136,241,255,255, 72,131,227,192,106, 0, 72, 57,220,117, +/* 0x0330 */ 249, 83, 72,141,123, 8,138, 78,255,255,202,136, 71, 2,136,200, +/* 0x0340 */ 192,233, 4,136, 79, 1, 36, 15,136, 7, 72,141, 79,252, 80, 65, +/* 0x0350 */ 87, 72,141, 71, 4, 69, 49,255, 65, 86, 65,190, 1, 0, 0, 0, +/* 0x0360 */ 65, 85, 69, 49,237, 65, 84, 85, 83, 72,137, 76, 36,240, 72,137, +/* 0x0370 */ 68, 36,216,184, 1, 0, 0, 0, 72,137,116, 36,248, 76,137, 68, +/* 0x0380 */ 36,232,137,195, 68,137, 76, 36,228, 15,182, 79, 2,211,227,137, +/* 0x0390 */ 217, 72,139, 92, 36, 56,255,201,137, 76, 36,212, 15,182, 79, 1, +/* 0x03a0 */ 211,224, 72,139, 76, 36,240,255,200,137, 68, 36,208, 15,182, 7, +/* 0x03b0 */ 199, 1, 0, 0, 0, 0,199, 68, 36,200, 0, 0, 0, 0,199, 68, +/* 0x03c0 */ 36,196, 1, 0, 0, 0,199, 68, 36,192, 1, 0, 0, 0,199, 68, +/* 0x03d0 */ 36,188, 1, 0, 0, 0,199, 3, 0, 0, 0, 0,137, 68, 36,204, +/* 0x03e0 */ 15,182, 79, 1, 1,193,184, 0, 3, 0, 0,211,224, 49,201,141, +/* 0x03f0 */ 184, 54, 7, 0, 0, 65, 57,255,115, 19, 72,139, 92, 36,216,137, +/* 0x0400 */ 200,255,193, 57,249,102,199, 4, 67, 0, 4,235,235, 72,139,124, +/* 0x0410 */ 36,248,137,208, 69, 49,210, 65,131,203,255, 49,210, 73,137,252, +/* 0x0420 */ 73, 1,196, 76, 57,231, 15,132,239, 8, 0, 0, 15,182, 7, 65, +/* 0x0430 */ 193,226, 8,255,194, 72,255,199, 65, 9,194,131,250, 4,126,227, +/* 0x0440 */ 68, 59,124, 36,228, 15,131,218, 8, 0, 0,139, 68, 36,212, 72, +/* 0x0450 */ 99, 92, 36,200, 72,139, 84, 36,216, 68, 33,248,137, 68, 36,184, +/* 0x0460 */ 72, 99,108, 36,184, 72,137,216, 72,193,224, 4, 72, 1,232, 65, +/* 0x0470 */ 129,251,255,255,255, 0, 76,141, 12, 66,119, 26, 76, 57,231, 15, +/* 0x0480 */ 132,150, 8, 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, +/* 0x0490 */ 72,255,199, 65, 9,194, 65, 15,183, 17, 68,137,216,193,232, 11, +/* 0x04a0 */ 15,183,202, 15,175,193, 65, 57,194, 15,131,197, 1, 0, 0, 65, +/* 0x04b0 */ 137,195,184, 0, 8, 0, 0, 72,139, 92, 36,216, 41,200, 15,182, +/* 0x04c0 */ 76, 36,204,190, 1, 0, 0, 0,193,248, 5,141, 4, 2, 65, 15, +/* 0x04d0 */ 182,213,102, 65,137, 1,139, 68, 36,208, 68, 33,248,211,224,185, +/* 0x04e0 */ 8, 0, 0, 0, 43, 76, 36,204,211,250, 1,208,105,192, 0, 3, +/* 0x04f0 */ 0, 0,131,124, 36,200, 6,137,192, 76,141,140, 67,108, 14, 0, +/* 0x0500 */ 0, 15,142,184, 0, 0, 0, 72,139, 84, 36,232, 68,137,248, 68, +/* 0x0510 */ 41,240, 15,182, 44, 2, 1,237, 72, 99,214,137,235,129,227, 0, +/* 0x0520 */ 1, 0, 0, 65,129,251,255,255,255, 0, 72, 99,195, 73,141, 4, +/* 0x0530 */ 65, 76,141, 4, 80,119, 26, 76, 57,231, 15,132,219, 7, 0, 0, +/* 0x0540 */ 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, 9, +/* 0x0550 */ 194, 65, 15,183,144, 0, 2, 0, 0, 68,137,216,193,232, 11, 15, +/* 0x0560 */ 183,202, 15,175,193, 65, 57,194,115, 32, 65,137,195,184, 0, 8, +/* 0x0570 */ 0, 0, 1,246, 41,200,193,248, 5,133,219,141, 4, 2,102, 65, +/* 0x0580 */ 137,128, 0, 2, 0, 0,116, 33,235, 45, 65, 41,195, 65, 41,194, +/* 0x0590 */ 137,208,102,193,232, 5,141,116, 54, 1,102, 41,194,133,219,102, +/* 0x05a0 */ 65,137,144, 0, 2, 0, 0,116, 14,129,254,255, 0, 0, 0, 15, +/* 0x05b0 */ 142, 97,255,255,255,235,120,129,254,255, 0, 0, 0,127,112, 72, +/* 0x05c0 */ 99,198, 65,129,251,255,255,255, 0, 77,141, 4, 65,119, 26, 76, +/* 0x05d0 */ 57,231, 15,132, 67, 7, 0, 0, 15,182, 7, 65,193,226, 8, 65, +/* 0x05e0 */ 193,227, 8, 72,255,199, 65, 9,194, 65, 15,183, 16, 68,137,216, +/* 0x05f0 */ 193,232, 11, 15,183,202, 15,175,193, 65, 57,194,115, 24, 65,137, +/* 0x0600 */ 195,184, 0, 8, 0, 0, 1,246, 41,200,193,248, 5,141, 4, 2, +/* 0x0610 */ 102, 65,137, 0,235,161, 65, 41,195, 65, 41,194,137,208,102,193, +/* 0x0620 */ 232, 5,141,116, 54, 1,102, 41,194,102, 65,137, 16,235,136, 72, +/* 0x0630 */ 139, 76, 36,232, 68,137,248, 65,255,199, 65,137,245, 64,136, 52, +/* 0x0640 */ 1,131,124, 36,200, 3,127, 13,199, 68, 36,200, 0, 0, 0, 0, +/* 0x0650 */ 233,166, 6, 0, 0,139, 84, 36,200,139, 68, 36,200,131,234, 3, +/* 0x0660 */ 131,232, 6,131,124, 36,200, 9, 15, 79,208,137, 84, 36,200,233, +/* 0x0670 */ 135, 6, 0, 0, 65, 41,195, 65, 41,194,137,208,102,193,232, 5, +/* 0x0680 */ 102, 41,194, 72,139, 68, 36,216, 65,129,251,255,255,255, 0,102, +/* 0x0690 */ 65,137, 17, 72,141, 52, 88,119, 26, 76, 57,231, 15,132,121, 6, +/* 0x06a0 */ 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, +/* 0x06b0 */ 65, 9,194, 15,183,150,128, 1, 0, 0, 68,137,216,193,232, 11, +/* 0x06c0 */ 15,183,202, 15,175,193, 65, 57,194,115, 78, 65,137,195,184, 0, +/* 0x06d0 */ 8, 0, 0, 76,139, 76, 36,216, 41,200,139, 76, 36,196, 68,137, +/* 0x06e0 */ 116, 36,196,193,248, 5,141, 4, 2,139, 84, 36,192,137, 76, 36, +/* 0x06f0 */ 192,102,137,134,128, 1, 0, 0, 49,192,131,124, 36,200, 6,137, +/* 0x0700 */ 84, 36,188, 15,159,192, 73,129,193,100, 6, 0, 0,141, 4, 64, +/* 0x0710 */ 137, 68, 36,200,233, 84, 2, 0, 0, 65, 41,195, 65, 41,194,137, +/* 0x0720 */ 208,102,193,232, 5,102, 41,194, 65,129,251,255,255,255, 0,102, +/* 0x0730 */ 137,150,128, 1, 0, 0,119, 26, 76, 57,231, 15,132,218, 5, 0, +/* 0x0740 */ 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, +/* 0x0750 */ 9,194, 15,183,150,152, 1, 0, 0, 68,137,216,193,232, 11, 15, +/* 0x0760 */ 183,202, 15,175,193, 65, 57,194, 15,131,208, 0, 0, 0, 65,184, +/* 0x0770 */ 0, 8, 0, 0, 65,137,195, 72,193,227, 5, 68,137,192, 41,200, +/* 0x0780 */ 193,248, 5,141, 4, 2,102,137,134,152, 1, 0, 0, 72,139, 68, +/* 0x0790 */ 36,216, 72, 1,216, 65,129,251,255,255,255, 0, 72,141, 52,104, +/* 0x07a0 */ 119, 26, 76, 57,231, 15,132,112, 5, 0, 0, 15,182, 7, 65,193, +/* 0x07b0 */ 226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, 15,183,150,224, +/* 0x07c0 */ 1, 0, 0, 68,137,216,193,232, 11, 15,183,202, 15,175,193, 65, +/* 0x07d0 */ 57,194,115, 79, 65, 41,200, 65,137,195, 65,193,248, 5, 69,133, +/* 0x07e0 */ 255, 66,141, 4, 2,102,137,134,224, 1, 0, 0, 15,132, 41, 5, +/* 0x07f0 */ 0, 0, 49,192,131,124, 36,200, 6, 72,139, 92, 36,232, 15,159, +/* 0x0800 */ 192,141, 68, 0, 9,137, 68, 36,200, 68,137,248, 68, 41,240, 68, +/* 0x0810 */ 15,182, 44, 3, 68,137,248, 65,255,199, 68,136, 44, 3,233,216, +/* 0x0820 */ 4, 0, 0, 65, 41,195, 65, 41,194,137,208,102,193,232, 5,102, +/* 0x0830 */ 41,194,102,137,150,224, 1, 0, 0,233, 17, 1, 0, 0, 65, 41, +/* 0x0840 */ 195, 65, 41,194,137,208,102,193,232, 5,102, 41,194, 65,129,251, +/* 0x0850 */ 255,255,255, 0,102,137,150,152, 1, 0, 0,119, 26, 76, 57,231, +/* 0x0860 */ 15,132,181, 4, 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, +/* 0x0870 */ 8, 72,255,199, 65, 9,194, 15,183,150,176, 1, 0, 0, 68,137, +/* 0x0880 */ 216,193,232, 11, 15,183,202, 15,175,193, 65, 57,194,115, 32, 65, +/* 0x0890 */ 137,195,184, 0, 8, 0, 0, 41,200,193,248, 5,141, 4, 2,102, +/* 0x08a0 */ 137,134,176, 1, 0, 0,139, 68, 36,196,233,152, 0, 0, 0, 65, +/* 0x08b0 */ 41,195, 65, 41,194,137,208,102,193,232, 5,102, 41,194, 65,129, +/* 0x08c0 */ 251,255,255,255, 0,102,137,150,176, 1, 0, 0,119, 26, 76, 57, +/* 0x08d0 */ 231, 15,132, 68, 4, 0, 0, 15,182, 7, 65,193,226, 8, 65,193, +/* 0x08e0 */ 227, 8, 72,255,199, 65, 9,194, 15,183,150,200, 1, 0, 0, 68, +/* 0x08f0 */ 137,216,193,232, 11, 15,183,202, 15,175,193, 65, 57,194,115, 29, +/* 0x0900 */ 65,137,195,184, 0, 8, 0, 0, 41,200,193,248, 5,141, 4, 2, +/* 0x0910 */ 102,137,134,200, 1, 0, 0,139, 68, 36,192,235, 34, 65, 41,195, +/* 0x0920 */ 65, 41,194,137,208,102,193,232, 5,102, 41,194,139, 68, 36,188, +/* 0x0930 */ 102,137,150,200, 1, 0, 0,139, 84, 36,192,137, 84, 36,188,139, +/* 0x0940 */ 76, 36,196,137, 76, 36,192, 68,137,116, 36,196, 65,137,198, 49, +/* 0x0950 */ 192,131,124, 36,200, 6, 76,139, 76, 36,216, 15,159,192, 73,129, +/* 0x0960 */ 193,104, 10, 0, 0,141, 68, 64, 8,137, 68, 36,200, 65,129,251, +/* 0x0970 */ 255,255,255, 0,119, 26, 76, 57,231, 15,132,156, 3, 0, 0, 15, +/* 0x0980 */ 182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, +/* 0x0990 */ 65, 15,183, 17, 68,137,216,193,232, 11, 15,183,202, 15,175,193, +/* 0x09a0 */ 65, 57,194,115, 39, 65,137,195,184, 0, 8, 0, 0, 69, 49,237, +/* 0x09b0 */ 41,200,193,248, 5,141, 4, 2,102, 65,137, 1, 72, 99, 68, 36, +/* 0x09c0 */ 184, 72,193,224, 4, 77,141, 68, 1, 4,235,120, 65, 41,195, 65, +/* 0x09d0 */ 41,194,137,208,102,193,232, 5,102, 41,194, 65,129,251,255,255, +/* 0x09e0 */ 255, 0,102, 65,137, 17,119, 26, 76, 57,231, 15,132, 42, 3, 0, +/* 0x09f0 */ 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, +/* 0x0a00 */ 9,194, 65, 15,183, 81, 2, 68,137,216,193,232, 11, 15,183,202, +/* 0x0a10 */ 15,175,193, 65, 57,194,115, 52, 65,137,195,184, 0, 8, 0, 0, +/* 0x0a20 */ 65,189, 8, 0, 0, 0, 41,200,193,248, 5,141, 4, 2,102, 65, +/* 0x0a30 */ 137, 65, 2, 72, 99, 68, 36,184, 72,193,224, 4, 77,141,132, 1, +/* 0x0a40 */ 4, 1, 0, 0, 65,185, 3, 0, 0, 0,235, 39, 65, 41,195, 65, +/* 0x0a50 */ 41,194,137,208,102,193,232, 5, 77,141,129, 4, 2, 0, 0, 65, +/* 0x0a60 */ 189, 16, 0, 0, 0,102, 41,194,102, 65,137, 81, 2, 65,185, 8, +/* 0x0a70 */ 0, 0, 0, 68,137,203,189, 1, 0, 0, 0, 72, 99,197, 65,129, +/* 0x0a80 */ 251,255,255,255, 0, 73,141, 52, 64,119, 26, 76, 57,231, 15,132, +/* 0x0a90 */ 135, 2, 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72, +/* 0x0aa0 */ 255,199, 65, 9,194, 15,183, 14, 68,137,216,193,232, 11, 15,183, +/* 0x0ab0 */ 209, 15,175,194, 65, 57,194,115, 23, 65,137,195,184, 0, 8, 0, +/* 0x0ac0 */ 0, 1,237, 41,208,193,248, 5,141, 4, 1,102,137, 6,235, 22, +/* 0x0ad0 */ 65, 41,195, 65, 41,194,137,200,102,193,232, 5,141,108, 45, 1, +/* 0x0ae0 */ 102, 41,193,102,137, 14,255,203,117,145,184, 1, 0, 0, 0, 68, +/* 0x0af0 */ 137,201,211,224, 41,197, 68, 1,237,131,124, 36,200, 3, 15,143, +/* 0x0b00 */ 194, 1, 0, 0,131, 68, 36,200, 7,184, 3, 0, 0, 0,131,253, +/* 0x0b10 */ 4, 15, 76,197, 72,139, 92, 36,216, 65,184, 1, 0, 0, 0, 72, +/* 0x0b20 */ 152, 72,193,224, 7, 76,141,140, 3, 96, 3, 0, 0,187, 6, 0, +/* 0x0b30 */ 0, 0, 73, 99,192, 65,129,251,255,255,255, 0, 73,141, 52, 65, +/* 0x0b40 */ 119, 26, 76, 57,231, 15,132,208, 1, 0, 0, 15,182, 7, 65,193, +/* 0x0b50 */ 226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, 15,183, 22, 68, +/* 0x0b60 */ 137,216,193,232, 11, 15,183,202, 15,175,193, 65, 57,194,115, 24, +/* 0x0b70 */ 65,137,195,184, 0, 8, 0, 0, 69, 1,192, 41,200,193,248, 5, +/* 0x0b80 */ 141, 4, 2,102,137, 6,235, 23, 65, 41,195, 65, 41,194,137,208, +/* 0x0b90 */ 102,193,232, 5, 71,141, 68, 0, 1,102, 41,194,102,137, 22,255, +/* 0x0ba0 */ 203,117,143, 65,131,232, 64, 65,131,248, 3, 69,137,198, 15,142, +/* 0x0bb0 */ 13, 1, 0, 0, 65,131,230, 1, 68,137,192,209,248, 65,131,206, +/* 0x0bc0 */ 2, 65,131,248, 13,141,112,255,127, 35,137,241, 72,139, 92, 36, +/* 0x0bd0 */ 216, 73, 99,192, 65,211,230, 72, 1,192, 68,137,242, 72,141, 20, +/* 0x0be0 */ 83, 72, 41,194, 76,141,138, 94, 5, 0, 0,235, 81,141,112,251, +/* 0x0bf0 */ 65,129,251,255,255,255, 0,119, 26, 76, 57,231, 15,132, 25, 1, +/* 0x0c00 */ 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, +/* 0x0c10 */ 65, 9,194, 65,209,235, 69, 1,246, 69, 57,218,114, 7, 69, 41, +/* 0x0c20 */ 218, 65,131,206, 1,255,206,117,199, 76,139, 76, 36,216, 65,193, +/* 0x0c30 */ 230, 4,190, 4, 0, 0, 0, 73,129,193, 68, 6, 0, 0, 65,189, +/* 0x0c40 */ 1, 0, 0, 0,187, 1, 0, 0, 0, 72, 99,195, 65,129,251,255, +/* 0x0c50 */ 255,255, 0, 77,141, 4, 65,119, 26, 76, 57,231, 15,132,185, 0, +/* 0x0c60 */ 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, +/* 0x0c70 */ 65, 9,194, 65, 15,183, 16, 68,137,216,193,232, 11, 15,183,202, +/* 0x0c80 */ 15,175,193, 65, 57,194,115, 24, 65,137,195,184, 0, 8, 0, 0, +/* 0x0c90 */ 1,219, 41,200,193,248, 5,141, 4, 2,102, 65,137, 0,235, 26, +/* 0x0ca0 */ 65, 41,195, 65, 41,194,137,208,102,193,232, 5,141, 92, 27, 1, +/* 0x0cb0 */ 69, 9,238,102, 41,194,102, 65,137, 16, 69, 1,237,255,206,117, +/* 0x0cc0 */ 136, 65,255,198,116, 64,131,197, 2, 69, 57,254,119, 77, 72,139, +/* 0x0cd0 */ 84, 36,232, 68,137,248, 68, 41,240, 68, 15,182, 44, 2, 68,137, +/* 0x0ce0 */ 248, 65,255,199,255,205, 68,136, 44, 2, 15,149,194, 49,192, 68, +/* 0x0cf0 */ 59,124, 36,228, 15,146,192,133,194,117,211, 68, 59,124, 36,228, +/* 0x0d00 */ 15,130, 69,247,255,255, 65,129,251,255,255,255, 0,119, 22, 76, +/* 0x0d10 */ 57,231,184, 1, 0, 0, 0,116, 35,235, 7,184, 1, 0, 0, 0, +/* 0x0d20 */ 235, 26, 72,255,199,137,248, 43, 68, 36,248, 72,139, 76, 36,240, +/* 0x0d30 */ 72,139, 92, 36, 56,137, 1, 68,137, 59, 49,192, 91, 93, 65, 92, +/* 0x0d40 */ 65, 93, 65, 94, 65, 95, 65, 87, 72,141, 71, 4, 69, 49,255, 65, +/* 0x0d50 */ 86, 65,190, 1, 0, 0, 0, 65, 85, 69, 49,237, 65, 84, 85, 83, +/* 0x0d60 */ 72,137, 76, 36,240, 72,137, 68, 36,216,184, 1, 0, 0, 0, 72, +/* 0x0d70 */ 137,116, 36,248, 76,137, 68, 36,232,137,195, 68,137, 76, 36,228, +/* 0x0d80 */ 15,182, 79, 2,211,227,137,217, 72,139, 92, 36, 56,255,201,137, +/* 0x0d90 */ 76, 36,212, 15,182, 79, 1,211,224, 72,139, 76, 36,240,255,200, +/* 0x0da0 */ 137, 68, 36,208, 15,182, 7,199, 1, 0, 0, 0, 0,199, 68, 36, +/* 0x0db0 */ 200, 0, 0, 0, 0,199, 68, 36,196, 1, 0, 0, 0,199, 68, 36, +/* 0x0dc0 */ 192, 1, 0, 0, 0,199, 68, 36,188, 1, 0, 0, 0,199, 3, 0, +/* 0x0dd0 */ 0, 0, 0,137, 68, 36,204, 15,182, 79, 1, 1,193,184, 0, 3, +/* 0x0de0 */ 0, 0,211,224, 49,201,141,184, 54, 7, 0, 0, 65, 57,255,115, +/* 0x0df0 */ 19, 72,139, 92, 36,216,137,200,255,193, 57,249,102,199, 4, 67, +/* 0x0e00 */ 0, 4,235,235, 72,139,124, 36,248,137,208, 69, 49,210, 65,131, +/* 0x0e10 */ 203,255, 49,210, 73,137,252, 73, 1,196, 76, 57,231, 15,132,239, +/* 0x0e20 */ 8, 0, 0, 15,182, 7, 65,193,226, 8,255,194, 72,255,199, 65, +/* 0x0e30 */ 9,194,131,250, 4,126,227, 68, 59,124, 36,228, 15,131,218, 8, +/* 0x0e40 */ 0, 0,139, 68, 36,212, 72, 99, 92, 36,200, 72,139, 84, 36,216, +/* 0x0e50 */ 68, 33,248,137, 68, 36,184, 72, 99,108, 36,184, 72,137,216, 72, +/* 0x0e60 */ 193,224, 4, 72, 1,232, 65,129,251,255,255,255, 0, 76,141, 12, +/* 0x0e70 */ 66,119, 26, 76, 57,231, 15,132,150, 8, 0, 0, 15,182, 7, 65, +/* 0x0e80 */ 193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, 65, 15,183, +/* 0x0e90 */ 17, 68,137,216,193,232, 11, 15,183,202, 15,175,193, 65, 57,194, +/* 0x0ea0 */ 15,131,197, 1, 0, 0, 65,137,195,184, 0, 8, 0, 0, 72,139, +/* 0x0eb0 */ 92, 36,216, 41,200, 15,182, 76, 36,204,190, 1, 0, 0, 0,193, +/* 0x0ec0 */ 248, 5,141, 4, 2, 65, 15,182,213,102, 65,137, 1,139, 68, 36, +/* 0x0ed0 */ 208, 68, 33,248,211,224,185, 8, 0, 0, 0, 43, 76, 36,204,211, +/* 0x0ee0 */ 250, 1,208,105,192, 0, 3, 0, 0,131,124, 36,200, 6,137,192, +/* 0x0ef0 */ 76,141,140, 67,108, 14, 0, 0, 15,142,184, 0, 0, 0, 72,139, +/* 0x0f00 */ 84, 36,232, 68,137,248, 68, 41,240, 15,182, 44, 2, 1,237, 72, +/* 0x0f10 */ 99,214,137,235,129,227, 0, 1, 0, 0, 65,129,251,255,255,255, +/* 0x0f20 */ 0, 72, 99,195, 73,141, 4, 65, 76,141, 4, 80,119, 26, 76, 57, +/* 0x0f30 */ 231, 15,132,219, 7, 0, 0, 15,182, 7, 65,193,226, 8, 65,193, +/* 0x0f40 */ 227, 8, 72,255,199, 65, 9,194, 65, 15,183,144, 0, 2, 0, 0, +/* 0x0f50 */ 68,137,216,193,232, 11, 15,183,202, 15,175,193, 65, 57,194,115, +/* 0x0f60 */ 32, 65,137,195,184, 0, 8, 0, 0, 1,246, 41,200,193,248, 5, +/* 0x0f70 */ 133,219,141, 4, 2,102, 65,137,128, 0, 2, 0, 0,116, 33,235, +/* 0x0f80 */ 45, 65, 41,195, 65, 41,194,137,208,102,193,232, 5,141,116, 54, +/* 0x0f90 */ 1,102, 41,194,133,219,102, 65,137,144, 0, 2, 0, 0,116, 14, +/* 0x0fa0 */ 129,254,255, 0, 0, 0, 15,142, 97,255,255,255,235,120,129,254, +/* 0x0fb0 */ 255, 0, 0, 0,127,112, 72, 99,198, 65,129,251,255,255,255, 0, +/* 0x0fc0 */ 77,141, 4, 65,119, 26, 76, 57,231, 15,132, 67, 7, 0, 0, 15, +/* 0x0fd0 */ 182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, +/* 0x0fe0 */ 65, 15,183, 16, 68,137,216,193,232, 11, 15,183,202, 15,175,193, +/* 0x0ff0 */ 65, 57,194,115, 24, 65,137,195,184, 0, 8, 0, 0, 1,246, 41, +/* 0x1000 */ 200,193,248, 5,141, 4, 2,102, 65,137, 0,235,161, 65, 41,195, +/* 0x1010 */ 65, 41,194,137,208,102,193,232, 5,141,116, 54, 1,102, 41,194, +/* 0x1020 */ 102, 65,137, 16,235,136, 72,139, 76, 36,232, 68,137,248, 65,255, +/* 0x1030 */ 199, 65,137,245, 64,136, 52, 1,131,124, 36,200, 3,127, 13,199, +/* 0x1040 */ 68, 36,200, 0, 0, 0, 0,233,166, 6, 0, 0,139, 84, 36,200, +/* 0x1050 */ 139, 68, 36,200,131,234, 3,131,232, 6,131,124, 36,200, 9, 15, +/* 0x1060 */ 79,208,137, 84, 36,200,233,135, 6, 0, 0, 65, 41,195, 65, 41, +/* 0x1070 */ 194,137,208,102,193,232, 5,102, 41,194, 72,139, 68, 36,216, 65, +/* 0x1080 */ 129,251,255,255,255, 0,102, 65,137, 17, 72,141, 52, 88,119, 26, +/* 0x1090 */ 76, 57,231, 15,132,121, 6, 0, 0, 15,182, 7, 65,193,226, 8, +/* 0x10a0 */ 65,193,227, 8, 72,255,199, 65, 9,194, 15,183,150,128, 1, 0, +/* 0x10b0 */ 0, 68,137,216,193,232, 11, 15,183,202, 15,175,193, 65, 57,194, +/* 0x10c0 */ 115, 78, 65,137,195,184, 0, 8, 0, 0, 76,139, 76, 36,216, 41, +/* 0x10d0 */ 200,139, 76, 36,196, 68,137,116, 36,196,193,248, 5,141, 4, 2, +/* 0x10e0 */ 139, 84, 36,192,137, 76, 36,192,102,137,134,128, 1, 0, 0, 49, +/* 0x10f0 */ 192,131,124, 36,200, 6,137, 84, 36,188, 15,159,192, 73,129,193, +/* 0x1100 */ 100, 6, 0, 0,141, 4, 64,137, 68, 36,200,233, 84, 2, 0, 0, +/* 0x1110 */ 65, 41,195, 65, 41,194,137,208,102,193,232, 5,102, 41,194, 65, +/* 0x1120 */ 129,251,255,255,255, 0,102,137,150,128, 1, 0, 0,119, 26, 76, +/* 0x1130 */ 57,231, 15,132,218, 5, 0, 0, 15,182, 7, 65,193,226, 8, 65, +/* 0x1140 */ 193,227, 8, 72,255,199, 65, 9,194, 15,183,150,152, 1, 0, 0, +/* 0x1150 */ 68,137,216,193,232, 11, 15,183,202, 15,175,193, 65, 57,194, 15, +/* 0x1160 */ 131,208, 0, 0, 0, 65,184, 0, 8, 0, 0, 65,137,195, 72,193, +/* 0x1170 */ 227, 5, 68,137,192, 41,200,193,248, 5,141, 4, 2,102,137,134, +/* 0x1180 */ 152, 1, 0, 0, 72,139, 68, 36,216, 72, 1,216, 65,129,251,255, +/* 0x1190 */ 255,255, 0, 72,141, 52,104,119, 26, 76, 57,231, 15,132,112, 5, +/* 0x11a0 */ 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, +/* 0x11b0 */ 65, 9,194, 15,183,150,224, 1, 0, 0, 68,137,216,193,232, 11, +/* 0x11c0 */ 15,183,202, 15,175,193, 65, 57,194,115, 79, 65, 41,200, 65,137, +/* 0x11d0 */ 195, 65,193,248, 5, 69,133,255, 66,141, 4, 2,102,137,134,224, +/* 0x11e0 */ 1, 0, 0, 15,132, 41, 5, 0, 0, 49,192,131,124, 36,200, 6, +/* 0x11f0 */ 72,139, 92, 36,232, 15,159,192,141, 68, 0, 9,137, 68, 36,200, +/* 0x1200 */ 68,137,248, 68, 41,240, 68, 15,182, 44, 3, 68,137,248, 65,255, +/* 0x1210 */ 199, 68,136, 44, 3,233,216, 4, 0, 0, 65, 41,195, 65, 41,194, +/* 0x1220 */ 137,208,102,193,232, 5,102, 41,194,102,137,150,224, 1, 0, 0, +/* 0x1230 */ 233, 17, 1, 0, 0, 65, 41,195, 65, 41,194,137,208,102,193,232, +/* 0x1240 */ 5,102, 41,194, 65,129,251,255,255,255, 0,102,137,150,152, 1, +/* 0x1250 */ 0, 0,119, 26, 76, 57,231, 15,132,181, 4, 0, 0, 15,182, 7, +/* 0x1260 */ 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, 15,183, +/* 0x1270 */ 150,176, 1, 0, 0, 68,137,216,193,232, 11, 15,183,202, 15,175, +/* 0x1280 */ 193, 65, 57,194,115, 32, 65,137,195,184, 0, 8, 0, 0, 41,200, +/* 0x1290 */ 193,248, 5,141, 4, 2,102,137,134,176, 1, 0, 0,139, 68, 36, +/* 0x12a0 */ 196,233,152, 0, 0, 0, 65, 41,195, 65, 41,194,137,208,102,193, +/* 0x12b0 */ 232, 5,102, 41,194, 65,129,251,255,255,255, 0,102,137,150,176, +/* 0x12c0 */ 1, 0, 0,119, 26, 76, 57,231, 15,132, 68, 4, 0, 0, 15,182, +/* 0x12d0 */ 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, 15, +/* 0x12e0 */ 183,150,200, 1, 0, 0, 68,137,216,193,232, 11, 15,183,202, 15, +/* 0x12f0 */ 175,193, 65, 57,194,115, 29, 65,137,195,184, 0, 8, 0, 0, 41, +/* 0x1300 */ 200,193,248, 5,141, 4, 2,102,137,134,200, 1, 0, 0,139, 68, +/* 0x1310 */ 36,192,235, 34, 65, 41,195, 65, 41,194,137,208,102,193,232, 5, +/* 0x1320 */ 102, 41,194,139, 68, 36,188,102,137,150,200, 1, 0, 0,139, 84, +/* 0x1330 */ 36,192,137, 84, 36,188,139, 76, 36,196,137, 76, 36,192, 68,137, +/* 0x1340 */ 116, 36,196, 65,137,198, 49,192,131,124, 36,200, 6, 76,139, 76, +/* 0x1350 */ 36,216, 15,159,192, 73,129,193,104, 10, 0, 0,141, 68, 64, 8, +/* 0x1360 */ 137, 68, 36,200, 65,129,251,255,255,255, 0,119, 26, 76, 57,231, +/* 0x1370 */ 15,132,156, 3, 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, +/* 0x1380 */ 8, 72,255,199, 65, 9,194, 65, 15,183, 17, 68,137,216,193,232, +/* 0x1390 */ 11, 15,183,202, 15,175,193, 65, 57,194,115, 39, 65,137,195,184, +/* 0x13a0 */ 0, 8, 0, 0, 69, 49,237, 41,200,193,248, 5,141, 4, 2,102, +/* 0x13b0 */ 65,137, 1, 72, 99, 68, 36,184, 72,193,224, 4, 77,141, 68, 1, +/* 0x13c0 */ 4,235,120, 65, 41,195, 65, 41,194,137,208,102,193,232, 5,102, +/* 0x13d0 */ 41,194, 65,129,251,255,255,255, 0,102, 65,137, 17,119, 26, 76, +/* 0x13e0 */ 57,231, 15,132, 42, 3, 0, 0, 15,182, 7, 65,193,226, 8, 65, +/* 0x13f0 */ 193,227, 8, 72,255,199, 65, 9,194, 65, 15,183, 81, 2, 68,137, +/* 0x1400 */ 216,193,232, 11, 15,183,202, 15,175,193, 65, 57,194,115, 52, 65, +/* 0x1410 */ 137,195,184, 0, 8, 0, 0, 65,189, 8, 0, 0, 0, 41,200,193, +/* 0x1420 */ 248, 5,141, 4, 2,102, 65,137, 65, 2, 72, 99, 68, 36,184, 72, +/* 0x1430 */ 193,224, 4, 77,141,132, 1, 4, 1, 0, 0, 65,185, 3, 0, 0, +/* 0x1440 */ 0,235, 39, 65, 41,195, 65, 41,194,137,208,102,193,232, 5, 77, +/* 0x1450 */ 141,129, 4, 2, 0, 0, 65,189, 16, 0, 0, 0,102, 41,194,102, +/* 0x1460 */ 65,137, 81, 2, 65,185, 8, 0, 0, 0, 68,137,203,189, 1, 0, +/* 0x1470 */ 0, 0, 72, 99,197, 65,129,251,255,255,255, 0, 73,141, 52, 64, +/* 0x1480 */ 119, 26, 76, 57,231, 15,132,135, 2, 0, 0, 15,182, 7, 65,193, +/* 0x1490 */ 226, 8, 65,193,227, 8, 72,255,199, 65, 9,194, 15,183, 14, 68, +/* 0x14a0 */ 137,216,193,232, 11, 15,183,209, 15,175,194, 65, 57,194,115, 23, +/* 0x14b0 */ 65,137,195,184, 0, 8, 0, 0, 1,237, 41,208,193,248, 5,141, +/* 0x14c0 */ 4, 1,102,137, 6,235, 22, 65, 41,195, 65, 41,194,137,200,102, +/* 0x14d0 */ 193,232, 5,141,108, 45, 1,102, 41,193,102,137, 14,255,203,117, +/* 0x14e0 */ 145,184, 1, 0, 0, 0, 68,137,201,211,224, 41,197, 68, 1,237, +/* 0x14f0 */ 131,124, 36,200, 3, 15,143,194, 1, 0, 0,131, 68, 36,200, 7, +/* 0x1500 */ 184, 3, 0, 0, 0,131,253, 4, 15, 76,197, 72,139, 92, 36,216, +/* 0x1510 */ 65,184, 1, 0, 0, 0, 72,152, 72,193,224, 7, 76,141,140, 3, +/* 0x1520 */ 96, 3, 0, 0,187, 6, 0, 0, 0, 73, 99,192, 65,129,251,255, +/* 0x1530 */ 255,255, 0, 73,141, 52, 65,119, 26, 76, 57,231, 15,132,208, 1, +/* 0x1540 */ 0, 0, 15,182, 7, 65,193,226, 8, 65,193,227, 8, 72,255,199, +/* 0x1550 */ 65, 9,194, 15,183, 22, 68,137,216,193,232, 11, 15,183,202, 15, +/* 0x1560 */ 175,193, 65, 57,194,115, 24, 65,137,195,184, 0, 8, 0, 0, 69, +/* 0x1570 */ 1,192, 41,200,193,248, 5,141, 4, 2,102,137, 6,235, 23, 65, +/* 0x1580 */ 41,195, 65, 41,194,137,208,102,193,232, 5, 71,141, 68, 0, 1, +/* 0x1590 */ 102, 41,194,102,137, 22,255,203,117,143, 65,131,232, 64, 65,131, +/* 0x15a0 */ 248, 3, 69,137,198, 15,142, 13, 1, 0, 0, 65,131,230, 1, 68, +/* 0x15b0 */ 137,192,209,248, 65,131,206, 2, 65,131,248, 13,141,112,255,127, +/* 0x15c0 */ 35,137,241, 72,139, 92, 36,216, 73, 99,192, 65,211,230, 72, 1, +/* 0x15d0 */ 192, 68,137,242, 72,141, 20, 83, 72, 41,194, 76,141,138, 94, 5, +/* 0x15e0 */ 0, 0,235, 81,141,112,251, 65,129,251,255,255,255, 0,119, 26, +/* 0x15f0 */ 76, 57,231, 15,132, 25, 1, 0, 0, 15,182, 7, 65,193,226, 8, +/* 0x1600 */ 65,193,227, 8, 72,255,199, 65, 9,194, 65,209,235, 69, 1,246, +/* 0x1610 */ 69, 57,218,114, 7, 69, 41,218, 65,131,206, 1,255,206,117,199, +/* 0x1620 */ 76,139, 76, 36,216, 65,193,230, 4,190, 4, 0, 0, 0, 73,129, +/* 0x1630 */ 193, 68, 6, 0, 0, 65,189, 1, 0, 0, 0,187, 1, 0, 0, 0, +/* 0x1640 */ 72, 99,195, 65,129,251,255,255,255, 0, 77,141, 4, 65,119, 26, +/* 0x1650 */ 76, 57,231, 15,132,185, 0, 0, 0, 15,182, 7, 65,193,226, 8, +/* 0x1660 */ 65,193,227, 8, 72,255,199, 65, 9,194, 65, 15,183, 16, 68,137, +/* 0x1670 */ 216,193,232, 11, 15,183,202, 15,175,193, 65, 57,194,115, 24, 65, +/* 0x1680 */ 137,195,184, 0, 8, 0, 0, 1,219, 41,200,193,248, 5,141, 4, +/* 0x1690 */ 2,102, 65,137, 0,235, 26, 65, 41,195, 65, 41,194,137,208,102, +/* 0x16a0 */ 193,232, 5,141, 92, 27, 1, 69, 9,238,102, 41,194,102, 65,137, +/* 0x16b0 */ 16, 69, 1,237,255,206,117,136, 65,255,198,116, 64,131,197, 2, +/* 0x16c0 */ 69, 57,254,119, 77, 72,139, 84, 36,232, 68,137,248, 68, 41,240, +/* 0x16d0 */ 68, 15,182, 44, 2, 68,137,248, 65,255,199,255,205, 68,136, 44, +/* 0x16e0 */ 2, 15,149,194, 49,192, 68, 59,124, 36,228, 15,146,192,133,194, +/* 0x16f0 */ 117,211, 68, 59,124, 36,228, 15,130, 69,247,255,255, 65,129,251, +/* 0x1700 */ 255,255,255, 0,119, 22, 76, 57,231,184, 1, 0, 0, 0,116, 35, +/* 0x1710 */ 235, 7,184, 1, 0, 0, 0,235, 26, 72,255,199,137,248, 43, 68, +/* 0x1720 */ 36,248, 72,139, 76, 36,240, 72,139, 92, 36, 56,137, 1, 68,137, +/* 0x1730 */ 59, 49,192, 91, 93, 65, 92, 65, 93, 65, 94, 65, 95, 72,139,117, +/* 0x1740 */ 248, 72,139,125, 16,139, 75, 4, 72, 1,206,139, 19, 72, 1,215, +/* 0x1750 */ 201, 89, 72,137,240, 72, 41,200, 90, 72, 41,215, 89,137, 57, 91, +/* 0x1760 */ 93,195, 91,139, 75, 4, 72,141,116, 25, 11,139, 59, 72,141,188, +/* 0x1770 */ 31,203, 0, 0, 0,253,243,164, 72,141,147,128, 0, 0, 0, 72, +/* 0x1780 */ 137,222, 72,141,127, 1, 82,252,173, 80, 72,137,225,173, 80,173, +/* 0x1790 */ 68, 15,182,192, 94,255,213, 89, 72,141, 93,247,195, 93,232,191, +/* 0x17a0 */ 255,255,255,102,105,108,101, 32,102,111,114,109, 97,116, 32,101, +/* 0x17b0 */ 108,102, 54, 52, 45,120, 56, 54, 45, 54, 52, 10, 10, 83,101, 99, +/* 0x17c0 */ 116,105,111,110,115, 58, 10, 73,100,120, 32, 78, 97,109,101, 32, +/* 0x17d0 */ 32, 32, 32, 32, 32, 32, 32, 32, 32, 83,105,122,101, 32, 32, 32, +/* 0x17e0 */ 32, 32, 32, 86, 77, 65, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, +/* 0x17f0 */ 32, 32, 32, 32, 32, 76, 77, 65, 32, 32, 32, 32, 32, 32, 32, 32, +/* 0x1800 */ 32, 32, 32, 32, 32, 32, 32, 70,105,108,101, 32,111,102,102, 32, +/* 0x1810 */ 32, 65,108,103,110, 32, 32, 70,108, 97,103,115, 10, 32, 32, 48, +/* 0x1820 */ 32, 65, 77, 68, 54, 52, 66, 88, 88, 32, 32, 32, 32, 32, 32, 48, +/* 0x1830 */ 48, 48, 48, 48, 48, 53, 50, 32, 32, 48, 48, 48, 48, 48, 48, 48, +/* 0x1840 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, +/* 0x1850 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, +/* 0x1860 */ 48, 48, 48, 52, 48, 32, 32, 50, 42, 42, 48, 32, 32, 67, 79, 78, +/* 0x1870 */ 84, 69, 78, 84, 83, 44, 32, 82, 69, 65, 68, 79, 78, 76, 89, 10, +/* 0x1880 */ 32, 32, 49, 32, 77, 65, 67, 72, 77, 65, 73, 78, 88, 32, 32, 32, +/* 0x1890 */ 32, 32, 48, 48, 48, 48, 48, 48, 48, 53, 32, 32, 48, 48, 48, 48, +/* 0x18a0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, +/* 0x18b0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, +/* 0x18c0 */ 48, 48, 48, 48, 48, 48, 57, 50, 32, 32, 50, 42, 42, 48, 32, 32, +/* 0x18d0 */ 67, 79, 78, 84, 69, 78, 84, 83, 44, 32, 82, 69, 76, 79, 67, 44, +/* 0x18e0 */ 32, 82, 69, 65, 68, 79, 78, 76, 89, 10, 32, 32, 50, 32, 77, 65, +/* 0x18f0 */ 67, 72, 95, 85, 78, 67, 32, 32, 32, 32, 32, 32, 48, 48, 48, 48, +/* 0x1900 */ 48, 48, 48, 56, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1910 */ 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1920 */ 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, +/* 0x1930 */ 57, 55, 32, 32, 50, 42, 42, 48, 32, 32, 67, 79, 78, 84, 69, 78, +/* 0x1940 */ 84, 83, 44, 32, 82, 69, 65, 68, 79, 78, 76, 89, 10, 32, 32, 51, +/* 0x1950 */ 32, 78, 82, 86, 95, 72, 69, 65, 68, 32, 32, 32, 32, 32, 32, 48, +/* 0x1960 */ 48, 48, 48, 48, 48, 54, 55, 32, 32, 48, 48, 48, 48, 48, 48, 48, +/* 0x1970 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, +/* 0x1980 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, +/* 0x1990 */ 48, 48, 48, 57,102, 32, 32, 50, 42, 42, 48, 32, 32, 67, 79, 78, +/* 0x19a0 */ 84, 69, 78, 84, 83, 44, 32, 82, 69, 65, 68, 79, 78, 76, 89, 10, +/* 0x19b0 */ 32, 32, 52, 32, 78, 82, 86, 50, 69, 32, 32, 32, 32, 32, 32, 32, +/* 0x19c0 */ 32, 32, 48, 48, 48, 48, 48, 48, 98, 55, 32, 32, 48, 48, 48, 48, +/* 0x19d0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, +/* 0x19e0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, +/* 0x19f0 */ 48, 48, 48, 48, 48, 49, 48, 54, 32, 32, 50, 42, 42, 48, 32, 32, +/* 0x1a00 */ 67, 79, 78, 84, 69, 78, 84, 83, 44, 32, 82, 69, 76, 79, 67, 44, +/* 0x1a10 */ 32, 82, 69, 65, 68, 79, 78, 76, 89, 10, 32, 32, 53, 32, 78, 82, +/* 0x1a20 */ 86, 50, 68, 32, 32, 32, 32, 32, 32, 32, 32, 32, 48, 48, 48, 48, +/* 0x1a30 */ 48, 48, 57,101, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1a40 */ 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1a50 */ 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 49, +/* 0x1a60 */ 98,100, 32, 32, 50, 42, 42, 48, 32, 32, 67, 79, 78, 84, 69, 78, +/* 0x1a70 */ 84, 83, 44, 32, 82, 69, 76, 79, 67, 44, 32, 82, 69, 65, 68, 79, +/* 0x1a80 */ 78, 76, 89, 10, 32, 32, 54, 32, 78, 82, 86, 50, 66, 32, 32, 32, +/* 0x1a90 */ 32, 32, 32, 32, 32, 32, 48, 48, 48, 48, 48, 48, 57, 48, 32, 32, +/* 0x1aa0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1ab0 */ 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1ac0 */ 48, 48, 32, 32, 48, 48, 48, 48, 48, 50, 53, 98, 32, 32, 50, 42, +/* 0x1ad0 */ 42, 48, 32, 32, 67, 79, 78, 84, 69, 78, 84, 83, 44, 32, 82, 69, +/* 0x1ae0 */ 76, 79, 67, 44, 32, 82, 69, 65, 68, 79, 78, 76, 89, 10, 32, 32, +/* 0x1af0 */ 55, 32, 76, 90, 77, 65, 95, 69, 76, 70, 48, 48, 32, 32, 32, 32, +/* 0x1b00 */ 48, 48, 48, 48, 48, 48, 54, 52, 32, 32, 48, 48, 48, 48, 48, 48, +/* 0x1b10 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, +/* 0x1b20 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, +/* 0x1b30 */ 48, 48, 48, 50,101, 98, 32, 32, 50, 42, 42, 48, 32, 32, 67, 79, +/* 0x1b40 */ 78, 84, 69, 78, 84, 83, 44, 32, 82, 69, 76, 79, 67, 44, 32, 82, +/* 0x1b50 */ 69, 65, 68, 79, 78, 76, 89, 10, 32, 32, 56, 32, 76, 90, 77, 65, +/* 0x1b60 */ 95, 68, 69, 67, 49, 48, 32, 32, 32, 32, 48, 48, 48, 48, 48, 57, +/* 0x1b70 */ 102, 55, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1b80 */ 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1b90 */ 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 51, 52,102, +/* 0x1ba0 */ 32, 32, 50, 42, 42, 48, 32, 32, 67, 79, 78, 84, 69, 78, 84, 83, +/* 0x1bb0 */ 44, 32, 82, 69, 65, 68, 79, 78, 76, 89, 10, 32, 32, 57, 32, 76, +/* 0x1bc0 */ 90, 77, 65, 95, 68, 69, 67, 50, 48, 32, 32, 32, 32, 48, 48, 48, +/* 0x1bd0 */ 48, 48, 57,102, 55, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1be0 */ 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, 48, +/* 0x1bf0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, +/* 0x1c00 */ 100, 52, 54, 32, 32, 50, 42, 42, 48, 32, 32, 67, 79, 78, 84, 69, +/* 0x1c10 */ 78, 84, 83, 44, 32, 82, 69, 65, 68, 79, 78, 76, 89, 10, 32, 49, +/* 0x1c20 */ 48, 32, 76, 90, 77, 65, 95, 68, 69, 67, 51, 48, 32, 32, 32, 32, +/* 0x1c30 */ 48, 48, 48, 48, 48, 48, 49, 52, 32, 32, 48, 48, 48, 48, 48, 48, +/* 0x1c40 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, +/* 0x1c50 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, +/* 0x1c60 */ 48, 48, 49, 55, 51,100, 32, 32, 50, 42, 42, 48, 32, 32, 67, 79, +/* 0x1c70 */ 78, 84, 69, 78, 84, 83, 44, 32, 82, 69, 65, 68, 79, 78, 76, 89, +/* 0x1c80 */ 10, 32, 49, 49, 32, 78, 82, 86, 95, 84, 65, 73, 76, 32, 32, 32, +/* 0x1c90 */ 32, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, +/* 0x1ca0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 32, 48, +/* 0x1cb0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, +/* 0x1cc0 */ 32, 48, 48, 48, 48, 49, 55, 53, 49, 32, 32, 50, 42, 42, 48, 32, +/* 0x1cd0 */ 32, 67, 79, 78, 84, 69, 78, 84, 83, 44, 32, 82, 69, 65, 68, 79, +/* 0x1ce0 */ 78, 76, 89, 10, 32, 49, 50, 32, 77, 65, 67, 72, 77, 65, 73, 78, +/* 0x1cf0 */ 89, 32, 32, 32, 32, 32, 48, 48, 48, 48, 48, 48, 49, 49, 32, 32, +/* 0x1d00 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1d10 */ 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1d20 */ 48, 48, 32, 32, 48, 48, 48, 48, 49, 55, 53, 49, 32, 32, 50, 42, +/* 0x1d30 */ 42, 48, 32, 32, 67, 79, 78, 84, 69, 78, 84, 83, 44, 32, 82, 69, +/* 0x1d40 */ 65, 68, 79, 78, 76, 89, 10, 32, 49, 51, 32, 77, 65, 67, 72, 77, +/* 0x1d50 */ 65, 73, 78, 90, 32, 32, 32, 32, 32, 48, 48, 48, 48, 48, 48, 52, +/* 0x1d60 */ 49, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1d70 */ 48, 48, 48, 32, 32, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1d80 */ 48, 48, 48, 48, 48, 32, 32, 48, 48, 48, 48, 49, 55, 54, 50, 32, +/* 0x1d90 */ 32, 50, 42, 42, 48, 32, 32, 67, 79, 78, 84, 69, 78, 84, 83, 44, +/* 0x1da0 */ 32, 82, 69, 65, 68, 79, 78, 76, 89, 10, 83, 89, 77, 66, 79, 76, +/* 0x1db0 */ 32, 84, 65, 66, 76, 69, 58, 10, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1dc0 */ 48, 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, 32, +/* 0x1dd0 */ 32, 78, 82, 86, 95, 72, 69, 65, 68, 9, 48, 48, 48, 48, 48, 48, +/* 0x1de0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 78, 82, 86, 95, 72, +/* 0x1df0 */ 69, 65, 68, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1e00 */ 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, 32, 32, 76, 90, 77, +/* 0x1e10 */ 65, 95, 68, 69, 67, 51, 48, 9, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1e20 */ 48, 48, 48, 48, 48, 48, 48, 48, 32, 76, 90, 77, 65, 95, 68, 69, +/* 0x1e30 */ 67, 51, 48, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1e40 */ 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, 32, 32, 77, 65, 67, +/* 0x1e50 */ 72, 77, 65, 73, 78, 89, 9, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1e60 */ 48, 48, 48, 48, 48, 48, 48, 32, 77, 65, 67, 72, 77, 65, 73, 78, +/* 0x1e70 */ 89, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1e80 */ 48, 48, 32,108, 32, 32, 32, 32,100, 32, 32, 77, 65, 67, 72, 77, +/* 0x1e90 */ 65, 73, 78, 90, 9, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1ea0 */ 48, 48, 48, 48, 48, 32, 77, 65, 67, 72, 77, 65, 73, 78, 90, 10, +/* 0x1eb0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1ec0 */ 32,108, 32, 32, 32, 32,100, 32, 32, 65, 77, 68, 54, 52, 66, 88, +/* 0x1ed0 */ 88, 9, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1ee0 */ 48, 48, 32, 65, 77, 68, 54, 52, 66, 88, 88, 10, 48, 48, 48, 48, +/* 0x1ef0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, +/* 0x1f00 */ 32, 32,100, 32, 32, 77, 65, 67, 72, 77, 65, 73, 78, 88, 9, 48, +/* 0x1f10 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, +/* 0x1f20 */ 77, 65, 67, 72, 77, 65, 73, 78, 88, 10, 48, 48, 48, 48, 48, 48, +/* 0x1f30 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, 32, +/* 0x1f40 */ 100, 32, 32, 77, 65, 67, 72, 95, 85, 78, 67, 9, 48, 48, 48, 48, +/* 0x1f50 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 77, 65, 67, +/* 0x1f60 */ 72, 95, 85, 78, 67, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1f70 */ 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, 32, 32, 78, +/* 0x1f80 */ 82, 86, 50, 69, 9, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1f90 */ 48, 48, 48, 48, 48, 32, 78, 82, 86, 50, 69, 10, 48, 48, 48, 48, +/* 0x1fa0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, +/* 0x1fb0 */ 32, 32,100, 32, 32, 78, 82, 86, 50, 68, 9, 48, 48, 48, 48, 48, +/* 0x1fc0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 78, 82, 86, 50, +/* 0x1fd0 */ 68, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x1fe0 */ 48, 48, 32,108, 32, 32, 32, 32,100, 32, 32, 78, 82, 86, 50, 66, +/* 0x1ff0 */ 9, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x2000 */ 48, 32, 78, 82, 86, 50, 66, 10, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x2010 */ 48, 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, 32, +/* 0x2020 */ 32, 76, 90, 77, 65, 95, 69, 76, 70, 48, 48, 9, 48, 48, 48, 48, +/* 0x2030 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 76, 90, 77, +/* 0x2040 */ 65, 95, 69, 76, 70, 48, 48, 10, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x2050 */ 48, 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, 32, +/* 0x2060 */ 32, 76, 90, 77, 65, 95, 68, 69, 67, 49, 48, 9, 48, 48, 48, 48, +/* 0x2070 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 76, 90, 77, +/* 0x2080 */ 65, 95, 68, 69, 67, 49, 48, 10, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x2090 */ 48, 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, 32, +/* 0x20a0 */ 32, 76, 90, 77, 65, 95, 68, 69, 67, 50, 48, 9, 48, 48, 48, 48, +/* 0x20b0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 76, 90, 77, +/* 0x20c0 */ 65, 95, 68, 69, 67, 50, 48, 10, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x20d0 */ 48, 48, 48, 48, 48, 48, 48, 48, 32,108, 32, 32, 32, 32,100, 32, +/* 0x20e0 */ 32, 78, 82, 86, 95, 84, 65, 73, 76, 9, 48, 48, 48, 48, 48, 48, +/* 0x20f0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 32, 78, 82, 86, 95, 84, +/* 0x2100 */ 65, 73, 76, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x2110 */ 48, 48, 48, 48, 32,103, 32, 32, 32, 32, 32, 32, 32, 77, 65, 67, +/* 0x2120 */ 72, 77, 65, 73, 78, 88, 9, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x2130 */ 48, 48, 48, 48, 48, 48, 48, 32, 95,115,116, 97,114,116, 10, 48, +/* 0x2140 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 49, 49, 32, +/* 0x2150 */ 103, 32, 32, 32, 32, 32, 32, 32, 77, 65, 67, 72, 77, 65, 73, 78, +/* 0x2160 */ 89, 9, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x2170 */ 48, 48, 32,101,110,100, 95,100,101, 99,111,109,112,114,101,115, +/* 0x2180 */ 115, 10, 10, 82, 69, 76, 79, 67, 65, 84, 73, 79, 78, 32, 82, 69, +/* 0x2190 */ 67, 79, 82, 68, 83, 32, 70, 79, 82, 32, 91, 77, 65, 67, 72, 77, +/* 0x21a0 */ 65, 73, 78, 88, 93, 58, 10, 79, 70, 70, 83, 69, 84, 32, 32, 32, +/* 0x21b0 */ 32, 32, 32, 32, 32, 32, 32, 32, 84, 89, 80, 69, 32, 32, 32, 32, +/* 0x21c0 */ 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 86, 65, 76, 85, 69, 10, +/* 0x21d0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 49, +/* 0x21e0 */ 32, 82, 95, 88, 56, 54, 95, 54, 52, 95, 80, 67, 51, 50, 32, 32, +/* 0x21f0 */ 32, 32, 32, 77, 65, 67, 72, 77, 65, 73, 78, 90, 43, 48,120, 48, +/* 0x2200 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 51, 55, 10, +/* 0x2210 */ 10, 82, 69, 76, 79, 67, 65, 84, 73, 79, 78, 32, 82, 69, 67, 79, +/* 0x2220 */ 82, 68, 83, 32, 70, 79, 82, 32, 91, 78, 82, 86, 50, 69, 93, 58, +/* 0x2230 */ 10, 79, 70, 70, 83, 69, 84, 32, 32, 32, 32, 32, 32, 32, 32, 32, +/* 0x2240 */ 32, 32, 84, 89, 80, 69, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, +/* 0x2250 */ 32, 32, 32, 32, 86, 65, 76, 85, 69, 10, 48, 48, 48, 48, 48, 48, +/* 0x2260 */ 48, 48, 48, 48, 48, 48, 48, 48, 97,101, 32, 82, 95, 88, 56, 54, +/* 0x2270 */ 95, 54, 52, 95, 80, 67, 51, 50, 32, 32, 32, 32, 32, 78, 82, 86, +/* 0x2280 */ 95, 72, 69, 65, 68, 43, 48,120, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x2290 */ 48, 48, 48, 48, 48, 48, 50, 49, 10, 48, 48, 48, 48, 48, 48, 48, +/* 0x22a0 */ 48, 48, 48, 48, 48, 48, 48, 53, 98, 32, 82, 95, 88, 56, 54, 95, +/* 0x22b0 */ 54, 52, 95, 80, 67, 51, 50, 32, 32, 32, 32, 32, 77, 65, 67, 72, +/* 0x22c0 */ 77, 65, 73, 78, 89, 43, 48,120,102,102,102,102,102,102,102,102, +/* 0x22d0 */ 102,102,102,102,102,102,102, 99, 10, 10, 82, 69, 76, 79, 67, 65, +/* 0x22e0 */ 84, 73, 79, 78, 32, 82, 69, 67, 79, 82, 68, 83, 32, 70, 79, 82, +/* 0x22f0 */ 32, 91, 78, 82, 86, 50, 68, 93, 58, 10, 79, 70, 70, 83, 69, 84, +/* 0x2300 */ 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 84, 89, 80, 69, 32, +/* 0x2310 */ 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 86, 65, 76, +/* 0x2320 */ 85, 69, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x2330 */ 48, 57, 53, 32, 82, 95, 88, 56, 54, 95, 54, 52, 95, 80, 67, 51, +/* 0x2340 */ 50, 32, 32, 32, 32, 32, 78, 82, 86, 95, 72, 69, 65, 68, 43, 48, +/* 0x2350 */ 120, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 50, +/* 0x2360 */ 49, 10, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, +/* 0x2370 */ 53, 98, 32, 82, 95, 88, 56, 54, 95, 54, 52, 95, 80, 67, 51, 50, +/* 0x2380 */ 32, 32, 32, 32, 32, 77, 65, 67, 72, 77, 65, 73, 78, 89, 43, 48, +/* 0x2390 */ 120,102,102,102,102,102,102,102,102,102,102,102,102,102,102,102, +/* 0x23a0 */ 99, 10, 10, 82, 69, 76, 79, 67, 65, 84, 73, 79, 78, 32, 82, 69, +/* 0x23b0 */ 67, 79, 82, 68, 83, 32, 70, 79, 82, 32, 91, 78, 82, 86, 50, 66, +/* 0x23c0 */ 93, 58, 10, 79, 70, 70, 83, 69, 84, 32, 32, 32, 32, 32, 32, 32, +/* 0x23d0 */ 32, 32, 32, 32, 84, 89, 80, 69, 32, 32, 32, 32, 32, 32, 32, 32, +/* 0x23e0 */ 32, 32, 32, 32, 32, 32, 86, 65, 76, 85, 69, 10, 48, 48, 48, 48, +/* 0x23f0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 56, 97, 32, 82, 95, 88, +/* 0x2400 */ 56, 54, 95, 54, 52, 95, 80, 67, 51, 50, 32, 32, 32, 32, 32, 78, +/* 0x2410 */ 82, 86, 95, 72, 69, 65, 68, 43, 48,120, 48, 48, 48, 48, 48, 48, +/* 0x2420 */ 48, 48, 48, 48, 48, 48, 48, 48, 50, 49, 10, 48, 48, 48, 48, 48, +/* 0x2430 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 53, 50, 32, 82, 95, 88, 56, +/* 0x2440 */ 54, 95, 54, 52, 95, 80, 67, 51, 50, 32, 32, 32, 32, 32, 77, 65, +/* 0x2450 */ 67, 72, 77, 65, 73, 78, 89, 43, 48,120,102,102,102,102,102,102, +/* 0x2460 */ 102,102,102,102,102,102,102,102,102, 99, 10, 10, 82, 69, 76, 79, +/* 0x2470 */ 67, 65, 84, 73, 79, 78, 32, 82, 69, 67, 79, 82, 68, 83, 32, 70, +/* 0x2480 */ 79, 82, 32, 91, 76, 90, 77, 65, 95, 69, 76, 70, 48, 48, 93, 58, +/* 0x2490 */ 10, 79, 70, 70, 83, 69, 84, 32, 32, 32, 32, 32, 32, 32, 32, 32, +/* 0x24a0 */ 32, 32, 84, 89, 80, 69, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, +/* 0x24b0 */ 32, 32, 32, 32, 86, 65, 76, 85, 69, 10, 48, 48, 48, 48, 48, 48, +/* 0x24c0 */ 48, 48, 48, 48, 48, 48, 48, 48, 48, 54, 32, 82, 95, 88, 56, 54, +/* 0x24d0 */ 95, 54, 52, 95, 80, 67, 51, 50, 32, 32, 32, 32, 32, 76, 90, 77, +/* 0x24e0 */ 65, 95, 68, 69, 67, 51, 48, 43, 48,120, 48, 48, 48, 48, 48, 48, +/* 0x24f0 */ 48, 48, 48, 48, 48, 48, 48, 48, 49, 48, 10 }; diff --git a/src/stub/amd64-darwin.macho-upxmain.h b/src/stub/amd64-darwin.macho-upxmain.h index b84577cd..a311e008 100644 --- a/src/stub/amd64-darwin.macho-upxmain.h +++ b/src/stub/amd64-darwin.macho-upxmain.h @@ -1,5 +1,5 @@ /* amd64-darwin.macho-upxmain.h - created from amd64-darwin.macho-upxmain.exe, 9092 (0x2384) bytes + created from amd64-darwin.macho-upxmain.exe, 8988 (0x231c) bytes This file is part of the UPX executable compressor. @@ -31,13 +31,13 @@ */ -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_SIZE 9092 -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x9ab36775 -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0xbd632719 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_SIZE 8988 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x5d90d86d +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0xa8ca228f -unsigned char stub_amd64_darwin_macho_upxmain_exe[9092] = { +unsigned char stub_amd64_darwin_macho_upxmain_exe[8988] = { /* 0x0000 */ 207,250,237,254, 7, 0, 0, 1, 3, 0, 0,128, 2, 0, 0, 0, -/* 0x0010 */ 15, 0, 0, 0, 0, 5, 0, 0,133, 0, 32, 0, 0, 0, 0, 0, +/* 0x0010 */ 13, 0, 0, 0,136, 4, 0, 0,133, 0, 0, 0, 0, 0, 0, 0, /* 0x0020 */ 25, 0, 0, 0, 72, 0, 0, 0, 95, 95, 80, 65, 71, 69, 90, 69, /* 0x0030 */ 82, 79, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0040 */ 0, 0,255,255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -49,13 +49,13 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[9092] = { /* 0x00a0 */ 7, 0, 0, 0, 5, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, /* 0x00b0 */ 95, 95,116,101,120,116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00c0 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x00d0 */ 240, 7,255,255, 0, 0, 0, 0, 19, 7, 0, 0, 0, 0, 0, 0, -/* 0x00e0 */ 240, 7, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x00d0 */ 59, 9,255,255, 0, 0, 0, 0,203, 5, 0, 0, 0, 0, 0, 0, +/* 0x00e0 */ 59, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00f0 */ 0, 4, 0,128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0100 */ 95, 95,115,116,117, 98,115, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0110 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0120 */ 4, 15,255,255, 0, 0, 0, 0, 54, 0, 0, 0, 0, 0, 0, 0, -/* 0x0130 */ 4, 15, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0120 */ 6, 15,255,255, 0, 0, 0, 0, 54, 0, 0, 0, 0, 0, 0, 0, +/* 0x0130 */ 6, 15, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0140 */ 8, 4, 0,128, 0, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, /* 0x0150 */ 95, 95,115,116,117, 98, 95,104,101,108,112,101,114, 0, 0, 0, /* 0x0160 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -64,14 +64,14 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[9092] = { /* 0x0190 */ 0, 4, 0,128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x01a0 */ 95, 95,117,110,119,105,110,100, 95,105,110,102,111, 0, 0, 0, /* 0x01b0 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x01c0 */ 168, 15,255,255, 0, 0, 0, 0, 80, 0, 0, 0, 0, 0, 0, 0, +/* 0x01c0 */ 168, 15,255,255, 0, 0, 0, 0, 88, 0, 0, 0, 0, 0, 0, 0, /* 0x01d0 */ 168, 15, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x01e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x01f0 */ 25, 0, 0, 0,136, 1, 0, 0, 95, 95, 68, 65, 84, 65, 0, 0, +/* 0x01f0 */ 25, 0, 0, 0, 56, 1, 0, 0, 95, 95, 68, 65, 84, 65, 0, 0, /* 0x0200 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16,255,255, 0, 0, 0, 0, /* 0x0210 */ 0, 16, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, /* 0x0220 */ 0, 16, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 3, 0, 0, 0, -/* 0x0230 */ 4, 0, 0, 0, 0, 0, 0, 0, 95, 95,110,108, 95,115,121,109, +/* 0x0230 */ 3, 0, 0, 0, 0, 0, 0, 0, 95, 95,110,108, 95,115,121,109, /* 0x0240 */ 98,111,108, 95,112,116,114, 0, 95, 95, 68, 65, 84, 65, 0, 0, /* 0x0250 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16,255,255, 0, 0, 0, 0, /* 0x0260 */ 16, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 3, 0, 0, 0, @@ -86,38 +86,38 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[9092] = { /* 0x02f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 24, 16,255,255, 0, 0, 0, 0, /* 0x0300 */ 72, 0, 0, 0, 0, 0, 0, 0, 24, 16, 0, 0, 3, 0, 0, 0, /* 0x0310 */ 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 0, 0, 0, -/* 0x0320 */ 0, 0, 0, 0, 0, 0, 0, 0, 95, 95, 99,111,109,109,111,110, -/* 0x0330 */ 0, 0, 0, 0, 0, 0, 0, 0, 95, 95, 68, 65, 84, 65, 0, 0, -/* 0x0340 */ 0, 0, 0, 0, 0, 0, 0, 0, 96, 16,255,255, 0, 0, 0, 0, -/* 0x0350 */ 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, -/* 0x0360 */ 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, -/* 0x0370 */ 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0, 72, 0, 0, 0, -/* 0x0380 */ 95, 95, 76, 73, 78, 75, 69, 68, 73, 84, 0, 0, 0, 0, 0, 0, -/* 0x0390 */ 0, 32,255,255, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, -/* 0x03a0 */ 0, 32, 0, 0, 0, 0, 0, 0,132, 3, 0, 0, 0, 0, 0, 0, -/* 0x03b0 */ 7, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x03c0 */ 34, 0, 0,128, 48, 0, 0, 0, 0, 32, 0, 0, 8, 0, 0, 0, -/* 0x03d0 */ 8, 32, 0, 0, 56, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x03e0 */ 64, 32, 0, 0,136, 0, 0, 0,200, 32, 0, 0, 96, 0, 0, 0, -/* 0x03f0 */ 2, 0, 0, 0, 24, 0, 0, 0, 56, 33, 0, 0, 19, 0, 0, 0, -/* 0x0400 */ 188, 34, 0, 0,200, 0, 0, 0, 11, 0, 0, 0, 80, 0, 0, 0, -/* 0x0410 */ 0, 0, 0, 0, 2, 0, 0, 0, 2, 0, 0, 0, 6, 0, 0, 0, -/* 0x0420 */ 8, 0, 0, 0, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0430 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0440 */ 104, 34, 0, 0, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0450 */ 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 32, 0, 0, 0, -/* 0x0460 */ 12, 0, 0, 0, 47,117,115,114, 47,108,105, 98, 47,100,121,108, -/* 0x0470 */ 100, 0, 0, 0, 0, 0, 0, 0, 27, 0, 0, 0, 24, 0, 0, 0, -/* 0x0480 */ 23, 55,189, 7,110,207, 57, 27,146, 38,212,221,128, 33, 19, 11, -/* 0x0490 */ 36, 0, 0, 0, 16, 0, 0, 0, 0, 12, 10, 0, 0, 12, 10, 0, -/* 0x04a0 */ 42, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x04b0 */ 40, 0, 0,128, 24, 0, 0, 0,128, 14, 0, 0, 0, 0, 0, 0, -/* 0x04c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 12, 0, 0, 0, 56, 0, 0, 0, -/* 0x04d0 */ 24, 0, 0, 0, 2, 0, 0, 0, 0, 0,214, 4, 0, 0, 1, 0, -/* 0x04e0 */ 47,117,115,114, 47,108,105, 98, 47,108,105, 98, 83,121,115,116, -/* 0x04f0 */ 101,109, 46, 66, 46,100,121,108,105, 98, 0, 0, 0, 0, 0, 0, -/* 0x0500 */ 38, 0, 0, 0, 16, 0, 0, 0, 40, 33, 0, 0, 16, 0, 0, 0, -/* 0x0510 */ 41, 0, 0, 0, 16, 0, 0, 0, 56, 33, 0, 0, 0, 0, 0, 0, +/* 0x0320 */ 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0, 72, 0, 0, 0, +/* 0x0330 */ 95, 95, 76, 73, 78, 75, 69, 68, 73, 84, 0, 0, 0, 0, 0, 0, +/* 0x0340 */ 0, 32,255,255, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, +/* 0x0350 */ 0, 32, 0, 0, 0, 0, 0, 0, 28, 3, 0, 0, 0, 0, 0, 0, +/* 0x0360 */ 7, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0370 */ 34, 0, 0,128, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0380 */ 0, 32, 0, 0, 56, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0390 */ 56, 32, 0, 0,136, 0, 0, 0,192, 32, 0, 0, 64, 0, 0, 0, +/* 0x03a0 */ 2, 0, 0, 0, 24, 0, 0, 0, 0, 33, 0, 0, 17, 0, 0, 0, +/* 0x03b0 */ 100, 34, 0, 0,184, 0, 0, 0, 11, 0, 0, 0, 80, 0, 0, 0, +/* 0x03c0 */ 0, 0, 0, 0, 3, 0, 0, 0, 3, 0, 0, 0, 3, 0, 0, 0, +/* 0x03d0 */ 6, 0, 0, 0, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x03e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x03f0 */ 16, 34, 0, 0, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0400 */ 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 32, 0, 0, 0, +/* 0x0410 */ 12, 0, 0, 0, 47,117,115,114, 47,108,105, 98, 47,100,121,108, +/* 0x0420 */ 100, 0, 0, 0, 0, 0, 0, 0, 36, 0, 0, 0, 16, 0, 0, 0, +/* 0x0430 */ 0, 11, 10, 0, 0, 11, 10, 0, 42, 0, 0, 0, 16, 0, 0, 0, +/* 0x0440 */ 0, 0, 0, 0, 0, 0, 0, 0, 40, 0, 0,128, 24, 0, 0, 0, +/* 0x0450 */ 253, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0460 */ 12, 0, 0, 0, 56, 0, 0, 0, 24, 0, 0, 0, 2, 0, 0, 0, +/* 0x0470 */ 1, 10,202, 4, 0, 0, 1, 0, 47,117,115,114, 47,108,105, 98, +/* 0x0480 */ 47,108,105, 98, 83,121,115,116,101,109, 46, 66, 46,100,121,108, +/* 0x0490 */ 105, 98, 0, 0, 0, 0, 0, 0, 41, 0, 0, 0, 16, 0, 0, 0, +/* 0x04a0 */ 0, 33, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x04b0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x04c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x04d0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x04e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x04f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0500 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0510 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0520 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0530 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0540 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -163,123 +163,123 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[9092] = { /* 0x07c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x07d0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x07e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x07f0 */ 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, -/* 0x0800 */ 72, 77,137,204, 76,137,195, 72,137, 77,152, 73,137,213, 76,139, -/* 0x0810 */ 125, 16, 72,137,117,208, 72,141, 71, 24, 72,137, 69,200, 72,139, -/* 0x0820 */ 69,208, 72,131,192,232, 72,137, 69,192, 76,137,109,184,139, 71, -/* 0x0830 */ 24, 72,137, 69,176, 72,139, 69,192, 72,139, 77,200, 72,137, 77, -/* 0x0840 */ 168, 72,137, 69,160, 69, 49,246, 72,141,125,192, 72,141,117,176, -/* 0x0850 */ 49,201, 72,137,218,232, 38, 1, 0, 0, 76,137, 36, 36, 72,141, -/* 0x0860 */ 85,160,190, 0, 0, 0, 0,185,255,255,255,255, 76,137,239, 77, -/* 0x0870 */ 137,248, 73,137,217,232,198, 3, 0, 0, 72,137,195, 65,139, 77, -/* 0x0880 */ 16,133,201, 15,132,228, 0, 0, 0, 73,141, 69, 32, 15, 31, 0, -/* 0x0890 */ 131, 56, 14,116, 19, 65,255,198,139, 80, 4, 72, 1,208, 65, 57, -/* 0x08a0 */ 206,114,237,233,197, 0, 0, 0,139,120, 8, 72, 1,199, 49,246, -/* 0x08b0 */ 49,210,232,119, 6, 0, 0, 65,137,199, 69,133,255, 72,139, 93, -/* 0x08c0 */ 152,120,119, 69, 49,228, 49,201, 68,137,255, 76,137,238, 72,137, -/* 0x08d0 */ 218,232, 94, 6, 0, 0, 72, 57,216,117, 95, 77,141,117, 8, 65, -/* 0x08e0 */ 139, 69, 0, 61,190,186,254,202,116, 7, 61,202,254,186,190,117, -/* 0x08f0 */ 83, 65,139, 69, 4, 49,201,133,192, 76,137,242,116, 70,102,144, -/* 0x0900 */ 129, 58, 7, 0, 0, 1,116, 24,255,193, 72,131,194, 20, 57,193, -/* 0x0910 */ 114,238,235, 48,102,102,102, 46, 15, 31,132, 0, 0, 0, 0, 0, -/* 0x0920 */ 68,139, 98, 8, 68,137,255, 76,137,238, 72,137,218, 68,137,225, -/* 0x0930 */ 232,255, 5, 0, 0, 72, 57,216,116,165,191,127, 0, 0, 0,232, -/* 0x0940 */ 210, 5, 0, 0, 72,199, 4, 36, 0, 0, 0, 0, 49,210, 69, 49, -/* 0x0950 */ 192, 69, 49,201, 76,137,239, 68,137,230, 68,137,249,232,222, 2, -/* 0x0960 */ 0, 0, 72,137,195, 68,137,255,232,163, 5, 0, 0, 72,137,216, -/* 0x0970 */ 72,131,196, 72, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195,144, -/* 0x0980 */ 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, -/* 0x0990 */ 40, 72,137, 77,184, 72,137, 85,176, 73,137,244, 73,137,255, 73, -/* 0x09a0 */ 131, 60, 36, 0, 15,132,103, 2, 0, 0,102, 15, 31, 68, 0, 0, -/* 0x09b0 */ 73,139, 7, 72,131,248, 11, 15,134,109, 2, 0, 0, 73,139, 87, -/* 0x09c0 */ 8,138, 10,136, 77,200,138, 74, 1,136, 77,201,138, 74, 2,136, -/* 0x09d0 */ 77,202,138, 74, 3,136, 77,203,138, 74, 4,136, 77,204,138, 74, -/* 0x09e0 */ 5,136, 77,205,138, 74, 6,136, 77,206,138, 74, 7,136, 77,207, -/* 0x09f0 */ 138, 74, 8,136, 77,208,138, 74, 9,136, 77,209,138, 74, 10,136, -/* 0x0a00 */ 77,210,138, 74, 11,136, 77,211, 72,141,122, 12, 73,137,127, 8, -/* 0x0a10 */ 72,131,192,244, 73,137, 7, 68,139,117,200, 68,139,109,204, 77, -/* 0x0a20 */ 133,246, 15,132,219, 1, 0, 0, 65,141, 77,255, 68, 57,241, 15, -/* 0x0a30 */ 131,235, 1, 0, 0, 77, 59, 52, 36, 15,135,225, 1, 0, 0, 69, -/* 0x0a40 */ 57,245,115, 92, 68,137,117,196, 73,139, 84, 36, 8,139, 93,208, -/* 0x0a50 */ 68, 15,182,195, 68,137,238, 72,141, 77,196,255, 85,176,133,192, -/* 0x0a60 */ 15,133,186, 1, 0, 0, 68, 57,117,196, 15,133,176, 1, 0, 0, -/* 0x0a70 */ 72,131,125,184, 0,116, 28, 15,182,199,102,133,192,116, 20,193, -/* 0x0a80 */ 235, 16, 15,183,200, 73,139,124, 36, 8, 15,182,211, 68,137,246, -/* 0x0a90 */ 255, 85,184, 77, 1,111, 8, 77, 41, 47,233, 73, 1, 0, 0,144, -/* 0x0aa0 */ 76, 57,232, 15,130,129, 1, 0, 0, 69,133,237, 15,132, 41, 1, -/* 0x0ab0 */ 0, 0, 73,139,116, 36, 8, 65,131,253, 32,114, 51, 69,137,232, -/* 0x0ac0 */ 65,131,224, 31, 69, 57,197,116, 39, 74,141, 68, 42, 11, 72, 57, -/* 0x0ad0 */ 198, 15,135,151, 0, 0, 0, 74,141, 68, 46,255, 72, 57,199, 15, -/* 0x0ae0 */ 135,137, 0, 0, 0,102,102, 46, 15, 31,132, 0, 0, 0, 0, 0, -/* 0x0af0 */ 76,137,232, 72,137,241, 72,141, 80,255,168, 7,116, 36,137,198, -/* 0x0b00 */ 131,230, 7, 72,247,222,102, 46, 15, 31,132, 0, 0, 0, 0, 0, -/* 0x0b10 */ 72,255,200,138, 31,136, 25, 72,255,199, 72,255,193, 72,255,198, -/* 0x0b20 */ 117,238, 72,131,250, 7, 15,130,164, 0, 0, 0, 15, 31, 64, 0, -/* 0x0b30 */ 138, 23,136, 17,138, 87, 1,136, 81, 1,138, 87, 2,136, 81, 2, -/* 0x0b40 */ 138, 87, 3,136, 81, 3,138, 87, 4,136, 81, 4,138, 87, 5,136, -/* 0x0b50 */ 81, 5,138, 87, 6,136, 81, 6, 72,131,192,248,138, 87, 7, 72, -/* 0x0b60 */ 141,127, 8,136, 81, 7, 72,141, 73, 8,117,196,235, 98, 76,137, -/* 0x0b70 */ 235, 76, 41,195, 76,137,232, 72, 41,216, 72,141, 12, 30, 72, 1, -/* 0x0b80 */ 223, 72,131,194, 28, 72,131,198, 16, 69,137,233, 65,131,225, 31, -/* 0x0b90 */ 76,137,235, 76, 41,203,102, 46, 15, 31,132, 0, 0, 0, 0, 0, -/* 0x0ba0 */ 15, 16, 66,240, 15, 16, 10, 15, 17, 70,240, 15, 17, 14, 72,131, -/* 0x0bb0 */ 194, 32, 72,131,198, 32, 72,131,195,224,117,228, 69,133,192, 15, -/* 0x0bc0 */ 133, 49,255,255,255,102,102, 46, 15, 31,132, 0, 0, 0, 0, 0, -/* 0x0bd0 */ 73,139, 7, 73,139,127, 8, 68,139,117,200, 76, 1,239, 73,137, -/* 0x0be0 */ 127, 8, 76, 41,232, 73,137, 7, 68,137,240, 73, 1, 68, 36, 8, -/* 0x0bf0 */ 73,139, 12, 36, 72, 41,193, 73,137, 12, 36, 15,133,175,253,255, -/* 0x0c00 */ 255,235, 14, 72,133,192,117, 24, 65,129,253, 85, 80, 88, 33,117, -/* 0x0c10 */ 15, 72,131,196, 40, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195, -/* 0x0c20 */ 191,127, 0, 0, 0,232,236, 2, 0, 0,191,127, 0, 0, 0,232, -/* 0x0c30 */ 226, 2, 0, 0,102,102,102, 46, 15, 31,132, 0, 0, 0, 0, 0, -/* 0x0c40 */ 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, -/* 0x0c50 */ 104, 76,137, 77,128, 76,137,133,120,255,255,255,137, 77,156, 72, -/* 0x0c60 */ 137, 85,192, 72,137,125,168,139, 71, 16, 49,219,133,192,185, 0, -/* 0x0c70 */ 0, 0, 0, 72,137, 77,160, 15,132,221, 1, 0, 0, 72,139, 77, -/* 0x0c80 */ 168, 76,141,113, 32, 72,131,125,192, 0, 15,149,193, 15,182,201, -/* 0x0c90 */ 72,141, 12, 73, 72,137, 77,144,137,241, 72,137, 77,136, 49,201, -/* 0x0ca0 */ 72,137, 77,160,102,102,102, 46, 15, 31,132, 0, 0, 0, 0, 0, -/* 0x0cb0 */ 73,139, 22, 72,137,209, 72,193,233, 32,131,250, 25, 15,133, 45, -/* 0x0cc0 */ 1, 0, 0, 73,139, 86, 32, 72,133,210, 15,132,123, 1, 0, 0, -/* 0x0cd0 */ 72,137, 85,176, 73,139, 70, 48, 72,137, 69,200, 77,139,126, 24, -/* 0x0ce0 */ 76,137,125,184, 76,137,125,208, 69,137,252, 65,129,228,255, 15, -/* 0x0cf0 */ 0, 0, 77, 41,231, 73, 1,196,116, 76, 72,139, 77,144, 73,141, -/* 0x0d00 */ 52, 12, 72,133,192,185, 18, 0, 0, 0,186, 18, 16, 0, 0, 15, -/* 0x0d10 */ 68,202, 72,131,125,192, 0, 15, 69,202, 72,131,248, 1, 69, 25, -/* 0x0d20 */ 192, 68, 11, 69,156, 69,139, 78, 40, 72,139, 69,136, 65, 1,193, -/* 0x0d30 */ 186, 3, 0, 0, 0, 76,137,255,232,223, 1, 0, 0, 73, 57,199, -/* 0x0d40 */ 15,133, 39, 1, 0, 0, 72,131,125,192, 0,116, 45, 73,131,126, -/* 0x0d50 */ 48, 0,116, 38, 73,131,126, 40, 0,117, 10, 72,139,133,120,255, -/* 0x0d60 */ 255,255, 76,137, 56, 72,139,125,192, 72,141,117,200, 72,139, 85, -/* 0x0d70 */ 128, 72,139, 77, 16,232, 6,252,255,255, 69,137,229, 65,247,221, -/* 0x0d80 */ 73,129,229,255, 15, 0, 0,116, 12, 75,141, 60, 39, 76,137,238, -/* 0x0d90 */ 232,111, 1, 0, 0, 77,133,228,116, 23, 65,139, 86, 60, 76,137, -/* 0x0da0 */ 255, 76,137,230,232,121, 1, 0, 0,133,192, 15,133,188, 0, 0, -/* 0x0db0 */ 0, 72,139, 69,184, 72, 3, 69,176, 77, 1,229, 77, 1,239, 73, -/* 0x0dc0 */ 57,199,115, 78, 77,133,255,116,119, 72,137,198, 76, 41,254, 65, -/* 0x0dd0 */ 139, 86, 60,185, 18, 16, 0, 0, 65,184,255,255,255,255, 69, 49, -/* 0x0de0 */ 201, 76,137,255,232, 51, 1, 0, 0, 73, 57,199,116, 82,235,125, -/* 0x0df0 */ 131,226,254,131,250, 4,117, 83, 72,186, 4, 0, 0, 0, 42, 0, -/* 0x0e00 */ 0, 0, 73, 57, 86, 8,117, 67, 73,141, 86, 16, 72,137, 85,160, -/* 0x0e10 */ 235, 57, 72,131,125,192, 0,116, 39, 65,131,196, 3, 65,129,228, -/* 0x0e20 */ 255, 15, 0, 0, 73,131,252, 3,119, 22, 76,137,255, 76,137,230, -/* 0x0e30 */ 232,243, 0, 0, 0,102,102, 46, 15, 31,132, 0, 0, 0, 0, 0, -/* 0x0e40 */ 65,139, 78, 4, 72,139, 69,168,139, 64, 16,255,195,137,201, 73, -/* 0x0e50 */ 1,206, 57,195, 15,130, 86,254,255,255, 72,139, 69,160, 72,131, -/* 0x0e60 */ 196,104, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195,191,127, 0, -/* 0x0e70 */ 0, 0,232,159, 0, 0, 0,102, 15, 31,132, 0, 0, 0, 0, 0, -/* 0x0e80 */ 85, 72,137,229, 65, 86, 83, 72,129,236, 32, 8, 0, 0, 76,139, -/* 0x0e90 */ 53,123, 1, 0, 0, 77,139, 54, 76,137,117,232,191,248,255,254, -/* 0x0ea0 */ 255, 72,139, 55, 72,131,199, 8, 72, 41,247, 72,141, 5,174, 1, -/* 0x0eb0 */ 0, 0, 76,139, 0, 72,141, 5,172, 1, 0, 0, 76,139, 8, 72, -/* 0x0ec0 */ 141,157,216,247,255,255, 72,137, 28, 36, 72,141,149,224,247,255, -/* 0x0ed0 */ 255,185, 0, 8, 0, 0,232, 21,249,255,255, 72,141, 13,142, 1, -/* 0x0ee0 */ 0, 0, 72,137,199, 72,137,222,255, 17, 76, 59,117,232,117, 14, -/* 0x0ef0 */ 49,192, 72,129,196, 32, 8, 0, 0, 91, 65, 94, 93,195,232, 7, -/* 0x0f00 */ 0, 0, 0,144,255, 37, 14, 1, 0, 0,255, 37, 16, 1, 0, 0, -/* 0x0f10 */ 255, 37, 18, 1, 0, 0,255, 37, 20, 1, 0, 0,255, 37, 22, 1, -/* 0x0f20 */ 0, 0,255, 37, 24, 1, 0, 0,255, 37, 26, 1, 0, 0,255, 37, -/* 0x0f30 */ 28, 1, 0, 0,255, 37, 30, 1, 0, 0, 0, 0, 76,141, 29,197, +/* 0x07f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0800 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0810 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0820 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0830 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0840 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0850 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0860 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0870 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0880 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0890 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x08a0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x08b0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x08c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x08d0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x08e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x08f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0900 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0910 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0920 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0930 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 85, 72,137,229, 65, +/* 0x0940 */ 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, 72, 77,137,204, 76, +/* 0x0950 */ 137,195, 72,137, 77,152, 73,137,213, 76,139,125, 16, 72,137,117, +/* 0x0960 */ 208, 72,141, 71, 24, 72,137, 69,200, 72,139, 69,208, 72,131,192, +/* 0x0970 */ 232, 72,137, 69,192, 76,137,109,184,139, 71, 24, 72,137, 69,176, +/* 0x0980 */ 72,139, 69,192, 72,139, 77,200, 72,137, 77,168, 72,137, 69,160, +/* 0x0990 */ 69, 49,246, 72,141,125,192, 72,141,117,176, 49,201, 72,137,218, +/* 0x09a0 */ 232, 20, 1, 0, 0, 76,137, 36, 36, 72,141, 85,160,190, 0, 0, +/* 0x09b0 */ 0, 0,185,255,255,255,255, 76,137,239, 77,137,248, 73,137,217, +/* 0x09c0 */ 232, 10, 2, 0, 0, 72,137,195, 65,139, 77, 16,133,201, 15,132, +/* 0x09d0 */ 211, 0, 0, 0, 73,141, 69, 32,131, 56, 14,116, 19, 65,255,198, +/* 0x09e0 */ 139, 80, 4, 72, 1,208, 65, 57,206,114,237,233,183, 0, 0, 0, +/* 0x09f0 */ 139,120, 8, 72, 1,199, 49,246, 49,210,232, 49, 5, 0, 0, 65, +/* 0x0a00 */ 137,199, 69,133,255, 72,139, 93,152,120,105, 49,201, 68,137,255, +/* 0x0a10 */ 76,137,238, 72,137,218,232, 27, 5, 0, 0, 72, 57,216,117, 84, +/* 0x0a20 */ 77,141,117, 16, 69, 49,228, 65,139, 69, 0, 61,190,186,254,202, +/* 0x0a30 */ 116, 7, 61,202,254,186,190,117, 69, 65,139, 69, 4, 49,201,133, +/* 0x0a40 */ 192, 76,137,242,116, 56,129,122,248, 7, 0, 0, 1,116, 12,255, +/* 0x0a50 */ 193, 72,131,194, 20, 57,193,114,237,235, 35, 68,139, 34, 68,137, +/* 0x0a60 */ 255, 76,137,238, 72,137,218, 76,137,225,232,199, 4, 0, 0, 72, +/* 0x0a70 */ 57,216,116,179,191,127, 0, 0, 0,232,154, 4, 0, 0, 72,199, +/* 0x0a80 */ 4, 36, 0, 0, 0, 0, 49,210, 69, 49,192, 69, 49,201, 76,137, +/* 0x0a90 */ 239, 76,137,230, 68,137,249,232, 51, 1, 0, 0, 72,137,195, 68, +/* 0x0aa0 */ 137,255,232,107, 4, 0, 0, 72,137,216, 72,131,196, 72, 91, 65, +/* 0x0ab0 */ 92, 65, 93, 65, 94, 65, 95, 93,195, 85, 72,137,229, 65, 87, 65, +/* 0x0ac0 */ 86, 65, 85, 65, 84, 83, 72,131,236, 56, 72,137, 77,176, 72,137, +/* 0x0ad0 */ 85,168, 73,137,246, 72,137,125,184, 73,131, 62, 0, 15,132,211, +/* 0x0ae0 */ 0, 0, 0, 76,141,101,200,186, 12, 0, 0, 0, 72,139,125,184, +/* 0x0af0 */ 76,137,230,232,196, 3, 0, 0, 68,139,109,200, 68,139,125,204, +/* 0x0b00 */ 77,133,237, 15,132,154, 0, 0, 0, 65,141, 71,255, 68, 57,232, +/* 0x0b10 */ 15,131,175, 0, 0, 0, 77, 59, 46, 15,135,166, 0, 0, 0, 69, +/* 0x0b20 */ 57,239,115, 90, 68,137,109,196, 72,139, 69,184, 72,139,120, 8, +/* 0x0b30 */ 73,139, 86, 8,139, 93,208, 68, 15,182,195, 68,137,254, 72,141, +/* 0x0b40 */ 77,196,255, 85,168,133,192,117,124, 68, 57,109,196,117,118, 72, +/* 0x0b50 */ 131,125,176, 0,116, 27, 15,182,199,102,133,192,116, 19,193,235, +/* 0x0b60 */ 16, 15,183,200, 73,139,126, 8, 15,182,211, 68,137,238,255, 85, +/* 0x0b70 */ 176, 72,139, 69,184, 76, 1,120, 8, 76, 41, 56,235, 16, 73,139, +/* 0x0b80 */ 118, 8, 72,139,125,184, 76,137,250,232, 46, 3, 0, 0, 77, 1, +/* 0x0b90 */ 110, 8, 73,139, 6, 76, 41,232, 73,137, 6, 15,133, 70,255,255, +/* 0x0ba0 */ 255,235, 19, 65,129,255, 85, 80, 88, 33,117, 25, 72,139, 69,184, +/* 0x0bb0 */ 72,131, 56, 0,117, 15, 72,131,196, 56, 91, 65, 92, 65, 93, 65, +/* 0x0bc0 */ 94, 65, 95, 93,195,191,127, 0, 0, 0,232, 73, 3, 0, 0, 85, +/* 0x0bd0 */ 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236,104, +/* 0x0be0 */ 76,137,141,120,255,255,255, 76,137,133,112,255,255,255,137, 77, +/* 0x0bf0 */ 148, 72,137, 85,192, 72,137,117,136, 72,137,125,152,139,119, 16, +/* 0x0c00 */ 69, 49,255,133,246,184, 0, 0, 0, 0, 15,132,212, 1, 0, 0, +/* 0x0c10 */ 72,139, 77,152, 76,141,105, 32, 72,131,125,192, 0, 15,149,193, +/* 0x0c20 */ 15,182,201, 72,141, 12, 73, 72,137, 77,128, 49,255, 49,192, 73, +/* 0x0c30 */ 139, 85, 0, 72,137,209, 72,193,233, 32,129,250, 40, 0, 0,128, +/* 0x0c40 */ 15,132, 65, 1, 0, 0,131,250, 25, 15,133,132, 1, 0, 0, 73, +/* 0x0c50 */ 139, 85, 32, 72,133,210, 15,132,119, 1, 0, 0, 72,137, 85,168, +/* 0x0c60 */ 72,137,125,184, 72,137, 69,160, 73,139, 69, 48, 72,137, 69,200, +/* 0x0c70 */ 77,139,101, 24, 76,137,101,176, 76,137,101,208, 69,137,230, 65, +/* 0x0c80 */ 129,230,255, 15, 0, 0, 77, 41,244, 73, 1,198,116, 73, 72,139, +/* 0x0c90 */ 77,128, 73,141, 52, 14, 72,133,192,185, 18, 0, 0, 0,186, 18, +/* 0x0ca0 */ 16, 0, 0, 15, 68,202, 72,131,125,192, 0, 15, 69,202, 72,131, +/* 0x0cb0 */ 248, 1, 69, 25,192, 68, 11, 69,148, 77,139, 77, 40, 76, 3, 77, +/* 0x0cc0 */ 136,186, 3, 0, 0, 0, 76,137,231,232, 80, 2, 0, 0, 73, 57, +/* 0x0cd0 */ 196, 15,133, 28, 1, 0, 0, 72,131,125,192, 0,116, 52, 73,131, +/* 0x0ce0 */ 125, 48, 0,116, 45, 73,131,125, 40, 0,117, 14, 72,139,133,112, +/* 0x0cf0 */ 255,255,255, 76,137, 32, 76,137,109,184, 72,139,125,192, 72,141, +/* 0x0d00 */ 117,200, 72,139,149,120,255,255,255, 72,139, 77, 16,232,167,253, +/* 0x0d10 */ 255,255, 68,137,243,247,219, 72,129,227,255, 15, 0, 0,116, 12, +/* 0x0d20 */ 75,141, 60, 52, 72,137,222,232,218, 1, 0, 0, 77,133,246,116, +/* 0x0d30 */ 23, 65,139, 85, 60, 76,137,231, 76,137,246,232,228, 1, 0, 0, +/* 0x0d40 */ 133,192, 15,133,171, 0, 0, 0, 72,139, 69,176, 72, 3, 69,168, +/* 0x0d50 */ 76, 1,243, 73, 1,220, 73, 57,196,115, 66, 77,133,228,116, 96, +/* 0x0d60 */ 72,137,198, 76, 41,230, 65,139, 85, 60,185, 18, 16, 0, 0, 65, +/* 0x0d70 */ 184,255,255,255,255, 69, 49,201, 76,137,231,232,158, 1, 0, 0, +/* 0x0d80 */ 73, 57,196,116, 59,235,108, 73,139, 69, 8, 72, 57, 71, 40,119, +/* 0x0d90 */ 66, 72, 59, 71, 48,115, 60, 72, 3, 71, 24,235, 54, 72,131,125, +/* 0x0da0 */ 192, 0,116, 28, 65,131,198, 3, 65,129,230,255, 15, 0, 0, 73, +/* 0x0db0 */ 131,254, 3,119, 11, 76,137,231, 76,137,246,232,106, 1, 0, 0, +/* 0x0dc0 */ 65,139, 77, 4, 72,139, 69,152,139,112, 16, 72,139, 69,160, 72, +/* 0x0dd0 */ 139,125,184, 65,255,199,137,201, 73, 1,205, 65, 57,247, 15,130, +/* 0x0de0 */ 75,254,255,255, 72,131,196,104, 91, 65, 92, 65, 93, 65, 94, 65, +/* 0x0df0 */ 95, 93,195,191,127, 0, 0, 0,232, 27, 1, 0, 0, 85, 72,137, +/* 0x0e00 */ 229, 65, 87, 65, 86, 83, 72,129,236, 24, 8, 0, 0, 76,139, 53, +/* 0x0e10 */ 252, 1, 0, 0, 77,139, 54, 76,137,117,224, 72,141, 5,219,255, +/* 0x0e20 */ 255,255, 72, 37, 0, 0,255,255, 68,139,120, 16, 69,133,255,116, +/* 0x0e30 */ 84, 72,131,200, 32, 49,210, 73,187, 85, 80, 88, 95, 68, 65, 84, +/* 0x0e40 */ 65, 73,186, 95, 95, 84, 69, 88, 84, 0, 0,131, 56, 25,117, 40, +/* 0x0e50 */ 72,139, 88, 8, 76, 57,219,116, 23, 76, 57,211,117, 26, 72,139, +/* 0x0e60 */ 88,104, 15,183, 11, 76,141, 68, 11, 2, 76,141, 75, 2,235, 8, +/* 0x0e70 */ 72,139,120, 24, 72,139,112, 48,255,194,139, 72, 4, 72, 1,200, +/* 0x0e80 */ 68, 57,250,114,198, 72,141,133,216,247,255,255, 72,137, 4, 36, +/* 0x0e90 */ 72,141,149,224,247,255,255,185, 0, 8, 0, 0,232,154,250,255, +/* 0x0ea0 */ 255, 76, 59,117,224,117, 16, 49,192, 72,129,196, 24, 8, 0, 0, +/* 0x0eb0 */ 91, 65, 94, 65, 95, 93,195,232, 80, 0, 0, 0, 72,139, 15, 72, +/* 0x0ec0 */ 57,209,114, 52, 72,139, 71, 8, 72,133,210,116, 29, 72,137,209, +/* 0x0ed0 */ 72,255,201, 68,138, 0, 72,141, 64, 1, 68,136, 6, 72,141,118, +/* 0x0ee0 */ 1,117,237, 72,139, 15, 72,139, 71, 8, 72, 1,208, 72,137, 71, +/* 0x0ef0 */ 8, 72, 41,209, 72,137, 15,195, 85, 72,137,229,191,127, 0, 0, +/* 0x0f00 */ 0,232, 18, 0, 0, 0,255, 37, 12, 1, 0, 0,255, 37, 14, 1, +/* 0x0f10 */ 0, 0,255, 37, 16, 1, 0, 0,255, 37, 18, 1, 0, 0,255, 37, +/* 0x0f20 */ 20, 1, 0, 0,255, 37, 22, 1, 0, 0,255, 37, 24, 1, 0, 0, +/* 0x0f30 */ 255, 37, 26, 1, 0, 0,255, 37, 28, 1, 0, 0, 76,141, 29,197, /* 0x0f40 */ 0, 0, 0, 65, 83,255, 37,181, 0, 0, 0,144,104, 0, 0, 0, /* 0x0f50 */ 0,233,230,255,255,255,104, 15, 0, 0, 0,233,220,255,255,255, /* 0x0f60 */ 104, 39, 0, 0, 0,233,210,255,255,255,104, 52, 0, 0, 0,233, @@ -288,10 +288,10 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[9092] = { /* 0x0f90 */ 255,255,104,106, 0, 0, 0,233,160,255,255,255,104,118, 0, 0, /* 0x0fa0 */ 0,233,150,255,255,255, 0, 0, 1, 0, 0, 0, 28, 0, 0, 0, /* 0x0fb0 */ 0, 0, 0, 0, 28, 0, 0, 0, 0, 0, 0, 0, 28, 0, 0, 0, -/* 0x0fc0 */ 2, 0, 0, 0,240, 7, 0, 0, 52, 0, 0, 0, 52, 0, 0, 0, -/* 0x0fd0 */ 4, 15, 0, 0, 0, 0, 0, 0, 52, 0, 0, 0, 3, 0, 0, 0, -/* 0x0fe0 */ 12, 0, 2, 0, 20, 0, 2, 0, 0, 0, 0, 1,144, 6, 0, 0, -/* 0x0ff0 */ 33, 0, 2, 1,209, 88, 5, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0fc0 */ 2, 0, 0, 0, 59, 9, 0, 0, 52, 0, 0, 0, 52, 0, 0, 0, +/* 0x0fd0 */ 7, 15, 0, 0, 0, 0, 0, 0, 52, 0, 0, 0, 3, 0, 0, 0, +/* 0x0fe0 */ 12, 0, 3, 0, 24, 0, 3, 0, 0, 0, 0, 2,194, 4, 0, 1, +/* 0x0ff0 */ 129, 5, 0, 0, 0, 0, 0, 1, 97, 1, 3, 1,209, 88, 5, 1, /* 0x1000 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x1010 */ 0, 0, 0, 0, 0, 0, 0, 0, 76, 15,255,255, 0, 0, 0, 0, /* 0x1020 */ 86, 15,255,255, 0, 0, 0, 0, 96, 15,255,255, 0, 0, 0, 0, @@ -548,61 +548,54 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[9092] = { /* 0x1fd0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x1fe0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x1ff0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x2000 */ 17, 34, 24, 89, 0, 0, 0, 0, 17, 64, 95, 95, 95,115,116, 97, -/* 0x2010 */ 99,107, 95, 99,104,107, 95,103,117, 97,114,100, 0, 81,114, 16, -/* 0x2020 */ 144, 64,100,121,108,100, 95,115,116,117, 98, 95, 98,105,110,100, -/* 0x2030 */ 101,114, 0,128,232,255,255,255,255,255,255,255,255, 1,144, 0, -/* 0x2040 */ 114, 24, 17, 64, 95, 95, 95, 98,122,101,114,111, 0,144, 0,114, -/* 0x2050 */ 32, 17, 64, 95, 95, 95,115,116, 97, 99,107, 95, 99,104,107, 95, -/* 0x2060 */ 102, 97,105,108, 0,144, 0,114, 40, 17, 64, 95, 99,108,111,115, -/* 0x2070 */ 101, 0,144, 0,114, 48, 17, 64, 95,101,120,105,116, 0,144, 0, -/* 0x2080 */ 114, 56, 17, 64, 95,109,109, 97,112, 0,144, 0,114, 64, 17, 64, -/* 0x2090 */ 95,109,112,114,111,116,101, 99,116, 0,144, 0,114, 72, 17, 64, -/* 0x20a0 */ 95,109,117,110,109, 97,112, 0,144, 0,114, 80, 17, 64, 95,111, -/* 0x20b0 */ 112,101,110, 0,144, 0,114, 88, 17, 64, 95,112,114,101, 97,100, -/* 0x20c0 */ 0,144, 0, 0, 0, 0, 0, 0, 0, 1, 95, 0, 5, 0, 5, 95, -/* 0x20d0 */ 109,104, 95,101,120,101, 99,117,116,101, 95,104,101, 97,100,101, -/* 0x20e0 */ 114, 0, 55,117,112,120, 95,109, 97,105,110, 0, 59,109, 97,105, -/* 0x20f0 */ 110, 0, 64,102, 95, 0, 69,108, 97,117,110, 99,104, 0, 91, 2, -/* 0x2100 */ 0, 0, 0, 3, 0,240, 15, 0, 3, 0,128, 29, 0, 0, 2,101, -/* 0x2110 */ 120,112, 0, 81,117,110,102, 0, 86, 3, 0,224, 32, 0, 3, 0, -/* 0x2120 */ 232, 32, 0, 3, 0,240, 32, 0,240, 15,144, 3,192, 5,192, 4, -/* 0x2130 */ 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 14, 1, 0, 0, -/* 0x2140 */ 128, 9,255,255, 0, 0, 0, 0, 16, 0, 0, 0, 14, 1, 0, 0, -/* 0x2150 */ 64, 12,255,255, 0, 0, 0, 0, 25, 0, 0, 0, 15, 1, 16, 0, -/* 0x2160 */ 0, 0,255,255, 0, 0, 0, 0, 45, 0, 0, 0, 15, 8, 0, 0, -/* 0x2170 */ 96, 16,255,255, 0, 0, 0, 0, 52, 0, 0, 0, 15, 8, 0, 0, -/* 0x2180 */ 104, 16,255,255, 0, 0, 0, 0, 59, 0, 0, 0, 15, 8, 0, 0, -/* 0x2190 */ 112, 16,255,255, 0, 0, 0, 0, 67, 0, 0, 0, 15, 1, 0, 0, -/* 0x21a0 */ 128, 14,255,255, 0, 0, 0, 0, 73, 0, 0, 0, 15, 1, 0, 0, -/* 0x21b0 */ 240, 7,255,255, 0, 0, 0, 0, 83, 0, 0, 0, 1, 0, 0, 1, -/* 0x21c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 92, 0, 0, 0, 1, 0, 0, 1, -/* 0x21d0 */ 0, 0, 0, 0, 0, 0, 0, 0,110, 0, 0, 0, 1, 0, 0, 1, -/* 0x21e0 */ 0, 0, 0, 0, 0, 0, 0, 0,129, 0, 0, 0, 1, 0, 0, 1, -/* 0x21f0 */ 0, 0, 0, 0, 0, 0, 0, 0,136, 0, 0, 0, 1, 0, 0, 1, -/* 0x2200 */ 0, 0, 0, 0, 0, 0, 0, 0,142, 0, 0, 0, 1, 0, 0, 1, -/* 0x2210 */ 0, 0, 0, 0, 0, 0, 0, 0,148, 0, 0, 0, 1, 0, 0, 1, -/* 0x2220 */ 0, 0, 0, 0, 0, 0, 0, 0,158, 0, 0, 0, 1, 0, 0, 1, -/* 0x2230 */ 0, 0, 0, 0, 0, 0, 0, 0,166, 0, 0, 0, 1, 0, 0, 1, -/* 0x2240 */ 0, 0, 0, 0, 0, 0, 0, 0,172, 0, 0, 0, 1, 0, 0, 1, -/* 0x2250 */ 0, 0, 0, 0, 0, 0, 0, 0,179, 0, 0, 0, 1, 0, 0, 1, -/* 0x2260 */ 0, 0, 0, 0, 0, 0, 0, 0, 8, 0, 0, 0, 9, 0, 0, 0, -/* 0x2270 */ 11, 0, 0, 0, 12, 0, 0, 0, 13, 0, 0, 0, 14, 0, 0, 0, -/* 0x2280 */ 15, 0, 0, 0, 16, 0, 0, 0, 17, 0, 0, 0, 18, 0, 0, 0, -/* 0x2290 */ 0, 0, 0, 64, 10, 0, 0, 0, 8, 0, 0, 0, 9, 0, 0, 0, -/* 0x22a0 */ 11, 0, 0, 0, 12, 0, 0, 0, 13, 0, 0, 0, 14, 0, 0, 0, -/* 0x22b0 */ 15, 0, 0, 0, 16, 0, 0, 0, 17, 0, 0, 0, 32, 0, 95,117, -/* 0x22c0 */ 110,112, 97, 99,107, 69,120,116,101,110,116, 0, 95,100,111, 95, -/* 0x22d0 */ 120,109, 97,112, 0, 95, 95,109,104, 95,101,120,101, 99,117,116, -/* 0x22e0 */ 101, 95,104,101, 97,100,101,114, 0, 95,102, 95,101,120,112, 0, -/* 0x22f0 */ 95,102, 95,117,110,102, 0, 95,108, 97,117,110, 99,104, 0, 95, -/* 0x2300 */ 109, 97,105,110, 0, 95,117,112,120, 95,109, 97,105,110, 0, 95, -/* 0x2310 */ 95, 95, 98,122,101,114,111, 0, 95, 95, 95,115,116, 97, 99,107, -/* 0x2320 */ 95, 99,104,107, 95,102, 97,105,108, 0, 95, 95, 95,115,116, 97, -/* 0x2330 */ 99,107, 95, 99,104,107, 95,103,117, 97,114,100, 0, 95, 99,108, -/* 0x2340 */ 111,115,101, 0, 95,101,120,105,116, 0, 95,109,109, 97,112, 0, -/* 0x2350 */ 95,109,112,114,111,116,101, 99,116, 0, 95,109,117,110,109, 97, -/* 0x2360 */ 112, 0, 95,111,112,101,110, 0, 95,112,114,101, 97,100, 0,100, -/* 0x2370 */ 121,108,100, 95,115,116,117, 98, 95, 98,105,110,100,101,114, 0, -/* 0x2380 */ 0, 0, 0, 0 +/* 0x2000 */ 17, 64, 95, 95, 95,115,116, 97, 99,107, 95, 99,104,107, 95,103, +/* 0x2010 */ 117, 97,114,100, 0, 81,114, 16,144, 64,100,121,108,100, 95,115, +/* 0x2020 */ 116,117, 98, 95, 98,105,110,100,101,114, 0,128,232,255,255,255, +/* 0x2030 */ 255,255,255,255,255, 1,144, 0,114, 24, 17, 64, 95, 95, 95, 98, +/* 0x2040 */ 122,101,114,111, 0,144, 0,114, 32, 17, 64, 95, 95, 95,115,116, +/* 0x2050 */ 97, 99,107, 95, 99,104,107, 95,102, 97,105,108, 0,144, 0,114, +/* 0x2060 */ 40, 17, 64, 95, 99,108,111,115,101, 0,144, 0,114, 48, 17, 64, +/* 0x2070 */ 95,101,120,105,116, 0,144, 0,114, 56, 17, 64, 95,109,109, 97, +/* 0x2080 */ 112, 0,144, 0,114, 64, 17, 64, 95,109,112,114,111,116,101, 99, +/* 0x2090 */ 116, 0,144, 0,114, 72, 17, 64, 95,109,117,110,109, 97,112, 0, +/* 0x20a0 */ 144, 0,114, 80, 17, 64, 95,111,112,101,110, 0,144, 0,114, 88, +/* 0x20b0 */ 17, 64, 95,112,114,101, 97,100, 0,144, 0, 0, 0, 0, 0, 0, +/* 0x20c0 */ 0, 1, 95, 0, 5, 0, 3, 95,109,104, 95,101,120,101, 99,117, +/* 0x20d0 */ 116,101, 95,104,101, 97,100,101,114, 0, 43,117,112,120, 95,109, +/* 0x20e0 */ 97,105,110, 0, 47,109, 97,105,110, 0, 52, 2, 0, 0, 0, 3, +/* 0x20f0 */ 0,187, 18, 0, 3, 0,253, 27, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x2100 */ 2, 0, 0, 0, 14, 1, 0, 0,185, 10,255,255, 0, 0, 0, 0, +/* 0x2110 */ 16, 0, 0, 0, 14, 1, 0, 0,207, 11,255,255, 0, 0, 0, 0, +/* 0x2120 */ 25, 0, 0, 0, 14, 1, 0, 0,188, 14,255,255, 0, 0, 0, 0, +/* 0x2130 */ 32, 0, 0, 0, 3, 1, 16, 0, 0, 0,255,255, 0, 0, 0, 0, +/* 0x2140 */ 52, 0, 0, 0, 15, 1, 0, 0,253, 13,255,255, 0, 0, 0, 0, +/* 0x2150 */ 58, 0, 0, 0, 15, 1, 0, 0, 59, 9,255,255, 0, 0, 0, 0, +/* 0x2160 */ 68, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x2170 */ 77, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x2180 */ 95, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x2190 */ 114, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x21a0 */ 121, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x21b0 */ 127, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x21c0 */ 133, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x21d0 */ 143, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x21e0 */ 151, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x21f0 */ 157, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x2200 */ 164, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x2210 */ 6, 0, 0, 0, 7, 0, 0, 0, 9, 0, 0, 0, 10, 0, 0, 0, +/* 0x2220 */ 11, 0, 0, 0, 12, 0, 0, 0, 13, 0, 0, 0, 14, 0, 0, 0, +/* 0x2230 */ 15, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, 64, 8, 0, 0, 0, +/* 0x2240 */ 6, 0, 0, 0, 7, 0, 0, 0, 9, 0, 0, 0, 10, 0, 0, 0, +/* 0x2250 */ 11, 0, 0, 0, 12, 0, 0, 0, 13, 0, 0, 0, 14, 0, 0, 0, +/* 0x2260 */ 15, 0, 0, 0, 32, 0, 95,117,110,112, 97, 99,107, 69,120,116, +/* 0x2270 */ 101,110,116, 0, 95,100,111, 95,120,109, 97,112, 0, 95,120,114, +/* 0x2280 */ 101, 97,100, 0, 95, 95,109,104, 95,101,120,101, 99,117,116,101, +/* 0x2290 */ 95,104,101, 97,100,101,114, 0, 95,109, 97,105,110, 0, 95,117, +/* 0x22a0 */ 112,120, 95,109, 97,105,110, 0, 95, 95, 95, 98,122,101,114,111, +/* 0x22b0 */ 0, 95, 95, 95,115,116, 97, 99,107, 95, 99,104,107, 95,102, 97, +/* 0x22c0 */ 105,108, 0, 95, 95, 95,115,116, 97, 99,107, 95, 99,104,107, 95, +/* 0x22d0 */ 103,117, 97,114,100, 0, 95, 99,108,111,115,101, 0, 95,101,120, +/* 0x22e0 */ 105,116, 0, 95,109,109, 97,112, 0, 95,109,112,114,111,116,101, +/* 0x22f0 */ 99,116, 0, 95,109,117,110,109, 97,112, 0, 95,111,112,101,110, +/* 0x2300 */ 0, 95,112,114,101, 97,100, 0,100,121,108,100, 95,115,116,117, +/* 0x2310 */ 98, 95, 98,105,110,100,101,114, 0, 0, 0, 0 }; diff --git a/src/stub/tmp/amd64-darwin.macho-entry.bin.dump b/src/stub/tmp/amd64-darwin.macho-entry.bin.dump index fbfe41f4..197e0d9b 100644 --- a/src/stub/tmp/amd64-darwin.macho-entry.bin.dump +++ b/src/stub/tmp/amd64-darwin.macho-entry.bin.dump @@ -2,24 +2,28 @@ file format elf64-x86-64 Sections: Idx Name Size VMA LMA File off Algn Flags - 0 MACHMAINX 0000000d 0000000000000000 0000000000000000 00000040 2**0 CONTENTS, RELOC, READONLY - 1 NRV_HEAD 00000066 0000000000000000 0000000000000000 0000004d 2**0 CONTENTS, READONLY - 2 NRV2E 000000b7 0000000000000000 0000000000000000 000000b3 2**0 CONTENTS, RELOC, READONLY - 3 NRV2D 0000009e 0000000000000000 0000000000000000 0000016a 2**0 CONTENTS, RELOC, READONLY - 4 NRV2B 00000090 0000000000000000 0000000000000000 00000208 2**0 CONTENTS, RELOC, READONLY - 5 LZMA_ELF00 00000064 0000000000000000 0000000000000000 00000298 2**0 CONTENTS, RELOC, READONLY - 6 LZMA_DEC10 000009f7 0000000000000000 0000000000000000 000002fc 2**0 CONTENTS, READONLY - 7 LZMA_DEC20 000009f7 0000000000000000 0000000000000000 00000cf3 2**0 CONTENTS, READONLY - 8 LZMA_DEC30 00000014 0000000000000000 0000000000000000 000016ea 2**0 CONTENTS, READONLY - 9 NRV_TAIL 00000000 0000000000000000 0000000000000000 000016fe 2**0 CONTENTS, READONLY - 10 MACHMAINY 00000011 0000000000000000 0000000000000000 000016fe 2**0 CONTENTS, READONLY - 11 MACHMAINZ 00000041 0000000000000000 0000000000000000 0000170f 2**0 CONTENTS, READONLY + 0 AMD64BXX 00000052 0000000000000000 0000000000000000 00000040 2**0 CONTENTS, READONLY + 1 MACHMAINX 00000005 0000000000000000 0000000000000000 00000092 2**0 CONTENTS, RELOC, READONLY + 2 MACH_UNC 00000008 0000000000000000 0000000000000000 00000097 2**0 CONTENTS, READONLY + 3 NRV_HEAD 00000067 0000000000000000 0000000000000000 0000009f 2**0 CONTENTS, READONLY + 4 NRV2E 000000b7 0000000000000000 0000000000000000 00000106 2**0 CONTENTS, RELOC, READONLY + 5 NRV2D 0000009e 0000000000000000 0000000000000000 000001bd 2**0 CONTENTS, RELOC, READONLY + 6 NRV2B 00000090 0000000000000000 0000000000000000 0000025b 2**0 CONTENTS, RELOC, READONLY + 7 LZMA_ELF00 00000064 0000000000000000 0000000000000000 000002eb 2**0 CONTENTS, RELOC, READONLY + 8 LZMA_DEC10 000009f7 0000000000000000 0000000000000000 0000034f 2**0 CONTENTS, READONLY + 9 LZMA_DEC20 000009f7 0000000000000000 0000000000000000 00000d46 2**0 CONTENTS, READONLY + 10 LZMA_DEC30 00000014 0000000000000000 0000000000000000 0000173d 2**0 CONTENTS, READONLY + 11 NRV_TAIL 00000000 0000000000000000 0000000000000000 00001751 2**0 CONTENTS, READONLY + 12 MACHMAINY 00000011 0000000000000000 0000000000000000 00001751 2**0 CONTENTS, READONLY + 13 MACHMAINZ 00000041 0000000000000000 0000000000000000 00001762 2**0 CONTENTS, READONLY SYMBOL TABLE: 0000000000000000 l d NRV_HEAD 0000000000000000 NRV_HEAD 0000000000000000 l d LZMA_DEC30 0000000000000000 LZMA_DEC30 0000000000000000 l d MACHMAINY 0000000000000000 MACHMAINY 0000000000000000 l d MACHMAINZ 0000000000000000 MACHMAINZ +0000000000000000 l d AMD64BXX 0000000000000000 AMD64BXX 0000000000000000 l d MACHMAINX 0000000000000000 MACHMAINX +0000000000000000 l d MACH_UNC 0000000000000000 MACH_UNC 0000000000000000 l d NRV2E 0000000000000000 NRV2E 0000000000000000 l d NRV2D 0000000000000000 NRV2D 0000000000000000 l d NRV2B 0000000000000000 NRV2B From 5bb6f246eddc3b7393a852823f2d04434339d0c9 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sat, 10 Sep 2016 15:46:36 -0700 Subject: [PATCH 11/29] Mach-O dyld: __LINKEDIT must have highest .vmaddr and .fileoff --- src/p_mach.cpp | 53 ++++++++++++++++++++++++++++---------------------- 1 file changed, 30 insertions(+), 23 deletions(-) diff --git a/src/p_mach.cpp b/src/p_mach.cpp index eb7a50ae..24fcad91 100644 --- a/src/p_mach.cpp +++ b/src/p_mach.cpp @@ -825,21 +825,21 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader memcpy(&segLINK, segptr, sizeof(segLINK)); delta = offLINK - segLINK.fileoff; // relocation constant - // Mach_command __LINKEDIT - // The contents remain the same, but at a different offset in the file + // The contents for __LINKEDIT remain the same, + // but move to a different offset in the file fo->seek(offLINK, SEEK_SET); fo->write(&stub_amd64_darwin_macho_upxmain_exe[segLINK.fileoff], segLINK.filesize); - // Update the __LINKEDIT header - segLINK.vmaddr += delta; - segLINK.fileoff = offLINK; - fo->seek((char const *)ptr1 - (char const *)ptr0, SEEK_SET); - fo->rewrite(&segLINK, sizeof(segLINK)); - // Mach_segment_command for new segXHDR segXHDR.cmdsize = sizeof(segXHDR); segXHDR.nsects = 0; + fo->seek((char const *)ptr1 - (char const *)ptr0, SEEK_SET); fo->rewrite(&segXHDR, sizeof(segXHDR)); + + // Update the __LINKEDIT header + segLINK.vmaddr += delta; + segLINK.fileoff = offLINK; + fo->rewrite(&segLINK, sizeof(segLINK)); } } break; case Mach_segment_command::LC_DYLD_INFO_ONLY: { @@ -1640,25 +1640,32 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e unsigned cmdsize = mhdro.sizeofcmds - sizeof(segXHDR); Mach_header const *const ptr0 = (Mach_header const *)stub_amd64_darwin_macho_upxmain_exe; Mach_command const *ptr1 = (Mach_command const *)(1+ ptr0); + uint64_t next_va = 0; + uint64_t next_fpos = 0; for (unsigned j = 0; j < mhdro.ncmds -1; ++j, (cmdsize -= ptr1->cmdsize), ptr1 = (Mach_command const *)(ptr1->cmdsize + (char const *)ptr1)) { Mach_segment_command const *const segptr = (Mach_segment_command const *)ptr1; - if (lc_seg == ptr1->cmd && !strcmp("__LINKEDIT", segptr->segname)) { - // Mach_command before __LINKEDIT - fo->write((1+ ptr0), (char const *)ptr1 - (char const *)(1+ ptr0)); - // Mach_command __LINKEDIT - fo->write(segptr, segptr->cmdsize); - // LC_SEGMENT_64 for payload; steal space from -Wl,-headerpadsize - segXHDR.cmdsize = sizeof(segXHDR); - segXHDR.nsects = 0; - fo->write(&segXHDR, sizeof(segXHDR)); - // Mach_command after __LINKEDIT - fo->write(ptr1->cmdsize + (char const *)ptr1, cmdsize - ptr1->cmdsize); - // Contents before __LINKEDIT; put non-headers at same offset in file - unsigned pos = sizeof(mhdro) + mhdro.sizeofcmds; // includes sizeof(segXHDR) - fo->write(&stub_amd64_darwin_macho_upxmain_exe[pos], segptr->fileoff - pos); - break; + if (lc_seg == ptr1->cmd) { + if (!strcmp("__LINKEDIT", segptr->segname)) { + // Mach_command before __LINKEDIT + fo->write((1+ ptr0), (char const *)ptr1 - (char const *)(1+ ptr0)); + // LC_SEGMENT_64 for UPX_DATA; steal space from -Wl,-headerpadsize + segXHDR.cmdsize = sizeof(segXHDR); + segXHDR.vmaddr = next_va; + segXHDR.fileoff = PAGE_MASK & (~PAGE_MASK + next_fpos); + segXHDR.maxprot = segXHDR.initprot = Mach_segment_command::VM_PROT_READ; + segXHDR.nsects = 0; + fo->write(&segXHDR, sizeof(segXHDR)); + // Mach_command __LINKEDIT and after + fo->write((char const *)ptr1, cmdsize); + // Contents before __LINKEDIT; put non-headers at same offset in file + unsigned pos = sizeof(mhdro) + mhdro.sizeofcmds; // includes sizeof(segXHDR) + fo->write(&stub_amd64_darwin_macho_upxmain_exe[pos], segptr->fileoff - pos); + break; + } + next_va = segptr->vmsize + segptr->vmaddr; + next_fpos = segptr->filesize + segptr->fileoff; } } } From 13475002d716becbc581a3f66664a631b634079d Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sat, 10 Sep 2016 20:13:44 -0700 Subject: [PATCH 12/29] segXHDR reserves address space; actual launch! changed src/p_mach.cpp changed src/stub/amd64-darwin.macho-upxmain.h changed src/stub/src/amd64-darwin.macho-upxmain.c --- src/p_mach.cpp | 15 +- src/stub/amd64-darwin.macho-upxmain.h | 419 +++++++++++----------- src/stub/src/amd64-darwin.macho-upxmain.c | 10 +- 3 files changed, 222 insertions(+), 222 deletions(-) diff --git a/src/p_mach.cpp b/src/p_mach.cpp index 24fcad91..2ecb8ecc 100644 --- a/src/p_mach.cpp +++ b/src/p_mach.cpp @@ -831,13 +831,14 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader fo->write(&stub_amd64_darwin_macho_upxmain_exe[segLINK.fileoff], segLINK.filesize); // Mach_segment_command for new segXHDR - segXHDR.cmdsize = sizeof(segXHDR); + segXHDR.cmdsize = sizeof(segXHDR); // no need for sections + segLINK.vmaddr = segXHDR.vmsize; + segXHDR.vmsize -= segXHDR.vmaddr; // reserve for decompressed program segXHDR.nsects = 0; fo->seek((char const *)ptr1 - (char const *)ptr0, SEEK_SET); fo->rewrite(&segXHDR, sizeof(segXHDR)); // Update the __LINKEDIT header - segLINK.vmaddr += delta; segLINK.fileoff = offLINK; fo->rewrite(&segLINK, sizeof(segLINK)); } @@ -1423,6 +1424,10 @@ int PackMachBase::pack2(OutputFile *fo, Filter &ft) // append compressed bo for (k = 0; k < n_segment; ++k) { if (lc_seg==msegcmd[k].cmd && 0!=msegcmd[k].filesize ) { + uint64_t const hi_va = msegcmd[k].vmaddr + msegcmd[k].vmsize; + if (segXHDR.vmsize < hi_va) { + segXHDR.vmsize = hi_va; + } uip->ui_total_passes++; if (my_filetype==Mach_header::MH_DYLIB) { break; @@ -1565,6 +1570,7 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e mhdro.ncmds += 1; // we add LC_SEGMENT{,_64} for UPX_DATA mhdro.sizeofcmds += sizeof(segXHDR); mhdro.flags &= ~Mach_header::MH_PIE; // we require fixed address + mhdro.flags |= Mach_header::MH_BINDATLOAD; // DT_BIND_NOW } fo->write(&mhdro, sizeof(mhdro)); @@ -1654,7 +1660,10 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e segXHDR.cmdsize = sizeof(segXHDR); segXHDR.vmaddr = next_va; segXHDR.fileoff = PAGE_MASK & (~PAGE_MASK + next_fpos); - segXHDR.maxprot = segXHDR.initprot = Mach_segment_command::VM_PROT_READ; + segXHDR.maxprot = Mach_segment_command::VM_PROT_READ + | Mach_segment_command::VM_PROT_WRITE + | Mach_segment_command::VM_PROT_EXECUTE; + segXHDR.initprot = Mach_segment_command::VM_PROT_READ; segXHDR.nsects = 0; fo->write(&segXHDR, sizeof(segXHDR)); // Mach_command __LINKEDIT and after diff --git a/src/stub/amd64-darwin.macho-upxmain.h b/src/stub/amd64-darwin.macho-upxmain.h index a311e008..29d4a0f1 100644 --- a/src/stub/amd64-darwin.macho-upxmain.h +++ b/src/stub/amd64-darwin.macho-upxmain.h @@ -1,5 +1,5 @@ /* amd64-darwin.macho-upxmain.h - created from amd64-darwin.macho-upxmain.exe, 8988 (0x231c) bytes + created from amd64-darwin.macho-upxmain.exe, 8848 (0x2290) bytes This file is part of the UPX executable compressor. @@ -31,13 +31,13 @@ */ -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_SIZE 8988 -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x5d90d86d -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0xa8ca228f +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_SIZE 8848 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x13cab0a0 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0xb26d00d6 -unsigned char stub_amd64_darwin_macho_upxmain_exe[8988] = { +unsigned char stub_amd64_darwin_macho_upxmain_exe[8848] = { /* 0x0000 */ 207,250,237,254, 7, 0, 0, 1, 3, 0, 0,128, 2, 0, 0, 0, -/* 0x0010 */ 13, 0, 0, 0,136, 4, 0, 0,133, 0, 0, 0, 0, 0, 0, 0, +/* 0x0010 */ 13, 0, 0, 0, 56, 4, 0, 0,133, 0, 0, 0, 0, 0, 0, 0, /* 0x0020 */ 25, 0, 0, 0, 72, 0, 0, 0, 95, 95, 80, 65, 71, 69, 90, 69, /* 0x0030 */ 82, 79, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0040 */ 0, 0,255,255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -49,68 +49,68 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[8988] = { /* 0x00a0 */ 7, 0, 0, 0, 5, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, /* 0x00b0 */ 95, 95,116,101,120,116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00c0 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x00d0 */ 59, 9,255,255, 0, 0, 0, 0,203, 5, 0, 0, 0, 0, 0, 0, -/* 0x00e0 */ 59, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x00d0 */ 31, 9,255,255, 0, 0, 0, 0,249, 5, 0, 0, 0, 0, 0, 0, +/* 0x00e0 */ 31, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00f0 */ 0, 4, 0,128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0100 */ 95, 95,115,116,117, 98,115, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0110 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0120 */ 6, 15,255,255, 0, 0, 0, 0, 54, 0, 0, 0, 0, 0, 0, 0, -/* 0x0130 */ 6, 15, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0120 */ 24, 15,255,255, 0, 0, 0, 0, 48, 0, 0, 0, 0, 0, 0, 0, +/* 0x0130 */ 24, 15, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0140 */ 8, 4, 0,128, 0, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, /* 0x0150 */ 95, 95,115,116,117, 98, 95,104,101,108,112,101,114, 0, 0, 0, /* 0x0160 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0170 */ 60, 15,255,255, 0, 0, 0, 0,106, 0, 0, 0, 0, 0, 0, 0, -/* 0x0180 */ 60, 15, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0170 */ 72, 15,255,255, 0, 0, 0, 0, 96, 0, 0, 0, 0, 0, 0, 0, +/* 0x0180 */ 72, 15, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0190 */ 0, 4, 0,128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x01a0 */ 95, 95,117,110,119,105,110,100, 95,105,110,102,111, 0, 0, 0, /* 0x01b0 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x01c0 */ 168, 15,255,255, 0, 0, 0, 0, 88, 0, 0, 0, 0, 0, 0, 0, /* 0x01d0 */ 168, 15, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x01e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x01f0 */ 25, 0, 0, 0, 56, 1, 0, 0, 95, 95, 68, 65, 84, 65, 0, 0, +/* 0x01f0 */ 25, 0, 0, 0,232, 0, 0, 0, 95, 95, 68, 65, 84, 65, 0, 0, /* 0x0200 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16,255,255, 0, 0, 0, 0, /* 0x0210 */ 0, 16, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, /* 0x0220 */ 0, 16, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 3, 0, 0, 0, -/* 0x0230 */ 3, 0, 0, 0, 0, 0, 0, 0, 95, 95,110,108, 95,115,121,109, +/* 0x0230 */ 2, 0, 0, 0, 0, 0, 0, 0, 95, 95,110,108, 95,115,121,109, /* 0x0240 */ 98,111,108, 95,112,116,114, 0, 95, 95, 68, 65, 84, 65, 0, 0, /* 0x0250 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16,255,255, 0, 0, 0, 0, /* 0x0260 */ 16, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 3, 0, 0, 0, -/* 0x0270 */ 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 9, 0, 0, 0, -/* 0x0280 */ 0, 0, 0, 0, 0, 0, 0, 0, 95, 95,103,111,116, 0, 0, 0, -/* 0x0290 */ 0, 0, 0, 0, 0, 0, 0, 0, 95, 95, 68, 65, 84, 65, 0, 0, +/* 0x0270 */ 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 8, 0, 0, 0, +/* 0x0280 */ 0, 0, 0, 0, 0, 0, 0, 0, 95, 95,108, 97, 95,115,121,109, +/* 0x0290 */ 98,111,108, 95,112,116,114, 0, 95, 95, 68, 65, 84, 65, 0, 0, /* 0x02a0 */ 0, 0, 0, 0, 0, 0, 0, 0, 16, 16,255,255, 0, 0, 0, 0, -/* 0x02b0 */ 8, 0, 0, 0, 0, 0, 0, 0, 16, 16, 0, 0, 3, 0, 0, 0, -/* 0x02c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 11, 0, 0, 0, -/* 0x02d0 */ 0, 0, 0, 0, 0, 0, 0, 0, 95, 95,108, 97, 95,115,121,109, -/* 0x02e0 */ 98,111,108, 95,112,116,114, 0, 95, 95, 68, 65, 84, 65, 0, 0, -/* 0x02f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 24, 16,255,255, 0, 0, 0, 0, -/* 0x0300 */ 72, 0, 0, 0, 0, 0, 0, 0, 24, 16, 0, 0, 3, 0, 0, 0, -/* 0x0310 */ 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 12, 0, 0, 0, -/* 0x0320 */ 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0, 72, 0, 0, 0, -/* 0x0330 */ 95, 95, 76, 73, 78, 75, 69, 68, 73, 84, 0, 0, 0, 0, 0, 0, -/* 0x0340 */ 0, 32,255,255, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, -/* 0x0350 */ 0, 32, 0, 0, 0, 0, 0, 0, 28, 3, 0, 0, 0, 0, 0, 0, -/* 0x0360 */ 7, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0370 */ 34, 0, 0,128, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0380 */ 0, 32, 0, 0, 56, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0390 */ 56, 32, 0, 0,136, 0, 0, 0,192, 32, 0, 0, 64, 0, 0, 0, -/* 0x03a0 */ 2, 0, 0, 0, 24, 0, 0, 0, 0, 33, 0, 0, 17, 0, 0, 0, -/* 0x03b0 */ 100, 34, 0, 0,184, 0, 0, 0, 11, 0, 0, 0, 80, 0, 0, 0, -/* 0x03c0 */ 0, 0, 0, 0, 3, 0, 0, 0, 3, 0, 0, 0, 3, 0, 0, 0, -/* 0x03d0 */ 6, 0, 0, 0, 11, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x03e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x03f0 */ 16, 34, 0, 0, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0400 */ 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 32, 0, 0, 0, -/* 0x0410 */ 12, 0, 0, 0, 47,117,115,114, 47,108,105, 98, 47,100,121,108, -/* 0x0420 */ 100, 0, 0, 0, 0, 0, 0, 0, 36, 0, 0, 0, 16, 0, 0, 0, -/* 0x0430 */ 0, 11, 10, 0, 0, 11, 10, 0, 42, 0, 0, 0, 16, 0, 0, 0, -/* 0x0440 */ 0, 0, 0, 0, 0, 0, 0, 0, 40, 0, 0,128, 24, 0, 0, 0, -/* 0x0450 */ 253, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0460 */ 12, 0, 0, 0, 56, 0, 0, 0, 24, 0, 0, 0, 2, 0, 0, 0, -/* 0x0470 */ 1, 10,202, 4, 0, 0, 1, 0, 47,117,115,114, 47,108,105, 98, -/* 0x0480 */ 47,108,105, 98, 83,121,115,116,101,109, 46, 66, 46,100,121,108, -/* 0x0490 */ 105, 98, 0, 0, 0, 0, 0, 0, 41, 0, 0, 0, 16, 0, 0, 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, 0, 0, 0, 0, 0, 14, 0, 0, 0, 32, 0, 0, 0, +/* 0x03c0 */ 12, 0, 0, 0, 47,117,115,114, 47,108,105, 98, 47,100,121,108, +/* 0x03d0 */ 100, 0, 0, 0, 0, 0, 0, 0, 36, 0, 0, 0, 16, 0, 0, 0, +/* 0x03e0 */ 0, 11, 10, 0, 0, 11, 10, 0, 42, 0, 0, 0, 16, 0, 0, 0, +/* 0x03f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 40, 0, 0,128, 24, 0, 0, 0, +/* 0x0400 */ 20, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0410 */ 12, 0, 0, 0, 56, 0, 0, 0, 24, 0, 0, 0, 2, 0, 0, 0, +/* 0x0420 */ 1, 10,202, 4, 0, 0, 1, 0, 47,117,115,114, 47,108,105, 98, +/* 0x0430 */ 47,108,105, 98, 83,121,115,116,101,109, 46, 66, 46,100,121,108, +/* 0x0440 */ 105, 98, 0, 0, 0, 0, 0, 0, 41, 0, 0, 0, 16, 0, 0, 0, +/* 0x0450 */ 200, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0460 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0470 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0480 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0490 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x04a0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x04b0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x04c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x04d0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -181,123 +181,123 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[8988] = { /* 0x08e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x08f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0900 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0910 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0920 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0930 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 85, 72,137,229, 65, -/* 0x0940 */ 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, 72, 77,137,204, 76, -/* 0x0950 */ 137,195, 72,137, 77,152, 73,137,213, 76,139,125, 16, 72,137,117, -/* 0x0960 */ 208, 72,141, 71, 24, 72,137, 69,200, 72,139, 69,208, 72,131,192, -/* 0x0970 */ 232, 72,137, 69,192, 76,137,109,184,139, 71, 24, 72,137, 69,176, -/* 0x0980 */ 72,139, 69,192, 72,139, 77,200, 72,137, 77,168, 72,137, 69,160, -/* 0x0990 */ 69, 49,246, 72,141,125,192, 72,141,117,176, 49,201, 72,137,218, -/* 0x09a0 */ 232, 20, 1, 0, 0, 76,137, 36, 36, 72,141, 85,160,190, 0, 0, -/* 0x09b0 */ 0, 0,185,255,255,255,255, 76,137,239, 77,137,248, 73,137,217, -/* 0x09c0 */ 232, 10, 2, 0, 0, 72,137,195, 65,139, 77, 16,133,201, 15,132, -/* 0x09d0 */ 211, 0, 0, 0, 73,141, 69, 32,131, 56, 14,116, 19, 65,255,198, -/* 0x09e0 */ 139, 80, 4, 72, 1,208, 65, 57,206,114,237,233,183, 0, 0, 0, -/* 0x09f0 */ 139,120, 8, 72, 1,199, 49,246, 49,210,232, 49, 5, 0, 0, 65, -/* 0x0a00 */ 137,199, 69,133,255, 72,139, 93,152,120,105, 49,201, 68,137,255, -/* 0x0a10 */ 76,137,238, 72,137,218,232, 27, 5, 0, 0, 72, 57,216,117, 84, -/* 0x0a20 */ 77,141,117, 16, 69, 49,228, 65,139, 69, 0, 61,190,186,254,202, -/* 0x0a30 */ 116, 7, 61,202,254,186,190,117, 69, 65,139, 69, 4, 49,201,133, -/* 0x0a40 */ 192, 76,137,242,116, 56,129,122,248, 7, 0, 0, 1,116, 12,255, -/* 0x0a50 */ 193, 72,131,194, 20, 57,193,114,237,235, 35, 68,139, 34, 68,137, -/* 0x0a60 */ 255, 76,137,238, 72,137,218, 76,137,225,232,199, 4, 0, 0, 72, -/* 0x0a70 */ 57,216,116,179,191,127, 0, 0, 0,232,154, 4, 0, 0, 72,199, -/* 0x0a80 */ 4, 36, 0, 0, 0, 0, 49,210, 69, 49,192, 69, 49,201, 76,137, -/* 0x0a90 */ 239, 76,137,230, 68,137,249,232, 51, 1, 0, 0, 72,137,195, 68, -/* 0x0aa0 */ 137,255,232,107, 4, 0, 0, 72,137,216, 72,131,196, 72, 91, 65, -/* 0x0ab0 */ 92, 65, 93, 65, 94, 65, 95, 93,195, 85, 72,137,229, 65, 87, 65, -/* 0x0ac0 */ 86, 65, 85, 65, 84, 83, 72,131,236, 56, 72,137, 77,176, 72,137, -/* 0x0ad0 */ 85,168, 73,137,246, 72,137,125,184, 73,131, 62, 0, 15,132,211, -/* 0x0ae0 */ 0, 0, 0, 76,141,101,200,186, 12, 0, 0, 0, 72,139,125,184, -/* 0x0af0 */ 76,137,230,232,196, 3, 0, 0, 68,139,109,200, 68,139,125,204, -/* 0x0b00 */ 77,133,237, 15,132,154, 0, 0, 0, 65,141, 71,255, 68, 57,232, -/* 0x0b10 */ 15,131,175, 0, 0, 0, 77, 59, 46, 15,135,166, 0, 0, 0, 69, -/* 0x0b20 */ 57,239,115, 90, 68,137,109,196, 72,139, 69,184, 72,139,120, 8, -/* 0x0b30 */ 73,139, 86, 8,139, 93,208, 68, 15,182,195, 68,137,254, 72,141, -/* 0x0b40 */ 77,196,255, 85,168,133,192,117,124, 68, 57,109,196,117,118, 72, -/* 0x0b50 */ 131,125,176, 0,116, 27, 15,182,199,102,133,192,116, 19,193,235, -/* 0x0b60 */ 16, 15,183,200, 73,139,126, 8, 15,182,211, 68,137,238,255, 85, -/* 0x0b70 */ 176, 72,139, 69,184, 76, 1,120, 8, 76, 41, 56,235, 16, 73,139, -/* 0x0b80 */ 118, 8, 72,139,125,184, 76,137,250,232, 46, 3, 0, 0, 77, 1, -/* 0x0b90 */ 110, 8, 73,139, 6, 76, 41,232, 73,137, 6, 15,133, 70,255,255, -/* 0x0ba0 */ 255,235, 19, 65,129,255, 85, 80, 88, 33,117, 25, 72,139, 69,184, -/* 0x0bb0 */ 72,131, 56, 0,117, 15, 72,131,196, 56, 91, 65, 92, 65, 93, 65, -/* 0x0bc0 */ 94, 65, 95, 93,195,191,127, 0, 0, 0,232, 73, 3, 0, 0, 85, -/* 0x0bd0 */ 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236,104, -/* 0x0be0 */ 76,137,141,120,255,255,255, 76,137,133,112,255,255,255,137, 77, -/* 0x0bf0 */ 148, 72,137, 85,192, 72,137,117,136, 72,137,125,152,139,119, 16, -/* 0x0c00 */ 69, 49,255,133,246,184, 0, 0, 0, 0, 15,132,212, 1, 0, 0, -/* 0x0c10 */ 72,139, 77,152, 76,141,105, 32, 72,131,125,192, 0, 15,149,193, -/* 0x0c20 */ 15,182,201, 72,141, 12, 73, 72,137, 77,128, 49,255, 49,192, 73, -/* 0x0c30 */ 139, 85, 0, 72,137,209, 72,193,233, 32,129,250, 40, 0, 0,128, -/* 0x0c40 */ 15,132, 65, 1, 0, 0,131,250, 25, 15,133,132, 1, 0, 0, 73, -/* 0x0c50 */ 139, 85, 32, 72,133,210, 15,132,119, 1, 0, 0, 72,137, 85,168, -/* 0x0c60 */ 72,137,125,184, 72,137, 69,160, 73,139, 69, 48, 72,137, 69,200, -/* 0x0c70 */ 77,139,101, 24, 76,137,101,176, 76,137,101,208, 69,137,230, 65, -/* 0x0c80 */ 129,230,255, 15, 0, 0, 77, 41,244, 73, 1,198,116, 73, 72,139, -/* 0x0c90 */ 77,128, 73,141, 52, 14, 72,133,192,185, 18, 0, 0, 0,186, 18, -/* 0x0ca0 */ 16, 0, 0, 15, 68,202, 72,131,125,192, 0, 15, 69,202, 72,131, -/* 0x0cb0 */ 248, 1, 69, 25,192, 68, 11, 69,148, 77,139, 77, 40, 76, 3, 77, -/* 0x0cc0 */ 136,186, 3, 0, 0, 0, 76,137,231,232, 80, 2, 0, 0, 73, 57, -/* 0x0cd0 */ 196, 15,133, 28, 1, 0, 0, 72,131,125,192, 0,116, 52, 73,131, -/* 0x0ce0 */ 125, 48, 0,116, 45, 73,131,125, 40, 0,117, 14, 72,139,133,112, -/* 0x0cf0 */ 255,255,255, 76,137, 32, 76,137,109,184, 72,139,125,192, 72,141, -/* 0x0d00 */ 117,200, 72,139,149,120,255,255,255, 72,139, 77, 16,232,167,253, -/* 0x0d10 */ 255,255, 68,137,243,247,219, 72,129,227,255, 15, 0, 0,116, 12, -/* 0x0d20 */ 75,141, 60, 52, 72,137,222,232,218, 1, 0, 0, 77,133,246,116, -/* 0x0d30 */ 23, 65,139, 85, 60, 76,137,231, 76,137,246,232,228, 1, 0, 0, -/* 0x0d40 */ 133,192, 15,133,171, 0, 0, 0, 72,139, 69,176, 72, 3, 69,168, -/* 0x0d50 */ 76, 1,243, 73, 1,220, 73, 57,196,115, 66, 77,133,228,116, 96, -/* 0x0d60 */ 72,137,198, 76, 41,230, 65,139, 85, 60,185, 18, 16, 0, 0, 65, -/* 0x0d70 */ 184,255,255,255,255, 69, 49,201, 76,137,231,232,158, 1, 0, 0, -/* 0x0d80 */ 73, 57,196,116, 59,235,108, 73,139, 69, 8, 72, 57, 71, 40,119, -/* 0x0d90 */ 66, 72, 59, 71, 48,115, 60, 72, 3, 71, 24,235, 54, 72,131,125, -/* 0x0da0 */ 192, 0,116, 28, 65,131,198, 3, 65,129,230,255, 15, 0, 0, 73, -/* 0x0db0 */ 131,254, 3,119, 11, 76,137,231, 76,137,246,232,106, 1, 0, 0, -/* 0x0dc0 */ 65,139, 77, 4, 72,139, 69,152,139,112, 16, 72,139, 69,160, 72, -/* 0x0dd0 */ 139,125,184, 65,255,199,137,201, 73, 1,205, 65, 57,247, 15,130, -/* 0x0de0 */ 75,254,255,255, 72,131,196,104, 91, 65, 92, 65, 93, 65, 94, 65, -/* 0x0df0 */ 95, 93,195,191,127, 0, 0, 0,232, 27, 1, 0, 0, 85, 72,137, -/* 0x0e00 */ 229, 65, 87, 65, 86, 83, 72,129,236, 24, 8, 0, 0, 76,139, 53, -/* 0x0e10 */ 252, 1, 0, 0, 77,139, 54, 76,137,117,224, 72,141, 5,219,255, -/* 0x0e20 */ 255,255, 72, 37, 0, 0,255,255, 68,139,120, 16, 69,133,255,116, -/* 0x0e30 */ 84, 72,131,200, 32, 49,210, 73,187, 85, 80, 88, 95, 68, 65, 84, -/* 0x0e40 */ 65, 73,186, 95, 95, 84, 69, 88, 84, 0, 0,131, 56, 25,117, 40, -/* 0x0e50 */ 72,139, 88, 8, 76, 57,219,116, 23, 76, 57,211,117, 26, 72,139, -/* 0x0e60 */ 88,104, 15,183, 11, 76,141, 68, 11, 2, 76,141, 75, 2,235, 8, -/* 0x0e70 */ 72,139,120, 24, 72,139,112, 48,255,194,139, 72, 4, 72, 1,200, -/* 0x0e80 */ 68, 57,250,114,198, 72,141,133,216,247,255,255, 72,137, 4, 36, -/* 0x0e90 */ 72,141,149,224,247,255,255,185, 0, 8, 0, 0,232,154,250,255, -/* 0x0ea0 */ 255, 76, 59,117,224,117, 16, 49,192, 72,129,196, 24, 8, 0, 0, -/* 0x0eb0 */ 91, 65, 94, 65, 95, 93,195,232, 80, 0, 0, 0, 72,139, 15, 72, -/* 0x0ec0 */ 57,209,114, 52, 72,139, 71, 8, 72,133,210,116, 29, 72,137,209, -/* 0x0ed0 */ 72,255,201, 68,138, 0, 72,141, 64, 1, 68,136, 6, 72,141,118, -/* 0x0ee0 */ 1,117,237, 72,139, 15, 72,139, 71, 8, 72, 1,208, 72,137, 71, -/* 0x0ef0 */ 8, 72, 41,209, 72,137, 15,195, 85, 72,137,229,191,127, 0, 0, -/* 0x0f00 */ 0,232, 18, 0, 0, 0,255, 37, 12, 1, 0, 0,255, 37, 14, 1, -/* 0x0f10 */ 0, 0,255, 37, 16, 1, 0, 0,255, 37, 18, 1, 0, 0,255, 37, -/* 0x0f20 */ 20, 1, 0, 0,255, 37, 22, 1, 0, 0,255, 37, 24, 1, 0, 0, -/* 0x0f30 */ 255, 37, 26, 1, 0, 0,255, 37, 28, 1, 0, 0, 76,141, 29,197, -/* 0x0f40 */ 0, 0, 0, 65, 83,255, 37,181, 0, 0, 0,144,104, 0, 0, 0, -/* 0x0f50 */ 0,233,230,255,255,255,104, 15, 0, 0, 0,233,220,255,255,255, -/* 0x0f60 */ 104, 39, 0, 0, 0,233,210,255,255,255,104, 52, 0, 0, 0,233, -/* 0x0f70 */ 200,255,255,255,104, 64, 0, 0, 0,233,190,255,255,255,104, 76, -/* 0x0f80 */ 0, 0, 0,233,180,255,255,255,104, 92, 0, 0, 0,233,170,255, -/* 0x0f90 */ 255,255,104,106, 0, 0, 0,233,160,255,255,255,104,118, 0, 0, -/* 0x0fa0 */ 0,233,150,255,255,255, 0, 0, 1, 0, 0, 0, 28, 0, 0, 0, +/* 0x0910 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 85, +/* 0x0920 */ 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, 72, +/* 0x0930 */ 77,137,204, 76,137,195, 72,137, 77,152, 73,137,213, 76,139,125, +/* 0x0940 */ 16, 72,137,117,208, 72,141, 71, 24, 72,137, 69,200, 72,139, 69, +/* 0x0950 */ 208, 72,131,192,232, 72,137, 69,192, 76,137,109,184,139, 71, 24, +/* 0x0960 */ 72,137, 69,176, 72,139, 69,192, 72,139, 77,200, 72,137, 77,168, +/* 0x0970 */ 72,137, 69,160, 69, 49,246, 72,141,125,192, 72,141,117,176, 49, +/* 0x0980 */ 201, 72,137,218,232, 20, 1, 0, 0, 76,137, 36, 36, 72,141, 85, +/* 0x0990 */ 160,190, 0, 0, 0, 0,185,255,255,255,255, 76,137,239, 77,137, +/* 0x09a0 */ 248, 73,137,217,232, 10, 2, 0, 0, 72,137,195, 65,139, 77, 16, +/* 0x09b0 */ 133,201, 15,132,211, 0, 0, 0, 73,141, 69, 32,131, 56, 14,116, +/* 0x09c0 */ 19, 65,255,198,139, 80, 4, 72, 1,208, 65, 57,206,114,237,233, +/* 0x09d0 */ 183, 0, 0, 0,139,120, 8, 72, 1,199, 49,246, 49,210,232, 89, +/* 0x09e0 */ 5, 0, 0, 65,137,199, 69,133,255, 72,139, 93,152,120,105, 49, +/* 0x09f0 */ 201, 68,137,255, 76,137,238, 72,137,218,232, 67, 5, 0, 0, 72, +/* 0x0a00 */ 57,216,117, 84, 77,141,117, 16, 69, 49,228, 65,139, 69, 0, 61, +/* 0x0a10 */ 190,186,254,202,116, 7, 61,202,254,186,190,117, 69, 65,139, 69, +/* 0x0a20 */ 4, 49,201,133,192, 76,137,242,116, 56,129,122,248, 7, 0, 0, +/* 0x0a30 */ 1,116, 12,255,193, 72,131,194, 20, 57,193,114,237,235, 35, 68, +/* 0x0a40 */ 139, 34, 68,137,255, 76,137,238, 72,137,218, 76,137,225,232,239, +/* 0x0a50 */ 4, 0, 0, 72, 57,216,116,179,191,127, 0, 0, 0,232,194, 4, +/* 0x0a60 */ 0, 0, 72,199, 4, 36, 0, 0, 0, 0, 49,210, 69, 49,192, 69, +/* 0x0a70 */ 49,201, 76,137,239, 76,137,230, 68,137,249,232, 51, 1, 0, 0, +/* 0x0a80 */ 72,137,195, 68,137,255,232,147, 4, 0, 0, 72,137,216, 72,131, +/* 0x0a90 */ 196, 72, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195, 85, 72,137, +/* 0x0aa0 */ 229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, 56, 72,137, +/* 0x0ab0 */ 77,176, 72,137, 85,168, 73,137,246, 72,137,125,184, 73,131, 62, +/* 0x0ac0 */ 0, 15,132,211, 0, 0, 0, 76,141,101,200,186, 12, 0, 0, 0, +/* 0x0ad0 */ 72,139,125,184, 76,137,230,232,242, 3, 0, 0, 68,139,109,200, +/* 0x0ae0 */ 68,139,125,204, 77,133,237, 15,132,154, 0, 0, 0, 65,141, 71, +/* 0x0af0 */ 255, 68, 57,232, 15,131,175, 0, 0, 0, 77, 59, 46, 15,135,166, +/* 0x0b00 */ 0, 0, 0, 69, 57,239,115, 90, 68,137,109,196, 72,139, 69,184, +/* 0x0b10 */ 72,139,120, 8, 73,139, 86, 8,139, 93,208, 68, 15,182,195, 68, +/* 0x0b20 */ 137,254, 72,141, 77,196,255, 85,168,133,192,117,124, 68, 57,109, +/* 0x0b30 */ 196,117,118, 72,131,125,176, 0,116, 27, 15,182,199,102,133,192, +/* 0x0b40 */ 116, 19,193,235, 16, 15,183,200, 73,139,126, 8, 15,182,211, 68, +/* 0x0b50 */ 137,238,255, 85,176, 72,139, 69,184, 76, 1,120, 8, 76, 41, 56, +/* 0x0b60 */ 235, 16, 73,139,118, 8, 72,139,125,184, 76,137,250,232, 92, 3, +/* 0x0b70 */ 0, 0, 77, 1,110, 8, 73,139, 6, 76, 41,232, 73,137, 6, 15, +/* 0x0b80 */ 133, 70,255,255,255,235, 19, 65,129,255, 85, 80, 88, 33,117, 25, +/* 0x0b90 */ 72,139, 69,184, 72,131, 56, 0,117, 15, 72,131,196, 56, 91, 65, +/* 0x0ba0 */ 92, 65, 93, 65, 94, 65, 95, 93,195,191,127, 0, 0, 0,232,113, +/* 0x0bb0 */ 3, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, +/* 0x0bc0 */ 72,131,236,104, 76,137,141,120,255,255,255, 76,137,133,112,255, +/* 0x0bd0 */ 255,255,137, 77,148, 72,137, 85,192, 72,137,117,136, 72,137,125, +/* 0x0be0 */ 152,139, 95, 16, 69, 49,255,133,219,184, 0, 0, 0, 0, 15,132, +/* 0x0bf0 */ 7, 2, 0, 0, 72,139, 77,152, 76,141,105, 32, 72,131,125,192, +/* 0x0c00 */ 0, 15,149,193, 15,182,201, 72,141, 12, 73, 72,137, 77,128, 72, +/* 0x0c10 */ 191, 4, 0, 0, 0, 42, 0, 0, 0, 69, 49,192, 49,192, 73,139, +/* 0x0c20 */ 85, 0, 72,137,209, 72,193,233, 32,141,114,252,131,254, 2, 15, +/* 0x0c30 */ 130, 80, 1, 0, 0,129,250, 40, 0, 0,128, 15,132, 83, 1, 0, +/* 0x0c40 */ 0,131,250, 25, 15,133,160, 1, 0, 0, 73,139, 85, 32, 72,133, +/* 0x0c50 */ 210, 15,132,147, 1, 0, 0, 72,137, 85,168, 76,137, 69,184, 72, +/* 0x0c60 */ 137, 69,160, 73,139, 69, 48, 72,137, 69,200, 77,139,101, 24, 76, +/* 0x0c70 */ 137,101,176, 76,137,101,208, 69,137,230, 65,129,230,255, 15, 0, +/* 0x0c80 */ 0, 77, 41,244, 73, 1,198,116, 73, 72,139, 77,128, 73,141, 52, +/* 0x0c90 */ 14, 72,133,192,185, 18, 0, 0, 0,186, 18, 16, 0, 0, 15, 68, +/* 0x0ca0 */ 202, 72,131,125,192, 0, 15, 69,202, 72,131,248, 1, 69, 25,192, +/* 0x0cb0 */ 68, 11, 69,148, 77,139, 77, 40, 76, 3, 77,136,186, 3, 0, 0, +/* 0x0cc0 */ 0, 76,137,231,232, 97, 2, 0, 0, 73, 57,196, 15,133, 56, 1, +/* 0x0cd0 */ 0, 0, 72,131,125,192, 0,116, 52, 73,131,125, 48, 0,116, 45, +/* 0x0ce0 */ 73,131,125, 40, 0,117, 14, 72,139,133,112,255,255,255, 76,137, +/* 0x0cf0 */ 32, 76,137,109,184, 72,139,125,192, 72,141,117,200, 72,139,149, +/* 0x0d00 */ 120,255,255,255, 72,139, 77, 16,232,144,253,255,255, 68,137,243, +/* 0x0d10 */ 247,219, 72,129,227,255, 15, 0, 0,116, 12, 75,141, 60, 52, 72, +/* 0x0d20 */ 137,222,232,241, 1, 0, 0, 77,133,246,116, 23, 65,139, 85, 60, +/* 0x0d30 */ 76,137,231, 76,137,246,232,245, 1, 0, 0,133,192, 15,133,199, +/* 0x0d40 */ 0, 0, 0, 72,139, 69,176, 72, 3, 69,168, 76, 1,243, 73, 1, +/* 0x0d50 */ 220, 73, 57,196,115, 84, 77,133,228,116,114, 72,137,198, 76, 41, +/* 0x0d60 */ 230, 65,139, 85, 60,185, 18, 16, 0, 0, 65,184,255,255,255,255, +/* 0x0d70 */ 69, 49,201, 76,137,231,232,175, 1, 0, 0, 73, 57,196,116, 77, +/* 0x0d80 */ 233,133, 0, 0, 0, 73, 57,125, 8,117, 95, 73,139,133,144, 0, +/* 0x0d90 */ 0, 0,235, 86, 73,139, 69, 8, 73, 57, 64, 40,119, 76, 73, 59, +/* 0x0da0 */ 64, 48,115, 70, 73, 3, 64, 24,235, 64, 72,131,125,192, 0,116, +/* 0x0db0 */ 28, 65,131,198, 3, 65,129,230,255, 15, 0, 0, 73,131,254, 3, +/* 0x0dc0 */ 119, 11, 76,137,231, 76,137,246,232,105, 1, 0, 0, 65,139, 77, +/* 0x0dd0 */ 4, 72,139, 69,152,139, 88, 16, 72,191, 4, 0, 0, 0, 42, 0, +/* 0x0de0 */ 0, 0, 72,139, 69,160, 76,139, 69,184, 65,255,199,137,201, 73, +/* 0x0df0 */ 1,205, 65, 57,223, 15,130, 35,254,255,255, 72,131,196,104, 91, +/* 0x0e00 */ 65, 92, 65, 93, 65, 94, 65, 95, 93,195,191,127, 0, 0, 0,232, +/* 0x0e10 */ 16, 1, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 65, 84, 83, 72, +/* 0x0e20 */ 129,236, 16, 8, 0, 0, 73,137,247, 65,137,254, 72,141, 5,225, +/* 0x0e30 */ 255,255,255, 72, 37, 0, 0,255,255, 68,139, 96, 16, 69,133,228, +/* 0x0e40 */ 116, 84, 72,131,200, 32, 49,210, 73,187, 85, 80, 88, 95, 68, 65, +/* 0x0e50 */ 84, 65, 73,186, 95, 95, 84, 69, 88, 84, 0, 0,131, 56, 25,117, +/* 0x0e60 */ 40, 72,139, 88, 8, 76, 57,219,116, 23, 76, 57,211,117, 26, 72, +/* 0x0e70 */ 139, 88,104, 15,183, 11, 76,141, 68, 11, 2, 76,141, 75, 2,235, +/* 0x0e80 */ 8, 72,139,120, 24, 72,139,112, 48,255,194,139, 72, 4, 72, 1, +/* 0x0e90 */ 200, 68, 57,226,114,198, 73,141, 71,240, 72,137, 4, 36, 72,141, +/* 0x0ea0 */ 149,224,247,255,255,185, 0, 8, 0, 0,232,112,250,255,255, 73, +/* 0x0eb0 */ 99,206, 73,137, 79,248, 73,141,103,240,255,224, 49,192, 72,129, +/* 0x0ec0 */ 196, 16, 8, 0, 0, 91, 65, 92, 65, 94, 65, 95, 93,195, 72,139, +/* 0x0ed0 */ 15, 72, 57,209,114, 52, 72,139, 71, 8, 72,133,210,116, 29, 72, +/* 0x0ee0 */ 137,209, 72,255,201, 68,138, 0, 72,141, 64, 1, 68,136, 6, 72, +/* 0x0ef0 */ 141,118, 1,117,237, 72,139, 15, 72,139, 71, 8, 72, 1,208, 72, +/* 0x0f00 */ 137, 71, 8, 72, 41,209, 72,137, 15,195, 85, 72,137,229,191,127, +/* 0x0f10 */ 0, 0, 0,232, 12, 0, 0, 0,255, 37,242, 0, 0, 0,255, 37, +/* 0x0f20 */ 244, 0, 0, 0,255, 37,246, 0, 0, 0,255, 37,248, 0, 0, 0, +/* 0x0f30 */ 255, 37,250, 0, 0, 0,255, 37,252, 0, 0, 0,255, 37,254, 0, +/* 0x0f40 */ 0, 0,255, 37, 0, 1, 0, 0, 76,141, 29,185, 0, 0, 0, 65, +/* 0x0f50 */ 83,255, 37,169, 0, 0, 0,144,104, 0, 0, 0, 0,233,230,255, +/* 0x0f60 */ 255,255,104, 15, 0, 0, 0,233,220,255,255,255,104, 28, 0, 0, +/* 0x0f70 */ 0,233,210,255,255,255,104, 40, 0, 0, 0,233,200,255,255,255, +/* 0x0f80 */ 104, 52, 0, 0, 0,233,190,255,255,255,104, 68, 0, 0, 0,233, +/* 0x0f90 */ 180,255,255,255,104, 82, 0, 0, 0,233,170,255,255,255,104, 94, +/* 0x0fa0 */ 0, 0, 0,233,160,255,255,255, 1, 0, 0, 0, 28, 0, 0, 0, /* 0x0fb0 */ 0, 0, 0, 0, 28, 0, 0, 0, 0, 0, 0, 0, 28, 0, 0, 0, -/* 0x0fc0 */ 2, 0, 0, 0, 59, 9, 0, 0, 52, 0, 0, 0, 52, 0, 0, 0, -/* 0x0fd0 */ 7, 15, 0, 0, 0, 0, 0, 0, 52, 0, 0, 0, 3, 0, 0, 0, -/* 0x0fe0 */ 12, 0, 3, 0, 24, 0, 3, 0, 0, 0, 0, 2,194, 4, 0, 1, -/* 0x0ff0 */ 129, 5, 0, 0, 0, 0, 0, 1, 97, 1, 3, 1,209, 88, 5, 1, +/* 0x0fc0 */ 2, 0, 0, 0, 31, 9, 0, 0, 52, 0, 0, 0, 52, 0, 0, 0, +/* 0x0fd0 */ 25, 15, 0, 0, 0, 0, 0, 0, 52, 0, 0, 0, 3, 0, 0, 0, +/* 0x0fe0 */ 12, 0, 3, 0, 24, 0, 3, 0, 0, 0, 0, 2,245, 4, 0, 1, +/* 0x0ff0 */ 175, 5, 0, 0, 0, 0, 0, 1, 17, 11, 4, 1,209, 88, 5, 1, /* 0x1000 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x1010 */ 0, 0, 0, 0, 0, 0, 0, 0, 76, 15,255,255, 0, 0, 0, 0, -/* 0x1020 */ 86, 15,255,255, 0, 0, 0, 0, 96, 15,255,255, 0, 0, 0, 0, -/* 0x1030 */ 106, 15,255,255, 0, 0, 0, 0,116, 15,255,255, 0, 0, 0, 0, -/* 0x1040 */ 126, 15,255,255, 0, 0, 0, 0,136, 15,255,255, 0, 0, 0, 0, -/* 0x1050 */ 146, 15,255,255, 0, 0, 0, 0,156, 15,255,255, 0, 0, 0, 0, +/* 0x1010 */ 88, 15,255,255, 0, 0, 0, 0, 98, 15,255,255, 0, 0, 0, 0, +/* 0x1020 */ 108, 15,255,255, 0, 0, 0, 0,118, 15,255,255, 0, 0, 0, 0, +/* 0x1030 */ 128, 15,255,255, 0, 0, 0, 0,138, 15,255,255, 0, 0, 0, 0, +/* 0x1040 */ 148, 15,255,255, 0, 0, 0, 0,158, 15,255,255, 0, 0, 0, 0, +/* 0x1050 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x1060 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x1070 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x1080 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -548,54 +548,45 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[8988] = { /* 0x1fd0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x1fe0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x1ff0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x2000 */ 17, 64, 95, 95, 95,115,116, 97, 99,107, 95, 99,104,107, 95,103, -/* 0x2010 */ 117, 97,114,100, 0, 81,114, 16,144, 64,100,121,108,100, 95,115, -/* 0x2020 */ 116,117, 98, 95, 98,105,110,100,101,114, 0,128,232,255,255,255, -/* 0x2030 */ 255,255,255,255,255, 1,144, 0,114, 24, 17, 64, 95, 95, 95, 98, -/* 0x2040 */ 122,101,114,111, 0,144, 0,114, 32, 17, 64, 95, 95, 95,115,116, -/* 0x2050 */ 97, 99,107, 95, 99,104,107, 95,102, 97,105,108, 0,144, 0,114, -/* 0x2060 */ 40, 17, 64, 95, 99,108,111,115,101, 0,144, 0,114, 48, 17, 64, -/* 0x2070 */ 95,101,120,105,116, 0,144, 0,114, 56, 17, 64, 95,109,109, 97, -/* 0x2080 */ 112, 0,144, 0,114, 64, 17, 64, 95,109,112,114,111,116,101, 99, -/* 0x2090 */ 116, 0,144, 0,114, 72, 17, 64, 95,109,117,110,109, 97,112, 0, -/* 0x20a0 */ 144, 0,114, 80, 17, 64, 95,111,112,101,110, 0,144, 0,114, 88, -/* 0x20b0 */ 17, 64, 95,112,114,101, 97,100, 0,144, 0, 0, 0, 0, 0, 0, -/* 0x20c0 */ 0, 1, 95, 0, 5, 0, 3, 95,109,104, 95,101,120,101, 99,117, -/* 0x20d0 */ 116,101, 95,104,101, 97,100,101,114, 0, 43,117,112,120, 95,109, -/* 0x20e0 */ 97,105,110, 0, 47,109, 97,105,110, 0, 52, 2, 0, 0, 0, 3, -/* 0x20f0 */ 0,187, 18, 0, 3, 0,253, 27, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x2100 */ 2, 0, 0, 0, 14, 1, 0, 0,185, 10,255,255, 0, 0, 0, 0, -/* 0x2110 */ 16, 0, 0, 0, 14, 1, 0, 0,207, 11,255,255, 0, 0, 0, 0, -/* 0x2120 */ 25, 0, 0, 0, 14, 1, 0, 0,188, 14,255,255, 0, 0, 0, 0, -/* 0x2130 */ 32, 0, 0, 0, 3, 1, 16, 0, 0, 0,255,255, 0, 0, 0, 0, -/* 0x2140 */ 52, 0, 0, 0, 15, 1, 0, 0,253, 13,255,255, 0, 0, 0, 0, -/* 0x2150 */ 58, 0, 0, 0, 15, 1, 0, 0, 59, 9,255,255, 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 101,110,116, 0, 95,100,111, 95,120,109, 97,112, 0, 95,120,114, -/* 0x2280 */ 101, 97,100, 0, 95, 95,109,104, 95,101,120,101, 99,117,116,101, -/* 0x2290 */ 95,104,101, 97,100,101,114, 0, 95,109, 97,105,110, 0, 95,117, -/* 0x22a0 */ 112,120, 95,109, 97,105,110, 0, 95, 95, 95, 98,122,101,114,111, -/* 0x22b0 */ 0, 95, 95, 95,115,116, 97, 99,107, 95, 99,104,107, 95,102, 97, -/* 0x22c0 */ 105,108, 0, 95, 95, 95,115,116, 97, 99,107, 95, 99,104,107, 95, -/* 0x22d0 */ 103,117, 97,114,100, 0, 95, 99,108,111,115,101, 0, 95,101,120, -/* 0x22e0 */ 105,116, 0, 95,109,109, 97,112, 0, 95,109,112,114,111,116,101, -/* 0x22f0 */ 99,116, 0, 95,109,117,110,109, 97,112, 0, 95,111,112,101,110, -/* 0x2300 */ 0, 95,112,114,101, 97,100, 0,100,121,108,100, 95,115,116,117, -/* 0x2310 */ 98, 95, 98,105,110,100,101,114, 0, 0, 0, 0 +/* 0x2000 */ 17, 64,100,121,108,100, 95,115,116,117, 98, 95, 98,105,110,100, +/* 0x2010 */ 101,114, 0, 81,114, 0,144, 0,114, 16, 17, 64, 95, 95, 95, 98, +/* 0x2020 */ 122,101,114,111, 0,144, 0,114, 24, 17, 64, 95, 99,108,111,115, +/* 0x2030 */ 101, 0,144, 0,114, 32, 17, 64, 95,101,120,105,116, 0,144, 0, +/* 0x2040 */ 114, 40, 17, 64, 95,109,109, 97,112, 0,144, 0,114, 48, 17, 64, +/* 0x2050 */ 95,109,112,114,111,116,101, 99,116, 0,144, 0,114, 56, 17, 64, +/* 0x2060 */ 95,109,117,110,109, 97,112, 0,144, 0,114, 64, 17, 64, 95,111, +/* 0x2070 */ 112,101,110, 0,144, 0,114, 72, 17, 64, 95,112,114,101, 97,100, +/* 0x2080 */ 0,144, 0, 0, 0, 0, 0, 0, 0, 1, 95, 0, 5, 0, 3, 95, +/* 0x2090 */ 109,104, 95,101,120,101, 99,117,116,101, 95,104,101, 97,100,101, +/* 0x20a0 */ 114, 0, 43,117,112,120, 95,109, 97,105,110, 0, 47,109, 97,105, +/* 0x20b0 */ 110, 0, 52, 2, 0, 0, 0, 3, 0,159, 18, 0, 3, 0,148, 28, +/* 0x20c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 14, 1, 0, 0, +/* 0x20d0 */ 157, 10,255,255, 0, 0, 0, 0, 16, 0, 0, 0, 14, 1, 0, 0, +/* 0x20e0 */ 179, 11,255,255, 0, 0, 0, 0, 25, 0, 0, 0, 14, 1, 0, 0, +/* 0x20f0 */ 206, 14,255,255, 0, 0, 0, 0, 32, 0, 0, 0, 3, 1, 16, 0, +/* 0x2100 */ 0, 0,255,255, 0, 0, 0, 0, 52, 0, 0, 0, 15, 1, 0, 0, +/* 0x2110 */ 20, 14,255,255, 0, 0, 0, 0, 58, 0, 0, 0, 15, 1, 0, 0, +/* 0x2120 */ 31, 9,255,255, 0, 0, 0, 0, 68, 0, 0, 0, 1, 0, 0, 1, +/* 0x2130 */ 0, 0, 0, 0, 0, 0, 0, 0, 77, 0, 0, 0, 1, 0, 0, 1, +/* 0x2140 */ 0, 0, 0, 0, 0, 0, 0, 0, 84, 0, 0, 0, 1, 0, 0, 1, +/* 0x2150 */ 0, 0, 0, 0, 0, 0, 0, 0, 90, 0, 0, 0, 1, 0, 0, 1, +/* 0x2160 */ 0, 0, 0, 0, 0, 0, 0, 0, 96, 0, 0, 0, 1, 0, 0, 1, +/* 0x2170 */ 0, 0, 0, 0, 0, 0, 0, 0,106, 0, 0, 0, 1, 0, 0, 1, +/* 0x2180 */ 0, 0, 0, 0, 0, 0, 0, 0,114, 0, 0, 0, 1, 0, 0, 1, +/* 0x2190 */ 0, 0, 0, 0, 0, 0, 0, 0,120, 0, 0, 0, 1, 0, 0, 1, +/* 0x21a0 */ 0, 0, 0, 0, 0, 0, 0, 0,127, 0, 0, 0, 1, 0, 0, 1, +/* 0x21b0 */ 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 7, 0, 0, 0, +/* 0x21c0 */ 8, 0, 0, 0, 9, 0, 0, 0, 10, 0, 0, 0, 11, 0, 0, 0, +/* 0x21d0 */ 12, 0, 0, 0, 13, 0, 0, 0, 14, 0, 0, 0, 0, 0, 0, 64, +/* 0x21e0 */ 6, 0, 0, 0, 7, 0, 0, 0, 8, 0, 0, 0, 9, 0, 0, 0, +/* 0x21f0 */ 10, 0, 0, 0, 11, 0, 0, 0, 12, 0, 0, 0, 13, 0, 0, 0, +/* 0x2200 */ 32, 0, 95,117,110,112, 97, 99,107, 69,120,116,101,110,116, 0, +/* 0x2210 */ 95,100,111, 95,120,109, 97,112, 0, 95,120,114,101, 97,100, 0, +/* 0x2220 */ 95, 95,109,104, 95,101,120,101, 99,117,116,101, 95,104,101, 97, +/* 0x2230 */ 100,101,114, 0, 95,109, 97,105,110, 0, 95,117,112,120, 95,109, +/* 0x2240 */ 97,105,110, 0, 95, 95, 95, 98,122,101,114,111, 0, 95, 99,108, +/* 0x2250 */ 111,115,101, 0, 95,101,120,105,116, 0, 95,109,109, 97,112, 0, +/* 0x2260 */ 95,109,112,114,111,116,101, 99,116, 0, 95,109,117,110,109, 97, +/* 0x2270 */ 112, 0, 95,111,112,101,110, 0, 95,112,114,101, 97,100, 0,100, +/* 0x2280 */ 121,108,100, 95,115,116,117, 98, 95, 98,105,110,100,101,114, 0 }; diff --git a/src/stub/src/amd64-darwin.macho-upxmain.c b/src/stub/src/amd64-darwin.macho-upxmain.c index 7b9892e2..9efec0e0 100644 --- a/src/stub/src/amd64-darwin.macho-upxmain.c +++ b/src/stub/src/amd64-darwin.macho-upxmain.c @@ -573,7 +573,8 @@ ERR_LAB Mach_thread_command const *const thrc = (Mach_thread_command const *)sc; if (AMD64_THREAD_STATE ==thrc->flavor && AMD64_THREAD_STATE_COUNT==thrc->count ) { - entry = thrc->rip; + entry = thrc->state.rip; + } } else if (LC_MAIN==sc->cmd) { entry = ((Mach_main_command const *)sc)->entryoff; @@ -681,7 +682,6 @@ typedef struct { int main(int argc, char *argv[]) { - Mach_header64 *mhdrp; Mach_header64 const *mhdr0 = (Mach_header64 const *)((~0ul<<16) & (unsigned long)&main); Mach_command const *ptr = (Mach_command const *)(1+ mhdr0); f_unfilter *f_unf; @@ -711,12 +711,12 @@ main(int argc, char *argv[]) } char mhdr[2048]; //fprintf(stderr, "call upx_main(payload=%p paysize=%lu mhdr=%p f_exp=%p f_unf=%p mhdrp@%p)\n", -//payload, paysize, mhdr, f_exp, f_unf, &mhdrp); +//payload, paysize, mhdr, f_exp, f_unf, &argv[-2]); uint64_t entry = upx_main((struct l_info const *)payload, paysize, (Mach_header64 *)mhdr, sizeof(mhdr), - f_exp, f_unf, &mhdrp); + f_exp, f_unf, (Mach_header64 **)&argv[-2]); //fprintf(stderr, "return to launch\n"); - //launch(entry, &mhdrp); + asm("movq %2,-1*8(%1); lea -2*8(%1),%rsp; jmp *%0" : : "r" (entry), "r" (argv), "r" ((long)argc)); return 0; } From c1da92ca22f105f534a1287bf8f2fc07b7896eba Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sun, 11 Sep 2016 06:03:06 -0700 Subject: [PATCH 13/29] reduce asm() changed src/stub/src/amd64-darwin.macho-upxmain.c --- src/stub/src/amd64-darwin.macho-upxmain.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/stub/src/amd64-darwin.macho-upxmain.c b/src/stub/src/amd64-darwin.macho-upxmain.c index 9efec0e0..bb04bd2a 100644 --- a/src/stub/src/amd64-darwin.macho-upxmain.c +++ b/src/stub/src/amd64-darwin.macho-upxmain.c @@ -716,7 +716,8 @@ main(int argc, char *argv[]) (Mach_header64 *)mhdr, sizeof(mhdr), f_exp, f_unf, (Mach_header64 **)&argv[-2]); //fprintf(stderr, "return to launch\n"); - asm("movq %2,-1*8(%1); lea -2*8(%1),%rsp; jmp *%0" : : "r" (entry), "r" (argv), "r" ((long)argc)); + argv[-1] = argc; + asm("lea -2*8(%1),%rsp; jmp *%0" : : "r" (entry), "r" (argv)); return 0; } From 1d3a66f890c827438ef8f6ffb51fb9d7dc01bdc5 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sun, 11 Sep 2016 14:22:19 -0700 Subject: [PATCH 14/29] bswap(), bzero(), fat_find(), assembly-language system calls added src/stub/src/amd64-darwin.macho-upxsubr.S changed src/stub/amd64-darwin.macho-upxmain.h changed src/stub/src/amd64-darwin.macho-upxmain.c --- src/stub/amd64-darwin.macho-upxmain.h | 729 ++++++++-------------- src/stub/src/amd64-darwin.macho-upxmain.c | 62 +- src/stub/src/amd64-darwin.macho-upxsubr.S | 57 ++ 3 files changed, 353 insertions(+), 495 deletions(-) create mode 100644 src/stub/src/amd64-darwin.macho-upxsubr.S diff --git a/src/stub/amd64-darwin.macho-upxmain.h b/src/stub/amd64-darwin.macho-upxmain.h index 29d4a0f1..e8c46628 100644 --- a/src/stub/amd64-darwin.macho-upxmain.h +++ b/src/stub/amd64-darwin.macho-upxmain.h @@ -1,5 +1,5 @@ /* amd64-darwin.macho-upxmain.h - created from amd64-darwin.macho-upxmain.exe, 8848 (0x2290) bytes + created from amd64-darwin.macho-upxmain.exe, 5464 (0x1558) bytes This file is part of the UPX executable compressor. @@ -31,81 +31,81 @@ */ -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_SIZE 8848 -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x13cab0a0 -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0xb26d00d6 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_SIZE 5464 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x588116f2 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0xd16eba11 -unsigned char stub_amd64_darwin_macho_upxmain_exe[8848] = { +unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x0000 */ 207,250,237,254, 7, 0, 0, 1, 3, 0, 0,128, 2, 0, 0, 0, -/* 0x0010 */ 13, 0, 0, 0, 56, 4, 0, 0,133, 0, 0, 0, 0, 0, 0, 0, +/* 0x0010 */ 13, 0, 0, 0,248, 2, 0, 0,133, 0, 0, 0, 0, 0, 0, 0, /* 0x0020 */ 25, 0, 0, 0, 72, 0, 0, 0, 95, 95, 80, 65, 71, 69, 90, 69, /* 0x0030 */ 82, 79, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0040 */ 0, 0,255,255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0050 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0060 */ 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0,136, 1, 0, 0, +/* 0x0060 */ 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0,232, 0, 0, 0, /* 0x0070 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0080 */ 0, 0,255,255, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, /* 0x0090 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, -/* 0x00a0 */ 7, 0, 0, 0, 5, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, +/* 0x00a0 */ 7, 0, 0, 0, 5, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, /* 0x00b0 */ 95, 95,116,101,120,116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00c0 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x00d0 */ 31, 9,255,255, 0, 0, 0, 0,249, 5, 0, 0, 0, 0, 0, 0, -/* 0x00e0 */ 31, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x00d0 */ 95, 9,255,255, 0, 0, 0, 0, 65, 6, 0, 0, 0, 0, 0, 0, +/* 0x00e0 */ 95, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00f0 */ 0, 4, 0,128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0100 */ 95, 95,115,116,117, 98,115, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0100 */ 95, 95,117,110,119,105,110,100, 95,105,110,102,111, 0, 0, 0, /* 0x0110 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0120 */ 24, 15,255,255, 0, 0, 0, 0, 48, 0, 0, 0, 0, 0, 0, 0, -/* 0x0130 */ 24, 15, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0140 */ 8, 4, 0,128, 0, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, -/* 0x0150 */ 95, 95,115,116,117, 98, 95,104,101,108,112,101,114, 0, 0, 0, -/* 0x0160 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0170 */ 72, 15,255,255, 0, 0, 0, 0, 96, 0, 0, 0, 0, 0, 0, 0, -/* 0x0180 */ 72, 15, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0190 */ 0, 4, 0,128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x01a0 */ 95, 95,117,110,119,105,110,100, 95,105,110,102,111, 0, 0, 0, -/* 0x01b0 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x01c0 */ 168, 15,255,255, 0, 0, 0, 0, 88, 0, 0, 0, 0, 0, 0, 0, -/* 0x01d0 */ 168, 15, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x01e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x01f0 */ 25, 0, 0, 0,232, 0, 0, 0, 95, 95, 68, 65, 84, 65, 0, 0, -/* 0x0200 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16,255,255, 0, 0, 0, 0, -/* 0x0210 */ 0, 16, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, -/* 0x0220 */ 0, 16, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 3, 0, 0, 0, -/* 0x0230 */ 2, 0, 0, 0, 0, 0, 0, 0, 95, 95,110,108, 95,115,121,109, -/* 0x0240 */ 98,111,108, 95,112,116,114, 0, 95, 95, 68, 65, 84, 65, 0, 0, -/* 0x0250 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16,255,255, 0, 0, 0, 0, -/* 0x0260 */ 16, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 3, 0, 0, 0, -/* 0x0270 */ 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 8, 0, 0, 0, -/* 0x0280 */ 0, 0, 0, 0, 0, 0, 0, 0, 95, 95,108, 97, 95,115,121,109, -/* 0x0290 */ 98,111,108, 95,112,116,114, 0, 95, 95, 68, 65, 84, 65, 0, 0, -/* 0x02a0 */ 0, 0, 0, 0, 0, 0, 0, 0, 16, 16,255,255, 0, 0, 0, 0, -/* 0x02b0 */ 64, 0, 0, 0, 0, 0, 0, 0, 16, 16, 0, 0, 3, 0, 0, 0, -/* 0x02c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 10, 0, 0, 0, -/* 0x02d0 */ 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0, 72, 0, 0, 0, -/* 0x02e0 */ 95, 95, 76, 73, 78, 75, 69, 68, 73, 84, 0, 0, 0, 0, 0, 0, -/* 0x02f0 */ 0, 32,255,255, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, -/* 0x0300 */ 0, 32, 0, 0, 0, 0, 0, 0,144, 2, 0, 0, 0, 0, 0, 0, -/* 0x0310 */ 7, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0320 */ 34, 0, 0,128, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0330 */ 0, 32, 0, 0, 24, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0340 */ 24, 32, 0, 0,112, 0, 0, 0,136, 32, 0, 0, 64, 0, 0, 0, -/* 0x0350 */ 2, 0, 0, 0, 24, 0, 0, 0,200, 32, 0, 0, 15, 0, 0, 0, -/* 0x0360 */ 0, 34, 0, 0,144, 0, 0, 0, 11, 0, 0, 0, 80, 0, 0, 0, -/* 0x0370 */ 0, 0, 0, 0, 3, 0, 0, 0, 3, 0, 0, 0, 3, 0, 0, 0, -/* 0x0380 */ 6, 0, 0, 0, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0120 */ 160, 15,255,255, 0, 0, 0, 0, 96, 0, 0, 0, 0, 0, 0, 0, +/* 0x0130 */ 160, 15, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0140 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0150 */ 25, 0, 0, 0, 72, 0, 0, 0, 95, 95, 68, 65, 84, 65, 0, 0, +/* 0x0160 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16,255,255, 0, 0, 0, 0, +/* 0x0170 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, +/* 0x0180 */ 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 3, 0, 0, 0, +/* 0x0190 */ 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0, 72, 0, 0, 0, +/* 0x01a0 */ 95, 95, 76, 73, 78, 75, 69, 68, 73, 84, 0, 0, 0, 0, 0, 0, +/* 0x01b0 */ 0, 16,255,255, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, +/* 0x01c0 */ 0, 16, 0, 0, 0, 0, 0, 0, 88, 5, 0, 0, 0, 0, 0, 0, +/* 0x01d0 */ 7, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x01e0 */ 34, 0, 0,128, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x01f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0200 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0,136, 1, 0, 0, +/* 0x0210 */ 2, 0, 0, 0, 24, 0, 0, 0,136, 17, 0, 0, 40, 0, 0, 0, +/* 0x0220 */ 8, 20, 0, 0, 80, 1, 0, 0, 11, 0, 0, 0, 80, 0, 0, 0, +/* 0x0230 */ 0, 0, 0, 0, 12, 0, 0, 0, 12, 0, 0, 0, 27, 0, 0, 0, +/* 0x0240 */ 39, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0250 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0260 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0270 */ 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 32, 0, 0, 0, +/* 0x0280 */ 12, 0, 0, 0, 47,117,115,114, 47,108,105, 98, 47,100,121,108, +/* 0x0290 */ 100, 0, 0, 0, 0, 0, 0, 0, 36, 0, 0, 0, 16, 0, 0, 0, +/* 0x02a0 */ 0, 11, 10, 0, 0, 11, 10, 0, 42, 0, 0, 0, 16, 0, 0, 0, +/* 0x02b0 */ 0, 0, 0, 0, 0, 0, 0, 0, 40, 0, 0,128, 24, 0, 0, 0, +/* 0x02c0 */ 86, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x02d0 */ 12, 0, 0, 0, 56, 0, 0, 0, 24, 0, 0, 0, 2, 0, 0, 0, +/* 0x02e0 */ 1, 10,202, 4, 0, 0, 1, 0, 47,117,115,114, 47,108,105, 98, +/* 0x02f0 */ 47,108,105, 98, 83,121,115,116,101,109, 46, 66, 46,100,121,108, +/* 0x0300 */ 105, 98, 0, 0, 0, 0, 0, 0, 41, 0, 0, 0, 16, 0, 0, 0, +/* 0x0310 */ 136, 17, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0320 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0330 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0340 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0350 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0360 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0370 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0380 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0390 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x03a0 */ 184, 33, 0, 0, 18, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x03b0 */ 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 32, 0, 0, 0, -/* 0x03c0 */ 12, 0, 0, 0, 47,117,115,114, 47,108,105, 98, 47,100,121,108, -/* 0x03d0 */ 100, 0, 0, 0, 0, 0, 0, 0, 36, 0, 0, 0, 16, 0, 0, 0, -/* 0x03e0 */ 0, 11, 10, 0, 0, 11, 10, 0, 42, 0, 0, 0, 16, 0, 0, 0, -/* 0x03f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 40, 0, 0,128, 24, 0, 0, 0, -/* 0x0400 */ 20, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0410 */ 12, 0, 0, 0, 56, 0, 0, 0, 24, 0, 0, 0, 2, 0, 0, 0, -/* 0x0420 */ 1, 10,202, 4, 0, 0, 1, 0, 47,117,115,114, 47,108,105, 98, -/* 0x0430 */ 47,108,105, 98, 83,121,115,116,101,109, 46, 66, 46,100,121,108, -/* 0x0440 */ 105, 98, 0, 0, 0, 0, 0, 0, 41, 0, 0, 0, 16, 0, 0, 0, -/* 0x0450 */ 200, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x03a0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x03b0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x03c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x03d0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x03e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x03f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0400 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0410 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0420 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0430 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0440 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0450 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0460 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0470 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0480 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -181,412 +181,201 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[8848] = { /* 0x08e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x08f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0900 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0910 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 85, -/* 0x0920 */ 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, 72, -/* 0x0930 */ 77,137,204, 76,137,195, 72,137, 77,152, 73,137,213, 76,139,125, -/* 0x0940 */ 16, 72,137,117,208, 72,141, 71, 24, 72,137, 69,200, 72,139, 69, -/* 0x0950 */ 208, 72,131,192,232, 72,137, 69,192, 76,137,109,184,139, 71, 24, -/* 0x0960 */ 72,137, 69,176, 72,139, 69,192, 72,139, 77,200, 72,137, 77,168, -/* 0x0970 */ 72,137, 69,160, 69, 49,246, 72,141,125,192, 72,141,117,176, 49, -/* 0x0980 */ 201, 72,137,218,232, 20, 1, 0, 0, 76,137, 36, 36, 72,141, 85, -/* 0x0990 */ 160,190, 0, 0, 0, 0,185,255,255,255,255, 76,137,239, 77,137, -/* 0x09a0 */ 248, 73,137,217,232, 10, 2, 0, 0, 72,137,195, 65,139, 77, 16, -/* 0x09b0 */ 133,201, 15,132,211, 0, 0, 0, 73,141, 69, 32,131, 56, 14,116, -/* 0x09c0 */ 19, 65,255,198,139, 80, 4, 72, 1,208, 65, 57,206,114,237,233, -/* 0x09d0 */ 183, 0, 0, 0,139,120, 8, 72, 1,199, 49,246, 49,210,232, 89, -/* 0x09e0 */ 5, 0, 0, 65,137,199, 69,133,255, 72,139, 93,152,120,105, 49, -/* 0x09f0 */ 201, 68,137,255, 76,137,238, 72,137,218,232, 67, 5, 0, 0, 72, -/* 0x0a00 */ 57,216,117, 84, 77,141,117, 16, 69, 49,228, 65,139, 69, 0, 61, -/* 0x0a10 */ 190,186,254,202,116, 7, 61,202,254,186,190,117, 69, 65,139, 69, -/* 0x0a20 */ 4, 49,201,133,192, 76,137,242,116, 56,129,122,248, 7, 0, 0, -/* 0x0a30 */ 1,116, 12,255,193, 72,131,194, 20, 57,193,114,237,235, 35, 68, -/* 0x0a40 */ 139, 34, 68,137,255, 76,137,238, 72,137,218, 76,137,225,232,239, -/* 0x0a50 */ 4, 0, 0, 72, 57,216,116,179,191,127, 0, 0, 0,232,194, 4, -/* 0x0a60 */ 0, 0, 72,199, 4, 36, 0, 0, 0, 0, 49,210, 69, 49,192, 69, -/* 0x0a70 */ 49,201, 76,137,239, 76,137,230, 68,137,249,232, 51, 1, 0, 0, -/* 0x0a80 */ 72,137,195, 68,137,255,232,147, 4, 0, 0, 72,137,216, 72,131, -/* 0x0a90 */ 196, 72, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195, 85, 72,137, -/* 0x0aa0 */ 229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, 56, 72,137, -/* 0x0ab0 */ 77,176, 72,137, 85,168, 73,137,246, 72,137,125,184, 73,131, 62, -/* 0x0ac0 */ 0, 15,132,211, 0, 0, 0, 76,141,101,200,186, 12, 0, 0, 0, -/* 0x0ad0 */ 72,139,125,184, 76,137,230,232,242, 3, 0, 0, 68,139,109,200, -/* 0x0ae0 */ 68,139,125,204, 77,133,237, 15,132,154, 0, 0, 0, 65,141, 71, -/* 0x0af0 */ 255, 68, 57,232, 15,131,175, 0, 0, 0, 77, 59, 46, 15,135,166, -/* 0x0b00 */ 0, 0, 0, 69, 57,239,115, 90, 68,137,109,196, 72,139, 69,184, -/* 0x0b10 */ 72,139,120, 8, 73,139, 86, 8,139, 93,208, 68, 15,182,195, 68, -/* 0x0b20 */ 137,254, 72,141, 77,196,255, 85,168,133,192,117,124, 68, 57,109, -/* 0x0b30 */ 196,117,118, 72,131,125,176, 0,116, 27, 15,182,199,102,133,192, -/* 0x0b40 */ 116, 19,193,235, 16, 15,183,200, 73,139,126, 8, 15,182,211, 68, -/* 0x0b50 */ 137,238,255, 85,176, 72,139, 69,184, 76, 1,120, 8, 76, 41, 56, -/* 0x0b60 */ 235, 16, 73,139,118, 8, 72,139,125,184, 76,137,250,232, 92, 3, -/* 0x0b70 */ 0, 0, 77, 1,110, 8, 73,139, 6, 76, 41,232, 73,137, 6, 15, -/* 0x0b80 */ 133, 70,255,255,255,235, 19, 65,129,255, 85, 80, 88, 33,117, 25, -/* 0x0b90 */ 72,139, 69,184, 72,131, 56, 0,117, 15, 72,131,196, 56, 91, 65, -/* 0x0ba0 */ 92, 65, 93, 65, 94, 65, 95, 93,195,191,127, 0, 0, 0,232,113, -/* 0x0bb0 */ 3, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, -/* 0x0bc0 */ 72,131,236,104, 76,137,141,120,255,255,255, 76,137,133,112,255, -/* 0x0bd0 */ 255,255,137, 77,148, 72,137, 85,192, 72,137,117,136, 72,137,125, -/* 0x0be0 */ 152,139, 95, 16, 69, 49,255,133,219,184, 0, 0, 0, 0, 15,132, -/* 0x0bf0 */ 7, 2, 0, 0, 72,139, 77,152, 76,141,105, 32, 72,131,125,192, -/* 0x0c00 */ 0, 15,149,193, 15,182,201, 72,141, 12, 73, 72,137, 77,128, 72, -/* 0x0c10 */ 191, 4, 0, 0, 0, 42, 0, 0, 0, 69, 49,192, 49,192, 73,139, -/* 0x0c20 */ 85, 0, 72,137,209, 72,193,233, 32,141,114,252,131,254, 2, 15, -/* 0x0c30 */ 130, 80, 1, 0, 0,129,250, 40, 0, 0,128, 15,132, 83, 1, 0, -/* 0x0c40 */ 0,131,250, 25, 15,133,160, 1, 0, 0, 73,139, 85, 32, 72,133, -/* 0x0c50 */ 210, 15,132,147, 1, 0, 0, 72,137, 85,168, 76,137, 69,184, 72, -/* 0x0c60 */ 137, 69,160, 73,139, 69, 48, 72,137, 69,200, 77,139,101, 24, 76, -/* 0x0c70 */ 137,101,176, 76,137,101,208, 69,137,230, 65,129,230,255, 15, 0, -/* 0x0c80 */ 0, 77, 41,244, 73, 1,198,116, 73, 72,139, 77,128, 73,141, 52, -/* 0x0c90 */ 14, 72,133,192,185, 18, 0, 0, 0,186, 18, 16, 0, 0, 15, 68, -/* 0x0ca0 */ 202, 72,131,125,192, 0, 15, 69,202, 72,131,248, 1, 69, 25,192, -/* 0x0cb0 */ 68, 11, 69,148, 77,139, 77, 40, 76, 3, 77,136,186, 3, 0, 0, -/* 0x0cc0 */ 0, 76,137,231,232, 97, 2, 0, 0, 73, 57,196, 15,133, 56, 1, -/* 0x0cd0 */ 0, 0, 72,131,125,192, 0,116, 52, 73,131,125, 48, 0,116, 45, -/* 0x0ce0 */ 73,131,125, 40, 0,117, 14, 72,139,133,112,255,255,255, 76,137, -/* 0x0cf0 */ 32, 76,137,109,184, 72,139,125,192, 72,141,117,200, 72,139,149, -/* 0x0d00 */ 120,255,255,255, 72,139, 77, 16,232,144,253,255,255, 68,137,243, -/* 0x0d10 */ 247,219, 72,129,227,255, 15, 0, 0,116, 12, 75,141, 60, 52, 72, -/* 0x0d20 */ 137,222,232,241, 1, 0, 0, 77,133,246,116, 23, 65,139, 85, 60, -/* 0x0d30 */ 76,137,231, 76,137,246,232,245, 1, 0, 0,133,192, 15,133,199, -/* 0x0d40 */ 0, 0, 0, 72,139, 69,176, 72, 3, 69,168, 76, 1,243, 73, 1, -/* 0x0d50 */ 220, 73, 57,196,115, 84, 77,133,228,116,114, 72,137,198, 76, 41, -/* 0x0d60 */ 230, 65,139, 85, 60,185, 18, 16, 0, 0, 65,184,255,255,255,255, -/* 0x0d70 */ 69, 49,201, 76,137,231,232,175, 1, 0, 0, 73, 57,196,116, 77, -/* 0x0d80 */ 233,133, 0, 0, 0, 73, 57,125, 8,117, 95, 73,139,133,144, 0, -/* 0x0d90 */ 0, 0,235, 86, 73,139, 69, 8, 73, 57, 64, 40,119, 76, 73, 59, -/* 0x0da0 */ 64, 48,115, 70, 73, 3, 64, 24,235, 64, 72,131,125,192, 0,116, -/* 0x0db0 */ 28, 65,131,198, 3, 65,129,230,255, 15, 0, 0, 73,131,254, 3, -/* 0x0dc0 */ 119, 11, 76,137,231, 76,137,246,232,105, 1, 0, 0, 65,139, 77, -/* 0x0dd0 */ 4, 72,139, 69,152,139, 88, 16, 72,191, 4, 0, 0, 0, 42, 0, -/* 0x0de0 */ 0, 0, 72,139, 69,160, 76,139, 69,184, 65,255,199,137,201, 73, -/* 0x0df0 */ 1,205, 65, 57,223, 15,130, 35,254,255,255, 72,131,196,104, 91, -/* 0x0e00 */ 65, 92, 65, 93, 65, 94, 65, 95, 93,195,191,127, 0, 0, 0,232, -/* 0x0e10 */ 16, 1, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 65, 84, 83, 72, -/* 0x0e20 */ 129,236, 16, 8, 0, 0, 73,137,247, 65,137,254, 72,141, 5,225, -/* 0x0e30 */ 255,255,255, 72, 37, 0, 0,255,255, 68,139, 96, 16, 69,133,228, -/* 0x0e40 */ 116, 84, 72,131,200, 32, 49,210, 73,187, 85, 80, 88, 95, 68, 65, -/* 0x0e50 */ 84, 65, 73,186, 95, 95, 84, 69, 88, 84, 0, 0,131, 56, 25,117, -/* 0x0e60 */ 40, 72,139, 88, 8, 76, 57,219,116, 23, 76, 57,211,117, 26, 72, -/* 0x0e70 */ 139, 88,104, 15,183, 11, 76,141, 68, 11, 2, 76,141, 75, 2,235, -/* 0x0e80 */ 8, 72,139,120, 24, 72,139,112, 48,255,194,139, 72, 4, 72, 1, -/* 0x0e90 */ 200, 68, 57,226,114,198, 73,141, 71,240, 72,137, 4, 36, 72,141, -/* 0x0ea0 */ 149,224,247,255,255,185, 0, 8, 0, 0,232,112,250,255,255, 73, -/* 0x0eb0 */ 99,206, 73,137, 79,248, 73,141,103,240,255,224, 49,192, 72,129, -/* 0x0ec0 */ 196, 16, 8, 0, 0, 91, 65, 92, 65, 94, 65, 95, 93,195, 72,139, -/* 0x0ed0 */ 15, 72, 57,209,114, 52, 72,139, 71, 8, 72,133,210,116, 29, 72, -/* 0x0ee0 */ 137,209, 72,255,201, 68,138, 0, 72,141, 64, 1, 68,136, 6, 72, -/* 0x0ef0 */ 141,118, 1,117,237, 72,139, 15, 72,139, 71, 8, 72, 1,208, 72, -/* 0x0f00 */ 137, 71, 8, 72, 41,209, 72,137, 15,195, 85, 72,137,229,191,127, -/* 0x0f10 */ 0, 0, 0,232, 12, 0, 0, 0,255, 37,242, 0, 0, 0,255, 37, -/* 0x0f20 */ 244, 0, 0, 0,255, 37,246, 0, 0, 0,255, 37,248, 0, 0, 0, -/* 0x0f30 */ 255, 37,250, 0, 0, 0,255, 37,252, 0, 0, 0,255, 37,254, 0, -/* 0x0f40 */ 0, 0,255, 37, 0, 1, 0, 0, 76,141, 29,185, 0, 0, 0, 65, -/* 0x0f50 */ 83,255, 37,169, 0, 0, 0,144,104, 0, 0, 0, 0,233,230,255, -/* 0x0f60 */ 255,255,104, 15, 0, 0, 0,233,220,255,255,255,104, 28, 0, 0, -/* 0x0f70 */ 0,233,210,255,255,255,104, 40, 0, 0, 0,233,200,255,255,255, -/* 0x0f80 */ 104, 52, 0, 0, 0,233,190,255,255,255,104, 68, 0, 0, 0,233, -/* 0x0f90 */ 180,255,255,255,104, 82, 0, 0, 0,233,170,255,255,255,104, 94, -/* 0x0fa0 */ 0, 0, 0,233,160,255,255,255, 1, 0, 0, 0, 28, 0, 0, 0, -/* 0x0fb0 */ 0, 0, 0, 0, 28, 0, 0, 0, 0, 0, 0, 0, 28, 0, 0, 0, -/* 0x0fc0 */ 2, 0, 0, 0, 31, 9, 0, 0, 52, 0, 0, 0, 52, 0, 0, 0, -/* 0x0fd0 */ 25, 15, 0, 0, 0, 0, 0, 0, 52, 0, 0, 0, 3, 0, 0, 0, -/* 0x0fe0 */ 12, 0, 3, 0, 24, 0, 3, 0, 0, 0, 0, 2,245, 4, 0, 1, -/* 0x0ff0 */ 175, 5, 0, 0, 0, 0, 0, 1, 17, 11, 4, 1,209, 88, 5, 1, -/* 0x1000 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x1010 */ 88, 15,255,255, 0, 0, 0, 0, 98, 15,255,255, 0, 0, 0, 0, -/* 0x1020 */ 108, 15,255,255, 0, 0, 0, 0,118, 15,255,255, 0, 0, 0, 0, -/* 0x1030 */ 128, 15,255,255, 0, 0, 0, 0,138, 15,255,255, 0, 0, 0, 0, -/* 0x1040 */ 148, 15,255,255, 0, 0, 0, 0,158, 15,255,255, 0, 0, 0, 0, -/* 0x1050 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x1060 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x1070 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x1080 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x1090 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x10a0 */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0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x1fb0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x1fc0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x1fd0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x1fe0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x1ff0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x2000 */ 17, 64,100,121,108,100, 95,115,116,117, 98, 95, 98,105,110,100, -/* 0x2010 */ 101,114, 0, 81,114, 0,144, 0,114, 16, 17, 64, 95, 95, 95, 98, -/* 0x2020 */ 122,101,114,111, 0,144, 0,114, 24, 17, 64, 95, 99,108,111,115, -/* 0x2030 */ 101, 0,144, 0,114, 32, 17, 64, 95,101,120,105,116, 0,144, 0, -/* 0x2040 */ 114, 40, 17, 64, 95,109,109, 97,112, 0,144, 0,114, 48, 17, 64, -/* 0x2050 */ 95,109,112,114,111,116,101, 99,116, 0,144, 0,114, 56, 17, 64, -/* 0x2060 */ 95,109,117,110,109, 97,112, 0,144, 0,114, 64, 17, 64, 95,111, -/* 0x2070 */ 112,101,110, 0,144, 0,114, 72, 17, 64, 95,112,114,101, 97,100, -/* 0x2080 */ 0,144, 0, 0, 0, 0, 0, 0, 0, 1, 95, 0, 5, 0, 3, 95, -/* 0x2090 */ 109,104, 95,101,120,101, 99,117,116,101, 95,104,101, 97,100,101, -/* 0x20a0 */ 114, 0, 43,117,112,120, 95,109, 97,105,110, 0, 47,109, 97,105, -/* 0x20b0 */ 110, 0, 52, 2, 0, 0, 0, 3, 0,159, 18, 0, 3, 0,148, 28, -/* 0x20c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 14, 1, 0, 0, -/* 0x20d0 */ 157, 10,255,255, 0, 0, 0, 0, 16, 0, 0, 0, 14, 1, 0, 0, -/* 0x20e0 */ 179, 11,255,255, 0, 0, 0, 0, 25, 0, 0, 0, 14, 1, 0, 0, -/* 0x20f0 */ 206, 14,255,255, 0, 0, 0, 0, 32, 0, 0, 0, 3, 1, 16, 0, -/* 0x2100 */ 0, 0,255,255, 0, 0, 0, 0, 52, 0, 0, 0, 15, 1, 0, 0, -/* 0x2110 */ 20, 14,255,255, 0, 0, 0, 0, 58, 0, 0, 0, 15, 1, 0, 0, -/* 0x2120 */ 31, 9,255,255, 0, 0, 0, 0, 68, 0, 0, 0, 1, 0, 0, 1, -/* 0x2130 */ 0, 0, 0, 0, 0, 0, 0, 0, 77, 0, 0, 0, 1, 0, 0, 1, -/* 0x2140 */ 0, 0, 0, 0, 0, 0, 0, 0, 84, 0, 0, 0, 1, 0, 0, 1, -/* 0x2150 */ 0, 0, 0, 0, 0, 0, 0, 0, 90, 0, 0, 0, 1, 0, 0, 1, -/* 0x2160 */ 0, 0, 0, 0, 0, 0, 0, 0, 96, 0, 0, 0, 1, 0, 0, 1, -/* 0x2170 */ 0, 0, 0, 0, 0, 0, 0, 0,106, 0, 0, 0, 1, 0, 0, 1, -/* 0x2180 */ 0, 0, 0, 0, 0, 0, 0, 0,114, 0, 0, 0, 1, 0, 0, 1, -/* 0x2190 */ 0, 0, 0, 0, 0, 0, 0, 0,120, 0, 0, 0, 1, 0, 0, 1, -/* 0x21a0 */ 0, 0, 0, 0, 0, 0, 0, 0,127, 0, 0, 0, 1, 0, 0, 1, -/* 0x21b0 */ 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 7, 0, 0, 0, -/* 0x21c0 */ 8, 0, 0, 0, 9, 0, 0, 0, 10, 0, 0, 0, 11, 0, 0, 0, -/* 0x21d0 */ 12, 0, 0, 0, 13, 0, 0, 0, 14, 0, 0, 0, 0, 0, 0, 64, -/* 0x21e0 */ 6, 0, 0, 0, 7, 0, 0, 0, 8, 0, 0, 0, 9, 0, 0, 0, -/* 0x21f0 */ 10, 0, 0, 0, 11, 0, 0, 0, 12, 0, 0, 0, 13, 0, 0, 0, -/* 0x2200 */ 32, 0, 95,117,110,112, 97, 99,107, 69,120,116,101,110,116, 0, -/* 0x2210 */ 95,100,111, 95,120,109, 97,112, 0, 95,120,114,101, 97,100, 0, -/* 0x2220 */ 95, 95,109,104, 95,101,120,101, 99,117,116,101, 95,104,101, 97, -/* 0x2230 */ 100,101,114, 0, 95,109, 97,105,110, 0, 95,117,112,120, 95,109, -/* 0x2240 */ 97,105,110, 0, 95, 95, 95, 98,122,101,114,111, 0, 95, 99,108, -/* 0x2250 */ 111,115,101, 0, 95,101,120,105,116, 0, 95,109,109, 97,112, 0, -/* 0x2260 */ 95,109,112,114,111,116,101, 99,116, 0, 95,109,117,110,109, 97, -/* 0x2270 */ 112, 0, 95,111,112,101,110, 0, 95,112,114,101, 97,100, 0,100, -/* 0x2280 */ 121,108,100, 95,115,116,117, 98, 95, 98,105,110,100,101,114, 0 +/* 0x0910 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0920 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0930 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0940 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0950 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 85, +/* 0x0960 */ 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, 72, +/* 0x0970 */ 77,137,205, 76,137,195, 73,137,206, 73,137,212, 72,137,117,208, +/* 0x0980 */ 72,141, 71, 24, 72,137, 69,200, 72,139, 69,208, 72,131,192,232, +/* 0x0990 */ 72,137, 69,192, 76,137,101,184,139, 71, 24, 72,137, 69,176, 72, +/* 0x09a0 */ 139, 69,192, 72,139, 77,200, 72,137, 77,168, 72,137, 69,160, 69, +/* 0x09b0 */ 49,255, 72,141,125,192, 72,141,117,176, 49,201, 72,137,218,232, +/* 0x09c0 */ 27, 1, 0, 0, 76,137, 44, 36, 72,141, 85,160,190, 0, 0, 0, +/* 0x09d0 */ 0,185,255,255,255,255, 76,137,231, 76,139, 69, 16, 73,137,217, +/* 0x09e0 */ 232, 16, 2, 0, 0, 72,137,195, 65,139, 76, 36, 16,133,201, 15, +/* 0x09f0 */ 132,216, 0, 0, 0, 73,141, 68, 36, 32,131, 56, 14,116, 19, 65, +/* 0x0a00 */ 255,199,139, 80, 4, 72, 1,208, 65, 57,207,114,237,233,187, 0, +/* 0x0a10 */ 0, 0,139,120, 8, 72, 1,199, 49,246, 49,210,232, 97, 5, 0, +/* 0x0a20 */ 0, 65,137,199, 69,133,255,120,113, 77,141,108, 36, 16, 49,219, +/* 0x0a30 */ 68,137,255, 76,137,230, 76,137,242, 72,137,217,232, 57, 5, 0, +/* 0x0a40 */ 0, 76, 57,240,117, 84, 65,139, 4, 36, 61,190,186,254,202,116, +/* 0x0a50 */ 7, 61,202,254,186,190,117, 76, 65, 15,182, 68, 36, 7,141, 4, +/* 0x0a60 */ 128,141, 52,133, 8, 0, 0, 0, 76,137,231,232,226, 4, 0, 0, +/* 0x0a70 */ 65,139, 68, 36, 4, 49,201,133,192, 76,137,234,116, 28,129,122, +/* 0x0a80 */ 248, 7, 0, 0, 1,116, 12,255,193, 72,131,194, 20, 57,193,114, +/* 0x0a90 */ 237,235, 7,139, 26, 72,133,219,117,150,191,127, 0, 0, 0,232, +/* 0x0aa0 */ 202, 4, 0, 0, 72,199, 4, 36, 0, 0, 0, 0, 49,210, 69, 49, +/* 0x0ab0 */ 192, 69, 49,201, 76,137,231, 72,137,222, 68,137,249,232, 51, 1, +/* 0x0ac0 */ 0, 0, 72,137,195, 68,137,255,232,177, 4, 0, 0, 72,137,216, +/* 0x0ad0 */ 72,131,196, 72, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195, 85, +/* 0x0ae0 */ 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, 56, +/* 0x0af0 */ 72,137, 77,176, 72,137, 85,168, 73,137,246, 72,137,125,184, 73, +/* 0x0b00 */ 131, 62, 0, 15,132,211, 0, 0, 0, 76,141,101,200,186, 12, 0, +/* 0x0b10 */ 0, 0, 72,139,125,184, 76,137,230,232,234, 3, 0, 0, 68,139, +/* 0x0b20 */ 109,200, 68,139,125,204, 77,133,237, 15,132,154, 0, 0, 0, 65, +/* 0x0b30 */ 141, 71,255, 68, 57,232, 15,131,175, 0, 0, 0, 77, 59, 46, 15, +/* 0x0b40 */ 135,166, 0, 0, 0, 69, 57,239,115, 90, 68,137,109,196, 72,139, +/* 0x0b50 */ 69,184, 72,139,120, 8, 73,139, 86, 8,139, 93,208, 68, 15,182, +/* 0x0b60 */ 195, 68,137,254, 72,141, 77,196,255, 85,168,133,192,117,124, 68, +/* 0x0b70 */ 57,109,196,117,118, 72,131,125,176, 0,116, 27, 15,182,199,102, +/* 0x0b80 */ 133,192,116, 19,193,235, 16, 15,183,200, 73,139,126, 8, 15,182, +/* 0x0b90 */ 211, 68,137,238,255, 85,176, 72,139, 69,184, 76, 1,120, 8, 76, +/* 0x0ba0 */ 41, 56,235, 16, 73,139,118, 8, 72,139,125,184, 76,137,250,232, +/* 0x0bb0 */ 84, 3, 0, 0, 77, 1,110, 8, 73,139, 6, 76, 41,232, 73,137, +/* 0x0bc0 */ 6, 15,133, 70,255,255,255,235, 19, 65,129,255, 85, 80, 88, 33, +/* 0x0bd0 */ 117, 25, 72,139, 69,184, 72,131, 56, 0,117, 15, 72,131,196, 56, +/* 0x0be0 */ 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195,191,127, 0, 0, 0, +/* 0x0bf0 */ 232,121, 3, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, +/* 0x0c00 */ 84, 83, 72,131,236,104, 76,137,141,120,255,255,255, 76,137,133, +/* 0x0c10 */ 112,255,255,255,137, 77,148, 72,137, 85,192, 72,137,117,136, 72, +/* 0x0c20 */ 137,125,152,139, 95, 16, 69, 49,255,133,219,184, 0, 0, 0, 0, +/* 0x0c30 */ 15,132, 7, 2, 0, 0, 72,139, 77,152, 76,141,105, 32, 72,131, +/* 0x0c40 */ 125,192, 0, 15,149,193, 15,182,201, 72,141, 12, 73, 72,137, 77, +/* 0x0c50 */ 128, 72,191, 4, 0, 0, 0, 42, 0, 0, 0, 69, 49,192, 49,192, +/* 0x0c60 */ 73,139, 85, 0, 72,137,209, 72,193,233, 32,141,114,252,131,254, +/* 0x0c70 */ 2, 15,130, 80, 1, 0, 0,129,250, 40, 0, 0,128, 15,132, 83, +/* 0x0c80 */ 1, 0, 0,131,250, 25, 15,133,160, 1, 0, 0, 73,139, 85, 32, +/* 0x0c90 */ 72,133,210, 15,132,147, 1, 0, 0, 72,137, 85,168, 76,137, 69, +/* 0x0ca0 */ 184, 72,137, 69,160, 73,139, 69, 48, 72,137, 69,200, 77,139,101, +/* 0x0cb0 */ 24, 76,137,101,176, 76,137,101,208, 69,137,230, 65,129,230,255, +/* 0x0cc0 */ 15, 0, 0, 77, 41,244, 73, 1,198,116, 73, 72,139, 77,128, 73, +/* 0x0cd0 */ 141, 52, 14, 72,133,192,185, 18, 0, 0, 0,186, 18, 16, 0, 0, +/* 0x0ce0 */ 15, 68,202, 72,131,125,192, 0, 15, 69,202, 72,131,248, 1, 69, +/* 0x0cf0 */ 25,192, 68, 11, 69,148, 77,139, 77, 40, 76, 3, 77,136,186, 3, +/* 0x0d00 */ 0, 0, 0, 76,137,231,232,123, 2, 0, 0, 73, 57,196, 15,133, +/* 0x0d10 */ 56, 1, 0, 0, 72,131,125,192, 0,116, 52, 73,131,125, 48, 0, +/* 0x0d20 */ 116, 45, 73,131,125, 40, 0,117, 14, 72,139,133,112,255,255,255, +/* 0x0d30 */ 76,137, 32, 76,137,109,184, 72,139,125,192, 72,141,117,200, 72, +/* 0x0d40 */ 139,149,120,255,255,255, 72,139, 77, 16,232,144,253,255,255, 68, +/* 0x0d50 */ 137,243,247,219, 72,129,227,255, 15, 0, 0,116, 12, 75,141, 60, +/* 0x0d60 */ 52, 72,137,222,232,250, 1, 0, 0, 77,133,246,116, 23, 65,139, +/* 0x0d70 */ 85, 60, 76,137,231, 76,137,246,232,245, 1, 0, 0,133,192, 15, +/* 0x0d80 */ 133,199, 0, 0, 0, 72,139, 69,176, 72, 3, 69,168, 76, 1,243, +/* 0x0d90 */ 73, 1,220, 73, 57,196,115, 84, 77,133,228,116,114, 72,137,198, +/* 0x0da0 */ 76, 41,230, 65,139, 85, 60,185, 18, 16, 0, 0, 65,184,255,255, +/* 0x0db0 */ 255,255, 69, 49,201, 76,137,231,232,201, 1, 0, 0, 73, 57,196, +/* 0x0dc0 */ 116, 77,233,133, 0, 0, 0, 73, 57,125, 8,117, 95, 73,139,133, +/* 0x0dd0 */ 144, 0, 0, 0,235, 86, 73,139, 69, 8, 73, 57, 64, 40,119, 76, +/* 0x0de0 */ 73, 59, 64, 48,115, 70, 73, 3, 64, 24,235, 64, 72,131,125,192, +/* 0x0df0 */ 0,116, 28, 65,131,198, 3, 65,129,230,255, 15, 0, 0, 73,131, +/* 0x0e00 */ 254, 3,119, 11, 76,137,231, 76,137,246,232,103, 1, 0, 0, 65, +/* 0x0e10 */ 139, 77, 4, 72,139, 69,152,139, 88, 16, 72,191, 4, 0, 0, 0, +/* 0x0e20 */ 42, 0, 0, 0, 72,139, 69,160, 76,139, 69,184, 65,255,199,137, +/* 0x0e30 */ 201, 73, 1,205, 65, 57,223, 15,130, 35,254,255,255, 72,131,196, +/* 0x0e40 */ 104, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195,191,127, 0, 0, +/* 0x0e50 */ 0,232, 24, 1, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 83, 72, +/* 0x0e60 */ 129,236, 24, 8, 0, 0, 73,137,247, 65,137,254, 72,141, 5,227, +/* 0x0e70 */ 255,255,255, 72, 37, 0, 0,255,255,139, 72, 16,133,201,116, 82, +/* 0x0e80 */ 72,131,200, 32, 49,210, 73,187, 85, 80, 88, 95, 68, 65, 84, 65, +/* 0x0e90 */ 73,186, 95, 95, 84, 69, 88, 84, 0, 0,131, 56, 25,117, 39, 72, +/* 0x0ea0 */ 139, 88, 8, 76, 57,219,116, 22, 76, 57,211,117, 25, 72,139, 88, +/* 0x0eb0 */ 104, 68, 15,183, 3, 73, 1,216, 76,141, 75, 2,235, 8, 72,139, +/* 0x0ec0 */ 120, 24, 72,139,112, 48,255,194,139, 88, 4, 72, 1,216, 57,202, +/* 0x0ed0 */ 114,200, 73,141, 71,240, 72,137, 4, 36, 72,141,149,224,247,255, +/* 0x0ee0 */ 255,185, 0, 8, 0, 0,232,116,250,255,255, 73, 99,206, 73,137, +/* 0x0ef0 */ 79,248, 73,141,103,240,255,224, 49,192, 72,129,196, 24, 8, 0, +/* 0x0f00 */ 0, 91, 65, 94, 65, 95, 93,195, 72,139, 15, 72, 57,209,114, 52, +/* 0x0f10 */ 72,139, 71, 8, 72,133,210,116, 29, 72,137,209, 72,255,201, 68, +/* 0x0f20 */ 138, 0, 72,141, 64, 1, 68,136, 6, 72,141,118, 1,117,237, 72, +/* 0x0f30 */ 139, 15, 72,139, 71, 8, 72, 1,208, 72,137, 71, 8, 72, 41,209, +/* 0x0f40 */ 72,137, 15,195, 85, 72,137,229,191,127, 0, 0, 0,232, 28, 0, +/* 0x0f50 */ 0, 0,139, 7, 15,200,137, 7, 72,131,238, 4, 72,141,127, 4, +/* 0x0f60 */ 119,240,195, 49,192,137,241,243,170,195,176, 4,235, 2,176, 1, +/* 0x0f70 */ 235, 2,176, 74,235, 2,176, 73,235, 2,176,153,235, 2,176, 6, +/* 0x0f80 */ 235, 2,176, 5,235, 2,176,197,235, 2,176, 3, 15,182,192, 13, +/* 0x0f90 */ 0, 0, 0, 2, 73,137,202, 15, 5,115, 4, 72,131,200,255,195, +/* 0x0fa0 */ 1, 0, 0, 0, 28, 0, 0, 0, 0, 0, 0, 0, 28, 0, 0, 0, +/* 0x0fb0 */ 0, 0, 0, 0, 28, 0, 0, 0, 2, 0, 0, 0, 95, 9, 0, 0, +/* 0x0fc0 */ 52, 0, 0, 0, 52, 0, 0, 0,161, 15, 0, 0, 0, 0, 0, 0, +/* 0x0fd0 */ 52, 0, 0, 0, 3, 0, 0, 0, 12, 0, 4, 0, 28, 0, 4, 0, +/* 0x0fe0 */ 0, 0, 0, 3,247, 4, 0, 2,169, 5, 0, 1,243, 5, 0, 0, +/* 0x0ff0 */ 0, 0, 0, 0, 0, 0, 0, 1, 97, 1, 3, 1,209, 88, 5, 1, +/* 0x1000 */ 0, 9, 95, 0, 58, 98, 0,233, 1,119,114,105,116,101, 0,151, +/* 0x1010 */ 2,101,120,105,116, 0,161, 2,109, 0,171, 2,112,114,101, 97, +/* 0x1020 */ 100, 0,217, 2, 99,108,111,115,101, 0,227, 2,111,112,101,110, +/* 0x1030 */ 0,237, 2,114,101, 97,100, 0,129, 3, 0, 10, 95, 0,127,117, +/* 0x1040 */ 112,120, 95,109, 97,105,110, 0,170, 1,109, 0,175, 1, 98, 0, +/* 0x1050 */ 212, 1,119,114,105,116,101, 0,146, 2,101,120,105,116, 0,156, +/* 0x1060 */ 2,112,114,101, 97,100, 0,212, 2, 99,108,111,115,101, 0,222, +/* 0x1070 */ 2,111,112,101,110, 0,232, 2,114,101, 97,100, 0,252, 2, 0, +/* 0x1080 */ 3,109,104, 95,101,120,101, 99,117,116,101, 95,104,101, 97,100, +/* 0x1090 */ 101,114, 0,166, 1, 95, 98,122,101,114,111, 0,254, 1, 98,122, +/* 0x10a0 */ 101,114,111, 0,131, 2, 2, 0, 0, 0, 3, 0,223, 18, 0, 0, +/* 0x10b0 */ 4, 97,105,110, 0,207, 1,112,114,111,116,101, 99,116, 0,166, +/* 0x10c0 */ 2,117,110,109, 97,112, 0,202, 2,109, 97,112, 0,242, 2, 3, +/* 0x10d0 */ 0,214, 28, 0, 0, 2,115,119, 97,112, 0,228, 1,122,101,114, +/* 0x10e0 */ 111, 0,136, 2, 3, 0,210, 30, 0, 0, 2,115,119, 97,112, 0, +/* 0x10f0 */ 249, 1,122,101,114,111, 0,141, 2, 3, 0,210, 30, 0, 3, 0, +/* 0x1100 */ 227, 30, 0, 3, 0,227, 30, 0, 3, 0,227, 30, 0, 3, 0,227, +/* 0x1110 */ 30, 0, 3, 0,234, 30, 0, 3, 0,234, 30, 0, 3, 0,238, 30, +/* 0x1120 */ 0, 3, 0,238, 30, 0, 3, 0,242, 30, 0, 0, 3,112,114,111, +/* 0x1130 */ 116,101, 99,116, 0,197, 2,117,110,109, 97,112, 0,207, 2,109, +/* 0x1140 */ 97,112, 0,247, 2, 3, 0,242, 30, 0, 3, 0,246, 30, 0, 3, +/* 0x1150 */ 0,246, 30, 0, 3, 0,250, 30, 0, 3, 0,250, 30, 0, 3, 0, +/* 0x1160 */ 254, 30, 0, 3, 0,254, 30, 0, 3, 0,130, 31, 0, 3, 0,130, +/* 0x1170 */ 31, 0, 3, 0,134, 31, 0, 3, 0,134, 31, 0, 3, 0,138, 31, +/* 0x1180 */ 0, 3, 0,138, 31, 0, 0, 0, 2, 0, 0, 0, 14, 1, 0, 0, +/* 0x1190 */ 223, 10,255,255, 0, 0, 0, 0, 16, 0, 0, 0, 14, 1, 0, 0, +/* 0x11a0 */ 245, 11,255,255, 0, 0, 0, 0, 25, 0, 0, 0, 14, 1, 0, 0, +/* 0x11b0 */ 8, 15,255,255, 0, 0, 0, 0, 32, 0, 0, 0, 2, 0, 0, 0, +/* 0x11c0 */ 1, 0, 0, 0, 0, 0, 0, 0, 41, 0, 0, 0, 2, 0, 0, 0, +/* 0x11d0 */ 3, 0, 0, 0, 0, 0, 0, 0, 50, 0, 0, 0, 2, 0, 0, 0, +/* 0x11e0 */ 4, 0, 0, 0, 0, 0, 0, 0, 60, 0, 0, 0, 2, 0, 0, 0, +/* 0x11f0 */ 5, 0, 0, 0, 0, 0, 0, 0, 69, 0, 0, 0, 2, 0, 0, 0, +/* 0x1200 */ 6, 0, 0, 0, 0, 0, 0, 0, 79, 0, 0, 0, 2, 0, 0, 0, +/* 0x1210 */ 73, 0, 0, 0, 0, 0, 0, 0, 90, 0, 0, 0, 2, 0, 0, 0, +/* 0x1220 */ 74, 0, 0, 0, 0, 0, 0, 0,103, 0, 0, 0, 2, 0, 0, 0, +/* 0x1230 */ 153, 0, 0, 0, 0, 0, 0, 0,113, 0, 0, 0, 2, 0, 0, 0, +/* 0x1240 */ 197, 0, 0, 0, 0, 0, 0, 0,122, 0, 0, 0, 15, 1, 0, 0, +/* 0x1250 */ 99, 15,255,255, 0, 0, 0, 0,131, 0, 0, 0, 15, 1, 0, 0, +/* 0x1260 */ 99, 15,255,255, 0, 0, 0, 0,139, 0, 0, 0, 3, 1, 16, 0, +/* 0x1270 */ 0, 0,255,255, 0, 0, 0, 0,159, 0, 0, 0, 15, 1, 0, 0, +/* 0x1280 */ 82, 15,255,255, 0, 0, 0, 0,166, 0, 0, 0, 15, 1, 0, 0, +/* 0x1290 */ 99, 15,255,255, 0, 0, 0, 0,173, 0, 0, 0, 15, 1, 0, 0, +/* 0x12a0 */ 126, 15,255,255, 0, 0, 0, 0,180, 0, 0, 0, 15, 1, 0, 0, +/* 0x12b0 */ 110, 15,255,255, 0, 0, 0, 0,186, 0, 0, 0, 15, 1, 0, 0, +/* 0x12c0 */ 86, 14,255,255, 0, 0, 0, 0,192, 0, 0, 0, 15, 1, 0, 0, +/* 0x12d0 */ 134, 15,255,255, 0, 0, 0, 0,198, 0, 0, 0, 15, 1, 0, 0, +/* 0x12e0 */ 114, 15,255,255, 0, 0, 0, 0,208, 0, 0, 0, 15, 1, 0, 0, +/* 0x12f0 */ 118, 15,255,255, 0, 0, 0, 0,216, 0, 0, 0, 15, 1, 0, 0, +/* 0x1300 */ 130, 15,255,255, 0, 0, 0, 0,222, 0, 0, 0, 15, 1, 0, 0, +/* 0x1310 */ 122, 15,255,255, 0, 0, 0, 0,229, 0, 0, 0, 15, 1, 0, 0, +/* 0x1320 */ 138, 15,255,255, 0, 0, 0, 0,235, 0, 0, 0, 15, 1, 0, 0, +/* 0x1330 */ 95, 9,255,255, 0, 0, 0, 0,245, 0, 0, 0, 15, 1, 0, 0, +/* 0x1340 */ 106, 15,255,255, 0, 0, 0, 0,252, 0, 0, 0, 15, 1, 0, 0, +/* 0x1350 */ 82, 15,255,255, 0, 0, 0, 0, 2, 1, 0, 0, 15, 1, 0, 0, +/* 0x1360 */ 99, 15,255,255, 0, 0, 0, 0, 8, 1, 0, 0, 15, 1, 0, 0, +/* 0x1370 */ 126, 15,255,255, 0, 0, 0, 0, 14, 1, 0, 0, 15, 1, 0, 0, +/* 0x1380 */ 110, 15,255,255, 0, 0, 0, 0, 19, 1, 0, 0, 15, 1, 0, 0, +/* 0x1390 */ 134, 15,255,255, 0, 0, 0, 0, 24, 1, 0, 0, 15, 1, 0, 0, +/* 0x13a0 */ 114, 15,255,255, 0, 0, 0, 0, 33, 1, 0, 0, 15, 1, 0, 0, +/* 0x13b0 */ 118, 15,255,255, 0, 0, 0, 0, 40, 1, 0, 0, 15, 1, 0, 0, +/* 0x13c0 */ 130, 15,255,255, 0, 0, 0, 0, 45, 1, 0, 0, 15, 1, 0, 0, +/* 0x13d0 */ 122, 15,255,255, 0, 0, 0, 0, 51, 1, 0, 0, 15, 1, 0, 0, +/* 0x13e0 */ 138, 15,255,255, 0, 0, 0, 0, 56, 1, 0, 0, 15, 1, 0, 0, +/* 0x13f0 */ 106, 15,255,255, 0, 0, 0, 0, 62, 1, 0, 0, 1, 0, 0, 1, +/* 0x1400 */ 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 95,117,110,112, 97, 99, +/* 0x1410 */ 107, 69,120,116,101,110,116, 0, 95,100,111, 95,120,109, 97,112, +/* 0x1420 */ 0, 95,120,114,101, 97,100, 0, 83, 89, 83, 95,101,120,105,116, +/* 0x1430 */ 0, 83, 89, 83, 95,114,101, 97,100, 0, 83, 89, 83, 95,119,114, +/* 0x1440 */ 105,116,101, 0, 83, 89, 83, 95,111,112,101,110, 0, 83, 89, 83, +/* 0x1450 */ 95, 99,108,111,115,101, 0, 83, 89, 83, 95,109,117,110,109, 97, +/* 0x1460 */ 112, 0, 83, 89, 83, 95,109,112,114,111,116,101, 99,116, 0, 83, +/* 0x1470 */ 89, 83, 95,112,114,101, 97,100, 0, 83, 89, 83, 95,109,109, 97, +/* 0x1480 */ 112, 0, 95, 95, 95, 98,122,101,114,111, 0, 95, 95, 98,122,101, +/* 0x1490 */ 114,111, 0, 95, 95,109,104, 95,101,120,101, 99,117,116,101, 95, +/* 0x14a0 */ 104,101, 97,100,101,114, 0, 95, 98,115,119, 97,112, 0, 95, 98, +/* 0x14b0 */ 122,101,114,111, 0, 95, 99,108,111,115,101, 0, 95,101,120,105, +/* 0x14c0 */ 116, 0, 95,109, 97,105,110, 0, 95,109,109, 97,112, 0, 95,109, +/* 0x14d0 */ 112,114,111,116,101, 99,116, 0, 95,109,117,110,109, 97,112, 0, +/* 0x14e0 */ 95,111,112,101,110, 0, 95,112,114,101, 97,100, 0, 95,114,101, +/* 0x14f0 */ 97,100, 0, 95,117,112,120, 95,109, 97,105,110, 0, 95,119,114, +/* 0x1500 */ 105,116,101, 0, 98,115,119, 97,112, 0, 98,122,101,114,111, 0, +/* 0x1510 */ 99,108,111,115,101, 0,101,120,105,116, 0,109,109, 97,112, 0, +/* 0x1520 */ 109,112,114,111,116,101, 99,116, 0,109,117,110,109, 97,112, 0, +/* 0x1530 */ 111,112,101,110, 0,112,114,101, 97,100, 0,114,101, 97,100, 0, +/* 0x1540 */ 119,114,105,116,101, 0,100,121,108,100, 95,115,116,117, 98, 95, +/* 0x1550 */ 98,105,110,100,101,114, 0, 0 }; diff --git a/src/stub/src/amd64-darwin.macho-upxmain.c b/src/stub/src/amd64-darwin.macho-upxmain.c index bb04bd2a..cc84b703 100644 --- a/src/stub/src/amd64-darwin.macho-upxmain.c +++ b/src/stub/src/amd64-darwin.macho-upxmain.c @@ -485,8 +485,7 @@ typedef union { extern void *mmap(void *, size_t, unsigned, unsigned, int, off_t); ssize_t pread(int, void *, size_t, off_t); -#define bswap(a,b) /*EMPTY*/ -//extern void bswap(void *, unsigned); +extern void bswap(void *, unsigned); DEBUG_STRCON(STR_mmap, "mmap addr=%%p len=%%p prot=%%x flags=%%x fd=%%d off=%%p\\n"); @@ -586,6 +585,20 @@ ERR_LAB return entry; } +static off_t +fat_find(Fat_header *fh) // *fh suffers bswap() +{ + Fat_arch *fa = (Fat_arch *)(1+ fh); + bswap(fh, sizeof(*fh) + (fh->nfat_arch>>24)*sizeof(*fa)); + unsigned j; + for (j= 0; j < fh->nfat_arch; ++j, ++fa) { + if (CPU_TYPE_AMD64==fa->cputype) { + return fa->offset; // should not be 0 because of header + } + } + return 0; +} + /************************************************************************* // upx_main - called by our entry code // @@ -637,28 +650,27 @@ upx_main( if (0 > fdi) { err_exit(18); } -fat: - if ((ssize_t)sz_mhdr!=pread(fdi, (void *)mhdr, sz_mhdr, fat_offset)) { + for (;;) { // possibly 2 times for 'fat' binary + if ((ssize_t)sz_mhdr!=pread(fdi, (void *)mhdr, sz_mhdr, fat_offset)) { ERR_LAB - err_exit(19); - } - switch (mhdr->magic) { - case MH_MAGIC: break; - case MH_MAGIC64: break; - case FAT_CIGAM: - case FAT_MAGIC: { - // stupid Apple: waste code and a page fault on EVERY execve - Fat_header *const fh = (Fat_header *)mhdr; - Fat_arch *fa = (Fat_arch *)(1+ fh); - bswap(fh, sizeof(*fh) + (fh->nfat_arch>>24)*sizeof(*fa)); - for (j= 0; j < fh->nfat_arch; ++j, ++fa) { - if (CPU_TYPE_AMD64==fa->cputype) { - fat_offset= fa->offset; - goto fat; - } + err_exit(19); } - } break; - } // switch + switch (mhdr->magic) { + case MH_MAGIC: break; // i686 on x86_64 ? + case MH_MAGIC64: break; + + case FAT_CIGAM: + case FAT_MAGIC: { + // stupid Apple: waste code and a page fault on EVERY execve + fat_offset = fat_find((Fat_header *)mhdr); + if (fat_offset) { + continue; // the 'for' loop + } + err_exit(20); // no other choice + } break; + } // switch + break; + } entry = do_xmap(mhdr, fat_offset, 0, fdi, 0, 0, 0); close(fdi); break; @@ -699,7 +711,7 @@ main(int argc, char *argv[]) Mach_section_command const *const secptr = (Mach_section_command const *)(1+ segptr); //if ((long)0x0000747865745f5ful == *(long const *)secptr->sectname) { // "__text" f_unf = (f_unfilter *)(sizeof(unsigned short) + secptr->addr); - f_exp = (f_expand *)((char const *)f_unf + ((unsigned short *)f_unf)[-1]); + f_exp = (f_expand *)(*(unsigned short *)secptr->addr + secptr->addr); //fprintf(stderr, "f_unf=%p f_exp=%p\n", f_unf, f_exp); //} } @@ -716,8 +728,8 @@ main(int argc, char *argv[]) (Mach_header64 *)mhdr, sizeof(mhdr), f_exp, f_unf, (Mach_header64 **)&argv[-2]); //fprintf(stderr, "return to launch\n"); - argv[-1] = argc; - asm("lea -2*8(%1),%rsp; jmp *%0" : : "r" (entry), "r" (argv)); + argv[-1] = (char *)(long)argc; + asm("lea -2*8(%1),%%rsp; jmp *%0" : : "r" (entry), "r" (argv)); return 0; } diff --git a/src/stub/src/amd64-darwin.macho-upxsubr.S b/src/stub/src/amd64-darwin.macho-upxsubr.S new file mode 100644 index 00000000..df566cba --- /dev/null +++ b/src/stub/src/amd64-darwin.macho-upxsubr.S @@ -0,0 +1,57 @@ +#define GLOBAL(sym) sym: .globl sym; _##sym: .globl _##sym + +GLOBAL(bswap) +0: + mov (%rdi),%eax + .byte 0x0f,0xc8 // bswap eax + mov %eax,(%rdi) + sub $4,%rsi + lea 4(%rdi),%rdi + ja 0b + ret + +GLOBAL(bzero) +GLOBAL(__bzero) + xor %eax,%eax // the value + mov %esi,%ecx // the count + rep; stosb // *rdi++ = %al + ret + +SYS_exit =1 +SYS_read =3 +SYS_write =4 +SYS_open =5 +SYS_close =6 + +SYS_pread =0x99 +SYS_mmap =0xc5 +SYS_munmap =0x49 +SYS_mprotect =0x4a + +// lazy jmps enable compression of this code +GLOBAL(write) + mov $SYS_write,%al; .word 0x02eb +GLOBAL(exit) + mov $SYS_exit,%al; .word 0x02eb +GLOBAL(mprotect) + mov $SYS_mprotect,%al; .word 0x02eb +GLOBAL(munmap) + mov $SYS_munmap,%al; .word 0x02eb +GLOBAL(pread) + mov $SYS_pread,%al; .word 0x02eb +GLOBAL(close) + mov $SYS_close,%al; .word 0x02eb +GLOBAL(open) + mov $SYS_open,%al; .word 0x02eb +GLOBAL(mmap) + mov $SYS_mmap,%al; .word 0x02eb +GLOBAL(read) + mov $SYS_read,%al + + movzbl %al,%eax; or $0x02000000,%eax + mov %rcx,%r10 + syscall // .byte 0x0f,0x05 + jnc 0f + or $~0,%rax //mov errno,eax +0: + ret From 63dec77ed6b3c36a627a293271d3a69fdfa35d04 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sun, 11 Sep 2016 15:08:56 -0700 Subject: [PATCH 15/29] Try auto-relocate for /usr/lib/dyld changed src/stub/amd64-darwin.macho-upxmain.h changed src/stub/src/amd64-darwin.macho-upxmain.c --- src/stub/amd64-darwin.macho-upxmain.h | 184 +++++++++++----------- src/stub/src/amd64-darwin.macho-upxmain.c | 22 ++- 2 files changed, 107 insertions(+), 99 deletions(-) diff --git a/src/stub/amd64-darwin.macho-upxmain.h b/src/stub/amd64-darwin.macho-upxmain.h index e8c46628..77ba9596 100644 --- a/src/stub/amd64-darwin.macho-upxmain.h +++ b/src/stub/amd64-darwin.macho-upxmain.h @@ -32,8 +32,8 @@ #define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_SIZE 5464 -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x588116f2 -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0xd16eba11 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x0147312d +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0x6ca9614a unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x0000 */ 207,250,237,254, 7, 0, 0, 1, 3, 0, 0,128, 2, 0, 0, 0, @@ -49,8 +49,8 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x00a0 */ 7, 0, 0, 0, 5, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, /* 0x00b0 */ 95, 95,116,101,120,116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00c0 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x00d0 */ 95, 9,255,255, 0, 0, 0, 0, 65, 6, 0, 0, 0, 0, 0, 0, -/* 0x00e0 */ 95, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x00d0 */ 37, 9,255,255, 0, 0, 0, 0,123, 6, 0, 0, 0, 0, 0, 0, +/* 0x00e0 */ 37, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00f0 */ 0, 4, 0,128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0100 */ 95, 95,117,110,119,105,110,100, 95,105,110,102,111, 0, 0, 0, /* 0x0110 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -182,89 +182,89 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x08f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0900 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0910 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0920 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0930 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0940 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0950 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 85, -/* 0x0960 */ 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, 72, -/* 0x0970 */ 77,137,205, 76,137,195, 73,137,206, 73,137,212, 72,137,117,208, -/* 0x0980 */ 72,141, 71, 24, 72,137, 69,200, 72,139, 69,208, 72,131,192,232, -/* 0x0990 */ 72,137, 69,192, 76,137,101,184,139, 71, 24, 72,137, 69,176, 72, -/* 0x09a0 */ 139, 69,192, 72,139, 77,200, 72,137, 77,168, 72,137, 69,160, 69, -/* 0x09b0 */ 49,255, 72,141,125,192, 72,141,117,176, 49,201, 72,137,218,232, -/* 0x09c0 */ 27, 1, 0, 0, 76,137, 44, 36, 72,141, 85,160,190, 0, 0, 0, -/* 0x09d0 */ 0,185,255,255,255,255, 76,137,231, 76,139, 69, 16, 73,137,217, -/* 0x09e0 */ 232, 16, 2, 0, 0, 72,137,195, 65,139, 76, 36, 16,133,201, 15, -/* 0x09f0 */ 132,216, 0, 0, 0, 73,141, 68, 36, 32,131, 56, 14,116, 19, 65, -/* 0x0a00 */ 255,199,139, 80, 4, 72, 1,208, 65, 57,207,114,237,233,187, 0, -/* 0x0a10 */ 0, 0,139,120, 8, 72, 1,199, 49,246, 49,210,232, 97, 5, 0, -/* 0x0a20 */ 0, 65,137,199, 69,133,255,120,113, 77,141,108, 36, 16, 49,219, -/* 0x0a30 */ 68,137,255, 76,137,230, 76,137,242, 72,137,217,232, 57, 5, 0, -/* 0x0a40 */ 0, 76, 57,240,117, 84, 65,139, 4, 36, 61,190,186,254,202,116, -/* 0x0a50 */ 7, 61,202,254,186,190,117, 76, 65, 15,182, 68, 36, 7,141, 4, -/* 0x0a60 */ 128,141, 52,133, 8, 0, 0, 0, 76,137,231,232,226, 4, 0, 0, -/* 0x0a70 */ 65,139, 68, 36, 4, 49,201,133,192, 76,137,234,116, 28,129,122, -/* 0x0a80 */ 248, 7, 0, 0, 1,116, 12,255,193, 72,131,194, 20, 57,193,114, -/* 0x0a90 */ 237,235, 7,139, 26, 72,133,219,117,150,191,127, 0, 0, 0,232, -/* 0x0aa0 */ 202, 4, 0, 0, 72,199, 4, 36, 0, 0, 0, 0, 49,210, 69, 49, -/* 0x0ab0 */ 192, 69, 49,201, 76,137,231, 72,137,222, 68,137,249,232, 51, 1, -/* 0x0ac0 */ 0, 0, 72,137,195, 68,137,255,232,177, 4, 0, 0, 72,137,216, -/* 0x0ad0 */ 72,131,196, 72, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195, 85, -/* 0x0ae0 */ 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, 56, -/* 0x0af0 */ 72,137, 77,176, 72,137, 85,168, 73,137,246, 72,137,125,184, 73, -/* 0x0b00 */ 131, 62, 0, 15,132,211, 0, 0, 0, 76,141,101,200,186, 12, 0, -/* 0x0b10 */ 0, 0, 72,139,125,184, 76,137,230,232,234, 3, 0, 0, 68,139, -/* 0x0b20 */ 109,200, 68,139,125,204, 77,133,237, 15,132,154, 0, 0, 0, 65, -/* 0x0b30 */ 141, 71,255, 68, 57,232, 15,131,175, 0, 0, 0, 77, 59, 46, 15, -/* 0x0b40 */ 135,166, 0, 0, 0, 69, 57,239,115, 90, 68,137,109,196, 72,139, -/* 0x0b50 */ 69,184, 72,139,120, 8, 73,139, 86, 8,139, 93,208, 68, 15,182, -/* 0x0b60 */ 195, 68,137,254, 72,141, 77,196,255, 85,168,133,192,117,124, 68, -/* 0x0b70 */ 57,109,196,117,118, 72,131,125,176, 0,116, 27, 15,182,199,102, -/* 0x0b80 */ 133,192,116, 19,193,235, 16, 15,183,200, 73,139,126, 8, 15,182, -/* 0x0b90 */ 211, 68,137,238,255, 85,176, 72,139, 69,184, 76, 1,120, 8, 76, -/* 0x0ba0 */ 41, 56,235, 16, 73,139,118, 8, 72,139,125,184, 76,137,250,232, -/* 0x0bb0 */ 84, 3, 0, 0, 77, 1,110, 8, 73,139, 6, 76, 41,232, 73,137, -/* 0x0bc0 */ 6, 15,133, 70,255,255,255,235, 19, 65,129,255, 85, 80, 88, 33, -/* 0x0bd0 */ 117, 25, 72,139, 69,184, 72,131, 56, 0,117, 15, 72,131,196, 56, -/* 0x0be0 */ 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195,191,127, 0, 0, 0, -/* 0x0bf0 */ 232,121, 3, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, -/* 0x0c00 */ 84, 83, 72,131,236,104, 76,137,141,120,255,255,255, 76,137,133, -/* 0x0c10 */ 112,255,255,255,137, 77,148, 72,137, 85,192, 72,137,117,136, 72, -/* 0x0c20 */ 137,125,152,139, 95, 16, 69, 49,255,133,219,184, 0, 0, 0, 0, -/* 0x0c30 */ 15,132, 7, 2, 0, 0, 72,139, 77,152, 76,141,105, 32, 72,131, -/* 0x0c40 */ 125,192, 0, 15,149,193, 15,182,201, 72,141, 12, 73, 72,137, 77, -/* 0x0c50 */ 128, 72,191, 4, 0, 0, 0, 42, 0, 0, 0, 69, 49,192, 49,192, -/* 0x0c60 */ 73,139, 85, 0, 72,137,209, 72,193,233, 32,141,114,252,131,254, -/* 0x0c70 */ 2, 15,130, 80, 1, 0, 0,129,250, 40, 0, 0,128, 15,132, 83, -/* 0x0c80 */ 1, 0, 0,131,250, 25, 15,133,160, 1, 0, 0, 73,139, 85, 32, -/* 0x0c90 */ 72,133,210, 15,132,147, 1, 0, 0, 72,137, 85,168, 76,137, 69, -/* 0x0ca0 */ 184, 72,137, 69,160, 73,139, 69, 48, 72,137, 69,200, 77,139,101, -/* 0x0cb0 */ 24, 76,137,101,176, 76,137,101,208, 69,137,230, 65,129,230,255, -/* 0x0cc0 */ 15, 0, 0, 77, 41,244, 73, 1,198,116, 73, 72,139, 77,128, 73, -/* 0x0cd0 */ 141, 52, 14, 72,133,192,185, 18, 0, 0, 0,186, 18, 16, 0, 0, -/* 0x0ce0 */ 15, 68,202, 72,131,125,192, 0, 15, 69,202, 72,131,248, 1, 69, -/* 0x0cf0 */ 25,192, 68, 11, 69,148, 77,139, 77, 40, 76, 3, 77,136,186, 3, -/* 0x0d00 */ 0, 0, 0, 76,137,231,232,123, 2, 0, 0, 73, 57,196, 15,133, -/* 0x0d10 */ 56, 1, 0, 0, 72,131,125,192, 0,116, 52, 73,131,125, 48, 0, -/* 0x0d20 */ 116, 45, 73,131,125, 40, 0,117, 14, 72,139,133,112,255,255,255, -/* 0x0d30 */ 76,137, 32, 76,137,109,184, 72,139,125,192, 72,141,117,200, 72, -/* 0x0d40 */ 139,149,120,255,255,255, 72,139, 77, 16,232,144,253,255,255, 68, -/* 0x0d50 */ 137,243,247,219, 72,129,227,255, 15, 0, 0,116, 12, 75,141, 60, -/* 0x0d60 */ 52, 72,137,222,232,250, 1, 0, 0, 77,133,246,116, 23, 65,139, -/* 0x0d70 */ 85, 60, 76,137,231, 76,137,246,232,245, 1, 0, 0,133,192, 15, -/* 0x0d80 */ 133,199, 0, 0, 0, 72,139, 69,176, 72, 3, 69,168, 76, 1,243, -/* 0x0d90 */ 73, 1,220, 73, 57,196,115, 84, 77,133,228,116,114, 72,137,198, -/* 0x0da0 */ 76, 41,230, 65,139, 85, 60,185, 18, 16, 0, 0, 65,184,255,255, -/* 0x0db0 */ 255,255, 69, 49,201, 76,137,231,232,201, 1, 0, 0, 73, 57,196, -/* 0x0dc0 */ 116, 77,233,133, 0, 0, 0, 73, 57,125, 8,117, 95, 73,139,133, -/* 0x0dd0 */ 144, 0, 0, 0,235, 86, 73,139, 69, 8, 73, 57, 64, 40,119, 76, -/* 0x0de0 */ 73, 59, 64, 48,115, 70, 73, 3, 64, 24,235, 64, 72,131,125,192, +/* 0x0920 */ 0, 0, 0, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, +/* 0x0930 */ 84, 83, 72,131,236, 72, 77,137,205, 76,137,195, 73,137,206, 73, +/* 0x0940 */ 137,212, 72,137,117,208, 72,141, 71, 24, 72,137, 69,200, 72,139, +/* 0x0950 */ 69,208, 72,131,192,232, 72,137, 69,192, 76,137,101,184,139, 71, +/* 0x0960 */ 24, 72,137, 69,176, 72,139, 69,192, 72,139, 77,200, 72,137, 77, +/* 0x0970 */ 168, 72,137, 69,160, 69, 49,255, 72,141,125,192, 72,141,117,176, +/* 0x0980 */ 49,201, 72,137,218,232, 27, 1, 0, 0, 76,137, 44, 36, 72,141, +/* 0x0990 */ 85,160,190, 0, 0, 0, 0,185,255,255,255,255, 76,137,231, 76, +/* 0x09a0 */ 139, 69, 16, 73,137,217,232, 16, 2, 0, 0, 72,137,195, 65,139, +/* 0x09b0 */ 76, 36, 16,133,201, 15,132,216, 0, 0, 0, 73,141, 68, 36, 32, +/* 0x09c0 */ 131, 56, 14,116, 19, 65,255,199,139, 80, 4, 72, 1,208, 65, 57, +/* 0x09d0 */ 207,114,237,233,187, 0, 0, 0,139,120, 8, 72, 1,199, 49,246, +/* 0x09e0 */ 49,210,232,155, 5, 0, 0, 65,137,199, 69,133,255,120,113, 77, +/* 0x09f0 */ 141,108, 36, 16, 49,219, 68,137,255, 76,137,230, 76,137,242, 72, +/* 0x0a00 */ 137,217,232,115, 5, 0, 0, 76, 57,240,117, 84, 65,139, 4, 36, +/* 0x0a10 */ 61,190,186,254,202,116, 7, 61,202,254,186,190,117, 76, 65, 15, +/* 0x0a20 */ 182, 68, 36, 7,141, 4,128,141, 52,133, 8, 0, 0, 0, 76,137, +/* 0x0a30 */ 231,232, 28, 5, 0, 0, 65,139, 68, 36, 4, 49,201,133,192, 76, +/* 0x0a40 */ 137,234,116, 28,129,122,248, 7, 0, 0, 1,116, 12,255,193, 72, +/* 0x0a50 */ 131,194, 20, 57,193,114,237,235, 7,139, 26, 72,133,219,117,150, +/* 0x0a60 */ 191,127, 0, 0, 0,232, 4, 5, 0, 0, 72,199, 4, 36, 0, 0, +/* 0x0a70 */ 0, 0, 49,210, 69, 49,192, 69, 49,201, 76,137,231, 72,137,222, +/* 0x0a80 */ 68,137,249,232, 51, 1, 0, 0, 72,137,195, 68,137,255,232,235, +/* 0x0a90 */ 4, 0, 0, 72,137,216, 72,131,196, 72, 91, 65, 92, 65, 93, 65, +/* 0x0aa0 */ 94, 65, 95, 93,195, 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, +/* 0x0ab0 */ 84, 83, 72,131,236, 56, 72,137, 77,176, 72,137, 85,168, 73,137, +/* 0x0ac0 */ 246, 72,137,125,184, 73,131, 62, 0, 15,132,211, 0, 0, 0, 76, +/* 0x0ad0 */ 141,101,200,186, 12, 0, 0, 0, 72,139,125,184, 76,137,230,232, +/* 0x0ae0 */ 36, 4, 0, 0, 68,139,109,200, 68,139,125,204, 77,133,237, 15, +/* 0x0af0 */ 132,154, 0, 0, 0, 65,141, 71,255, 68, 57,232, 15,131,175, 0, +/* 0x0b00 */ 0, 0, 77, 59, 46, 15,135,166, 0, 0, 0, 69, 57,239,115, 90, +/* 0x0b10 */ 68,137,109,196, 72,139, 69,184, 72,139,120, 8, 73,139, 86, 8, +/* 0x0b20 */ 139, 93,208, 68, 15,182,195, 68,137,254, 72,141, 77,196,255, 85, +/* 0x0b30 */ 168,133,192,117,124, 68, 57,109,196,117,118, 72,131,125,176, 0, +/* 0x0b40 */ 116, 27, 15,182,199,102,133,192,116, 19,193,235, 16, 15,183,200, +/* 0x0b50 */ 73,139,126, 8, 15,182,211, 68,137,238,255, 85,176, 72,139, 69, +/* 0x0b60 */ 184, 76, 1,120, 8, 76, 41, 56,235, 16, 73,139,118, 8, 72,139, +/* 0x0b70 */ 125,184, 76,137,250,232,142, 3, 0, 0, 77, 1,110, 8, 73,139, +/* 0x0b80 */ 6, 76, 41,232, 73,137, 6, 15,133, 70,255,255,255,235, 19, 65, +/* 0x0b90 */ 129,255, 85, 80, 88, 33,117, 25, 72,139, 69,184, 72,131, 56, 0, +/* 0x0ba0 */ 117, 15, 72,131,196, 56, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93, +/* 0x0bb0 */ 195,191,127, 0, 0, 0,232,179, 3, 0, 0, 85, 72,137,229, 65, +/* 0x0bc0 */ 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236,120, 76,137,141,112, +/* 0x0bd0 */ 255,255,255, 76,137,133,104,255,255,255,137, 77,140, 72,137, 85, +/* 0x0be0 */ 184, 72,137,117,128, 72,137,125,144,139, 95, 16, 69, 49,255,133, +/* 0x0bf0 */ 219,184, 0, 0, 0, 0, 15,132, 65, 2, 0, 0, 72,139, 77,144, +/* 0x0c00 */ 76,141,105, 32, 72,131,125,184, 0, 15,149,193, 15,182,201, 72, +/* 0x0c10 */ 141, 12, 73, 72,137,141,120,255,255,255, 72,191, 4, 0, 0, 0, +/* 0x0c20 */ 42, 0, 0, 0, 69, 49,192, 49,192, 49,201, 72,137, 77,192, 73, +/* 0x0c30 */ 139, 85, 0, 72,137,209, 72,193,233, 32,141,114,252,131,254, 2, +/* 0x0c40 */ 15,130,125, 1, 0, 0,129,250, 40, 0, 0,128, 15,132,132, 1, +/* 0x0c50 */ 0, 0,131,250, 25, 15,133,209, 1, 0, 0, 73,139, 85, 32, 72, +/* 0x0c60 */ 133,210, 15,132,196, 1, 0, 0, 72,137, 85,160, 76,137, 69,176, +/* 0x0c70 */ 72,137, 69,152, 73,139, 69, 48, 72,137, 69,200, 77,139,101, 24, +/* 0x0c80 */ 76,137,101,168, 76,137,101,208, 69,137,230, 65,129,230,255, 15, +/* 0x0c90 */ 0, 0, 77, 41,244, 73, 1,198,116,118, 72,139,141,120,255,255, +/* 0x0ca0 */ 255, 73,141, 52, 14, 76,137,231, 72,139, 77,192, 72, 1,207,186, +/* 0x0cb0 */ 2, 0, 0, 0,185, 18, 0, 0, 0, 15, 69,209, 72,133,192, 15, +/* 0x0cc0 */ 148,193, 15,182,201,193,225, 12, 72,131,125,184, 0,187, 0, 16, +/* 0x0cd0 */ 0, 0, 15, 69,203, 9,209, 72,131,248, 1, 69, 25,192, 68, 11, +/* 0x0ce0 */ 69,140, 77,139, 77, 40, 76, 3, 77,128,186, 3, 0, 0, 0,232, +/* 0x0cf0 */ 146, 2, 0, 0, 72,139, 77,192, 73, 1,204, 72, 15, 68,200, 72, +/* 0x0d00 */ 137, 77,192, 72,131,248,255, 73,137,196, 15,132, 60, 1, 0, 0, +/* 0x0d10 */ 72,131,125,184, 0,116, 52, 73,131,125, 48, 0,116, 45, 73,131, +/* 0x0d20 */ 125, 40, 0,117, 14, 72,139,133,104,255,255,255, 76,137, 32, 76, +/* 0x0d30 */ 137,109,176, 72,139,125,184, 72,141,117,200, 72,139,149,112,255, +/* 0x0d40 */ 255,255, 72,139, 77, 16,232, 90,253,255,255, 68,137,243,247,219, +/* 0x0d50 */ 72,129,227,255, 15, 0, 0,116, 12, 75,141, 60, 52, 72,137,222, +/* 0x0d60 */ 232,254, 1, 0, 0, 77,133,246,116, 23, 65,139, 85, 60, 76,137, +/* 0x0d70 */ 231, 76,137,246,232,249, 1, 0, 0,133,192, 15,133,203, 0, 0, +/* 0x0d80 */ 0, 72,139, 69,168, 72, 3, 69,160, 76, 1,243, 73, 1,220, 73, +/* 0x0d90 */ 57,196,115, 88, 77,133,228,116,118, 72,137,198, 76, 41,230, 65, +/* 0x0da0 */ 139, 85, 60,185, 18, 16, 0, 0, 65,184,255,255,255,255, 69, 49, +/* 0x0db0 */ 201, 76,137,231,232,205, 1, 0, 0, 73, 57,196,116, 81,233,137, +/* 0x0dc0 */ 0, 0, 0, 73, 57,125, 8,117, 99, 73,139,133,144, 0, 0, 0, +/* 0x0dd0 */ 72, 3, 69,192,235, 86, 73,139, 69, 8, 73, 57, 64, 40,119, 76, +/* 0x0de0 */ 73, 59, 64, 48,115, 70, 73, 3, 64, 24,235, 64, 72,131,125,184, /* 0x0df0 */ 0,116, 28, 65,131,198, 3, 65,129,230,255, 15, 0, 0, 73,131, /* 0x0e00 */ 254, 3,119, 11, 76,137,231, 76,137,246,232,103, 1, 0, 0, 65, -/* 0x0e10 */ 139, 77, 4, 72,139, 69,152,139, 88, 16, 72,191, 4, 0, 0, 0, -/* 0x0e20 */ 42, 0, 0, 0, 72,139, 69,160, 76,139, 69,184, 65,255,199,137, -/* 0x0e30 */ 201, 73, 1,205, 65, 57,223, 15,130, 35,254,255,255, 72,131,196, -/* 0x0e40 */ 104, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195,191,127, 0, 0, +/* 0x0e10 */ 139, 77, 4, 72,139, 69,144,139, 88, 16, 72,191, 4, 0, 0, 0, +/* 0x0e20 */ 42, 0, 0, 0, 72,139, 69,152, 76,139, 69,176, 65,255,199,137, +/* 0x0e30 */ 201, 73, 1,205, 65, 57,223, 15,130,242,253,255,255, 72,131,196, +/* 0x0e40 */ 120, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195,191,127, 0, 0, /* 0x0e50 */ 0,232, 24, 1, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 83, 72, /* 0x0e60 */ 129,236, 24, 8, 0, 0, 73,137,247, 65,137,254, 72,141, 5,227, /* 0x0e70 */ 255,255,255, 72, 37, 0, 0,255,255,139, 72, 16,133,201,116, 82, @@ -274,7 +274,7 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x0eb0 */ 104, 68, 15,183, 3, 73, 1,216, 76,141, 75, 2,235, 8, 72,139, /* 0x0ec0 */ 120, 24, 72,139,112, 48,255,194,139, 88, 4, 72, 1,216, 57,202, /* 0x0ed0 */ 114,200, 73,141, 71,240, 72,137, 4, 36, 72,141,149,224,247,255, -/* 0x0ee0 */ 255,185, 0, 8, 0, 0,232,116,250,255,255, 73, 99,206, 73,137, +/* 0x0ee0 */ 255,185, 0, 8, 0, 0,232, 58,250,255,255, 73, 99,206, 73,137, /* 0x0ef0 */ 79,248, 73,141,103,240,255,224, 49,192, 72,129,196, 24, 8, 0, /* 0x0f00 */ 0, 91, 65, 94, 65, 95, 93,195, 72,139, 15, 72, 57,209,114, 52, /* 0x0f10 */ 72,139, 71, 8, 72,133,210,116, 29, 72,137,209, 72,255,201, 68, @@ -287,10 +287,10 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x0f80 */ 235, 2,176, 5,235, 2,176,197,235, 2,176, 3, 15,182,192, 13, /* 0x0f90 */ 0, 0, 0, 2, 73,137,202, 15, 5,115, 4, 72,131,200,255,195, /* 0x0fa0 */ 1, 0, 0, 0, 28, 0, 0, 0, 0, 0, 0, 0, 28, 0, 0, 0, -/* 0x0fb0 */ 0, 0, 0, 0, 28, 0, 0, 0, 2, 0, 0, 0, 95, 9, 0, 0, +/* 0x0fb0 */ 0, 0, 0, 0, 28, 0, 0, 0, 2, 0, 0, 0, 37, 9, 0, 0, /* 0x0fc0 */ 52, 0, 0, 0, 52, 0, 0, 0,161, 15, 0, 0, 0, 0, 0, 0, /* 0x0fd0 */ 52, 0, 0, 0, 3, 0, 0, 0, 12, 0, 4, 0, 28, 0, 4, 0, -/* 0x0fe0 */ 0, 0, 0, 3,247, 4, 0, 2,169, 5, 0, 1,243, 5, 0, 0, +/* 0x0fe0 */ 0, 0, 0, 3, 49, 5, 0, 2,227, 5, 0, 1, 45, 6, 0, 0, /* 0x0ff0 */ 0, 0, 0, 0, 0, 0, 0, 1, 97, 1, 3, 1,209, 88, 5, 1, /* 0x1000 */ 0, 9, 95, 0, 58, 98, 0,233, 1,119,114,105,116,101, 0,151, /* 0x1010 */ 2,101,120,105,116, 0,161, 2,109, 0,171, 2,112,114,101, 97, @@ -302,7 +302,7 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x1070 */ 2,111,112,101,110, 0,232, 2,114,101, 97,100, 0,252, 2, 0, /* 0x1080 */ 3,109,104, 95,101,120,101, 99,117,116,101, 95,104,101, 97,100, /* 0x1090 */ 101,114, 0,166, 1, 95, 98,122,101,114,111, 0,254, 1, 98,122, -/* 0x10a0 */ 101,114,111, 0,131, 2, 2, 0, 0, 0, 3, 0,223, 18, 0, 0, +/* 0x10a0 */ 101,114,111, 0,131, 2, 2, 0, 0, 0, 3, 0,165, 18, 0, 0, /* 0x10b0 */ 4, 97,105,110, 0,207, 1,112,114,111,116,101, 99,116, 0,166, /* 0x10c0 */ 2,117,110,109, 97,112, 0,202, 2,109, 97,112, 0,242, 2, 3, /* 0x10d0 */ 0,214, 28, 0, 0, 2,115,119, 97,112, 0,228, 1,122,101,114, @@ -317,8 +317,8 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x1160 */ 254, 30, 0, 3, 0,254, 30, 0, 3, 0,130, 31, 0, 3, 0,130, /* 0x1170 */ 31, 0, 3, 0,134, 31, 0, 3, 0,134, 31, 0, 3, 0,138, 31, /* 0x1180 */ 0, 3, 0,138, 31, 0, 0, 0, 2, 0, 0, 0, 14, 1, 0, 0, -/* 0x1190 */ 223, 10,255,255, 0, 0, 0, 0, 16, 0, 0, 0, 14, 1, 0, 0, -/* 0x11a0 */ 245, 11,255,255, 0, 0, 0, 0, 25, 0, 0, 0, 14, 1, 0, 0, +/* 0x1190 */ 165, 10,255,255, 0, 0, 0, 0, 16, 0, 0, 0, 14, 1, 0, 0, +/* 0x11a0 */ 187, 11,255,255, 0, 0, 0, 0, 25, 0, 0, 0, 14, 1, 0, 0, /* 0x11b0 */ 8, 15,255,255, 0, 0, 0, 0, 32, 0, 0, 0, 2, 0, 0, 0, /* 0x11c0 */ 1, 0, 0, 0, 0, 0, 0, 0, 41, 0, 0, 0, 2, 0, 0, 0, /* 0x11d0 */ 3, 0, 0, 0, 0, 0, 0, 0, 50, 0, 0, 0, 2, 0, 0, 0, @@ -343,7 +343,7 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x1300 */ 130, 15,255,255, 0, 0, 0, 0,222, 0, 0, 0, 15, 1, 0, 0, /* 0x1310 */ 122, 15,255,255, 0, 0, 0, 0,229, 0, 0, 0, 15, 1, 0, 0, /* 0x1320 */ 138, 15,255,255, 0, 0, 0, 0,235, 0, 0, 0, 15, 1, 0, 0, -/* 0x1330 */ 95, 9,255,255, 0, 0, 0, 0,245, 0, 0, 0, 15, 1, 0, 0, +/* 0x1330 */ 37, 9,255,255, 0, 0, 0, 0,245, 0, 0, 0, 15, 1, 0, 0, /* 0x1340 */ 106, 15,255,255, 0, 0, 0, 0,252, 0, 0, 0, 15, 1, 0, 0, /* 0x1350 */ 82, 15,255,255, 0, 0, 0, 0, 2, 1, 0, 0, 15, 1, 0, 0, /* 0x1360 */ 99, 15,255,255, 0, 0, 0, 0, 8, 1, 0, 0, 15, 1, 0, 0, diff --git a/src/stub/src/amd64-darwin.macho-upxmain.c b/src/stub/src/amd64-darwin.macho-upxmain.c index cc84b703..be538401 100644 --- a/src/stub/src/amd64-darwin.macho-upxmain.c +++ b/src/stub/src/amd64-darwin.macho-upxmain.c @@ -482,6 +482,7 @@ typedef union { #define PROT_WRITE 2 #define PROT_EXEC 4 #define MAP_ANON_FD -1 +#define MAP_FAILED ((void *) -1) extern void *mmap(void *, size_t, unsigned, unsigned, int, off_t); ssize_t pread(int, void *, size_t, off_t); @@ -506,6 +507,7 @@ do_xmap( Mach_segment_command const *sc = (Mach_segment_command const *)(1+ mhdr); Mach_segment_command const *segTEXT = 0; uint64_t entry = 0; + unsigned long base = 0; unsigned j; DPRINTF((STR_do_xmap(), @@ -522,19 +524,24 @@ do_xmap( addr -= frag; mlen += frag; - if (0!=mlen) { + if (0!=mlen) { // In particular, omitted for __PAGEZERO // Decompressor can overrun the destination by 3 bytes. [x86 only] size_t const mlen3 = mlen + (xi ? 3 : 0); unsigned const prot = VM_PROT_READ | VM_PROT_WRITE; - unsigned const flags = MAP_FIXED | MAP_PRIVATE | + unsigned const flags = ((addr + base) ? MAP_FIXED : 0) | MAP_PRIVATE | ((xi || 0==sc->filesize) ? MAP_ANON : 0); int const fdm = ((0==sc->filesize) ? MAP_ANON_FD : fdi); off_t const offset = sc->fileoff + fat_offset; - DPRINTF((STR_mmap(), addr, mlen3, prot, flags, fdm, offset)); - if (addr != mmap(addr, mlen3, prot, flags, fdm, offset)) { + DPRINTF((STR_mmap(), addr + base, mlen3, prot, flags, fdm, offset)); + unsigned char *mapa = mmap(addr + base, mlen3, prot, flags, fdm, offset); + if (MAP_FAILED == mapa) { err_exit(8); } + if (0 == (addr + base)) { // dyld auto-relocate + base = (unsigned long)mapa; // relocation constant + } + addr = mapa; } if (xi && 0!=sc->filesize) { if (0==sc->fileoff /*&& 0!=mhdrpp*/) { @@ -572,15 +579,16 @@ ERR_LAB Mach_thread_command const *const thrc = (Mach_thread_command const *)sc; if (AMD64_THREAD_STATE ==thrc->flavor && AMD64_THREAD_STATE_COUNT==thrc->count ) { - entry = thrc->state.rip; + entry = thrc->state.rip + base; // JMP } } else if (LC_MAIN==sc->cmd) { entry = ((Mach_main_command const *)sc)->entryoff; if (segTEXT->fileoff <= entry && entry < segTEXT->filesize) { - entry += segTEXT->vmaddr; + entry += segTEXT->vmaddr; // CALL } - // XXX FIXME TODO: if entry not in segTEXT + // XXX FIXME TODO: if entry not in segTEXT? + // XXX FIXME TODO: LC_MAIN is a CALL; LC_*THREAD is a JMP } return entry; } From 4a1100b6a48233099ee89949ee88944e407c1ad9 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sun, 11 Sep 2016 15:28:42 -0700 Subject: [PATCH 16/29] Unexport all symbols in compressed output. added src/stub/src/amd64-darwin.macho-upxhide.txt changed src/stub/src/amd64-darwin.macho-upxmain.c --- src/stub/src/amd64-darwin.macho-upxhide.txt | 1 + src/stub/src/amd64-darwin.macho-upxmain.c | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) create mode 100644 src/stub/src/amd64-darwin.macho-upxhide.txt diff --git a/src/stub/src/amd64-darwin.macho-upxhide.txt b/src/stub/src/amd64-darwin.macho-upxhide.txt new file mode 100644 index 00000000..72e8ffc0 --- /dev/null +++ b/src/stub/src/amd64-darwin.macho-upxhide.txt @@ -0,0 +1 @@ +* diff --git a/src/stub/src/amd64-darwin.macho-upxmain.c b/src/stub/src/amd64-darwin.macho-upxmain.c index be538401..3b5ae8ec 100644 --- a/src/stub/src/amd64-darwin.macho-upxmain.c +++ b/src/stub/src/amd64-darwin.macho-upxmain.c @@ -698,7 +698,8 @@ typedef struct { // Build on Mac OS X: (where gcc is really clang) // gcc -o amd64-darwin.macho-upxmain.exe -fno-stack-protector \ // -Os -fPIC amd64-darwin.macho-upxmain.c -Wl,-pagezero_size,0xffff0000 \ -// -Wl,-no_pie -Wl,-no_uuid -Wl,-no_function_starts -Wl,-headerpad,0x400 +// -Wl,-no_pie -Wl,-no_uuid -Wl,-no_function_starts -Wl,-headerpad,0x400 \ +// -Wl,-unexported_symbols_list amd64-darwin.macho-upxhide.txt int main(int argc, char *argv[]) { From 37747043267fe86133228ac1c2375b7dd574c559 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Tue, 13 Sep 2016 20:14:44 -0700 Subject: [PATCH 17/29] forgotten file; 3 FIXME ! added src/stub/src/arch/arm/v8a/lzma_d-arm.S --- src/stub/src/arch/arm/v8a/lzma_d-arm.S | 525 +++++++++++++++++++++++++ 1 file changed, 525 insertions(+) create mode 100644 src/stub/src/arch/arm/v8a/lzma_d-arm.S diff --git a/src/stub/src/arch/arm/v8a/lzma_d-arm.S b/src/stub/src/arch/arm/v8a/lzma_d-arm.S new file mode 100644 index 00000000..39f37862 --- /dev/null +++ b/src/stub/src/arch/arm/v8a/lzma_d-arm.S @@ -0,0 +1,525 @@ +// In LZMA SDK 4.63 file lzma.txt (2008-12-30): +// LZMA SDK is written and placed in the public domain by Igor Pavlov. +// The creative expression of this hand compilation into assembly language, +// including (but not limited to) code organization and register assignment, +// remains copyright by John F. Reiser and licensed under GNU Lesser General +// Public License (GNU LGPL). + +// Hand compiled Copyright (c) 2006-2015 John F. Reiser (2007-06-18) +// from modified LzmaDecode.c. +// LZMA SDK 4.40 Copyright (c) 1999-2015 Igor Pavlov (2006-05-01) +// +// This file is licensed under either of these two licenses: +// 1) GNU Lesser General Public License (GNU LGPL) +// 2) Common Public License (CPL) +// See files LGPL.txt and CPL.html for the text of the licenses. + +#include "macros.S" + +kLzmaStreamWasFinishedId= (-1) + +kNumTopBits= 24 +kTopValue= 1<> 1)) + +kNumPosSlotBits= 6 +kNumLenToPosStates= 4 + +kNumAlignBits= 4 +kAlignTableSize= (1 << kNumAlignBits) + +kMatchMinLen= 2 + +IsMatch= 0 +IsRep= (IsMatch + (kNumStates << kNumPosBitsMax)) +IsRepG0= (IsRep + kNumStates) +IsRepG1= (IsRepG0 + kNumStates) +IsRepG2= (IsRepG1 + kNumStates) +IsRep0Long= (IsRepG2 + kNumStates) +PosSlot= (IsRep0Long + (kNumStates << kNumPosBitsMax)) +SpecPos= (PosSlot + (kNumLenToPosStates << kNumPosSlotBits)) +Align= (SpecPos + kNumFullDistances - kEndPosModelIndex) + + LenCoder= (Align + kAlignTableSize) +RepLenCoder= (LenCoder + kNumLenProbs) +Literal= (RepLenCoder + kNumLenProbs) + +LZMA_BASE_SIZE= Literal /* 1846 */ +LZMA_LIT_SIZE= 768 + +#define call bl /* subroutine call */ + +#define symbol mi +#define mo mi + +#define mi w0 +#define p_in x1 +#define t1 w2 +#define t1x x2 +#define t0 w3 +#define t0x x3 + +#define bit w4 +#define bitx x4 +#define i w5 +#define ix x5 +#define state w6 +#define Range w7 + +#define inPtr x8 +#define outPtr x9 +#define prob x10 +#define p x11 + +#define Code w12 +#define inLim x13 +#define outLim x14 + +#define rep0 w15 + +#define t2x x17 + +#define nowPos bit /* temporary only */ +#define nowPosx bitx /* temporary only */ +#define distance bit +#define numDirectBits bit +#define hibit bit +#define matchB i +#define probLen ix +#define probLit ix +#define posSlot posState +#define r_posSlot t0 + +#define r_len i + +#define vs x0 +vs_ps= 2 +vs_lp= 1 +vs_lc= 0 + +#if !defined(PARAMETER_STYLE) /*{*/ + #define PARAMETER_STYLE 1 +// Possible choices: +// 1 /* 0 bytes; 1-byte encoding of pb,lp,lc [default] */ +// 2 /* -24 bytes; 2-byte encoding requires no division */ +// 3 /* -32 bytes; separate bytes lc,lp,pb,xx at -4+ probs */ +#endif /*}*/ + +/* LzmaDecode(x0=vs, x1=inStream, w2=inSize, x3= &inSizeProcessed, + x4= outStream, w5= outSize, x6= &outSizeProcessed) +*/ +LzmaDecode: .globl LzmaDecode + // save &inSizeProcesesed and caller registers + PUSH5(x3,x4,x5,x6, x30) + mov inPtr,x1 + add inLim,x1,w2, uxtw + mov outPtr,x4 + add outLim,x4,w5, uxtw + +#if 1==PARAMETER_STYLE /*{ [0]: pb*45 + lp*9 + lc */ + mov p,vs + ldrb w6,[inPtr],#1 + + mov w0,#45; udiv w4,w6,w0 // w4 = quo(w6, 45) = pb + mul w0,w0,w4; sub w6,w6,w0 // w6 = rem(w6, 45) + + mov w0,#9; udiv w5,w6,w0 // w5 = quo(w6, 9) = lp + mul w0,w0,w5; sub w6,w6,w0 // w6 = rem(w6, 9) = lc +#endif /*}*/ + +#if 2==PARAMETER_STYLE /*{ [0]: ((lc + lp)<<3) | pb; [1]: (lp<<4) | lc */ + mov p,vs + ldrb w4,[inPtr],#1; and w4,w4,#7 // pb + ldrb w6,[inPtr],#1; mov w5,w6,lsr #4 // lp + and w6,w6,#0xf // lc + +#endif /*}*/ + +#if 3==PARAMETER_STYLE /*{ lc,lp,pb,xx in separate bytes before probs[] */ + add p,vs,#4 + ldrb w6,[vs, #vs_lc] + ldrb w5,[vs, #vs_lp] + ldrb w4,[vs, #vs_ps] +#endif /*}*/ +#undef vs + + add w14,w5,w6 // lp + lc + mov Range,#~0 + lsl w5,Range,w5; mvn w5,w5 // ~(~0<>1) // 0.5 starting probability + mov x1,p + orr x0,x0,x0,lsl #16 + orr x0,x0,x0,lsl #32 +L10: + str x0,[x1],#4*2 // 4 at a time + subs w2,w2,#4; bgt L10 + + add x0,inPtr,#5 // sentinel +L14: + call rcInit2; cmp x0,inPtr; bne L14 + +L200: // main loop + ldr t0x,outBuf + ldr t1,posStateMask + sub nowPosx,outPtr,t0x + and mi,nowPos,t1 + str mi,posState + add mi,mi,state, lsl #kNumPosBitsMax + add p_in,p,#IsMatch<<1 + call rcGetBit_mi0; bne L270 + + ldr t0,litPosMask + ldr t1,lc + and t0,t0,nowPos + ldrb mi,prevB + lsl t0,t0,t1 // (nowPos & litPosMask)<> (8- lc) + add t0,t0,t1 + add prob, p,#Literal<<1 + add t0,t0,t0,lsl #1 // *3 + uxtw t0x,t0 + mov symbol,#1 + add prob,prob,t0x,lsl #1+ 8 // *768 *2 + + cmp state,#kNumLitStates; blo L240 +L205: + sxtw t0x,rep0 + neg t0x,t0x + ldrb matchB,[outPtr,t0x] +L210: // symbol === mi === mo + lsl matchB,matchB,#1 + add p_in,prob,#0x100<<1 + and bit,matchB,#0x100 + uxtw t0x,bit + add p_in,p_in,t0x,lsl #1 + call rcGetBit_mi + and t0,symbol,#1 + cmp t0,bit,lsr #8; bne L243 // break + cmp symbol,#0x100; blo L210 + b L245 +L240: // symbol === mi === mo + mov p_in,prob + call rcGetBit_mi +L243: + cmp symbol,#0x100; blo L240 +L245: + mov t1,#3; mov t0,#6 + cmp state,#10; csel t0,t1, t0,lo + cmp state,# 4; csel t0,state,t0,lo + sub state,state,t0 + b L298 // assumes symbol===w0 +L270: + add p_in,p,#IsRep<<1 + call rcGetBit_state0; bne L290 + ldr t0,rep2 + ldr t1,rep1 + str t0,rep3 + str t1,rep2 + str rep0,rep1 + mov t0,#0 + cmp state,#kNumLitStates + mov state,#3 + csel state,t0,state,lo + add prob, p,#LenCoder<<1 + b L350 +L290: + add p_in,p,#IsRepG0<<1 + call rcGetBit_state0; bne L300 +L293: + ldr t0,posState + add p_in,p,#IsRep0Long<<1 + add mi,t0,state,lsl #kNumPosBitsMax + call rcGetBit_mi0; bne L340 +L295: + mov t0,#9 + cmp state,#kNumLitStates + mov state,#11 + csel state,t0,state,lo +L297: + ldr t0x,outBuf + sub nowPosx,outPtr,t0x + cmp nowPos,rep0; blo lzmaDataError + sxtw t0x,rep0 + neg t0x,t0x + ldrb w0,[outPtr,t0x] +L298: + strb w0,[outPtr],#1 + b L519 +L300: + add p_in,p,#IsRepG1<<1 + call rcGetBit_state0; ldr distance,rep1; beq L330 +L310: + add p_in,p,#IsRepG2<<1 + call rcGetBit_state0; ldr distance,rep2; beq L325 +L320: + ldr t0,rep2 + ldr distance,rep3 + str t0,rep3 +L325: + ldr t0,rep1 + str t0,rep2 +L330: + str rep0,rep1 + mov rep0,distance +L340: + mov t0,#8 + cmp state,#kNumLitStates + mov state,#11 + csel state,t0,state,lo + add prob, p,#RepLenCoder<<1 +L350: + add p_in,prob,#LenChoice<<1 + call rcGetBit_0; bne L360 + ldr t0,posState + add probLen,prob,#LenLow<<1 + uxtw t0x,t0 + mov t1,#0 + add probLen,probLen,t0x,lsl #1+ kLenNumLowBits + mov hibit,#1<=Range) Code-=Range; + adc rep0,rep0,rep0 // rep0 = (rep0<<1) + (Code>=Range) +L430: + subs numDirectBits,numDirectBits,#1; bne L420 + add prob,p, #Align<<1 + lsl rep0,rep0,#kNumAlignBits + mov numDirectBits,#kNumAlignBits +L438: + mov i,#1 + mov mi,#1 +L440: + mov p_in,prob; call rcGetBit_mi + tst mo,#1; beq L445 + orr rep0,rep0,i +L445: + lsl i,i,#1 + subs numDirectBits,numDirectBits,#1; bne L440 + b L465 +L450: +L460: + ldr rep0,posSlot +L465: + adds rep0,rep0,#1 +#if 0 /*{ only for the stream version */ + bne L470 + mov t0,#kLzmaStreamWasFinishedId + str t0,m_len + b L530 +L470: +#endif /*}*/ + ldr r_len,m_len +L500: + ldr t0x,outBuf + add r_len,r_len,#kMatchMinLen + sub t0x,outPtr,t0x // nowPos + cmp rep0,t0; bhi lzmaDataError + sxtw t0x,rep0 + neg t0x,t0x +L510: // const t0x= -rep0; + ldrb w0,[outPtr,t0x] + strb w0,[outPtr],#1 + cmp outPtr,outLim; bhs L530 + subs r_len,r_len,#1; bne L510 + // FIXME: prfm PLDL1KEEP,outPtr,#32 // fetch next cache line +L519: + strb w0,prevB // implicit &0xFF +L520: // bottom of while loop + cmp outPtr,outLim; blo L200 +L530: + call rcNormalize + mov w0,#0 // success +lzmaExit: + ldr t1x,inBuf + sub t0x,inPtr,t1x + ldr t1x,inSizeProcessed + str t0,[t1x] + + ldr t1x,outBuf + sub t0x,outPtr,t1x + ldr t1x,outSizeProcessed + str t0,[t1x] + + add sp,sp,#(14+1)*4 +// FIXME ldmia sp!,{r4,r5,r6,r7, r8,r9,r10,r11, pc} + +lzmaDataError: + mov w0,#1 // failure + b lzmaExit + + +rcNormalize: + lsr t0,Range,#kNumTopBits + cbnz t0,retNorm +rcLoad: + cmp inPtr,inLim + lsl Range,Range,#8 + bhs lzmaDataError +rcInit2: + ldrb t0,[inPtr],#1 + orr Code,t0,Code, lsl #8 +retNorm: + ret + +rcGetBit_state0: // rcGetBit(0, state + p_in) + mov mi,state +rcGetBit_mi0: // rcGetBit(0, mi + p_in) + add p_in,p_in,mi, uxtw #1 +rcGetBit_0: // rcGetBit(0, p_in) + mov mi,#0 +rcGetBit_mi: // rcGetBit(mi, mi + p_in) + add p_in,p_in,mi, uxtw #1 +rcGetBit: // Out: CC set on mo + lsr t0,Range,#kNumTopBits + mov t2x,x30 // save lr if need rcLoad + adr x30,rcGetBitCont; cbz t0,rcLoad // conditional subroutine call +rcGetBitCont: +#define starp t0 +#define bound t1 +#define y0tmp t1 + ldrh starp,[p_in] + lsr y0tmp,Range,#kNumBitModelTotalBits + mul bound,starp,y0tmp + cmp Code,bound; bhs rcGB1 +rcGB0: // Code < bound + mov y0tmp,#kBitModelTotal + mov Range,bound + sub y0tmp,y0tmp,starp + adcs mo,mi,mi // mo = (mi<<1) | (Code >= bound); set CC + add starp,starp,y0tmp, lsr #kNumMoveBits + strh starp,[p_in] + ret t2x +rcGB1: // Code >= bound + sub Code,Code,bound + sub Range,Range,bound + sub starp,starp,starp, lsr #kNumMoveBits + adcs mo,mi,mi // mo = (mi<<1) | (Code >= bound); set CC + strh starp,[p_in] + ret t2x +#undef y0tmp +#undef bound +#undef starp +#undef t1x +#undef t1 +#undef t0x +#undef t0 + +// vi:ts=8:et From 3e065ead650e47f1c6b79d7154c769869ef0c98b Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Tue, 13 Sep 2016 20:17:51 -0700 Subject: [PATCH 18/29] fix .bss in floating dyld changed src/stub/src/amd64-darwin.macho-upxmain.c --- src/stub/src/amd64-darwin.macho-upxmain.c | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/src/stub/src/amd64-darwin.macho-upxmain.c b/src/stub/src/amd64-darwin.macho-upxmain.c index 3b5ae8ec..43044a85 100644 --- a/src/stub/src/amd64-darwin.macho-upxmain.c +++ b/src/stub/src/amd64-darwin.macho-upxmain.c @@ -518,8 +518,8 @@ do_xmap( ) if (LC_SEGMENT_64==sc->cmd && sc->vmsize!=0) { Extent xo; size_t mlen = xo.size = sc->filesize; - unsigned char *addr = xo.buf = (unsigned char *)sc->vmaddr; - unsigned char *haddr = sc->vmsize + addr; + unsigned char *addr = xo.buf = base + (unsigned char *)sc->vmaddr; + unsigned char *haddr = sc->vmsize + addr; size_t frag = (int)(uint64_t)addr &~ PAGE_MASK; addr -= frag; mlen += frag; @@ -528,17 +528,17 @@ do_xmap( // Decompressor can overrun the destination by 3 bytes. [x86 only] size_t const mlen3 = mlen + (xi ? 3 : 0); unsigned const prot = VM_PROT_READ | VM_PROT_WRITE; - unsigned const flags = ((addr + base) ? MAP_FIXED : 0) | MAP_PRIVATE | + unsigned const flags = (addr ? MAP_FIXED : 0) | MAP_PRIVATE | ((xi || 0==sc->filesize) ? MAP_ANON : 0); int const fdm = ((0==sc->filesize) ? MAP_ANON_FD : fdi); off_t const offset = sc->fileoff + fat_offset; - DPRINTF((STR_mmap(), addr + base, mlen3, prot, flags, fdm, offset)); - unsigned char *mapa = mmap(addr + base, mlen3, prot, flags, fdm, offset); + DPRINTF((STR_mmap(), addr, mlen3, prot, flags, fdm, offset)); + unsigned char *mapa = mmap(addr, mlen3, prot, flags, fdm, offset); if (MAP_FAILED == mapa) { err_exit(8); } - if (0 == (addr + base)) { // dyld auto-relocate + if (0 == addr) { // dyld auto-relocate base = (unsigned long)mapa; // relocation constant } addr = mapa; @@ -703,6 +703,9 @@ typedef struct { int main(int argc, char *argv[]) { + // Entry via JMP + asm("movl 1*8(%%rbp),%0; leaq 2*8(%%rbp),%1" : "=r" (argc), "=r" (argv) : ); + Mach_header64 const *mhdr0 = (Mach_header64 const *)((~0ul<<16) & (unsigned long)&main); Mach_command const *ptr = (Mach_command const *)(1+ mhdr0); f_unfilter *f_unf; From af2fddfd6d58815c0cc1a430737f2d51059c1a23 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Tue, 13 Sep 2016 20:18:54 -0700 Subject: [PATCH 19/29] rebuild stub changed src/stub/amd64-darwin.macho-upxmain.h --- src/stub/amd64-darwin.macho-upxmain.h | 216 +++++++++++++------------- 1 file changed, 108 insertions(+), 108 deletions(-) diff --git a/src/stub/amd64-darwin.macho-upxmain.h b/src/stub/amd64-darwin.macho-upxmain.h index 77ba9596..446474ec 100644 --- a/src/stub/amd64-darwin.macho-upxmain.h +++ b/src/stub/amd64-darwin.macho-upxmain.h @@ -32,8 +32,8 @@ #define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_SIZE 5464 -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x0147312d -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0x6ca9614a +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x1cd43541 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0x366ed71b unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x0000 */ 207,250,237,254, 7, 0, 0, 1, 3, 0, 0,128, 2, 0, 0, 0, @@ -49,8 +49,8 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x00a0 */ 7, 0, 0, 0, 5, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, /* 0x00b0 */ 95, 95,116,101,120,116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00c0 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x00d0 */ 37, 9,255,255, 0, 0, 0, 0,123, 6, 0, 0, 0, 0, 0, 0, -/* 0x00e0 */ 37, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x00d0 */ 10, 9,255,255, 0, 0, 0, 0,150, 6, 0, 0, 0, 0, 0, 0, +/* 0x00e0 */ 10, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00f0 */ 0, 4, 0,128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0100 */ 95, 95,117,110,119,105,110,100, 95,105,110,102,111, 0, 0, 0, /* 0x0110 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -80,7 +80,7 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x0290 */ 100, 0, 0, 0, 0, 0, 0, 0, 36, 0, 0, 0, 16, 0, 0, 0, /* 0x02a0 */ 0, 11, 10, 0, 0, 11, 10, 0, 42, 0, 0, 0, 16, 0, 0, 0, /* 0x02b0 */ 0, 0, 0, 0, 0, 0, 0, 0, 40, 0, 0,128, 24, 0, 0, 0, -/* 0x02c0 */ 86, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x02c0 */ 81, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x02d0 */ 12, 0, 0, 0, 56, 0, 0, 0, 24, 0, 0, 0, 2, 0, 0, 0, /* 0x02e0 */ 1, 10,202, 4, 0, 0, 1, 0, 47,117,115,114, 47,108,105, 98, /* 0x02f0 */ 47,108,105, 98, 83,121,115,116,101,109, 46, 66, 46,100,121,108, @@ -180,101 +180,101 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x08d0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x08e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x08f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0900 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0910 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0920 */ 0, 0, 0, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, -/* 0x0930 */ 84, 83, 72,131,236, 72, 77,137,205, 76,137,195, 73,137,206, 73, -/* 0x0940 */ 137,212, 72,137,117,208, 72,141, 71, 24, 72,137, 69,200, 72,139, -/* 0x0950 */ 69,208, 72,131,192,232, 72,137, 69,192, 76,137,101,184,139, 71, -/* 0x0960 */ 24, 72,137, 69,176, 72,139, 69,192, 72,139, 77,200, 72,137, 77, -/* 0x0970 */ 168, 72,137, 69,160, 69, 49,255, 72,141,125,192, 72,141,117,176, -/* 0x0980 */ 49,201, 72,137,218,232, 27, 1, 0, 0, 76,137, 44, 36, 72,141, -/* 0x0990 */ 85,160,190, 0, 0, 0, 0,185,255,255,255,255, 76,137,231, 76, -/* 0x09a0 */ 139, 69, 16, 73,137,217,232, 16, 2, 0, 0, 72,137,195, 65,139, -/* 0x09b0 */ 76, 36, 16,133,201, 15,132,216, 0, 0, 0, 73,141, 68, 36, 32, -/* 0x09c0 */ 131, 56, 14,116, 19, 65,255,199,139, 80, 4, 72, 1,208, 65, 57, -/* 0x09d0 */ 207,114,237,233,187, 0, 0, 0,139,120, 8, 72, 1,199, 49,246, -/* 0x09e0 */ 49,210,232,155, 5, 0, 0, 65,137,199, 69,133,255,120,113, 77, -/* 0x09f0 */ 141,108, 36, 16, 49,219, 68,137,255, 76,137,230, 76,137,242, 72, -/* 0x0a00 */ 137,217,232,115, 5, 0, 0, 76, 57,240,117, 84, 65,139, 4, 36, -/* 0x0a10 */ 61,190,186,254,202,116, 7, 61,202,254,186,190,117, 76, 65, 15, -/* 0x0a20 */ 182, 68, 36, 7,141, 4,128,141, 52,133, 8, 0, 0, 0, 76,137, -/* 0x0a30 */ 231,232, 28, 5, 0, 0, 65,139, 68, 36, 4, 49,201,133,192, 76, -/* 0x0a40 */ 137,234,116, 28,129,122,248, 7, 0, 0, 1,116, 12,255,193, 72, -/* 0x0a50 */ 131,194, 20, 57,193,114,237,235, 7,139, 26, 72,133,219,117,150, -/* 0x0a60 */ 191,127, 0, 0, 0,232, 4, 5, 0, 0, 72,199, 4, 36, 0, 0, -/* 0x0a70 */ 0, 0, 49,210, 69, 49,192, 69, 49,201, 76,137,231, 72,137,222, -/* 0x0a80 */ 68,137,249,232, 51, 1, 0, 0, 72,137,195, 68,137,255,232,235, -/* 0x0a90 */ 4, 0, 0, 72,137,216, 72,131,196, 72, 91, 65, 92, 65, 93, 65, -/* 0x0aa0 */ 94, 65, 95, 93,195, 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, -/* 0x0ab0 */ 84, 83, 72,131,236, 56, 72,137, 77,176, 72,137, 85,168, 73,137, -/* 0x0ac0 */ 246, 72,137,125,184, 73,131, 62, 0, 15,132,211, 0, 0, 0, 76, -/* 0x0ad0 */ 141,101,200,186, 12, 0, 0, 0, 72,139,125,184, 76,137,230,232, -/* 0x0ae0 */ 36, 4, 0, 0, 68,139,109,200, 68,139,125,204, 77,133,237, 15, -/* 0x0af0 */ 132,154, 0, 0, 0, 65,141, 71,255, 68, 57,232, 15,131,175, 0, -/* 0x0b00 */ 0, 0, 77, 59, 46, 15,135,166, 0, 0, 0, 69, 57,239,115, 90, -/* 0x0b10 */ 68,137,109,196, 72,139, 69,184, 72,139,120, 8, 73,139, 86, 8, -/* 0x0b20 */ 139, 93,208, 68, 15,182,195, 68,137,254, 72,141, 77,196,255, 85, -/* 0x0b30 */ 168,133,192,117,124, 68, 57,109,196,117,118, 72,131,125,176, 0, -/* 0x0b40 */ 116, 27, 15,182,199,102,133,192,116, 19,193,235, 16, 15,183,200, -/* 0x0b50 */ 73,139,126, 8, 15,182,211, 68,137,238,255, 85,176, 72,139, 69, -/* 0x0b60 */ 184, 76, 1,120, 8, 76, 41, 56,235, 16, 73,139,118, 8, 72,139, -/* 0x0b70 */ 125,184, 76,137,250,232,142, 3, 0, 0, 77, 1,110, 8, 73,139, -/* 0x0b80 */ 6, 76, 41,232, 73,137, 6, 15,133, 70,255,255,255,235, 19, 65, -/* 0x0b90 */ 129,255, 85, 80, 88, 33,117, 25, 72,139, 69,184, 72,131, 56, 0, -/* 0x0ba0 */ 117, 15, 72,131,196, 56, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93, -/* 0x0bb0 */ 195,191,127, 0, 0, 0,232,179, 3, 0, 0, 85, 72,137,229, 65, -/* 0x0bc0 */ 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236,120, 76,137,141,112, -/* 0x0bd0 */ 255,255,255, 76,137,133,104,255,255,255,137, 77,140, 72,137, 85, -/* 0x0be0 */ 184, 72,137,117,128, 72,137,125,144,139, 95, 16, 69, 49,255,133, -/* 0x0bf0 */ 219,184, 0, 0, 0, 0, 15,132, 65, 2, 0, 0, 72,139, 77,144, -/* 0x0c00 */ 76,141,105, 32, 72,131,125,184, 0, 15,149,193, 15,182,201, 72, -/* 0x0c10 */ 141, 12, 73, 72,137,141,120,255,255,255, 72,191, 4, 0, 0, 0, -/* 0x0c20 */ 42, 0, 0, 0, 69, 49,192, 49,192, 49,201, 72,137, 77,192, 73, -/* 0x0c30 */ 139, 85, 0, 72,137,209, 72,193,233, 32,141,114,252,131,254, 2, -/* 0x0c40 */ 15,130,125, 1, 0, 0,129,250, 40, 0, 0,128, 15,132,132, 1, -/* 0x0c50 */ 0, 0,131,250, 25, 15,133,209, 1, 0, 0, 73,139, 85, 32, 72, -/* 0x0c60 */ 133,210, 15,132,196, 1, 0, 0, 72,137, 85,160, 76,137, 69,176, -/* 0x0c70 */ 72,137, 69,152, 73,139, 69, 48, 72,137, 69,200, 77,139,101, 24, -/* 0x0c80 */ 76,137,101,168, 76,137,101,208, 69,137,230, 65,129,230,255, 15, -/* 0x0c90 */ 0, 0, 77, 41,244, 73, 1,198,116,118, 72,139,141,120,255,255, -/* 0x0ca0 */ 255, 73,141, 52, 14, 76,137,231, 72,139, 77,192, 72, 1,207,186, -/* 0x0cb0 */ 2, 0, 0, 0,185, 18, 0, 0, 0, 15, 69,209, 72,133,192, 15, -/* 0x0cc0 */ 148,193, 15,182,201,193,225, 12, 72,131,125,184, 0,187, 0, 16, -/* 0x0cd0 */ 0, 0, 15, 69,203, 9,209, 72,131,248, 1, 69, 25,192, 68, 11, -/* 0x0ce0 */ 69,140, 77,139, 77, 40, 76, 3, 77,128,186, 3, 0, 0, 0,232, -/* 0x0cf0 */ 146, 2, 0, 0, 72,139, 77,192, 73, 1,204, 72, 15, 68,200, 72, -/* 0x0d00 */ 137, 77,192, 72,131,248,255, 73,137,196, 15,132, 60, 1, 0, 0, -/* 0x0d10 */ 72,131,125,184, 0,116, 52, 73,131,125, 48, 0,116, 45, 73,131, -/* 0x0d20 */ 125, 40, 0,117, 14, 72,139,133,104,255,255,255, 76,137, 32, 76, -/* 0x0d30 */ 137,109,176, 72,139,125,184, 72,141,117,200, 72,139,149,112,255, -/* 0x0d40 */ 255,255, 72,139, 77, 16,232, 90,253,255,255, 68,137,243,247,219, -/* 0x0d50 */ 72,129,227,255, 15, 0, 0,116, 12, 75,141, 60, 52, 72,137,222, -/* 0x0d60 */ 232,254, 1, 0, 0, 77,133,246,116, 23, 65,139, 85, 60, 76,137, -/* 0x0d70 */ 231, 76,137,246,232,249, 1, 0, 0,133,192, 15,133,203, 0, 0, -/* 0x0d80 */ 0, 72,139, 69,168, 72, 3, 69,160, 76, 1,243, 73, 1,220, 73, -/* 0x0d90 */ 57,196,115, 88, 77,133,228,116,118, 72,137,198, 76, 41,230, 65, -/* 0x0da0 */ 139, 85, 60,185, 18, 16, 0, 0, 65,184,255,255,255,255, 69, 49, -/* 0x0db0 */ 201, 76,137,231,232,205, 1, 0, 0, 73, 57,196,116, 81,233,137, -/* 0x0dc0 */ 0, 0, 0, 73, 57,125, 8,117, 99, 73,139,133,144, 0, 0, 0, -/* 0x0dd0 */ 72, 3, 69,192,235, 86, 73,139, 69, 8, 73, 57, 64, 40,119, 76, -/* 0x0de0 */ 73, 59, 64, 48,115, 70, 73, 3, 64, 24,235, 64, 72,131,125,184, -/* 0x0df0 */ 0,116, 28, 65,131,198, 3, 65,129,230,255, 15, 0, 0, 73,131, -/* 0x0e00 */ 254, 3,119, 11, 76,137,231, 76,137,246,232,103, 1, 0, 0, 65, -/* 0x0e10 */ 139, 77, 4, 72,139, 69,144,139, 88, 16, 72,191, 4, 0, 0, 0, -/* 0x0e20 */ 42, 0, 0, 0, 72,139, 69,152, 76,139, 69,176, 65,255,199,137, -/* 0x0e30 */ 201, 73, 1,205, 65, 57,223, 15,130,242,253,255,255, 72,131,196, -/* 0x0e40 */ 120, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195,191,127, 0, 0, -/* 0x0e50 */ 0,232, 24, 1, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 83, 72, -/* 0x0e60 */ 129,236, 24, 8, 0, 0, 73,137,247, 65,137,254, 72,141, 5,227, -/* 0x0e70 */ 255,255,255, 72, 37, 0, 0,255,255,139, 72, 16,133,201,116, 82, -/* 0x0e80 */ 72,131,200, 32, 49,210, 73,187, 85, 80, 88, 95, 68, 65, 84, 65, -/* 0x0e90 */ 73,186, 95, 95, 84, 69, 88, 84, 0, 0,131, 56, 25,117, 39, 72, -/* 0x0ea0 */ 139, 88, 8, 76, 57,219,116, 22, 76, 57,211,117, 25, 72,139, 88, -/* 0x0eb0 */ 104, 68, 15,183, 3, 73, 1,216, 76,141, 75, 2,235, 8, 72,139, -/* 0x0ec0 */ 120, 24, 72,139,112, 48,255,194,139, 88, 4, 72, 1,216, 57,202, -/* 0x0ed0 */ 114,200, 73,141, 71,240, 72,137, 4, 36, 72,141,149,224,247,255, -/* 0x0ee0 */ 255,185, 0, 8, 0, 0,232, 58,250,255,255, 73, 99,206, 73,137, +/* 0x0900 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 85, 72,137,229, 65, 87, +/* 0x0910 */ 65, 86, 65, 85, 65, 84, 83, 72,131,236, 72, 77,137,205, 76,137, +/* 0x0920 */ 195, 73,137,206, 73,137,212, 72,137,117,208, 72,141, 71, 24, 72, +/* 0x0930 */ 137, 69,200, 72,139, 69,208, 72,131,192,232, 72,137, 69,192, 76, +/* 0x0940 */ 137,101,184,139, 71, 24, 72,137, 69,176, 72,139, 69,192, 72,139, +/* 0x0950 */ 77,200, 72,137, 77,168, 72,137, 69,160, 69, 49,255, 72,141,125, +/* 0x0960 */ 192, 72,141,117,176, 49,201, 72,137,218,232, 27, 1, 0, 0, 76, +/* 0x0970 */ 137, 44, 36, 72,141, 85,160,190, 0, 0, 0, 0,185,255,255,255, +/* 0x0980 */ 255, 76,137,231, 76,139, 69, 16, 73,137,217,232, 16, 2, 0, 0, +/* 0x0990 */ 72,137,195, 65,139, 76, 36, 16,133,201, 15,132,216, 0, 0, 0, +/* 0x09a0 */ 73,141, 68, 36, 32,131, 56, 14,116, 19, 65,255,199,139, 80, 4, +/* 0x09b0 */ 72, 1,208, 65, 57,207,114,237,233,187, 0, 0, 0,139,120, 8, +/* 0x09c0 */ 72, 1,199, 49,246, 49,210,232,182, 5, 0, 0, 65,137,199, 69, +/* 0x09d0 */ 133,255,120,113, 77,141,108, 36, 16, 49,219, 68,137,255, 76,137, +/* 0x09e0 */ 230, 76,137,242, 72,137,217,232,142, 5, 0, 0, 76, 57,240,117, +/* 0x09f0 */ 84, 65,139, 4, 36, 61,190,186,254,202,116, 7, 61,202,254,186, +/* 0x0a00 */ 190,117, 76, 65, 15,182, 68, 36, 7,141, 4,128,141, 52,133, 8, +/* 0x0a10 */ 0, 0, 0, 76,137,231,232, 55, 5, 0, 0, 65,139, 68, 36, 4, +/* 0x0a20 */ 49,201,133,192, 76,137,234,116, 28,129,122,248, 7, 0, 0, 1, +/* 0x0a30 */ 116, 12,255,193, 72,131,194, 20, 57,193,114,237,235, 7,139, 26, +/* 0x0a40 */ 72,133,219,117,150,191,127, 0, 0, 0,232, 31, 5, 0, 0, 72, +/* 0x0a50 */ 199, 4, 36, 0, 0, 0, 0, 49,210, 69, 49,192, 69, 49,201, 76, +/* 0x0a60 */ 137,231, 72,137,222, 68,137,249,232, 51, 1, 0, 0, 72,137,195, +/* 0x0a70 */ 68,137,255,232, 6, 5, 0, 0, 72,137,216, 72,131,196, 72, 91, +/* 0x0a80 */ 65, 92, 65, 93, 65, 94, 65, 95, 93,195, 85, 72,137,229, 65, 87, +/* 0x0a90 */ 65, 86, 65, 85, 65, 84, 83, 72,131,236, 56, 72,137, 77,176, 72, +/* 0x0aa0 */ 137, 85,168, 73,137,246, 72,137,125,184, 73,131, 62, 0, 15,132, +/* 0x0ab0 */ 211, 0, 0, 0, 76,141,101,200,186, 12, 0, 0, 0, 72,139,125, +/* 0x0ac0 */ 184, 76,137,230,232, 63, 4, 0, 0, 68,139,109,200, 68,139,125, +/* 0x0ad0 */ 204, 77,133,237, 15,132,154, 0, 0, 0, 65,141, 71,255, 68, 57, +/* 0x0ae0 */ 232, 15,131,175, 0, 0, 0, 77, 59, 46, 15,135,166, 0, 0, 0, +/* 0x0af0 */ 69, 57,239,115, 90, 68,137,109,196, 72,139, 69,184, 72,139,120, +/* 0x0b00 */ 8, 73,139, 86, 8,139, 93,208, 68, 15,182,195, 68,137,254, 72, +/* 0x0b10 */ 141, 77,196,255, 85,168,133,192,117,124, 68, 57,109,196,117,118, +/* 0x0b20 */ 72,131,125,176, 0,116, 27, 15,182,199,102,133,192,116, 19,193, +/* 0x0b30 */ 235, 16, 15,183,200, 73,139,126, 8, 15,182,211, 68,137,238,255, +/* 0x0b40 */ 85,176, 72,139, 69,184, 76, 1,120, 8, 76, 41, 56,235, 16, 73, +/* 0x0b50 */ 139,118, 8, 72,139,125,184, 76,137,250,232,169, 3, 0, 0, 77, +/* 0x0b60 */ 1,110, 8, 73,139, 6, 76, 41,232, 73,137, 6, 15,133, 70,255, +/* 0x0b70 */ 255,255,235, 19, 65,129,255, 85, 80, 88, 33,117, 25, 72,139, 69, +/* 0x0b80 */ 184, 72,131, 56, 0,117, 15, 72,131,196, 56, 91, 65, 92, 65, 93, +/* 0x0b90 */ 65, 94, 65, 95, 93,195,191,127, 0, 0, 0,232,206, 3, 0, 0, +/* 0x0ba0 */ 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, +/* 0x0bb0 */ 120, 76,137,141,112,255,255,255, 76,137,133,104,255,255,255,137, +/* 0x0bc0 */ 77,140, 72,137, 85,192, 72,137,117,128, 72,137,125,144,139, 95, +/* 0x0bd0 */ 16, 69, 49,255,133,219,184, 0, 0, 0, 0, 15,132, 87, 2, 0, +/* 0x0be0 */ 0, 72,139, 77,144, 76,141,105, 32, 72,131,125,192, 0, 15,149, +/* 0x0bf0 */ 193, 15,182,201, 72,141, 12, 73, 72,137,141,120,255,255,255, 72, +/* 0x0c00 */ 191, 4, 0, 0, 0, 42, 0, 0, 0, 69, 49,201, 49,192, 69, 49, +/* 0x0c10 */ 192, 73,139, 85, 0, 72,137,209, 72,193,233, 32,141,114,252,131, +/* 0x0c20 */ 254, 2, 15,130,205, 0, 0, 0,129,250, 40, 0, 0,128, 15,132, +/* 0x0c30 */ 218, 0, 0, 0,131,250, 25, 15,133,234, 1, 0, 0, 73,139, 85, +/* 0x0c40 */ 32, 72,133,210, 15,132,221, 1, 0, 0, 72,137, 85,168, 76,137, +/* 0x0c50 */ 77,184, 72,137, 69,160, 73,139, 69, 48, 72,137, 69,200, 77,139, +/* 0x0c60 */ 101, 24, 77, 1,196, 76,137,101,176, 76,137,101,208, 69,137,230, +/* 0x0c70 */ 65,129,230,255, 15, 0, 0, 77, 41,244, 73, 1,198, 76,137,195, +/* 0x0c80 */ 15,132,169, 0, 0, 0, 72,139,141,120,255,255,255, 73,141, 52, +/* 0x0c90 */ 14, 77,133,228,186, 2, 0, 0, 0,185, 18, 0, 0, 0, 15, 69, +/* 0x0ca0 */ 209, 72,133,192, 15,148,193, 15,182,201,193,225, 12, 72,131,125, +/* 0x0cb0 */ 192, 0,191, 0, 16, 0, 0, 15, 69,207, 9,209, 72,131,248, 1, +/* 0x0cc0 */ 69, 25,192, 68, 11, 69,140, 77,139, 77, 40, 76, 3, 77,128,186, +/* 0x0cd0 */ 3, 0, 0, 0, 76,137,231,232,170, 2, 0, 0, 77,133,228, 72, +/* 0x0ce0 */ 15, 68,216, 72,137, 93,152, 72,131,248,255, 73,137,196,117, 67, +/* 0x0cf0 */ 233, 82, 1, 0, 0, 73, 57,125, 8, 15,133, 40, 1, 0, 0, 73, +/* 0x0d00 */ 139,133,144, 0, 0, 0, 76, 1,192,233, 25, 1, 0, 0, 73,139, +/* 0x0d10 */ 69, 8, 73, 57, 65, 40, 15,135, 11, 1, 0, 0, 73, 59, 65, 48, +/* 0x0d20 */ 15,131, 1, 1, 0, 0, 73, 3, 65, 24,233,248, 0, 0, 0, 72, +/* 0x0d30 */ 137, 93,152, 72,131,125,192, 0,116, 52, 73,131,125, 48, 0,116, +/* 0x0d40 */ 45, 73,131,125, 40, 0,117, 14, 72,139,133,104,255,255,255, 76, +/* 0x0d50 */ 137, 32, 76,137,109,184, 72,139,125,192, 72,141,117,200, 72,139, +/* 0x0d60 */ 149,112,255,255,255, 72,139, 77, 16,232, 28,253,255,255, 68,137, +/* 0x0d70 */ 243,247,219, 72,129,227,255, 15, 0, 0,116, 12, 75,141, 60, 52, +/* 0x0d80 */ 72,137,222,232,219, 1, 0, 0, 77,133,246,116, 23, 65,139, 85, +/* 0x0d90 */ 60, 76,137,231, 76,137,246,232,214, 1, 0, 0,133,192, 15,133, +/* 0x0da0 */ 163, 0, 0, 0, 72,139, 69,176, 72, 3, 69,168, 76, 1,243, 73, +/* 0x0db0 */ 1,220, 73, 57,196,115, 44, 77,133,228,116, 74, 72,137,198, 76, +/* 0x0dc0 */ 41,230, 65,139, 85, 60,185, 18, 16, 0, 0, 65,184,255,255,255, +/* 0x0dd0 */ 255, 69, 49,201, 76,137,231,232,170, 1, 0, 0, 73, 57,196,116, +/* 0x0de0 */ 37,235,100, 72,131,125,192, 0,116, 28, 65,131,198, 3, 65,129, +/* 0x0df0 */ 230,255, 15, 0, 0, 73,131,254, 3,119, 11, 76,137,231, 76,137, +/* 0x0e00 */ 246,232,112, 1, 0, 0, 65,139, 77, 4, 72,139, 69,144,139, 88, +/* 0x0e10 */ 16, 72,191, 4, 0, 0, 0, 42, 0, 0, 0, 72,139, 69,160, 76, +/* 0x0e20 */ 139, 69,152, 76,139, 77,184, 65,255,199,137,201, 73, 1,205, 65, +/* 0x0e30 */ 57,223, 15,130,217,253,255,255, 72,131,196,120, 91, 65, 92, 65, +/* 0x0e40 */ 93, 65, 94, 65, 95, 93,195,191,127, 0, 0, 0,232, 29, 1, 0, +/* 0x0e50 */ 0, 85, 72,137,229, 65, 87, 65, 86, 83, 72,129,236, 24, 8, 0, +/* 0x0e60 */ 0, 68,139,117, 8, 76,141,125, 16, 72,141, 5,225,255,255,255, +/* 0x0e70 */ 72, 37, 0, 0,255,255,139, 72, 16,133,201,116, 82, 72,131,200, +/* 0x0e80 */ 32, 49,210, 73,187, 85, 80, 88, 95, 68, 65, 84, 65, 73,186, 95, +/* 0x0e90 */ 95, 84, 69, 88, 84, 0, 0,131, 56, 25,117, 39, 72,139, 88, 8, +/* 0x0ea0 */ 76, 57,219,116, 22, 76, 57,211,117, 25, 72,139, 88,104, 68, 15, +/* 0x0eb0 */ 183, 3, 73, 1,216, 76,141, 75, 2,235, 8, 72,139,120, 24, 72, +/* 0x0ec0 */ 139,112, 48,255,194,139, 88, 4, 72, 1,216, 57,202,114,200, 76, +/* 0x0ed0 */ 137,248, 72,131,192,240, 72,137, 4, 36, 72,141,149,224,247,255, +/* 0x0ee0 */ 255,185, 0, 8, 0, 0,232, 31,250,255,255, 73, 99,206, 73,137, /* 0x0ef0 */ 79,248, 73,141,103,240,255,224, 49,192, 72,129,196, 24, 8, 0, /* 0x0f00 */ 0, 91, 65, 94, 65, 95, 93,195, 72,139, 15, 72, 57,209,114, 52, /* 0x0f10 */ 72,139, 71, 8, 72,133,210,116, 29, 72,137,209, 72,255,201, 68, @@ -287,10 +287,10 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x0f80 */ 235, 2,176, 5,235, 2,176,197,235, 2,176, 3, 15,182,192, 13, /* 0x0f90 */ 0, 0, 0, 2, 73,137,202, 15, 5,115, 4, 72,131,200,255,195, /* 0x0fa0 */ 1, 0, 0, 0, 28, 0, 0, 0, 0, 0, 0, 0, 28, 0, 0, 0, -/* 0x0fb0 */ 0, 0, 0, 0, 28, 0, 0, 0, 2, 0, 0, 0, 37, 9, 0, 0, +/* 0x0fb0 */ 0, 0, 0, 0, 28, 0, 0, 0, 2, 0, 0, 0, 10, 9, 0, 0, /* 0x0fc0 */ 52, 0, 0, 0, 52, 0, 0, 0,161, 15, 0, 0, 0, 0, 0, 0, /* 0x0fd0 */ 52, 0, 0, 0, 3, 0, 0, 0, 12, 0, 4, 0, 28, 0, 4, 0, -/* 0x0fe0 */ 0, 0, 0, 3, 49, 5, 0, 2,227, 5, 0, 1, 45, 6, 0, 0, +/* 0x0fe0 */ 0, 0, 0, 3, 71, 5, 0, 2,254, 5, 0, 1, 72, 6, 0, 0, /* 0x0ff0 */ 0, 0, 0, 0, 0, 0, 0, 1, 97, 1, 3, 1,209, 88, 5, 1, /* 0x1000 */ 0, 9, 95, 0, 58, 98, 0,233, 1,119,114,105,116,101, 0,151, /* 0x1010 */ 2,101,120,105,116, 0,161, 2,109, 0,171, 2,112,114,101, 97, @@ -302,10 +302,10 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x1070 */ 2,111,112,101,110, 0,232, 2,114,101, 97,100, 0,252, 2, 0, /* 0x1080 */ 3,109,104, 95,101,120,101, 99,117,116,101, 95,104,101, 97,100, /* 0x1090 */ 101,114, 0,166, 1, 95, 98,122,101,114,111, 0,254, 1, 98,122, -/* 0x10a0 */ 101,114,111, 0,131, 2, 2, 0, 0, 0, 3, 0,165, 18, 0, 0, +/* 0x10a0 */ 101,114,111, 0,131, 2, 2, 0, 0, 0, 3, 0,138, 18, 0, 0, /* 0x10b0 */ 4, 97,105,110, 0,207, 1,112,114,111,116,101, 99,116, 0,166, /* 0x10c0 */ 2,117,110,109, 97,112, 0,202, 2,109, 97,112, 0,242, 2, 3, -/* 0x10d0 */ 0,214, 28, 0, 0, 2,115,119, 97,112, 0,228, 1,122,101,114, +/* 0x10d0 */ 0,209, 28, 0, 0, 2,115,119, 97,112, 0,228, 1,122,101,114, /* 0x10e0 */ 111, 0,136, 2, 3, 0,210, 30, 0, 0, 2,115,119, 97,112, 0, /* 0x10f0 */ 249, 1,122,101,114,111, 0,141, 2, 3, 0,210, 30, 0, 3, 0, /* 0x1100 */ 227, 30, 0, 3, 0,227, 30, 0, 3, 0,227, 30, 0, 3, 0,227, @@ -317,8 +317,8 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x1160 */ 254, 30, 0, 3, 0,254, 30, 0, 3, 0,130, 31, 0, 3, 0,130, /* 0x1170 */ 31, 0, 3, 0,134, 31, 0, 3, 0,134, 31, 0, 3, 0,138, 31, /* 0x1180 */ 0, 3, 0,138, 31, 0, 0, 0, 2, 0, 0, 0, 14, 1, 0, 0, -/* 0x1190 */ 165, 10,255,255, 0, 0, 0, 0, 16, 0, 0, 0, 14, 1, 0, 0, -/* 0x11a0 */ 187, 11,255,255, 0, 0, 0, 0, 25, 0, 0, 0, 14, 1, 0, 0, +/* 0x1190 */ 138, 10,255,255, 0, 0, 0, 0, 16, 0, 0, 0, 14, 1, 0, 0, +/* 0x11a0 */ 160, 11,255,255, 0, 0, 0, 0, 25, 0, 0, 0, 14, 1, 0, 0, /* 0x11b0 */ 8, 15,255,255, 0, 0, 0, 0, 32, 0, 0, 0, 2, 0, 0, 0, /* 0x11c0 */ 1, 0, 0, 0, 0, 0, 0, 0, 41, 0, 0, 0, 2, 0, 0, 0, /* 0x11d0 */ 3, 0, 0, 0, 0, 0, 0, 0, 50, 0, 0, 0, 2, 0, 0, 0, @@ -336,14 +336,14 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x1290 */ 99, 15,255,255, 0, 0, 0, 0,173, 0, 0, 0, 15, 1, 0, 0, /* 0x12a0 */ 126, 15,255,255, 0, 0, 0, 0,180, 0, 0, 0, 15, 1, 0, 0, /* 0x12b0 */ 110, 15,255,255, 0, 0, 0, 0,186, 0, 0, 0, 15, 1, 0, 0, -/* 0x12c0 */ 86, 14,255,255, 0, 0, 0, 0,192, 0, 0, 0, 15, 1, 0, 0, +/* 0x12c0 */ 81, 14,255,255, 0, 0, 0, 0,192, 0, 0, 0, 15, 1, 0, 0, /* 0x12d0 */ 134, 15,255,255, 0, 0, 0, 0,198, 0, 0, 0, 15, 1, 0, 0, /* 0x12e0 */ 114, 15,255,255, 0, 0, 0, 0,208, 0, 0, 0, 15, 1, 0, 0, /* 0x12f0 */ 118, 15,255,255, 0, 0, 0, 0,216, 0, 0, 0, 15, 1, 0, 0, /* 0x1300 */ 130, 15,255,255, 0, 0, 0, 0,222, 0, 0, 0, 15, 1, 0, 0, /* 0x1310 */ 122, 15,255,255, 0, 0, 0, 0,229, 0, 0, 0, 15, 1, 0, 0, /* 0x1320 */ 138, 15,255,255, 0, 0, 0, 0,235, 0, 0, 0, 15, 1, 0, 0, -/* 0x1330 */ 37, 9,255,255, 0, 0, 0, 0,245, 0, 0, 0, 15, 1, 0, 0, +/* 0x1330 */ 10, 9,255,255, 0, 0, 0, 0,245, 0, 0, 0, 15, 1, 0, 0, /* 0x1340 */ 106, 15,255,255, 0, 0, 0, 0,252, 0, 0, 0, 15, 1, 0, 0, /* 0x1350 */ 82, 15,255,255, 0, 0, 0, 0, 2, 1, 0, 0, 15, 1, 0, 0, /* 0x1360 */ 99, 15,255,255, 0, 0, 0, 0, 8, 1, 0, 0, 15, 1, 0, 0, From 73d1b331f1ebe444e7519118035de9a331078e64 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Tue, 13 Sep 2016 20:20:41 -0700 Subject: [PATCH 20/29] trim Mach_command from stub. [Dirty, needs cleanup!] changed src/p_mach.cpp --- src/p_mach.cpp | 46 +++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 45 insertions(+), 1 deletion(-) diff --git a/src/p_mach.cpp b/src/p_mach.cpp index 2ecb8ecc..1c3d8b9e 100644 --- a/src/p_mach.cpp +++ b/src/p_mach.cpp @@ -765,6 +765,7 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader super::pack4(fo, ft); unsigned const t = fo->getBytesWritten(); + segTEXT.vmaddr = segZERO.vmaddr + segZERO.vmsize; segTEXT.filesize = t; segTEXT.vmsize += t; // utilize GAP + NO_LAP + sz_unc - sz_cpr secTEXT.offset = overlay_offset - sizeof(linfo); @@ -800,14 +801,16 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader unsigned cmdsize = mhdro.sizeofcmds - sizeof(segXHDR); Mach_header const *const ptr0 = (Mach_header const *)stub_amd64_darwin_macho_upxmain_exe; Mach_command const *ptr1 = (Mach_command const *)(1+ ptr0); + unsigned const ncmds = mhdro.ncmds; unsigned delta = 0; - for (unsigned j = 0; j < mhdro.ncmds -1; ++j, + for (unsigned j = 0; j < ncmds -1; ++j, (cmdsize -= ptr1->cmdsize), ptr1 = (Mach_command const *)(ptr1->cmdsize + (char const *)ptr1)) switch (ptr1->cmd) { case Mach_segment_command::LC_SEGMENT_64: { Mach_segment_command const *const segptr = (Mach_segment_command const *)ptr1; if (!strcmp("__TEXT", segptr->segname)) { + memcpy(&segTEXT, segptr, sizeof(segTEXT)); Mach_section_command const *const secptr = (Mach_section_command const *)(1+ segptr); memcpy(&secTEXT, secptr, sizeof(secTEXT)); secTEXT.align = 0; @@ -849,6 +852,8 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader if (blk.bind_off) blk.bind_off += delta; if (blk.lazy_bind_off) blk.lazy_bind_off += delta; if (blk.export_off) blk.export_off += delta; +blk.export_off = 0; +blk.export_size = 0; fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); fo->rewrite(&blk, sizeof(blk)); } break; @@ -867,6 +872,12 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader if (blk.indirectsymoff) blk.indirectsymoff += delta; if (blk.extreloff) blk.extreloff += delta; if (blk.locreloff) blk.locreloff += delta; +blk.ilocalsym = 0; +blk.nlocalsym = 0; +blk.iextdefsym = 0; +blk.nextdefsym = 0; +blk.iundefsym = 0; +blk.nundefsym = 0; fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); fo->rewrite(&blk, sizeof(blk)); } break; @@ -876,11 +887,44 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); fo->rewrite(&blk, sizeof(blk)); } break; + case Mach_segment_command::LC_MAIN: { + // TEMPORARY: change to LC_UNIX_THREAD; known to be continusous with last +// LC_MAIN requires libSystem.B.dylib to provide the environment for main(), and CALLs the entryoff. +// LC_UNIXTHREAD does not need libSystem.B.dylib, and JMPs to the .rip with %rsp/argc and argv= 8+%rsp + threado.cmd = Mach_segment_command::LC_UNIXTHREAD; + threado.cmdsize = sizeof(threado); + threado.flavor = my_thread_flavor; + threado.count = my_thread_state_word_count; + memset(&threado.state, 0, sizeof(threado.state)); + threado.state.rip = ((N_Mach::Mach_main_command const *)ptr1)->entryoff + segTEXT.vmaddr; + fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); + fo->rewrite(&threado, sizeof(threado)); + mhdro.sizeofcmds += sizeof(threado) - ((Mach_command const *)ptr1)->cmdsize; + fo->seek(0, SEEK_SET); + fo->rewrite(&mhdro, sizeof(mhdro)); + } break; + case Mach_segment_command::LC_LOAD_DYLIB: { + // Temporary test: remove this command; known to be contiguous with last + N_Mach::Mach_load_dylib_command blk; +memset(&blk, 0, sizeof(blk)); + fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); + fo->rewrite(&blk, sizeof(blk)); + mhdro.ncmds -= 1; + mhdro.sizeofcmds -= ((Mach_command const *)ptr1)->cmdsize; + fo->seek(0, SEEK_SET); + fo->rewrite(&mhdro, sizeof(mhdro)); + } break; case Mach_segment_command::LC_DATA_IN_CODE: { N_Mach::Mach_data_in_code_command blk; memcpy(&blk, ptr1, sizeof(blk)); if (blk.dataoff) blk.dataoff += delta; +memset(&blk, 0, sizeof(blk)); fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); fo->rewrite(&blk, sizeof(blk)); + // Temporary test: remove this command; known to be last + mhdro.ncmds -= 1; + mhdro.sizeofcmds -= ((Mach_command const *)ptr1)->cmdsize; + fo->seek(0, SEEK_SET); + fo->rewrite(&mhdro, sizeof(mhdro)); } break; } // end switch fo->seek(0, SEEK_END); From 4c253d68d436314d4e04a8050f5faf04e1178083 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Thu, 15 Sep 2016 21:38:39 -0700 Subject: [PATCH 21/29] new start address 0xfe000000 changed src/stub/amd64-darwin.macho-upxmain.h --- src/stub/amd64-darwin.macho-upxmain.h | 76 +++++++++++++-------------- 1 file changed, 38 insertions(+), 38 deletions(-) diff --git a/src/stub/amd64-darwin.macho-upxmain.h b/src/stub/amd64-darwin.macho-upxmain.h index 446474ec..83514dee 100644 --- a/src/stub/amd64-darwin.macho-upxmain.h +++ b/src/stub/amd64-darwin.macho-upxmain.h @@ -32,38 +32,38 @@ #define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_SIZE 5464 -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x1cd43541 -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0x366ed71b +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x01a91141 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0xc9501621 unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x0000 */ 207,250,237,254, 7, 0, 0, 1, 3, 0, 0,128, 2, 0, 0, 0, /* 0x0010 */ 13, 0, 0, 0,248, 2, 0, 0,133, 0, 0, 0, 0, 0, 0, 0, /* 0x0020 */ 25, 0, 0, 0, 72, 0, 0, 0, 95, 95, 80, 65, 71, 69, 90, 69, /* 0x0030 */ 82, 79, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0040 */ 0, 0,255,255, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0040 */ 0, 0, 0,254, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0050 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0060 */ 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0,232, 0, 0, 0, /* 0x0070 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0080 */ 0, 0,255,255, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, +/* 0x0080 */ 0, 0, 0,254, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, /* 0x0090 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, /* 0x00a0 */ 7, 0, 0, 0, 5, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, /* 0x00b0 */ 95, 95,116,101,120,116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00c0 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x00d0 */ 10, 9,255,255, 0, 0, 0, 0,150, 6, 0, 0, 0, 0, 0, 0, +/* 0x00d0 */ 10, 9, 0,254, 0, 0, 0, 0,150, 6, 0, 0, 0, 0, 0, 0, /* 0x00e0 */ 10, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00f0 */ 0, 4, 0,128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0100 */ 95, 95,117,110,119,105,110,100, 95,105,110,102,111, 0, 0, 0, /* 0x0110 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0120 */ 160, 15,255,255, 0, 0, 0, 0, 96, 0, 0, 0, 0, 0, 0, 0, +/* 0x0120 */ 160, 15, 0,254, 0, 0, 0, 0, 96, 0, 0, 0, 0, 0, 0, 0, /* 0x0130 */ 160, 15, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0140 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0150 */ 25, 0, 0, 0, 72, 0, 0, 0, 95, 95, 68, 65, 84, 65, 0, 0, -/* 0x0160 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16,255,255, 0, 0, 0, 0, +/* 0x0160 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0,254, 0, 0, 0, 0, /* 0x0170 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, /* 0x0180 */ 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 3, 0, 0, 0, /* 0x0190 */ 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0, 72, 0, 0, 0, /* 0x01a0 */ 95, 95, 76, 73, 78, 75, 69, 68, 73, 84, 0, 0, 0, 0, 0, 0, -/* 0x01b0 */ 0, 16,255,255, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, +/* 0x01b0 */ 0, 16, 0,254, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, /* 0x01c0 */ 0, 16, 0, 0, 0, 0, 0, 0, 88, 5, 0, 0, 0, 0, 0, 0, /* 0x01d0 */ 7, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x01e0 */ 34, 0, 0,128, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -317,9 +317,9 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x1160 */ 254, 30, 0, 3, 0,254, 30, 0, 3, 0,130, 31, 0, 3, 0,130, /* 0x1170 */ 31, 0, 3, 0,134, 31, 0, 3, 0,134, 31, 0, 3, 0,138, 31, /* 0x1180 */ 0, 3, 0,138, 31, 0, 0, 0, 2, 0, 0, 0, 14, 1, 0, 0, -/* 0x1190 */ 138, 10,255,255, 0, 0, 0, 0, 16, 0, 0, 0, 14, 1, 0, 0, -/* 0x11a0 */ 160, 11,255,255, 0, 0, 0, 0, 25, 0, 0, 0, 14, 1, 0, 0, -/* 0x11b0 */ 8, 15,255,255, 0, 0, 0, 0, 32, 0, 0, 0, 2, 0, 0, 0, +/* 0x1190 */ 138, 10, 0,254, 0, 0, 0, 0, 16, 0, 0, 0, 14, 1, 0, 0, +/* 0x11a0 */ 160, 11, 0,254, 0, 0, 0, 0, 25, 0, 0, 0, 14, 1, 0, 0, +/* 0x11b0 */ 8, 15, 0,254, 0, 0, 0, 0, 32, 0, 0, 0, 2, 0, 0, 0, /* 0x11c0 */ 1, 0, 0, 0, 0, 0, 0, 0, 41, 0, 0, 0, 2, 0, 0, 0, /* 0x11d0 */ 3, 0, 0, 0, 0, 0, 0, 0, 50, 0, 0, 0, 2, 0, 0, 0, /* 0x11e0 */ 4, 0, 0, 0, 0, 0, 0, 0, 60, 0, 0, 0, 2, 0, 0, 0, @@ -329,33 +329,33 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x1220 */ 74, 0, 0, 0, 0, 0, 0, 0,103, 0, 0, 0, 2, 0, 0, 0, /* 0x1230 */ 153, 0, 0, 0, 0, 0, 0, 0,113, 0, 0, 0, 2, 0, 0, 0, /* 0x1240 */ 197, 0, 0, 0, 0, 0, 0, 0,122, 0, 0, 0, 15, 1, 0, 0, -/* 0x1250 */ 99, 15,255,255, 0, 0, 0, 0,131, 0, 0, 0, 15, 1, 0, 0, -/* 0x1260 */ 99, 15,255,255, 0, 0, 0, 0,139, 0, 0, 0, 3, 1, 16, 0, -/* 0x1270 */ 0, 0,255,255, 0, 0, 0, 0,159, 0, 0, 0, 15, 1, 0, 0, -/* 0x1280 */ 82, 15,255,255, 0, 0, 0, 0,166, 0, 0, 0, 15, 1, 0, 0, -/* 0x1290 */ 99, 15,255,255, 0, 0, 0, 0,173, 0, 0, 0, 15, 1, 0, 0, -/* 0x12a0 */ 126, 15,255,255, 0, 0, 0, 0,180, 0, 0, 0, 15, 1, 0, 0, -/* 0x12b0 */ 110, 15,255,255, 0, 0, 0, 0,186, 0, 0, 0, 15, 1, 0, 0, -/* 0x12c0 */ 81, 14,255,255, 0, 0, 0, 0,192, 0, 0, 0, 15, 1, 0, 0, -/* 0x12d0 */ 134, 15,255,255, 0, 0, 0, 0,198, 0, 0, 0, 15, 1, 0, 0, -/* 0x12e0 */ 114, 15,255,255, 0, 0, 0, 0,208, 0, 0, 0, 15, 1, 0, 0, -/* 0x12f0 */ 118, 15,255,255, 0, 0, 0, 0,216, 0, 0, 0, 15, 1, 0, 0, -/* 0x1300 */ 130, 15,255,255, 0, 0, 0, 0,222, 0, 0, 0, 15, 1, 0, 0, -/* 0x1310 */ 122, 15,255,255, 0, 0, 0, 0,229, 0, 0, 0, 15, 1, 0, 0, -/* 0x1320 */ 138, 15,255,255, 0, 0, 0, 0,235, 0, 0, 0, 15, 1, 0, 0, -/* 0x1330 */ 10, 9,255,255, 0, 0, 0, 0,245, 0, 0, 0, 15, 1, 0, 0, -/* 0x1340 */ 106, 15,255,255, 0, 0, 0, 0,252, 0, 0, 0, 15, 1, 0, 0, -/* 0x1350 */ 82, 15,255,255, 0, 0, 0, 0, 2, 1, 0, 0, 15, 1, 0, 0, -/* 0x1360 */ 99, 15,255,255, 0, 0, 0, 0, 8, 1, 0, 0, 15, 1, 0, 0, -/* 0x1370 */ 126, 15,255,255, 0, 0, 0, 0, 14, 1, 0, 0, 15, 1, 0, 0, -/* 0x1380 */ 110, 15,255,255, 0, 0, 0, 0, 19, 1, 0, 0, 15, 1, 0, 0, -/* 0x1390 */ 134, 15,255,255, 0, 0, 0, 0, 24, 1, 0, 0, 15, 1, 0, 0, -/* 0x13a0 */ 114, 15,255,255, 0, 0, 0, 0, 33, 1, 0, 0, 15, 1, 0, 0, -/* 0x13b0 */ 118, 15,255,255, 0, 0, 0, 0, 40, 1, 0, 0, 15, 1, 0, 0, -/* 0x13c0 */ 130, 15,255,255, 0, 0, 0, 0, 45, 1, 0, 0, 15, 1, 0, 0, -/* 0x13d0 */ 122, 15,255,255, 0, 0, 0, 0, 51, 1, 0, 0, 15, 1, 0, 0, -/* 0x13e0 */ 138, 15,255,255, 0, 0, 0, 0, 56, 1, 0, 0, 15, 1, 0, 0, -/* 0x13f0 */ 106, 15,255,255, 0, 0, 0, 0, 62, 1, 0, 0, 1, 0, 0, 1, +/* 0x1250 */ 99, 15, 0,254, 0, 0, 0, 0,131, 0, 0, 0, 15, 1, 0, 0, +/* 0x1260 */ 99, 15, 0,254, 0, 0, 0, 0,139, 0, 0, 0, 3, 1, 16, 0, +/* 0x1270 */ 0, 0, 0,254, 0, 0, 0, 0,159, 0, 0, 0, 15, 1, 0, 0, +/* 0x1280 */ 82, 15, 0,254, 0, 0, 0, 0,166, 0, 0, 0, 15, 1, 0, 0, +/* 0x1290 */ 99, 15, 0,254, 0, 0, 0, 0,173, 0, 0, 0, 15, 1, 0, 0, +/* 0x12a0 */ 126, 15, 0,254, 0, 0, 0, 0,180, 0, 0, 0, 15, 1, 0, 0, +/* 0x12b0 */ 110, 15, 0,254, 0, 0, 0, 0,186, 0, 0, 0, 15, 1, 0, 0, +/* 0x12c0 */ 81, 14, 0,254, 0, 0, 0, 0,192, 0, 0, 0, 15, 1, 0, 0, +/* 0x12d0 */ 134, 15, 0,254, 0, 0, 0, 0,198, 0, 0, 0, 15, 1, 0, 0, +/* 0x12e0 */ 114, 15, 0,254, 0, 0, 0, 0,208, 0, 0, 0, 15, 1, 0, 0, +/* 0x12f0 */ 118, 15, 0,254, 0, 0, 0, 0,216, 0, 0, 0, 15, 1, 0, 0, +/* 0x1300 */ 130, 15, 0,254, 0, 0, 0, 0,222, 0, 0, 0, 15, 1, 0, 0, +/* 0x1310 */ 122, 15, 0,254, 0, 0, 0, 0,229, 0, 0, 0, 15, 1, 0, 0, +/* 0x1320 */ 138, 15, 0,254, 0, 0, 0, 0,235, 0, 0, 0, 15, 1, 0, 0, +/* 0x1330 */ 10, 9, 0,254, 0, 0, 0, 0,245, 0, 0, 0, 15, 1, 0, 0, +/* 0x1340 */ 106, 15, 0,254, 0, 0, 0, 0,252, 0, 0, 0, 15, 1, 0, 0, +/* 0x1350 */ 82, 15, 0,254, 0, 0, 0, 0, 2, 1, 0, 0, 15, 1, 0, 0, +/* 0x1360 */ 99, 15, 0,254, 0, 0, 0, 0, 8, 1, 0, 0, 15, 1, 0, 0, +/* 0x1370 */ 126, 15, 0,254, 0, 0, 0, 0, 14, 1, 0, 0, 15, 1, 0, 0, +/* 0x1380 */ 110, 15, 0,254, 0, 0, 0, 0, 19, 1, 0, 0, 15, 1, 0, 0, +/* 0x1390 */ 134, 15, 0,254, 0, 0, 0, 0, 24, 1, 0, 0, 15, 1, 0, 0, +/* 0x13a0 */ 114, 15, 0,254, 0, 0, 0, 0, 33, 1, 0, 0, 15, 1, 0, 0, +/* 0x13b0 */ 118, 15, 0,254, 0, 0, 0, 0, 40, 1, 0, 0, 15, 1, 0, 0, +/* 0x13c0 */ 130, 15, 0,254, 0, 0, 0, 0, 45, 1, 0, 0, 15, 1, 0, 0, +/* 0x13d0 */ 122, 15, 0,254, 0, 0, 0, 0, 51, 1, 0, 0, 15, 1, 0, 0, +/* 0x13e0 */ 138, 15, 0,254, 0, 0, 0, 0, 56, 1, 0, 0, 15, 1, 0, 0, +/* 0x13f0 */ 106, 15, 0,254, 0, 0, 0, 0, 62, 1, 0, 0, 1, 0, 0, 1, /* 0x1400 */ 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 95,117,110,112, 97, 99, /* 0x1410 */ 107, 69,120,116,101,110,116, 0, 95,100,111, 95,120,109, 97,112, /* 0x1420 */ 0, 95,120,114,101, 97,100, 0, 83, 89, 83, 95,101,120,105,116, From 8d0b3b7d44e16ad92e5e87d7b3befe5b079c688b Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Thu, 15 Sep 2016 21:44:17 -0700 Subject: [PATCH 22/29] Fix segXHDR, but assume no __DATA in stub for now. changed src/p_mach.cpp --- src/p_mach.cpp | 32 ++++++++++++++------------------ 1 file changed, 14 insertions(+), 18 deletions(-) diff --git a/src/p_mach.cpp b/src/p_mach.cpp index 1c3d8b9e..7a592796 100644 --- a/src/p_mach.cpp +++ b/src/p_mach.cpp @@ -764,10 +764,10 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader } super::pack4(fo, ft); - unsigned const t = fo->getBytesWritten(); + unsigned const eofcmpr = fo->getBytesWritten(); segTEXT.vmaddr = segZERO.vmaddr + segZERO.vmsize; - segTEXT.filesize = t; - segTEXT.vmsize += t; // utilize GAP + NO_LAP + sz_unc - sz_cpr + segTEXT.filesize = eofcmpr; + segTEXT.vmsize += eofcmpr; // utilize GAP + NO_LAP + sz_unc - sz_cpr secTEXT.offset = overlay_offset - sizeof(linfo); secTEXT.addr = segTEXT.vmaddr + secTEXT.offset; secTEXT.size = segTEXT.filesize - secTEXT.offset; @@ -813,6 +813,8 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader memcpy(&segTEXT, segptr, sizeof(segTEXT)); Mach_section_command const *const secptr = (Mach_section_command const *)(1+ segptr); memcpy(&secTEXT, secptr, sizeof(secTEXT)); + // Put f_unf and f_exp before compiled C code: + // steal space from -Wl,-headerpadsize secTEXT.align = 0; unsigned const d = getLoaderSize(); secTEXT.addr -= d; @@ -835,13 +837,17 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader // Mach_segment_command for new segXHDR segXHDR.cmdsize = sizeof(segXHDR); // no need for sections - segLINK.vmaddr = segXHDR.vmsize; - segXHDR.vmsize -= segXHDR.vmaddr; // reserve for decompressed program + segXHDR.vmaddr = segTEXT.vmsize + segTEXT.vmaddr; // XXX FIXME + segXHDR.vmsize = offLINK - segTEXT.vmsize; + segXHDR.fileoff = segTEXT.filesize + segTEXT.fileoff; // XXX FIXME: assumes no __DATA in stub + segXHDR.filesize = offLINK - segTEXT.filesize; // XXX FIXME: assumes no __DATA in stub; + segXHDR.maxprot = Mach_segment_command::VM_PROT_READ; segXHDR.nsects = 0; fo->seek((char const *)ptr1 - (char const *)ptr0, SEEK_SET); fo->rewrite(&segXHDR, sizeof(segXHDR)); // Update the __LINKEDIT header + segLINK.vmaddr = segXHDR.vmsize + segXHDR.vmaddr; segLINK.fileoff = offLINK; fo->rewrite(&segLINK, sizeof(segLINK)); } @@ -1468,10 +1474,6 @@ int PackMachBase::pack2(OutputFile *fo, Filter &ft) // append compressed bo for (k = 0; k < n_segment; ++k) { if (lc_seg==msegcmd[k].cmd && 0!=msegcmd[k].filesize ) { - uint64_t const hi_va = msegcmd[k].vmaddr + msegcmd[k].vmsize; - if (segXHDR.vmsize < hi_va) { - segXHDR.vmsize = hi_va; - } uip->ui_total_passes++; if (my_filetype==Mach_header::MH_DYLIB) { break; @@ -1690,8 +1692,6 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e unsigned cmdsize = mhdro.sizeofcmds - sizeof(segXHDR); Mach_header const *const ptr0 = (Mach_header const *)stub_amd64_darwin_macho_upxmain_exe; Mach_command const *ptr1 = (Mach_command const *)(1+ ptr0); - uint64_t next_va = 0; - uint64_t next_fpos = 0; for (unsigned j = 0; j < mhdro.ncmds -1; ++j, (cmdsize -= ptr1->cmdsize), ptr1 = (Mach_command const *)(ptr1->cmdsize + (char const *)ptr1)) { @@ -1702,11 +1702,9 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e fo->write((1+ ptr0), (char const *)ptr1 - (char const *)(1+ ptr0)); // LC_SEGMENT_64 for UPX_DATA; steal space from -Wl,-headerpadsize segXHDR.cmdsize = sizeof(segXHDR); - segXHDR.vmaddr = next_va; - segXHDR.fileoff = PAGE_MASK & (~PAGE_MASK + next_fpos); - segXHDR.maxprot = Mach_segment_command::VM_PROT_READ - | Mach_segment_command::VM_PROT_WRITE - | Mach_segment_command::VM_PROT_EXECUTE; + segXHDR.vmaddr = 0; + segXHDR.fileoff = 0; + segXHDR.maxprot = Mach_segment_command::VM_PROT_READ; segXHDR.initprot = Mach_segment_command::VM_PROT_READ; segXHDR.nsects = 0; fo->write(&segXHDR, sizeof(segXHDR)); @@ -1717,8 +1715,6 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e fo->write(&stub_amd64_darwin_macho_upxmain_exe[pos], segptr->fileoff - pos); break; } - next_va = segptr->vmsize + segptr->vmaddr; - next_fpos = segptr->filesize + segptr->fileoff; } } } From 90caf19e9e19bb9d4928141bda85ef4241bd33f5 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Fri, 16 Sep 2016 21:29:37 -0700 Subject: [PATCH 23/29] Cleanup amd64-darwin.macho-upxmain.c changed src/stub/amd64-darwin.macho-upxmain.h changed src/stub/src/amd64-darwin.macho-upxmain.c changed src/stub/src/amd64-darwin.macho-upxsubr.S --- src/stub/amd64-darwin.macho-upxmain.h | 413 ++++++++++------------ src/stub/src/amd64-darwin.macho-upxmain.c | 32 +- src/stub/src/amd64-darwin.macho-upxsubr.S | 35 +- 3 files changed, 246 insertions(+), 234 deletions(-) diff --git a/src/stub/amd64-darwin.macho-upxmain.h b/src/stub/amd64-darwin.macho-upxmain.h index 83514dee..edbed26b 100644 --- a/src/stub/amd64-darwin.macho-upxmain.h +++ b/src/stub/amd64-darwin.macho-upxmain.h @@ -1,5 +1,5 @@ /* amd64-darwin.macho-upxmain.h - created from amd64-darwin.macho-upxmain.exe, 5464 (0x1558) bytes + created from amd64-darwin.macho-upxmain.exe, 5032 (0x13a8) bytes This file is part of the UPX executable compressor. @@ -31,48 +31,48 @@ */ -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_SIZE 5464 -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x01a91141 -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0xc9501621 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_SIZE 5032 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0xb823c21c +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0x8e69c33a -unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { +unsigned char stub_amd64_darwin_macho_upxmain_exe[5032] = { /* 0x0000 */ 207,250,237,254, 7, 0, 0, 1, 3, 0, 0,128, 2, 0, 0, 0, /* 0x0010 */ 13, 0, 0, 0,248, 2, 0, 0,133, 0, 0, 0, 0, 0, 0, 0, /* 0x0020 */ 25, 0, 0, 0, 72, 0, 0, 0, 95, 95, 80, 65, 71, 69, 90, 69, /* 0x0030 */ 82, 79, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0040 */ 0, 0, 0,254, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0040 */ 0, 0, 0,240, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0050 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0060 */ 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0,232, 0, 0, 0, /* 0x0070 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0080 */ 0, 0, 0,254, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, +/* 0x0080 */ 0, 0, 0,240, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, /* 0x0090 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, /* 0x00a0 */ 7, 0, 0, 0, 5, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, /* 0x00b0 */ 95, 95,116,101,120,116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00c0 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x00d0 */ 10, 9, 0,254, 0, 0, 0, 0,150, 6, 0, 0, 0, 0, 0, 0, -/* 0x00e0 */ 10, 9, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x00d0 */ 244, 8, 0,240, 0, 0, 0, 0,180, 6, 0, 0, 0, 0, 0, 0, +/* 0x00e0 */ 244, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00f0 */ 0, 4, 0,128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0100 */ 95, 95,117,110,119,105,110,100, 95,105,110,102,111, 0, 0, 0, /* 0x0110 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0120 */ 160, 15, 0,254, 0, 0, 0, 0, 96, 0, 0, 0, 0, 0, 0, 0, -/* 0x0130 */ 160, 15, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0120 */ 168, 15, 0,240, 0, 0, 0, 0, 88, 0, 0, 0, 0, 0, 0, 0, +/* 0x0130 */ 168, 15, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0140 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0150 */ 25, 0, 0, 0, 72, 0, 0, 0, 95, 95, 68, 65, 84, 65, 0, 0, -/* 0x0160 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0,254, 0, 0, 0, 0, +/* 0x0160 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0,240, 0, 0, 0, 0, /* 0x0170 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, /* 0x0180 */ 0, 0, 0, 0, 0, 0, 0, 0, 7, 0, 0, 0, 3, 0, 0, 0, /* 0x0190 */ 0, 0, 0, 0, 0, 0, 0, 0, 25, 0, 0, 0, 72, 0, 0, 0, /* 0x01a0 */ 95, 95, 76, 73, 78, 75, 69, 68, 73, 84, 0, 0, 0, 0, 0, 0, -/* 0x01b0 */ 0, 16, 0,254, 0, 0, 0, 0, 0, 16, 0, 0, 0, 0, 0, 0, -/* 0x01c0 */ 0, 16, 0, 0, 0, 0, 0, 0, 88, 5, 0, 0, 0, 0, 0, 0, +/* 0x01b0 */ 0, 16, 0,240, 0, 0, 0, 0, 0, 16, 0, 0, 0,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char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x0290 */ 100, 0, 0, 0, 0, 0, 0, 0, 36, 0, 0, 0, 16, 0, 0, 0, /* 0x02a0 */ 0, 11, 10, 0, 0, 11, 10, 0, 42, 0, 0, 0, 16, 0, 0, 0, /* 0x02b0 */ 0, 0, 0, 0, 0, 0, 0, 0, 40, 0, 0,128, 24, 0, 0, 0, -/* 0x02c0 */ 81, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x02c0 */ 59, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x02d0 */ 12, 0, 0, 0, 56, 0, 0, 0, 24, 0, 0, 0, 2, 0, 0, 0, /* 0x02e0 */ 1, 10,202, 4, 0, 0, 1, 0, 47,117,115,114, 47,108,105, 98, /* 0x02f0 */ 47,108,105, 98, 83,121,115,116,101,109, 46, 66, 46,100,121,108, /* 0x0300 */ 105, 98, 0, 0, 0, 0, 0, 0, 41, 0, 0, 0, 16, 0, 0, 0, -/* 0x0310 */ 136, 17, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x0310 */ 224, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0320 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0330 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0340 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -179,203 +179,176 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5464] = { /* 0x08c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x08d0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x08e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x08f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x0900 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 85, 72,137,229, 65, 87, -/* 0x0910 */ 65, 86, 65, 85, 65, 84, 83, 72,131,236, 72, 77,137,205, 76,137, -/* 0x0920 */ 195, 73,137,206, 73,137,212, 72,137,117,208, 72,141, 71, 24, 72, -/* 0x0930 */ 137, 69,200, 72,139, 69,208, 72,131,192,232, 72,137, 69,192, 76, -/* 0x0940 */ 137,101,184,139, 71, 24, 72,137, 69,176, 72,139, 69,192, 72,139, -/* 0x0950 */ 77,200, 72,137, 77,168, 72,137, 69,160, 69, 49,255, 72,141,125, -/* 0x0960 */ 192, 72,141,117,176, 49,201, 72,137,218,232, 27, 1, 0, 0, 76, -/* 0x0970 */ 137, 44, 36, 72,141, 85,160,190, 0, 0, 0, 0,185,255,255,255, -/* 0x0980 */ 255, 76,137,231, 76,139, 69, 16, 73,137,217,232, 16, 2, 0, 0, -/* 0x0990 */ 72,137,195, 65,139, 76, 36, 16,133,201, 15,132,216, 0, 0, 0, -/* 0x09a0 */ 73,141, 68, 36, 32,131, 56, 14,116, 19, 65,255,199,139, 80, 4, -/* 0x09b0 */ 72, 1,208, 65, 57,207,114,237,233,187, 0, 0, 0,139,120, 8, -/* 0x09c0 */ 72, 1,199, 49,246, 49,210,232,182, 5, 0, 0, 65,137,199, 69, -/* 0x09d0 */ 133,255,120,113, 77,141,108, 36, 16, 49,219, 68,137,255, 76,137, -/* 0x09e0 */ 230, 76,137,242, 72,137,217,232,142, 5, 0, 0, 76, 57,240,117, -/* 0x09f0 */ 84, 65,139, 4, 36, 61,190,186,254,202,116, 7, 61,202,254,186, -/* 0x0a00 */ 190,117, 76, 65, 15,182, 68, 36, 7,141, 4,128,141, 52,133, 8, -/* 0x0a10 */ 0, 0, 0, 76,137,231,232, 55, 5, 0, 0, 65,139, 68, 36, 4, -/* 0x0a20 */ 49,201,133,192, 76,137,234,116, 28,129,122,248, 7, 0, 0, 1, -/* 0x0a30 */ 116, 12,255,193, 72,131,194, 20, 57,193,114,237,235, 7,139, 26, -/* 0x0a40 */ 72,133,219,117,150,191,127, 0, 0, 0,232, 31, 5, 0, 0, 72, -/* 0x0a50 */ 199, 4, 36, 0, 0, 0, 0, 49,210, 69, 49,192, 69, 49,201, 76, -/* 0x0a60 */ 137,231, 72,137,222, 68,137,249,232, 51, 1, 0, 0, 72,137,195, -/* 0x0a70 */ 68,137,255,232, 6, 5, 0, 0, 72,137,216, 72,131,196, 72, 91, -/* 0x0a80 */ 65, 92, 65, 93, 65, 94, 65, 95, 93,195, 85, 72,137,229, 65, 87, -/* 0x0a90 */ 65, 86, 65, 85, 65, 84, 83, 72,131,236, 56, 72,137, 77,176, 72, -/* 0x0aa0 */ 137, 85,168, 73,137,246, 72,137,125,184, 73,131, 62, 0, 15,132, -/* 0x0ab0 */ 211, 0, 0, 0, 76,141,101,200,186, 12, 0, 0, 0, 72,139,125, -/* 0x0ac0 */ 184, 76,137,230,232, 63, 4, 0, 0, 68,139,109,200, 68,139,125, -/* 0x0ad0 */ 204, 77,133,237, 15,132,154, 0, 0, 0, 65,141, 71,255, 68, 57, -/* 0x0ae0 */ 232, 15,131,175, 0, 0, 0, 77, 59, 46, 15,135,166, 0, 0, 0, -/* 0x0af0 */ 69, 57,239,115, 90, 68,137,109,196, 72,139, 69,184, 72,139,120, -/* 0x0b00 */ 8, 73,139, 86, 8,139, 93,208, 68, 15,182,195, 68,137,254, 72, -/* 0x0b10 */ 141, 77,196,255, 85,168,133,192,117,124, 68, 57,109,196,117,118, -/* 0x0b20 */ 72,131,125,176, 0,116, 27, 15,182,199,102,133,192,116, 19,193, -/* 0x0b30 */ 235, 16, 15,183,200, 73,139,126, 8, 15,182,211, 68,137,238,255, -/* 0x0b40 */ 85,176, 72,139, 69,184, 76, 1,120, 8, 76, 41, 56,235, 16, 73, -/* 0x0b50 */ 139,118, 8, 72,139,125,184, 76,137,250,232,169, 3, 0, 0, 77, -/* 0x0b60 */ 1,110, 8, 73,139, 6, 76, 41,232, 73,137, 6, 15,133, 70,255, -/* 0x0b70 */ 255,255,235, 19, 65,129,255, 85, 80, 88, 33,117, 25, 72,139, 69, -/* 0x0b80 */ 184, 72,131, 56, 0,117, 15, 72,131,196, 56, 91, 65, 92, 65, 93, -/* 0x0b90 */ 65, 94, 65, 95, 93,195,191,127, 0, 0, 0,232,206, 3, 0, 0, -/* 0x0ba0 */ 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, -/* 0x0bb0 */ 120, 76,137,141,112,255,255,255, 76,137,133,104,255,255,255,137, -/* 0x0bc0 */ 77,140, 72,137, 85,192, 72,137,117,128, 72,137,125,144,139, 95, -/* 0x0bd0 */ 16, 69, 49,255,133,219,184, 0, 0, 0, 0, 15,132, 87, 2, 0, -/* 0x0be0 */ 0, 72,139, 77,144, 76,141,105, 32, 72,131,125,192, 0, 15,149, -/* 0x0bf0 */ 193, 15,182,201, 72,141, 12, 73, 72,137,141,120,255,255,255, 72, -/* 0x0c00 */ 191, 4, 0, 0, 0, 42, 0, 0, 0, 69, 49,201, 49,192, 69, 49, -/* 0x0c10 */ 192, 73,139, 85, 0, 72,137,209, 72,193,233, 32,141,114,252,131, -/* 0x0c20 */ 254, 2, 15,130,205, 0, 0, 0,129,250, 40, 0, 0,128, 15,132, -/* 0x0c30 */ 218, 0, 0, 0,131,250, 25, 15,133,234, 1, 0, 0, 73,139, 85, -/* 0x0c40 */ 32, 72,133,210, 15,132,221, 1, 0, 0, 72,137, 85,168, 76,137, -/* 0x0c50 */ 77,184, 72,137, 69,160, 73,139, 69, 48, 72,137, 69,200, 77,139, -/* 0x0c60 */ 101, 24, 77, 1,196, 76,137,101,176, 76,137,101,208, 69,137,230, -/* 0x0c70 */ 65,129,230,255, 15, 0, 0, 77, 41,244, 73, 1,198, 76,137,195, -/* 0x0c80 */ 15,132,169, 0, 0, 0, 72,139,141,120,255,255,255, 73,141, 52, -/* 0x0c90 */ 14, 77,133,228,186, 2, 0, 0, 0,185, 18, 0, 0, 0, 15, 69, -/* 0x0ca0 */ 209, 72,133,192, 15,148,193, 15,182,201,193,225, 12, 72,131,125, -/* 0x0cb0 */ 192, 0,191, 0, 16, 0, 0, 15, 69,207, 9,209, 72,131,248, 1, -/* 0x0cc0 */ 69, 25,192, 68, 11, 69,140, 77,139, 77, 40, 76, 3, 77,128,186, -/* 0x0cd0 */ 3, 0, 0, 0, 76,137,231,232,170, 2, 0, 0, 77,133,228, 72, -/* 0x0ce0 */ 15, 68,216, 72,137, 93,152, 72,131,248,255, 73,137,196,117, 67, -/* 0x0cf0 */ 233, 82, 1, 0, 0, 73, 57,125, 8, 15,133, 40, 1, 0, 0, 73, -/* 0x0d00 */ 139,133,144, 0, 0, 0, 76, 1,192,233, 25, 1, 0, 0, 73,139, -/* 0x0d10 */ 69, 8, 73, 57, 65, 40, 15,135, 11, 1, 0, 0, 73, 59, 65, 48, -/* 0x0d20 */ 15,131, 1, 1, 0, 0, 73, 3, 65, 24,233,248, 0, 0, 0, 72, -/* 0x0d30 */ 137, 93,152, 72,131,125,192, 0,116, 52, 73,131,125, 48, 0,116, -/* 0x0d40 */ 45, 73,131,125, 40, 0,117, 14, 72,139,133,104,255,255,255, 76, -/* 0x0d50 */ 137, 32, 76,137,109,184, 72,139,125,192, 72,141,117,200, 72,139, -/* 0x0d60 */ 149,112,255,255,255, 72,139, 77, 16,232, 28,253,255,255, 68,137, -/* 0x0d70 */ 243,247,219, 72,129,227,255, 15, 0, 0,116, 12, 75,141, 60, 52, -/* 0x0d80 */ 72,137,222,232,219, 1, 0, 0, 77,133,246,116, 23, 65,139, 85, -/* 0x0d90 */ 60, 76,137,231, 76,137,246,232,214, 1, 0, 0,133,192, 15,133, -/* 0x0da0 */ 163, 0, 0, 0, 72,139, 69,176, 72, 3, 69,168, 76, 1,243, 73, -/* 0x0db0 */ 1,220, 73, 57,196,115, 44, 77,133,228,116, 74, 72,137,198, 76, -/* 0x0dc0 */ 41,230, 65,139, 85, 60,185, 18, 16, 0, 0, 65,184,255,255,255, -/* 0x0dd0 */ 255, 69, 49,201, 76,137,231,232,170, 1, 0, 0, 73, 57,196,116, -/* 0x0de0 */ 37,235,100, 72,131,125,192, 0,116, 28, 65,131,198, 3, 65,129, -/* 0x0df0 */ 230,255, 15, 0, 0, 73,131,254, 3,119, 11, 76,137,231, 76,137, -/* 0x0e00 */ 246,232,112, 1, 0, 0, 65,139, 77, 4, 72,139, 69,144,139, 88, -/* 0x0e10 */ 16, 72,191, 4, 0, 0, 0, 42, 0, 0, 0, 72,139, 69,160, 76, -/* 0x0e20 */ 139, 69,152, 76,139, 77,184, 65,255,199,137,201, 73, 1,205, 65, -/* 0x0e30 */ 57,223, 15,130,217,253,255,255, 72,131,196,120, 91, 65, 92, 65, -/* 0x0e40 */ 93, 65, 94, 65, 95, 93,195,191,127, 0, 0, 0,232, 29, 1, 0, -/* 0x0e50 */ 0, 85, 72,137,229, 65, 87, 65, 86, 83, 72,129,236, 24, 8, 0, -/* 0x0e60 */ 0, 68,139,117, 8, 76,141,125, 16, 72,141, 5,225,255,255,255, -/* 0x0e70 */ 72, 37, 0, 0,255,255,139, 72, 16,133,201,116, 82, 72,131,200, -/* 0x0e80 */ 32, 49,210, 73,187, 85, 80, 88, 95, 68, 65, 84, 65, 73,186, 95, -/* 0x0e90 */ 95, 84, 69, 88, 84, 0, 0,131, 56, 25,117, 39, 72,139, 88, 8, -/* 0x0ea0 */ 76, 57,219,116, 22, 76, 57,211,117, 25, 72,139, 88,104, 68, 15, -/* 0x0eb0 */ 183, 3, 73, 1,216, 76,141, 75, 2,235, 8, 72,139,120, 24, 72, -/* 0x0ec0 */ 139,112, 48,255,194,139, 88, 4, 72, 1,216, 57,202,114,200, 76, -/* 0x0ed0 */ 137,248, 72,131,192,240, 72,137, 4, 36, 72,141,149,224,247,255, -/* 0x0ee0 */ 255,185, 0, 8, 0, 0,232, 31,250,255,255, 73, 99,206, 73,137, -/* 0x0ef0 */ 79,248, 73,141,103,240,255,224, 49,192, 72,129,196, 24, 8, 0, -/* 0x0f00 */ 0, 91, 65, 94, 65, 95, 93,195, 72,139, 15, 72, 57,209,114, 52, -/* 0x0f10 */ 72,139, 71, 8, 72,133,210,116, 29, 72,137,209, 72,255,201, 68, -/* 0x0f20 */ 138, 0, 72,141, 64, 1, 68,136, 6, 72,141,118, 1,117,237, 72, -/* 0x0f30 */ 139, 15, 72,139, 71, 8, 72, 1,208, 72,137, 71, 8, 72, 41,209, -/* 0x0f40 */ 72,137, 15,195, 85, 72,137,229,191,127, 0, 0, 0,232, 28, 0, -/* 0x0f50 */ 0, 0,139, 7, 15,200,137, 7, 72,131,238, 4, 72,141,127, 4, -/* 0x0f60 */ 119,240,195, 49,192,137,241,243,170,195,176, 4,235, 2,176, 1, -/* 0x0f70 */ 235, 2,176, 74,235, 2,176, 73,235, 2,176,153,235, 2,176, 6, -/* 0x0f80 */ 235, 2,176, 5,235, 2,176,197,235, 2,176, 3, 15,182,192, 13, -/* 0x0f90 */ 0, 0, 0, 2, 73,137,202, 15, 5,115, 4, 72,131,200,255,195, -/* 0x0fa0 */ 1, 0, 0, 0, 28, 0, 0, 0, 0, 0, 0, 0, 28, 0, 0, 0, -/* 0x0fb0 */ 0, 0, 0, 0, 28, 0, 0, 0, 2, 0, 0, 0, 10, 9, 0, 0, -/* 0x0fc0 */ 52, 0, 0, 0, 52, 0, 0, 0,161, 15, 0, 0, 0, 0, 0, 0, -/* 0x0fd0 */ 52, 0, 0, 0, 3, 0, 0, 0, 12, 0, 4, 0, 28, 0, 4, 0, -/* 0x0fe0 */ 0, 0, 0, 3, 71, 5, 0, 2,254, 5, 0, 1, 72, 6, 0, 0, -/* 0x0ff0 */ 0, 0, 0, 0, 0, 0, 0, 1, 97, 1, 3, 1,209, 88, 5, 1, -/* 0x1000 */ 0, 9, 95, 0, 58, 98, 0,233, 1,119,114,105,116,101, 0,151, -/* 0x1010 */ 2,101,120,105,116, 0,161, 2,109, 0,171, 2,112,114,101, 97, -/* 0x1020 */ 100, 0,217, 2, 99,108,111,115,101, 0,227, 2,111,112,101,110, -/* 0x1030 */ 0,237, 2,114,101, 97,100, 0,129, 3, 0, 10, 95, 0,127,117, -/* 0x1040 */ 112,120, 95,109, 97,105,110, 0,170, 1,109, 0,175, 1, 98, 0, -/* 0x1050 */ 212, 1,119,114,105,116,101, 0,146, 2,101,120,105,116, 0,156, -/* 0x1060 */ 2,112,114,101, 97,100, 0,212, 2, 99,108,111,115,101, 0,222, -/* 0x1070 */ 2,111,112,101,110, 0,232, 2,114,101, 97,100, 0,252, 2, 0, -/* 0x1080 */ 3,109,104, 95,101,120,101, 99,117,116,101, 95,104,101, 97,100, -/* 0x1090 */ 101,114, 0,166, 1, 95, 98,122,101,114,111, 0,254, 1, 98,122, -/* 0x10a0 */ 101,114,111, 0,131, 2, 2, 0, 0, 0, 3, 0,138, 18, 0, 0, -/* 0x10b0 */ 4, 97,105,110, 0,207, 1,112,114,111,116,101, 99,116, 0,166, -/* 0x10c0 */ 2,117,110,109, 97,112, 0,202, 2,109, 97,112, 0,242, 2, 3, -/* 0x10d0 */ 0,209, 28, 0, 0, 2,115,119, 97,112, 0,228, 1,122,101,114, -/* 0x10e0 */ 111, 0,136, 2, 3, 0,210, 30, 0, 0, 2,115,119, 97,112, 0, -/* 0x10f0 */ 249, 1,122,101,114,111, 0,141, 2, 3, 0,210, 30, 0, 3, 0, -/* 0x1100 */ 227, 30, 0, 3, 0,227, 30, 0, 3, 0,227, 30, 0, 3, 0,227, -/* 0x1110 */ 30, 0, 3, 0,234, 30, 0, 3, 0,234, 30, 0, 3, 0,238, 30, -/* 0x1120 */ 0, 3, 0,238, 30, 0, 3, 0,242, 30, 0, 0, 3,112,114,111, -/* 0x1130 */ 116,101, 99,116, 0,197, 2,117,110,109, 97,112, 0,207, 2,109, -/* 0x1140 */ 97,112, 0,247, 2, 3, 0,242, 30, 0, 3, 0,246, 30, 0, 3, -/* 0x1150 */ 0,246, 30, 0, 3, 0,250, 30, 0, 3, 0,250, 30, 0, 3, 0, -/* 0x1160 */ 254, 30, 0, 3, 0,254, 30, 0, 3, 0,130, 31, 0, 3, 0,130, -/* 0x1170 */ 31, 0, 3, 0,134, 31, 0, 3, 0,134, 31, 0, 3, 0,138, 31, -/* 0x1180 */ 0, 3, 0,138, 31, 0, 0, 0, 2, 0, 0, 0, 14, 1, 0, 0, -/* 0x1190 */ 138, 10, 0,254, 0, 0, 0, 0, 16, 0, 0, 0, 14, 1, 0, 0, -/* 0x11a0 */ 160, 11, 0,254, 0, 0, 0, 0, 25, 0, 0, 0, 14, 1, 0, 0, -/* 0x11b0 */ 8, 15, 0,254, 0, 0, 0, 0, 32, 0, 0, 0, 2, 0, 0, 0, -/* 0x11c0 */ 1, 0, 0, 0, 0, 0, 0, 0, 41, 0, 0, 0, 2, 0, 0, 0, -/* 0x11d0 */ 3, 0, 0, 0, 0, 0, 0, 0, 50, 0, 0, 0, 2, 0, 0, 0, -/* 0x11e0 */ 4, 0, 0, 0, 0, 0, 0, 0, 60, 0, 0, 0, 2, 0, 0, 0, -/* 0x11f0 */ 5, 0, 0, 0, 0, 0, 0, 0, 69, 0, 0, 0, 2, 0, 0, 0, -/* 0x1200 */ 6, 0, 0, 0, 0, 0, 0, 0, 79, 0, 0, 0, 2, 0, 0, 0, -/* 0x1210 */ 73, 0, 0, 0, 0, 0, 0, 0, 90, 0, 0, 0, 2, 0, 0, 0, -/* 0x1220 */ 74, 0, 0, 0, 0, 0, 0, 0,103, 0, 0, 0, 2, 0, 0, 0, -/* 0x1230 */ 153, 0, 0, 0, 0, 0, 0, 0,113, 0, 0, 0, 2, 0, 0, 0, -/* 0x1240 */ 197, 0, 0, 0, 0, 0, 0, 0,122, 0, 0, 0, 15, 1, 0, 0, -/* 0x1250 */ 99, 15, 0,254, 0, 0, 0, 0,131, 0, 0, 0, 15, 1, 0, 0, -/* 0x1260 */ 99, 15, 0,254, 0, 0, 0, 0,139, 0, 0, 0, 3, 1, 16, 0, -/* 0x1270 */ 0, 0, 0,254, 0, 0, 0, 0,159, 0, 0, 0, 15, 1, 0, 0, -/* 0x1280 */ 82, 15, 0,254, 0, 0, 0, 0,166, 0, 0, 0, 15, 1, 0, 0, -/* 0x1290 */ 99, 15, 0,254, 0, 0, 0, 0,173, 0, 0, 0, 15, 1, 0, 0, -/* 0x12a0 */ 126, 15, 0,254, 0, 0, 0, 0,180, 0, 0, 0, 15, 1, 0, 0, -/* 0x12b0 */ 110, 15, 0,254, 0, 0, 0, 0,186, 0, 0, 0, 15, 1, 0, 0, -/* 0x12c0 */ 81, 14, 0,254, 0, 0, 0, 0,192, 0, 0, 0, 15, 1, 0, 0, -/* 0x12d0 */ 134, 15, 0,254, 0, 0, 0, 0,198, 0, 0, 0, 15, 1, 0, 0, -/* 0x12e0 */ 114, 15, 0,254, 0, 0, 0, 0,208, 0, 0, 0, 15, 1, 0, 0, -/* 0x12f0 */ 118, 15, 0,254, 0, 0, 0, 0,216, 0, 0, 0, 15, 1, 0, 0, -/* 0x1300 */ 130, 15, 0,254, 0, 0, 0, 0,222, 0, 0, 0, 15, 1, 0, 0, -/* 0x1310 */ 122, 15, 0,254, 0, 0, 0, 0,229, 0, 0, 0, 15, 1, 0, 0, -/* 0x1320 */ 138, 15, 0,254, 0, 0, 0, 0,235, 0, 0, 0, 15, 1, 0, 0, -/* 0x1330 */ 10, 9, 0,254, 0, 0, 0, 0,245, 0, 0, 0, 15, 1, 0, 0, -/* 0x1340 */ 106, 15, 0,254, 0, 0, 0, 0,252, 0, 0, 0, 15, 1, 0, 0, -/* 0x1350 */ 82, 15, 0,254, 0, 0, 0, 0, 2, 1, 0, 0, 15, 1, 0, 0, -/* 0x1360 */ 99, 15, 0,254, 0, 0, 0, 0, 8, 1, 0, 0, 15, 1, 0, 0, -/* 0x1370 */ 126, 15, 0,254, 0, 0, 0, 0, 14, 1, 0, 0, 15, 1, 0, 0, -/* 0x1380 */ 110, 15, 0,254, 0, 0, 0, 0, 19, 1, 0, 0, 15, 1, 0, 0, -/* 0x1390 */ 134, 15, 0,254, 0, 0, 0, 0, 24, 1, 0, 0, 15, 1, 0, 0, -/* 0x13a0 */ 114, 15, 0,254, 0, 0, 0, 0, 33, 1, 0, 0, 15, 1, 0, 0, -/* 0x13b0 */ 118, 15, 0,254, 0, 0, 0, 0, 40, 1, 0, 0, 15, 1, 0, 0, -/* 0x13c0 */ 130, 15, 0,254, 0, 0, 0, 0, 45, 1, 0, 0, 15, 1, 0, 0, -/* 0x13d0 */ 122, 15, 0,254, 0, 0, 0, 0, 51, 1, 0, 0, 15, 1, 0, 0, -/* 0x13e0 */ 138, 15, 0,254, 0, 0, 0, 0, 56, 1, 0, 0, 15, 1, 0, 0, -/* 0x13f0 */ 106, 15, 0,254, 0, 0, 0, 0, 62, 1, 0, 0, 1, 0, 0, 1, -/* 0x1400 */ 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 95,117,110,112, 97, 99, -/* 0x1410 */ 107, 69,120,116,101,110,116, 0, 95,100,111, 95,120,109, 97,112, -/* 0x1420 */ 0, 95,120,114,101, 97,100, 0, 83, 89, 83, 95,101,120,105,116, -/* 0x1430 */ 0, 83, 89, 83, 95,114,101, 97,100, 0, 83, 89, 83, 95,119,114, -/* 0x1440 */ 105,116,101, 0, 83, 89, 83, 95,111,112,101,110, 0, 83, 89, 83, -/* 0x1450 */ 95, 99,108,111,115,101, 0, 83, 89, 83, 95,109,117,110,109, 97, -/* 0x1460 */ 112, 0, 83, 89, 83, 95,109,112,114,111,116,101, 99,116, 0, 83, -/* 0x1470 */ 89, 83, 95,112,114,101, 97,100, 0, 83, 89, 83, 95,109,109, 97, -/* 0x1480 */ 112, 0, 95, 95, 95, 98,122,101,114,111, 0, 95, 95, 98,122,101, -/* 0x1490 */ 114,111, 0, 95, 95,109,104, 95,101,120,101, 99,117,116,101, 95, -/* 0x14a0 */ 104,101, 97,100,101,114, 0, 95, 98,115,119, 97,112, 0, 95, 98, -/* 0x14b0 */ 122,101,114,111, 0, 95, 99,108,111,115,101, 0, 95,101,120,105, -/* 0x14c0 */ 116, 0, 95,109, 97,105,110, 0, 95,109,109, 97,112, 0, 95,109, -/* 0x14d0 */ 112,114,111,116,101, 99,116, 0, 95,109,117,110,109, 97,112, 0, -/* 0x14e0 */ 95,111,112,101,110, 0, 95,112,114,101, 97,100, 0, 95,114,101, -/* 0x14f0 */ 97,100, 0, 95,117,112,120, 95,109, 97,105,110, 0, 95,119,114, -/* 0x1500 */ 105,116,101, 0, 98,115,119, 97,112, 0, 98,122,101,114,111, 0, -/* 0x1510 */ 99,108,111,115,101, 0,101,120,105,116, 0,109,109, 97,112, 0, -/* 0x1520 */ 109,112,114,111,116,101, 99,116, 0,109,117,110,109, 97,112, 0, -/* 0x1530 */ 111,112,101,110, 0,112,114,101, 97,100, 0,114,101, 97,100, 0, -/* 0x1540 */ 119,114,105,116,101, 0,100,121,108,100, 95,115,116,117, 98, 95, -/* 0x1550 */ 98,105,110,100,101,114, 0, 0 +/* 0x08f0 */ 0, 0, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, +/* 0x0900 */ 83, 72,131,236, 72, 77,137,205, 76,137,195, 73,137,206, 73,137, +/* 0x0910 */ 212, 72,137,117,208, 72,141, 71, 24, 72,137, 69,200, 72,139, 69, +/* 0x0920 */ 208, 72,131,192,232, 72,137, 69,192, 76,137,101,184,139, 71, 24, +/* 0x0930 */ 72,137, 69,176, 72,139, 69,192, 72,139, 77,200, 72,137, 77,168, +/* 0x0940 */ 72,137, 69,160, 69, 49,255, 72,141,125,192, 72,141,117,176, 49, +/* 0x0950 */ 201, 72,137,218,232, 27, 1, 0, 0, 76,137, 44, 36, 72,141, 85, +/* 0x0960 */ 160,190, 0, 0, 0, 0,185,255,255,255,255, 76,137,231, 76,139, +/* 0x0970 */ 69, 16, 73,137,217,232, 16, 2, 0, 0, 72,137,195, 65,139, 76, +/* 0x0980 */ 36, 16,133,201, 15,132,216, 0, 0, 0, 73,141, 68, 36, 32,131, +/* 0x0990 */ 56, 14,116, 19, 65,255,199,139, 80, 4, 72, 1,208, 65, 57,207, +/* 0x09a0 */ 114,237,233,187, 0, 0, 0,139,120, 8, 72, 1,199, 49,246, 49, +/* 0x09b0 */ 210,232,212, 5, 0, 0, 65,137,199, 69,133,255,120,113, 77,141, +/* 0x09c0 */ 108, 36, 16, 49,219, 68,137,255, 76,137,230, 76,137,242, 72,137, +/* 0x09d0 */ 217,232,172, 5, 0, 0, 76, 57,240,117, 84, 65,139, 4, 36, 61, +/* 0x09e0 */ 190,186,254,202,116, 7, 61,202,254,186,190,117, 76, 65, 15,182, +/* 0x09f0 */ 68, 36, 7,141, 4,128,141, 52,133, 8, 0, 0, 0, 76,137,231, +/* 0x0a00 */ 232, 85, 5, 0, 0, 65,139, 68, 36, 4, 49,201,133,192, 76,137, +/* 0x0a10 */ 234,116, 28,129,122,248, 7, 0, 0, 1,116, 12,255,193, 72,131, +/* 0x0a20 */ 194, 20, 57,193,114,237,235, 7,139, 26, 72,133,219,117,150,191, +/* 0x0a30 */ 127, 0, 0, 0,232, 61, 5, 0, 0, 72,199, 4, 36, 0, 0, 0, +/* 0x0a40 */ 0, 49,210, 69, 49,192, 69, 49,201, 76,137,231, 72,137,222, 68, +/* 0x0a50 */ 137,249,232, 51, 1, 0, 0, 72,137,195, 68,137,255,232, 36, 5, +/* 0x0a60 */ 0, 0, 72,137,216, 72,131,196, 72, 91, 65, 92, 65, 93, 65, 94, +/* 0x0a70 */ 65, 95, 93,195, 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, +/* 0x0a80 */ 83, 72,131,236, 56, 72,137, 77,176, 72,137, 85,168, 73,137,246, +/* 0x0a90 */ 72,137,125,184, 73,131, 62, 0, 15,132,211, 0, 0, 0, 76,141, +/* 0x0aa0 */ 101,200,186, 12, 0, 0, 0, 72,139,125,184, 76,137,230,232, 93, +/* 0x0ab0 */ 4, 0, 0, 68,139,109,200, 68,139,125,204, 77,133,237, 15,132, +/* 0x0ac0 */ 154, 0, 0, 0, 65,141, 71,255, 68, 57,232, 15,131,175, 0, 0, +/* 0x0ad0 */ 0, 77, 59, 46, 15,135,166, 0, 0, 0, 69, 57,239,115, 90, 68, +/* 0x0ae0 */ 137,109,196, 72,139, 69,184, 72,139,120, 8, 73,139, 86, 8,139, +/* 0x0af0 */ 93,208, 68, 15,182,195, 68,137,254, 72,141, 77,196,255, 85,168, +/* 0x0b00 */ 133,192,117,124, 68, 57,109,196,117,118, 72,131,125,176, 0,116, +/* 0x0b10 */ 27, 15,182,199,102,133,192,116, 19,193,235, 16, 15,183,200, 73, +/* 0x0b20 */ 139,126, 8, 15,182,211, 68,137,238,255, 85,176, 72,139, 69,184, +/* 0x0b30 */ 76, 1,120, 8, 76, 41, 56,235, 16, 73,139,118, 8, 72,139,125, +/* 0x0b40 */ 184, 76,137,250,232,199, 3, 0, 0, 77, 1,110, 8, 73,139, 6, +/* 0x0b50 */ 76, 41,232, 73,137, 6, 15,133, 70,255,255,255,235, 19, 65,129, +/* 0x0b60 */ 255, 85, 80, 88, 33,117, 25, 72,139, 69,184, 72,131, 56, 0,117, +/* 0x0b70 */ 15, 72,131,196, 56, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195, +/* 0x0b80 */ 191,127, 0, 0, 0,232,236, 3, 0, 0, 85, 72,137,229, 65, 87, +/* 0x0b90 */ 65, 86, 65, 85, 65, 84, 83, 72,131,236,120, 76,137,141,112,255, +/* 0x0ba0 */ 255,255, 76,137,133,104,255,255,255,137, 77,140, 72,137, 85,192, +/* 0x0bb0 */ 72,137,117,128, 72,137,125,144,139, 95, 16, 69, 49,255,133,219, +/* 0x0bc0 */ 184, 0, 0, 0, 0, 15,132, 87, 2, 0, 0, 72,139, 77,144, 76, +/* 0x0bd0 */ 141,105, 32, 72,131,125,192, 0, 15,149,193, 15,182,201, 72,141, +/* 0x0be0 */ 12, 73, 72,137,141,120,255,255,255, 72,191, 4, 0, 0, 0, 42, +/* 0x0bf0 */ 0, 0, 0, 69, 49,201, 49,192, 69, 49,192, 73,139, 85, 0, 72, +/* 0x0c00 */ 137,209, 72,193,233, 32,141,114,252,131,254, 2, 15,130,205, 0, +/* 0x0c10 */ 0, 0,129,250, 40, 0, 0,128, 15,132,218, 0, 0, 0,131,250, +/* 0x0c20 */ 25, 15,133,234, 1, 0, 0, 73,139, 85, 32, 72,133,210, 15,132, +/* 0x0c30 */ 221, 1, 0, 0, 72,137, 85,168, 76,137, 77,184, 72,137, 69,160, +/* 0x0c40 */ 73,139, 69, 48, 72,137, 69,200, 77,139,101, 24, 77, 1,196, 76, +/* 0x0c50 */ 137,101,176, 76,137,101,208, 69,137,230, 65,129,230,255, 15, 0, +/* 0x0c60 */ 0, 77, 41,244, 73, 1,198, 76,137,195, 15,132,169, 0, 0, 0, +/* 0x0c70 */ 72,139,141,120,255,255,255, 73,141, 52, 14, 77,133,228,186, 2, +/* 0x0c80 */ 0, 0, 0,185, 18, 0, 0, 0, 15, 69,209, 72,133,192, 15,148, +/* 0x0c90 */ 193, 15,182,201,193,225, 12, 72,131,125,192, 0,191, 0, 16, 0, +/* 0x0ca0 */ 0, 15, 69,207, 9,209, 72,131,248, 1, 69, 25,192, 68, 11, 69, +/* 0x0cb0 */ 140, 77,139, 77, 40, 76, 3, 77,128,186, 3, 0, 0, 0, 76,137, +/* 0x0cc0 */ 231,232,200, 2, 0, 0, 77,133,228, 72, 15, 68,216, 72,137, 93, +/* 0x0cd0 */ 152, 72,131,248,255, 73,137,196,117, 67,233, 82, 1, 0, 0, 73, +/* 0x0ce0 */ 57,125, 8, 15,133, 40, 1, 0, 0, 73,139,133,144, 0, 0, 0, +/* 0x0cf0 */ 76, 1,192,233, 25, 1, 0, 0, 73,139, 69, 8, 73, 57, 65, 40, +/* 0x0d00 */ 15,135, 11, 1, 0, 0, 73, 59, 65, 48, 15,131, 1, 1, 0, 0, +/* 0x0d10 */ 73, 3, 65, 24,233,248, 0, 0, 0, 72,137, 93,152, 72,131,125, +/* 0x0d20 */ 192, 0,116, 52, 73,131,125, 48, 0,116, 45, 73,131,125, 40, 0, +/* 0x0d30 */ 117, 14, 72,139,133,104,255,255,255, 76,137, 32, 76,137,109,184, +/* 0x0d40 */ 72,139,125,192, 72,141,117,200, 72,139,149,112,255,255,255, 72, +/* 0x0d50 */ 139, 77, 16,232, 28,253,255,255, 68,137,243,247,219, 72,129,227, +/* 0x0d60 */ 255, 15, 0, 0,116, 12, 75,141, 60, 52, 72,137,222,232,249, 1, +/* 0x0d70 */ 0, 0, 77,133,246,116, 23, 65,139, 85, 60, 76,137,231, 76,137, +/* 0x0d80 */ 246,232,244, 1, 0, 0,133,192, 15,133,163, 0, 0, 0, 72,139, +/* 0x0d90 */ 69,176, 72, 3, 69,168, 76, 1,243, 73, 1,220, 73, 57,196,115, +/* 0x0da0 */ 44, 77,133,228,116, 74, 72,137,198, 76, 41,230, 65,139, 85, 60, +/* 0x0db0 */ 185, 18, 16, 0, 0, 65,184,255,255,255,255, 69, 49,201, 76,137, +/* 0x0dc0 */ 231,232,200, 1, 0, 0, 73, 57,196,116, 37,235,100, 72,131,125, +/* 0x0dd0 */ 192, 0,116, 28, 65,131,198, 3, 65,129,230,255, 15, 0, 0, 73, +/* 0x0de0 */ 131,254, 3,119, 11, 76,137,231, 76,137,246,232,142, 1, 0, 0, +/* 0x0df0 */ 65,139, 77, 4, 72,139, 69,144,139, 88, 16, 72,191, 4, 0, 0, +/* 0x0e00 */ 0, 42, 0, 0, 0, 72,139, 69,160, 76,139, 69,152, 76,139, 77, +/* 0x0e10 */ 184, 65,255,199,137,201, 73, 1,205, 65, 57,223, 15,130,217,253, +/* 0x0e20 */ 255,255, 72,131,196,120, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93, +/* 0x0e30 */ 195,191,127, 0, 0, 0,232, 59, 1, 0, 0, 85, 72,137,229, 65, +/* 0x0e40 */ 87, 65, 86, 65, 85, 65, 84, 83, 72,129,236, 24, 8, 0, 0, 68, +/* 0x0e50 */ 139,109, 8, 76,141,101, 16, 72,141, 5,221,255,255,255, 72, 37, +/* 0x0e60 */ 0, 0,255,255,139, 72, 16,133,201,116, 82, 72,131,200, 32, 49, +/* 0x0e70 */ 210, 72,190, 85, 80, 88, 95, 68, 65, 84, 65, 72,191, 95, 95, 84, +/* 0x0e80 */ 69, 88, 84, 0, 0,131, 56, 25,117, 39, 72,139, 88, 8, 72, 57, +/* 0x0e90 */ 243,116, 22, 72, 57,251,117, 25, 72,139, 88,104, 68, 15,183, 3, +/* 0x0ea0 */ 73, 1,216, 76,141, 75, 2,235, 8, 76,139,120, 24, 76,139,112, +/* 0x0eb0 */ 48,255,194,139, 88, 4, 72, 1,216, 57,202,114,200, 76,137,224, +/* 0x0ec0 */ 72,131,192,240, 72,137, 4, 36, 72,141,149,208,247,255,255,185, +/* 0x0ed0 */ 0, 8, 0, 0, 76,137,255, 76,137,246,232, 21,250,255,255, 72, +/* 0x0ee0 */ 137,195, 76,137,255, 76,137,246,232,145, 0, 0, 0, 73, 99,197, +/* 0x0ef0 */ 73,137, 68, 36,248, 73,141,100, 36,240,255,227, 49,192, 72,129, +/* 0x0f00 */ 196, 24, 8, 0, 0, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195, +/* 0x0f10 */ 72,139, 15, 72, 57,209,114, 52, 72,139, 71, 8, 72,133,210,116, +/* 0x0f20 */ 29, 72,137,209, 72,255,201, 68,138, 0, 72,141, 64, 1, 68,136, +/* 0x0f30 */ 6, 72,141,118, 1,117,237, 72,139, 15, 72,139, 71, 8, 72, 1, +/* 0x0f40 */ 208, 72,137, 71, 8, 72, 41,209, 72,137, 15,195, 85, 72,137,229, +/* 0x0f50 */ 191,127, 0, 0, 0,232, 28, 0, 0, 0,139, 7, 15,200,137, 7, +/* 0x0f60 */ 72,131,238, 4, 72,141,127, 4,119,240,195, 49,192,137,241,243, +/* 0x0f70 */ 170,195,176, 4,235, 2,176, 1,235, 2,176, 74,235, 2,176, 73, +/* 0x0f80 */ 235, 2,176,153,235, 2,176, 6,235, 2,176, 5,235, 2,176,197, +/* 0x0f90 */ 235, 2,176, 3, 15,182,192, 13, 0, 0, 0, 2, 73,137,202, 15, +/* 0x0fa0 */ 5,115, 4, 72,131,200,255,195, 1, 0, 0, 0, 28, 0, 0, 0, +/* 0x0fb0 */ 0, 0, 0, 0, 28, 0, 0, 0, 0, 0, 0, 0, 28, 0, 0, 0, +/* 0x0fc0 */ 2, 0, 0, 0,244, 8, 0, 0, 52, 0, 0, 0, 52, 0, 0, 0, +/* 0x0fd0 */ 169, 15, 0, 0, 0, 0, 0, 0, 52, 0, 0, 0, 3, 0, 0, 0, +/* 0x0fe0 */ 12, 0, 3, 0, 24, 0, 3, 0, 0, 0, 0, 2, 28, 6, 0, 1, +/* 0x0ff0 */ 102, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1,209, 88, 5, 1, +/* 0x1000 */ 0, 1, 95, 0, 5, 0, 10, 95, 0, 72,117,112,120, 95,109, 97, +/* 0x1010 */ 105,110, 0,106,109, 0,111, 98, 0,148, 1,119,114,105,116,101, +/* 0x1020 */ 0,179, 1,101,120,105,116, 0,184, 1,112,114,101, 97,100, 0, +/* 0x1030 */ 199, 1, 99,108,111,115,101, 0,204, 1,111,112,101,110, 0,209, +/* 0x1040 */ 1,114,101, 97,100, 0,219, 1, 0, 2,109,104, 95,101,120,101, +/* 0x1050 */ 99,117,116,101, 95,104,101, 97,100,101,114, 0,102, 95, 98,122, +/* 0x1060 */ 101,114,111, 0,169, 1, 2, 0, 0, 0, 3, 0,244, 17, 0, 0, +/* 0x1070 */ 4, 97,105,110, 0,143, 1,112,114,111,116,101, 99,116, 0,189, +/* 0x1080 */ 1,117,110,109, 97,112, 0,194, 1,109, 97,112, 0,214, 1, 3, +/* 0x1090 */ 0,187, 28, 0, 0, 2,115,119, 97,112, 0,164, 1,122,101,114, +/* 0x10a0 */ 111, 0,174, 1, 3, 0,218, 30, 0, 3, 0,235, 30, 0, 3, 0, +/* 0x10b0 */ 235, 30, 0, 3, 0,242, 30, 0, 3, 0,246, 30, 0, 3, 0,250, +/* 0x10c0 */ 30, 0, 3, 0,254, 30, 0, 3, 0,130, 31, 0, 3, 0,134, 31, +/* 0x10d0 */ 0, 3, 0,138, 31, 0, 3, 0,142, 31, 0, 3, 0,146, 31, 0, +/* 0x10e0 */ 2, 0, 0, 0, 14, 1, 0, 0,116, 10, 0,240, 0, 0, 0, 0, +/* 0x10f0 */ 16, 0, 0, 0, 14, 1, 0, 0,138, 11, 0,240, 0, 0, 0, 0, +/* 0x1100 */ 25, 0, 0, 0, 14, 1, 0, 0, 16, 15, 0,240, 0, 0, 0, 0, +/* 0x1110 */ 32, 0, 0, 0, 2, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, +/* 0x1120 */ 41, 0, 0, 0, 2, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, +/* 0x1130 */ 50, 0, 0, 0, 2, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, +/* 0x1140 */ 60, 0, 0, 0, 2, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, +/* 0x1150 */ 69, 0, 0, 0, 2, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, +/* 0x1160 */ 79, 0, 0, 0, 2, 0, 0, 0, 73, 0, 0, 0, 0, 0, 0, 0, +/* 0x1170 */ 90, 0, 0, 0, 2, 0, 0, 0, 74, 0, 0, 0, 0, 0, 0, 0, +/* 0x1180 */ 103, 0, 0, 0, 2, 0, 0, 0,153, 0, 0, 0, 0, 0, 0, 0, +/* 0x1190 */ 113, 0, 0, 0, 2, 0, 0, 0,197, 0, 0, 0, 0, 0, 0, 0, +/* 0x11a0 */ 122, 0, 0, 0, 15, 1, 0, 0,107, 15, 0,240, 0, 0, 0, 0, +/* 0x11b0 */ 131, 0, 0, 0, 3, 1, 16, 0, 0, 0, 0,240, 0, 0, 0, 0, +/* 0x11c0 */ 151, 0, 0, 0, 15, 1, 0, 0, 90, 15, 0,240, 0, 0, 0, 0, +/* 0x11d0 */ 158, 0, 0, 0, 15, 1, 0, 0,107, 15, 0,240, 0, 0, 0, 0, +/* 0x11e0 */ 165, 0, 0, 0, 15, 1, 0, 0,134, 15, 0,240, 0, 0, 0, 0, +/* 0x11f0 */ 172, 0, 0, 0, 15, 1, 0, 0,118, 15, 0,240, 0, 0, 0, 0, +/* 0x1200 */ 178, 0, 0, 0, 15, 1, 0, 0, 59, 14, 0,240, 0, 0, 0, 0, +/* 0x1210 */ 184, 0, 0, 0, 15, 1, 0, 0,142, 15, 0,240, 0, 0, 0, 0, +/* 0x1220 */ 190, 0, 0, 0, 15, 1, 0, 0,122, 15, 0,240, 0, 0, 0, 0, +/* 0x1230 */ 200, 0, 0, 0, 15, 1, 0, 0,126, 15, 0,240, 0, 0, 0, 0, +/* 0x1240 */ 208, 0, 0, 0, 15, 1, 0, 0,138, 15, 0,240, 0, 0, 0, 0, +/* 0x1250 */ 214, 0, 0, 0, 15, 1, 0, 0,130, 15, 0,240, 0, 0, 0, 0, +/* 0x1260 */ 221, 0, 0, 0, 15, 1, 0, 0,146, 15, 0,240, 0, 0, 0, 0, +/* 0x1270 */ 227, 0, 0, 0, 15, 1, 0, 0,244, 8, 0,240, 0, 0, 0, 0, +/* 0x1280 */ 237, 0, 0, 0, 15, 1, 0, 0,114, 15, 0,240, 0, 0, 0, 0, +/* 0x1290 */ 244, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x12a0 */ 32, 0, 95,117,110,112, 97, 99,107, 69,120,116,101,110,116, 0, +/* 0x12b0 */ 95,100,111, 95,120,109, 97,112, 0, 95,120,114,101, 97,100, 0, +/* 0x12c0 */ 83, 89, 83, 95,101,120,105,116, 0, 83, 89, 83, 95,114,101, 97, +/* 0x12d0 */ 100, 0, 83, 89, 83, 95,119,114,105,116,101, 0, 83, 89, 83, 95, +/* 0x12e0 */ 111,112,101,110, 0, 83, 89, 83, 95, 99,108,111,115,101, 0, 83, +/* 0x12f0 */ 89, 83, 95,109,117,110,109, 97,112, 0, 83, 89, 83, 95,109,112, +/* 0x1300 */ 114,111,116,101, 99,116, 0, 83, 89, 83, 95,112,114,101, 97,100, +/* 0x1310 */ 0, 83, 89, 83, 95,109,109, 97,112, 0, 95, 95, 95, 98,122,101, +/* 0x1320 */ 114,111, 0, 95, 95,109,104, 95,101,120,101, 99,117,116,101, 95, +/* 0x1330 */ 104,101, 97,100,101,114, 0, 95, 98,115,119, 97,112, 0, 95, 98, +/* 0x1340 */ 122,101,114,111, 0, 95, 99,108,111,115,101, 0, 95,101,120,105, +/* 0x1350 */ 116, 0, 95,109, 97,105,110, 0, 95,109,109, 97,112, 0, 95,109, +/* 0x1360 */ 112,114,111,116,101, 99,116, 0, 95,109,117,110,109, 97,112, 0, +/* 0x1370 */ 95,111,112,101,110, 0, 95,112,114,101, 97,100, 0, 95,114,101, +/* 0x1380 */ 97,100, 0, 95,117,112,120, 95,109, 97,105,110, 0, 95,119,114, +/* 0x1390 */ 105,116,101, 0,100,121,108,100, 95,115,116,117, 98, 95, 98,105, +/* 0x13a0 */ 110,100,101,114, 0, 0, 0, 0 }; diff --git a/src/stub/src/amd64-darwin.macho-upxmain.c b/src/stub/src/amd64-darwin.macho-upxmain.c index 43044a85..3de45d5d 100644 --- a/src/stub/src/amd64-darwin.macho-upxmain.c +++ b/src/stub/src/amd64-darwin.macho-upxmain.c @@ -696,21 +696,31 @@ typedef struct { // // Build on Mac OS X: (where gcc is really clang) -// gcc -o amd64-darwin.macho-upxmain.exe -fno-stack-protector \ -// -Os -fPIC amd64-darwin.macho-upxmain.c -Wl,-pagezero_size,0xffff0000 \ -// -Wl,-no_pie -Wl,-no_uuid -Wl,-no_function_starts -Wl,-headerpad,0x400 \ -// -Wl,-unexported_symbols_list amd64-darwin.macho-upxhide.txt +// gcc -o amd64-darwin.macho-upxmain.exe \ +// -Os -fPIC -fno-stack-protector \ +// amd64-darwin.macho-upxmain.c \ +// amd64-darwin.macho-upxsubr.S \ +// -Wl,-pagezero_size,0xf0000000 \ +// -Wl,-no_pie \ +// -Wl,-no_uuid \ +// -Wl,-no_function_starts \ +// -Wl,-bind_at_load \ +// -Wl,-headerpad,0x400 \ +// +//# -Wl,-unexported_symbols_list unexport-upxload.txt \ +//# strip -u -r amd64-darwin.macho-upxmain.exe + int main(int argc, char *argv[]) { - // Entry via JMP + // Entry via JMP (with no parameters) instead of CALL asm("movl 1*8(%%rbp),%0; leaq 2*8(%%rbp),%1" : "=r" (argc), "=r" (argv) : ); Mach_header64 const *mhdr0 = (Mach_header64 const *)((~0ul<<16) & (unsigned long)&main); Mach_command const *ptr = (Mach_command const *)(1+ mhdr0); f_unfilter *f_unf; f_expand *f_exp; - unsigned char const *payload; + char *payload; size_t paysize; unsigned j; @@ -718,28 +728,24 @@ main(int argc, char *argv[]) ptr = (Mach_command const *)(ptr->cmdsize + (char const *)ptr)) if (LC_SEGMENT_64==ptr->cmd) { Mach_segment_command const *const segptr = (Mach_segment_command const *)ptr; -//fprintf(stderr, "ptr=%p segptr=%p\n", ptr, segptr); if ((long)0x0000545845545f5ful == *(long const *)segptr->segname) { // "__TEXT" Mach_section_command const *const secptr = (Mach_section_command const *)(1+ segptr); //if ((long)0x0000747865745f5ful == *(long const *)secptr->sectname) { // "__text" f_unf = (f_unfilter *)(sizeof(unsigned short) + secptr->addr); f_exp = (f_expand *)(*(unsigned short *)secptr->addr + secptr->addr); -//fprintf(stderr, "f_unf=%p f_exp=%p\n", f_unf, f_exp); //} } if ((long)0x415441445f585055ul == *(long const *)segptr->segname) { // "UPX_DATA" - payload = (unsigned char const *)(segptr->vmaddr); + payload = (char *)(segptr->vmaddr); paysize = segptr->filesize; -//fprintf(stderr, "payload=%p paysize=%lu\n", payload, paysize); } } char mhdr[2048]; -//fprintf(stderr, "call upx_main(payload=%p paysize=%lu mhdr=%p f_exp=%p f_unf=%p mhdrp@%p)\n", -//payload, paysize, mhdr, f_exp, f_unf, &argv[-2]); uint64_t entry = upx_main((struct l_info const *)payload, paysize, (Mach_header64 *)mhdr, sizeof(mhdr), f_exp, f_unf, (Mach_header64 **)&argv[-2]); -//fprintf(stderr, "return to launch\n"); + + munmap(payload, paysize); // leaving __LINKEDIT argv[-1] = (char *)(long)argc; asm("lea -2*8(%1),%%rsp; jmp *%0" : : "r" (entry), "r" (argv)); return 0; diff --git a/src/stub/src/amd64-darwin.macho-upxsubr.S b/src/stub/src/amd64-darwin.macho-upxsubr.S index df566cba..fcd83740 100644 --- a/src/stub/src/amd64-darwin.macho-upxsubr.S +++ b/src/stub/src/amd64-darwin.macho-upxsubr.S @@ -1,4 +1,37 @@ -#define GLOBAL(sym) sym: .globl sym; _##sym: .globl _##sym +/* +; amd64-darwin.macho-upxsubr.S -- system calls, bswap, bzero (amd64 Mach-o) +; +; This file is part of the UPX executable compressor. +; +; Copyright (C) 1996-2015 Markus Franz Xaver Johannes Oberhumer +; Copyright (C) 1996-2015 Laszlo Molnar +; Copyright (C) 2000-2015 John F. Reiser +; All Rights Reserved. +; +; UPX and the UCL library are free software; you can redistribute them +; and/or modify them under the terms of the GNU General Public License as +; published by the Free Software Foundation; either version 2 of +; the License, or (at your option) any later version. +; +; This program is distributed in the hope that it will be useful, +; but WITHOUT ANY WARRANTY; without even the implied warranty of +; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +; GNU General Public License for more details. +; +; You should have received a copy of the GNU General Public License +; along with this program; see the file COPYING. +; If not, write to the Free Software Foundation, Inc., +; 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. +; +; Markus F.X.J. Oberhumer Laszlo Molnar +; +; +; John F. Reiser +; +; +*/ +// Prepend one underscore +#define GLOBAL(sym) _##sym: .globl _##sym GLOBAL(bswap) 0: From 7ad1e7756b8fa7b1ff845fab906195cf0092e5f7 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sat, 17 Sep 2016 06:49:41 -0700 Subject: [PATCH 24/29] Cleanup for checkin changed src/p_mach.cpp --- src/p_mach.cpp | 37 +++++++++++++++++++------------------ 1 file changed, 19 insertions(+), 18 deletions(-) diff --git a/src/p_mach.cpp b/src/p_mach.cpp index 7a592796..69e441d0 100644 --- a/src/p_mach.cpp +++ b/src/p_mach.cpp @@ -858,8 +858,9 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader if (blk.bind_off) blk.bind_off += delta; if (blk.lazy_bind_off) blk.lazy_bind_off += delta; if (blk.export_off) blk.export_off += delta; -blk.export_off = 0; -blk.export_size = 0; + // But we don't want any exported symbols. + blk.export_off = 0; + blk.export_size = 0; fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); fo->rewrite(&blk, sizeof(blk)); } break; @@ -878,12 +879,13 @@ blk.export_size = 0; if (blk.indirectsymoff) blk.indirectsymoff += delta; if (blk.extreloff) blk.extreloff += delta; if (blk.locreloff) blk.locreloff += delta; -blk.ilocalsym = 0; -blk.nlocalsym = 0; -blk.iextdefsym = 0; -blk.nextdefsym = 0; -blk.iundefsym = 0; -blk.nundefsym = 0; + // But we don't want any symbols. + blk.ilocalsym = 0; + blk.nlocalsym = 0; + blk.iextdefsym = 0; + blk.nextdefsym = 0; + blk.iundefsym = 0; + blk.nundefsym = 0; fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); fo->rewrite(&blk, sizeof(blk)); } break; @@ -894,14 +896,14 @@ blk.nundefsym = 0; fo->rewrite(&blk, sizeof(blk)); } break; case Mach_segment_command::LC_MAIN: { - // TEMPORARY: change to LC_UNIX_THREAD; known to be continusous with last + // Change to LC_UNIX_THREAD; known to be contiguous with last // LC_MAIN requires libSystem.B.dylib to provide the environment for main(), and CALLs the entryoff. // LC_UNIXTHREAD does not need libSystem.B.dylib, and JMPs to the .rip with %rsp/argc and argv= 8+%rsp - threado.cmd = Mach_segment_command::LC_UNIXTHREAD; - threado.cmdsize = sizeof(threado); - threado.flavor = my_thread_flavor; - threado.count = my_thread_state_word_count; - memset(&threado.state, 0, sizeof(threado.state)); + threado.cmd = Mach_segment_command::LC_UNIXTHREAD; + threado.cmdsize = sizeof(threado); + threado.flavor = my_thread_flavor; + threado.count = my_thread_state_word_count; + memset(&threado.state, 0, sizeof(threado.state)); threado.state.rip = ((N_Mach::Mach_main_command const *)ptr1)->entryoff + segTEXT.vmaddr; fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); fo->rewrite(&threado, sizeof(threado)); @@ -910,9 +912,8 @@ blk.nundefsym = 0; fo->rewrite(&mhdro, sizeof(mhdro)); } break; case Mach_segment_command::LC_LOAD_DYLIB: { - // Temporary test: remove this command; known to be contiguous with last - N_Mach::Mach_load_dylib_command blk; -memset(&blk, 0, sizeof(blk)); + // Remove this command; known to be contiguous with last + N_Mach::Mach_load_dylib_command blk; memset(&blk, 0, sizeof(blk)); fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); fo->rewrite(&blk, sizeof(blk)); mhdro.ncmds -= 1; @@ -923,7 +924,7 @@ memset(&blk, 0, sizeof(blk)); case Mach_segment_command::LC_DATA_IN_CODE: { N_Mach::Mach_data_in_code_command blk; memcpy(&blk, ptr1, sizeof(blk)); if (blk.dataoff) blk.dataoff += delta; -memset(&blk, 0, sizeof(blk)); + memset(&blk, 0, sizeof(blk)); fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); fo->rewrite(&blk, sizeof(blk)); // Temporary test: remove this command; known to be last From 345a1c64f91fafa5052fccce455577941bccd34c Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sat, 17 Sep 2016 09:36:58 -0700 Subject: [PATCH 25/29] Omit Mach_command from stub where allowed. changed src/p_mach.cpp --- src/p_mach.cpp | 44 ++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 40 insertions(+), 4 deletions(-) diff --git a/src/p_mach.cpp b/src/p_mach.cpp index 69e441d0..5e32a1b1 100644 --- a/src/p_mach.cpp +++ b/src/p_mach.cpp @@ -798,14 +798,19 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader fo->rewrite(&linfo, sizeof(linfo)); } if (my_filetype == Mach_header::MH_EXECUTE) { + // Get a writeable copy of the stub to make editing easier. + unsigned char upxstub[sizeof(stub_amd64_darwin_macho_upxmain_exe)]; + memcpy(upxstub, stub_amd64_darwin_macho_upxmain_exe, sizeof(upxstub)); + + Mach_header *const ptr0 = (Mach_header *)upxstub; + Mach_command *ptr1 = (Mach_command *)(1+ ptr0); unsigned cmdsize = mhdro.sizeofcmds - sizeof(segXHDR); - Mach_header const *const ptr0 = (Mach_header const *)stub_amd64_darwin_macho_upxmain_exe; - Mach_command const *ptr1 = (Mach_command const *)(1+ ptr0); unsigned const ncmds = mhdro.ncmds; unsigned delta = 0; for (unsigned j = 0; j < ncmds -1; ++j, (cmdsize -= ptr1->cmdsize), - ptr1 = (Mach_command const *)(ptr1->cmdsize + (char const *)ptr1)) + ptr1 = (Mach_command *)(ptr1->cmdsize + (char *)ptr1)) +next: switch (ptr1->cmd) { case Mach_segment_command::LC_SEGMENT_64: { Mach_segment_command const *const segptr = (Mach_segment_command const *)ptr1; @@ -826,7 +831,10 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader fo->rewrite(getLoader(), d); fo->seek(0, SEEK_END); } - if (!strcmp("__LINKEDIT", ((Mach_segment_command const *)ptr1)->segname)) { + if (!strcmp("__DATA", segptr->segname) && !segptr->vmsize) { + goto omit; + } + if (!strcmp("__LINKEDIT", segptr->segname)) { memcpy(&segLINK, segptr, sizeof(segLINK)); delta = offLINK - segLINK.fileoff; // relocation constant @@ -863,6 +871,7 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader blk.export_size = 0; fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); fo->rewrite(&blk, sizeof(blk)); + goto omit; // try omitting this } break; case Mach_segment_command::LC_SYMTAB: { Mach_symtab_command blk; memcpy(&blk, ptr1, sizeof(blk)); @@ -870,6 +879,7 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader if (blk.stroff) blk.stroff += delta; fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); fo->rewrite(&blk, sizeof(blk)); + goto omit; // try omitting this } break; case Mach_segment_command::LC_DYSYMTAB: { Mach_dysymtab_command blk; memcpy(&blk, ptr1, sizeof(blk)); @@ -888,6 +898,7 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader blk.nundefsym = 0; fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); fo->rewrite(&blk, sizeof(blk)); + goto omit; // adds full path as another agrument? } break; case Mach_segment_command::LC_FUNCTION_STARTS: { N_Mach::Mach_function_starts_command blk; memcpy(&blk, ptr1, sizeof(blk)); @@ -933,7 +944,32 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader fo->seek(0, SEEK_SET); fo->rewrite(&mhdro, sizeof(mhdro)); } break; + case Mach_segment_command::LC_LOAD_DYLINKER: { + // Try omitting this +omit: + fo->seek(sizeof(mhdro) + mhdro.sizeofcmds - cmdsize, SEEK_SET); + Mach_command *ptr2 = ptr1; + unsigned const sz_omit = ptr1->cmdsize; + ptr1 = (Mach_command *)(sz_omit + (char *)ptr1); + cmdsize -= sz_omit; + + fo->rewrite(ptr1, cmdsize); // slide in file TODO: clear the garbage + memmove(ptr2, ptr1, cmdsize); // overlapping slide lower + ptr1 = ptr2; + + mhdro.ncmds -= 1; + mhdro.sizeofcmds -= sz_omit; + fo->seek(0, SEEK_SET); + fo->rewrite(&mhdro, sizeof(mhdro)); + if (++j < (ncmds -1)) + goto next; + goto done; + } break; + case Mach_segment_command::LC_SOURCE_VERSION: { + goto omit; + } break; } // end switch +done: fo->seek(0, SEEK_END); } } From e2160fb6c9f522c07030f9f9b2b17e01b1ef0b64 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sat, 17 Sep 2016 10:41:38 -0700 Subject: [PATCH 26/29] segLINK.initprot |= VM_PROT_EXECUTE changed src/p_mach.cpp --- src/p_mach.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/p_mach.cpp b/src/p_mach.cpp index 5e32a1b1..c30730c3 100644 --- a/src/p_mach.cpp +++ b/src/p_mach.cpp @@ -836,6 +836,8 @@ next: } if (!strcmp("__LINKEDIT", segptr->segname)) { memcpy(&segLINK, segptr, sizeof(segLINK)); + segLINK.initprot = Mach_segment_command::VM_PROT_READ + | Mach_segment_command::VM_PROT_EXECUTE; delta = offLINK - segLINK.fileoff; // relocation constant // The contents for __LINKEDIT remain the same, @@ -1722,7 +1724,8 @@ void PackMachBase::pack1(OutputFile *const fo, Filter &/*ft*/) // generate e segLINK.cmdsize = sizeof(segLINK); strncpy((char *)segLINK.segname, "__LINKEDIT", sizeof(segLINK.segname)); segLINK.nsects = 0; - segLINK.initprot = Mach_segment_command::VM_PROT_READ; + segLINK.initprot = Mach_segment_command::VM_PROT_READ + | Mach_segment_command::VM_PROT_EXECUTE; // Adjust later: .vmaddr .vmsize .fileoff .filesize if (my_filetype == Mach_header::MH_EXECUTE) { From 9b26ebed75a1fde4357eb1ba3cefaa112e7808ee Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sat, 17 Sep 2016 15:24:23 -0700 Subject: [PATCH 27/29] LINKEDIT has unfilter and decompressor changed src/p_mach.cpp changed src/stub/amd64-darwin.macho-upxmain.h changed src/stub/src/amd64-darwin.macho-upxmain.c --- src/p_mach.cpp | 53 ++-- src/stub/amd64-darwin.macho-upxmain.h | 308 +++++++++++----------- src/stub/src/amd64-darwin.macho-upxmain.c | 20 +- 3 files changed, 192 insertions(+), 189 deletions(-) diff --git a/src/p_mach.cpp b/src/p_mach.cpp index c30730c3..736600fc 100644 --- a/src/p_mach.cpp +++ b/src/p_mach.cpp @@ -776,12 +776,9 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader secXHDR.offset -= sizeof(linkitem); } secXHDR.addr += secXHDR.offset; - unsigned offLINK = (PAGE_MASK & (~PAGE_MASK + segTEXT.filesize)); - if (offLINK < segTEXT.vmsize) - offLINK += PAGE_SIZE; // codesign disallows overhang - segLINK.fileoff = offLINK; + unsigned offLINK = segLINK.fileoff; segLINK.vmaddr = segTEXT.vmaddr + offLINK; - if (0) { + if (my_filetype != Mach_header::MH_EXECUTE) { fo->seek(offLINK - 1, SEEK_SET); fo->write("", 1); fo->seek(sizeof(mhdro), SEEK_SET); fo->rewrite(&segZERO, sizeof(segZERO)); @@ -818,32 +815,31 @@ next: memcpy(&segTEXT, segptr, sizeof(segTEXT)); Mach_section_command const *const secptr = (Mach_section_command const *)(1+ segptr); memcpy(&secTEXT, secptr, sizeof(secTEXT)); - // Put f_unf and f_exp before compiled C code: - // steal space from -Wl,-headerpadsize - secTEXT.align = 0; - unsigned const d = getLoaderSize(); - secTEXT.addr -= d; - secTEXT.size += d; - secTEXT.offset -= d; + // // Put f_unf and f_exp before compiled C code: + // // steal space from -Wl,-headerpadsize + //secTEXT.align = 0; + //unsigned const d = getLoaderSize(); + //secTEXT.addr -= d; + //secTEXT.size += d; + //secTEXT.offset -= d; fo->seek((char const *)secptr - (char const *)ptr0, SEEK_SET); fo->rewrite(&secTEXT, sizeof(secTEXT)); - fo->seek(secTEXT.offset, SEEK_SET); - fo->rewrite(getLoader(), d); + //fo->seek(secTEXT.offset, SEEK_SET); + //fo->rewrite(getLoader(), d); fo->seek(0, SEEK_END); } if (!strcmp("__DATA", segptr->segname) && !segptr->vmsize) { goto omit; } if (!strcmp("__LINKEDIT", segptr->segname)) { - memcpy(&segLINK, segptr, sizeof(segLINK)); segLINK.initprot = Mach_segment_command::VM_PROT_READ | Mach_segment_command::VM_PROT_EXECUTE; - delta = offLINK - segLINK.fileoff; // relocation constant + delta = offLINK - segptr->fileoff; // relocation constant - // The contents for __LINKEDIT remain the same, - // but move to a different offset in the file - fo->seek(offLINK, SEEK_SET); - fo->write(&stub_amd64_darwin_macho_upxmain_exe[segLINK.fileoff], segLINK.filesize); + //// The contents for __LINKEDIT remain the same, + //// but move to a different offset in the file + //fo->seek(offLINK, SEEK_SET); + //fo->write(&stub_amd64_darwin_macho_upxmain_exe[segLINK.fileoff], segLINK.filesize); // Mach_segment_command for new segXHDR segXHDR.cmdsize = sizeof(segXHDR); // no need for sections @@ -857,8 +853,10 @@ next: fo->rewrite(&segXHDR, sizeof(segXHDR)); // Update the __LINKEDIT header - segLINK.vmaddr = segXHDR.vmsize + segXHDR.vmaddr; - segLINK.fileoff = offLINK; + segLINK.filesize = eofcmpr - offLINK; + segLINK.vmsize = PAGE_MASK64 & (~PAGE_MASK64 + eofcmpr - offLINK); + segLINK.fileoff = segXHDR.filesize + segXHDR.fileoff; + segLINK.vmaddr = segXHDR.vmsize + segXHDR.vmaddr; fo->rewrite(&segLINK, sizeof(segLINK)); } } break; @@ -1317,11 +1315,18 @@ void PackMachAMD64::pack3(OutputFile *fo, Filter &ft) // append loader unsigned const zero = 0; unsigned len = fo->getBytesWritten(); fo->write(&zero, 3& (0u-len)); - len += (3& (0u-len)); + len += (3& (0u-len)); // 0 mod 4 + disp = len - sz_mach_headers; fo->write(&disp, sizeof(disp)); + len += sizeof(disp); - threado.state.rip = len + sizeof(disp) + segTEXT.vmaddr; /* entry address */ + char page[~PAGE_MASK]; memset(page, 0, sizeof(page)); + fo->write(page, ~PAGE_MASK & -len); + len += ~PAGE_MASK & -len; + segLINK.fileoff = len; + + threado.state.rip = len + segTEXT.vmaddr; /* entry address */ super::pack3(fo, ft); } diff --git a/src/stub/amd64-darwin.macho-upxmain.h b/src/stub/amd64-darwin.macho-upxmain.h index edbed26b..54c8d202 100644 --- a/src/stub/amd64-darwin.macho-upxmain.h +++ b/src/stub/amd64-darwin.macho-upxmain.h @@ -32,8 +32,8 @@ #define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_SIZE 5032 -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0xb823c21c -#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0x8e69c33a +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_ADLER32 0x56d6c085 +#define STUB_AMD64_DARWIN_MACHO_UPXMAIN_EXE_CRC32 0xefaad113 unsigned char stub_amd64_darwin_macho_upxmain_exe[5032] = { /* 0x0000 */ 207,250,237,254, 7, 0, 0, 1, 3, 0, 0,128, 2, 0, 0, 0, @@ -49,8 +49,8 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5032] = { /* 0x00a0 */ 7, 0, 0, 0, 5, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, /* 0x00b0 */ 95, 95,116,101,120,116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00c0 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x00d0 */ 244, 8, 0,240, 0, 0, 0, 0,180, 6, 0, 0, 0, 0, 0, 0, -/* 0x00e0 */ 244, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x00d0 */ 253, 8, 0,240, 0, 0, 0, 0,171, 6, 0, 0, 0, 0, 0, 0, +/* 0x00e0 */ 253, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x00f0 */ 0, 4, 0,128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x0100 */ 95, 95,117,110,119,105,110,100, 95,105,110,102,111, 0, 0, 0, /* 0x0110 */ 95, 95, 84, 69, 88, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -78,11 +78,11 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5032] = { /* 0x0270 */ 0, 0, 0, 0, 0, 0, 0, 0, 14, 0, 0, 0, 32, 0, 0, 0, /* 0x0280 */ 12, 0, 0, 0, 47,117,115,114, 47,108,105, 98, 47,100,121,108, /* 0x0290 */ 100, 0, 0, 0, 0, 0, 0, 0, 36, 0, 0, 0, 16, 0, 0, 0, -/* 0x02a0 */ 0, 11, 10, 0, 0, 11, 10, 0, 42, 0, 0, 0, 16, 0, 0, 0, +/* 0x02a0 */ 0, 12, 10, 0, 0, 12, 10, 0, 42, 0, 0, 0, 16, 0, 0, 0, /* 0x02b0 */ 0, 0, 0, 0, 0, 0, 0, 0, 40, 0, 0,128, 24, 0, 0, 0, -/* 0x02c0 */ 59, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x02c0 */ 68, 14, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x02d0 */ 12, 0, 0, 0, 56, 0, 0, 0, 24, 0, 0, 0, 2, 0, 0, 0, -/* 0x02e0 */ 1, 10,202, 4, 0, 0, 1, 0, 47,117,115,114, 47,108,105, 98, +/* 0x02e0 */ 0, 0,214, 4, 0, 0, 1, 0, 47,117,115,114, 47,108,105, 98, /* 0x02f0 */ 47,108,105, 98, 83,121,115,116,101,109, 46, 66, 46,100,121,108, /* 0x0300 */ 105, 98, 0, 0, 0, 0, 0, 0, 41, 0, 0, 0, 16, 0, 0, 0, /* 0x0310 */ 224, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, @@ -179,103 +179,103 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5032] = { /* 0x08c0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x08d0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, /* 0x08e0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x08f0 */ 0, 0, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, -/* 0x0900 */ 83, 72,131,236, 72, 77,137,205, 76,137,195, 73,137,206, 73,137, -/* 0x0910 */ 212, 72,137,117,208, 72,141, 71, 24, 72,137, 69,200, 72,139, 69, -/* 0x0920 */ 208, 72,131,192,232, 72,137, 69,192, 76,137,101,184,139, 71, 24, -/* 0x0930 */ 72,137, 69,176, 72,139, 69,192, 72,139, 77,200, 72,137, 77,168, -/* 0x0940 */ 72,137, 69,160, 69, 49,255, 72,141,125,192, 72,141,117,176, 49, -/* 0x0950 */ 201, 72,137,218,232, 27, 1, 0, 0, 76,137, 44, 36, 72,141, 85, -/* 0x0960 */ 160,190, 0, 0, 0, 0,185,255,255,255,255, 76,137,231, 76,139, -/* 0x0970 */ 69, 16, 73,137,217,232, 16, 2, 0, 0, 72,137,195, 65,139, 76, -/* 0x0980 */ 36, 16,133,201, 15,132,216, 0, 0, 0, 73,141, 68, 36, 32,131, -/* 0x0990 */ 56, 14,116, 19, 65,255,199,139, 80, 4, 72, 1,208, 65, 57,207, -/* 0x09a0 */ 114,237,233,187, 0, 0, 0,139,120, 8, 72, 1,199, 49,246, 49, -/* 0x09b0 */ 210,232,212, 5, 0, 0, 65,137,199, 69,133,255,120,113, 77,141, -/* 0x09c0 */ 108, 36, 16, 49,219, 68,137,255, 76,137,230, 76,137,242, 72,137, -/* 0x09d0 */ 217,232,172, 5, 0, 0, 76, 57,240,117, 84, 65,139, 4, 36, 61, -/* 0x09e0 */ 190,186,254,202,116, 7, 61,202,254,186,190,117, 76, 65, 15,182, -/* 0x09f0 */ 68, 36, 7,141, 4,128,141, 52,133, 8, 0, 0, 0, 76,137,231, -/* 0x0a00 */ 232, 85, 5, 0, 0, 65,139, 68, 36, 4, 49,201,133,192, 76,137, -/* 0x0a10 */ 234,116, 28,129,122,248, 7, 0, 0, 1,116, 12,255,193, 72,131, -/* 0x0a20 */ 194, 20, 57,193,114,237,235, 7,139, 26, 72,133,219,117,150,191, -/* 0x0a30 */ 127, 0, 0, 0,232, 61, 5, 0, 0, 72,199, 4, 36, 0, 0, 0, -/* 0x0a40 */ 0, 49,210, 69, 49,192, 69, 49,201, 76,137,231, 72,137,222, 68, -/* 0x0a50 */ 137,249,232, 51, 1, 0, 0, 72,137,195, 68,137,255,232, 36, 5, -/* 0x0a60 */ 0, 0, 72,137,216, 72,131,196, 72, 91, 65, 92, 65, 93, 65, 94, -/* 0x0a70 */ 65, 95, 93,195, 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, -/* 0x0a80 */ 83, 72,131,236, 56, 72,137, 77,176, 72,137, 85,168, 73,137,246, -/* 0x0a90 */ 72,137,125,184, 73,131, 62, 0, 15,132,211, 0, 0, 0, 76,141, -/* 0x0aa0 */ 101,200,186, 12, 0, 0, 0, 72,139,125,184, 76,137,230,232, 93, -/* 0x0ab0 */ 4, 0, 0, 68,139,109,200, 68,139,125,204, 77,133,237, 15,132, -/* 0x0ac0 */ 154, 0, 0, 0, 65,141, 71,255, 68, 57,232, 15,131,175, 0, 0, -/* 0x0ad0 */ 0, 77, 59, 46, 15,135,166, 0, 0, 0, 69, 57,239,115, 90, 68, -/* 0x0ae0 */ 137,109,196, 72,139, 69,184, 72,139,120, 8, 73,139, 86, 8,139, -/* 0x0af0 */ 93,208, 68, 15,182,195, 68,137,254, 72,141, 77,196,255, 85,168, -/* 0x0b00 */ 133,192,117,124, 68, 57,109,196,117,118, 72,131,125,176, 0,116, -/* 0x0b10 */ 27, 15,182,199,102,133,192,116, 19,193,235, 16, 15,183,200, 73, -/* 0x0b20 */ 139,126, 8, 15,182,211, 68,137,238,255, 85,176, 72,139, 69,184, -/* 0x0b30 */ 76, 1,120, 8, 76, 41, 56,235, 16, 73,139,118, 8, 72,139,125, -/* 0x0b40 */ 184, 76,137,250,232,199, 3, 0, 0, 77, 1,110, 8, 73,139, 6, -/* 0x0b50 */ 76, 41,232, 73,137, 6, 15,133, 70,255,255,255,235, 19, 65,129, -/* 0x0b60 */ 255, 85, 80, 88, 33,117, 25, 72,139, 69,184, 72,131, 56, 0,117, -/* 0x0b70 */ 15, 72,131,196, 56, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195, -/* 0x0b80 */ 191,127, 0, 0, 0,232,236, 3, 0, 0, 85, 72,137,229, 65, 87, -/* 0x0b90 */ 65, 86, 65, 85, 65, 84, 83, 72,131,236,120, 76,137,141,112,255, -/* 0x0ba0 */ 255,255, 76,137,133,104,255,255,255,137, 77,140, 72,137, 85,192, -/* 0x0bb0 */ 72,137,117,128, 72,137,125,144,139, 95, 16, 69, 49,255,133,219, -/* 0x0bc0 */ 184, 0, 0, 0, 0, 15,132, 87, 2, 0, 0, 72,139, 77,144, 76, -/* 0x0bd0 */ 141,105, 32, 72,131,125,192, 0, 15,149,193, 15,182,201, 72,141, -/* 0x0be0 */ 12, 73, 72,137,141,120,255,255,255, 72,191, 4, 0, 0, 0, 42, -/* 0x0bf0 */ 0, 0, 0, 69, 49,201, 49,192, 69, 49,192, 73,139, 85, 0, 72, -/* 0x0c00 */ 137,209, 72,193,233, 32,141,114,252,131,254, 2, 15,130,205, 0, -/* 0x0c10 */ 0, 0,129,250, 40, 0, 0,128, 15,132,218, 0, 0, 0,131,250, -/* 0x0c20 */ 25, 15,133,234, 1, 0, 0, 73,139, 85, 32, 72,133,210, 15,132, -/* 0x0c30 */ 221, 1, 0, 0, 72,137, 85,168, 76,137, 77,184, 72,137, 69,160, -/* 0x0c40 */ 73,139, 69, 48, 72,137, 69,200, 77,139,101, 24, 77, 1,196, 76, -/* 0x0c50 */ 137,101,176, 76,137,101,208, 69,137,230, 65,129,230,255, 15, 0, -/* 0x0c60 */ 0, 77, 41,244, 73, 1,198, 76,137,195, 15,132,169, 0, 0, 0, -/* 0x0c70 */ 72,139,141,120,255,255,255, 73,141, 52, 14, 77,133,228,186, 2, -/* 0x0c80 */ 0, 0, 0,185, 18, 0, 0, 0, 15, 69,209, 72,133,192, 15,148, -/* 0x0c90 */ 193, 15,182,201,193,225, 12, 72,131,125,192, 0,191, 0, 16, 0, -/* 0x0ca0 */ 0, 15, 69,207, 9,209, 72,131,248, 1, 69, 25,192, 68, 11, 69, -/* 0x0cb0 */ 140, 77,139, 77, 40, 76, 3, 77,128,186, 3, 0, 0, 0, 76,137, -/* 0x0cc0 */ 231,232,200, 2, 0, 0, 77,133,228, 72, 15, 68,216, 72,137, 93, -/* 0x0cd0 */ 152, 72,131,248,255, 73,137,196,117, 67,233, 82, 1, 0, 0, 73, -/* 0x0ce0 */ 57,125, 8, 15,133, 40, 1, 0, 0, 73,139,133,144, 0, 0, 0, -/* 0x0cf0 */ 76, 1,192,233, 25, 1, 0, 0, 73,139, 69, 8, 73, 57, 65, 40, -/* 0x0d00 */ 15,135, 11, 1, 0, 0, 73, 59, 65, 48, 15,131, 1, 1, 0, 0, -/* 0x0d10 */ 73, 3, 65, 24,233,248, 0, 0, 0, 72,137, 93,152, 72,131,125, -/* 0x0d20 */ 192, 0,116, 52, 73,131,125, 48, 0,116, 45, 73,131,125, 40, 0, -/* 0x0d30 */ 117, 14, 72,139,133,104,255,255,255, 76,137, 32, 76,137,109,184, -/* 0x0d40 */ 72,139,125,192, 72,141,117,200, 72,139,149,112,255,255,255, 72, -/* 0x0d50 */ 139, 77, 16,232, 28,253,255,255, 68,137,243,247,219, 72,129,227, -/* 0x0d60 */ 255, 15, 0, 0,116, 12, 75,141, 60, 52, 72,137,222,232,249, 1, -/* 0x0d70 */ 0, 0, 77,133,246,116, 23, 65,139, 85, 60, 76,137,231, 76,137, -/* 0x0d80 */ 246,232,244, 1, 0, 0,133,192, 15,133,163, 0, 0, 0, 72,139, -/* 0x0d90 */ 69,176, 72, 3, 69,168, 76, 1,243, 73, 1,220, 73, 57,196,115, -/* 0x0da0 */ 44, 77,133,228,116, 74, 72,137,198, 76, 41,230, 65,139, 85, 60, -/* 0x0db0 */ 185, 18, 16, 0, 0, 65,184,255,255,255,255, 69, 49,201, 76,137, -/* 0x0dc0 */ 231,232,200, 1, 0, 0, 73, 57,196,116, 37,235,100, 72,131,125, -/* 0x0dd0 */ 192, 0,116, 28, 65,131,198, 3, 65,129,230,255, 15, 0, 0, 73, -/* 0x0de0 */ 131,254, 3,119, 11, 76,137,231, 76,137,246,232,142, 1, 0, 0, -/* 0x0df0 */ 65,139, 77, 4, 72,139, 69,144,139, 88, 16, 72,191, 4, 0, 0, -/* 0x0e00 */ 0, 42, 0, 0, 0, 72,139, 69,160, 76,139, 69,152, 76,139, 77, -/* 0x0e10 */ 184, 65,255,199,137,201, 73, 1,205, 65, 57,223, 15,130,217,253, -/* 0x0e20 */ 255,255, 72,131,196,120, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93, -/* 0x0e30 */ 195,191,127, 0, 0, 0,232, 59, 1, 0, 0, 85, 72,137,229, 65, -/* 0x0e40 */ 87, 65, 86, 65, 85, 65, 84, 83, 72,129,236, 24, 8, 0, 0, 68, -/* 0x0e50 */ 139,109, 8, 76,141,101, 16, 72,141, 5,221,255,255,255, 72, 37, -/* 0x0e60 */ 0, 0,255,255,139, 72, 16,133,201,116, 82, 72,131,200, 32, 49, -/* 0x0e70 */ 210, 72,190, 85, 80, 88, 95, 68, 65, 84, 65, 72,191, 95, 95, 84, -/* 0x0e80 */ 69, 88, 84, 0, 0,131, 56, 25,117, 39, 72,139, 88, 8, 72, 57, -/* 0x0e90 */ 243,116, 22, 72, 57,251,117, 25, 72,139, 88,104, 68, 15,183, 3, -/* 0x0ea0 */ 73, 1,216, 76,141, 75, 2,235, 8, 76,139,120, 24, 76,139,112, -/* 0x0eb0 */ 48,255,194,139, 88, 4, 72, 1,216, 57,202,114,200, 76,137,224, -/* 0x0ec0 */ 72,131,192,240, 72,137, 4, 36, 72,141,149,208,247,255,255,185, -/* 0x0ed0 */ 0, 8, 0, 0, 76,137,255, 76,137,246,232, 21,250,255,255, 72, -/* 0x0ee0 */ 137,195, 76,137,255, 76,137,246,232,145, 0, 0, 0, 73, 99,197, -/* 0x0ef0 */ 73,137, 68, 36,248, 73,141,100, 36,240,255,227, 49,192, 72,129, +/* 0x08f0 */ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 85, 72,137, +/* 0x0900 */ 229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, 72, 77,137, +/* 0x0910 */ 205, 76,137,195, 73,137,206, 73,137,212, 72,137,117,208, 72,141, +/* 0x0920 */ 71, 24, 72,137, 69,200, 72,139, 69,208, 72,131,192,232, 72,137, +/* 0x0930 */ 69,192, 76,137,101,184,139, 71, 24, 72,137, 69,176, 72,139, 69, +/* 0x0940 */ 192, 72,139, 77,200, 72,137, 77,168, 72,137, 69,160, 69, 49,255, +/* 0x0950 */ 72,141,125,192, 72,141,117,176, 49,201, 72,137,218,232, 27, 1, +/* 0x0960 */ 0, 0, 76,137, 44, 36, 72,141, 85,160,190, 0, 0, 0, 0,185, +/* 0x0970 */ 255,255,255,255, 76,137,231, 76,139, 69, 16, 73,137,217,232, 16, +/* 0x0980 */ 2, 0, 0, 72,137,195, 65,139, 76, 36, 16,133,201, 15,132,216, +/* 0x0990 */ 0, 0, 0, 73,141, 68, 36, 32,131, 56, 14,116, 19, 65,255,199, +/* 0x09a0 */ 139, 80, 4, 72, 1,208, 65, 57,207,114,237,233,187, 0, 0, 0, +/* 0x09b0 */ 139,120, 8, 72, 1,199, 49,246, 49,210,232,203, 5, 0, 0, 65, +/* 0x09c0 */ 137,199, 69,133,255,120,113, 77,141,108, 36, 16, 49,219, 68,137, +/* 0x09d0 */ 255, 76,137,230, 76,137,242, 72,137,217,232,163, 5, 0, 0, 76, +/* 0x09e0 */ 57,240,117, 84, 65,139, 4, 36, 61,190,186,254,202,116, 7, 61, +/* 0x09f0 */ 202,254,186,190,117, 76, 65, 15,182, 68, 36, 7,141, 4,128,141, +/* 0x0a00 */ 52,133, 8, 0, 0, 0, 76,137,231,232, 76, 5, 0, 0, 65,139, +/* 0x0a10 */ 68, 36, 4, 49,201,133,192, 76,137,234,116, 28,129,122,248, 7, +/* 0x0a20 */ 0, 0, 1,116, 12,255,193, 72,131,194, 20, 57,193,114,237,235, +/* 0x0a30 */ 7,139, 26, 72,133,219,117,150,191,127, 0, 0, 0,232, 52, 5, +/* 0x0a40 */ 0, 0, 72,199, 4, 36, 0, 0, 0, 0, 49,210, 69, 49,192, 69, +/* 0x0a50 */ 49,201, 76,137,231, 72,137,222, 68,137,249,232, 51, 1, 0, 0, +/* 0x0a60 */ 72,137,195, 68,137,255,232, 27, 5, 0, 0, 72,137,216, 72,131, +/* 0x0a70 */ 196, 72, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195, 85, 72,137, +/* 0x0a80 */ 229, 65, 87, 65, 86, 65, 85, 65, 84, 83, 72,131,236, 56, 72,137, +/* 0x0a90 */ 77,176, 72,137, 85,168, 73,137,246, 72,137,125,184, 73,131, 62, +/* 0x0aa0 */ 0, 15,132,211, 0, 0, 0, 76,141,101,200,186, 12, 0, 0, 0, +/* 0x0ab0 */ 72,139,125,184, 76,137,230,232, 84, 4, 0, 0, 68,139,109,200, +/* 0x0ac0 */ 68,139,125,204, 77,133,237, 15,132,154, 0, 0, 0, 65,141, 71, +/* 0x0ad0 */ 255, 68, 57,232, 15,131,175, 0, 0, 0, 77, 59, 46, 15,135,166, +/* 0x0ae0 */ 0, 0, 0, 69, 57,239,115, 90, 68,137,109,196, 72,139, 69,184, +/* 0x0af0 */ 72,139,120, 8, 73,139, 86, 8,139, 93,208, 68, 15,182,195, 68, +/* 0x0b00 */ 137,254, 72,141, 77,196,255, 85,168,133,192,117,124, 68, 57,109, +/* 0x0b10 */ 196,117,118, 72,131,125,176, 0,116, 27, 15,182,199,102,133,192, +/* 0x0b20 */ 116, 19,193,235, 16, 15,183,200, 73,139,126, 8, 15,182,211, 68, +/* 0x0b30 */ 137,238,255, 85,176, 72,139, 69,184, 76, 1,120, 8, 76, 41, 56, +/* 0x0b40 */ 235, 16, 73,139,118, 8, 72,139,125,184, 76,137,250,232,190, 3, +/* 0x0b50 */ 0, 0, 77, 1,110, 8, 73,139, 6, 76, 41,232, 73,137, 6, 15, +/* 0x0b60 */ 133, 70,255,255,255,235, 19, 65,129,255, 85, 80, 88, 33,117, 25, +/* 0x0b70 */ 72,139, 69,184, 72,131, 56, 0,117, 15, 72,131,196, 56, 91, 65, +/* 0x0b80 */ 92, 65, 93, 65, 94, 65, 95, 93,195,191,127, 0, 0, 0,232,227, +/* 0x0b90 */ 3, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, 83, +/* 0x0ba0 */ 72,131,236,120, 76,137,141,112,255,255,255, 76,137,133,104,255, +/* 0x0bb0 */ 255,255,137, 77,140, 72,137, 85,192, 72,137,117,128, 72,137,125, +/* 0x0bc0 */ 144,139, 95, 16, 69, 49,255,133,219,184, 0, 0, 0, 0, 15,132, +/* 0x0bd0 */ 87, 2, 0, 0, 72,139, 77,144, 76,141,105, 32, 72,131,125,192, +/* 0x0be0 */ 0, 15,149,193, 15,182,201, 72,141, 12, 73, 72,137,141,120,255, +/* 0x0bf0 */ 255,255, 72,191, 4, 0, 0, 0, 42, 0, 0, 0, 69, 49,201, 49, +/* 0x0c00 */ 192, 69, 49,192, 73,139, 85, 0, 72,137,209, 72,193,233, 32,141, +/* 0x0c10 */ 114,252,131,254, 2, 15,130,205, 0, 0, 0,129,250, 40, 0, 0, +/* 0x0c20 */ 128, 15,132,218, 0, 0, 0,131,250, 25, 15,133,234, 1, 0, 0, +/* 0x0c30 */ 73,139, 85, 32, 72,133,210, 15,132,221, 1, 0, 0, 72,137, 85, +/* 0x0c40 */ 168, 76,137, 77,184, 72,137, 69,160, 73,139, 69, 48, 72,137, 69, +/* 0x0c50 */ 200, 77,139,101, 24, 77, 1,196, 76,137,101,176, 76,137,101,208, +/* 0x0c60 */ 69,137,230, 65,129,230,255, 15, 0, 0, 77, 41,244, 73, 1,198, +/* 0x0c70 */ 76,137,195, 15,132,169, 0, 0, 0, 72,139,141,120,255,255,255, +/* 0x0c80 */ 73,141, 52, 14, 77,133,228,186, 2, 0, 0, 0,185, 18, 0, 0, +/* 0x0c90 */ 0, 15, 69,209, 72,133,192, 15,148,193, 15,182,201,193,225, 12, +/* 0x0ca0 */ 72,131,125,192, 0,191, 0, 16, 0, 0, 15, 69,207, 9,209, 72, +/* 0x0cb0 */ 131,248, 1, 69, 25,192, 68, 11, 69,140, 77,139, 77, 40, 76, 3, +/* 0x0cc0 */ 77,128,186, 3, 0, 0, 0, 76,137,231,232,191, 2, 0, 0, 77, +/* 0x0cd0 */ 133,228, 72, 15, 68,216, 72,137, 93,152, 72,131,248,255, 73,137, +/* 0x0ce0 */ 196,117, 67,233, 82, 1, 0, 0, 73, 57,125, 8, 15,133, 40, 1, +/* 0x0cf0 */ 0, 0, 73,139,133,144, 0, 0, 0, 76, 1,192,233, 25, 1, 0, +/* 0x0d00 */ 0, 73,139, 69, 8, 73, 57, 65, 40, 15,135, 11, 1, 0, 0, 73, +/* 0x0d10 */ 59, 65, 48, 15,131, 1, 1, 0, 0, 73, 3, 65, 24,233,248, 0, +/* 0x0d20 */ 0, 0, 72,137, 93,152, 72,131,125,192, 0,116, 52, 73,131,125, +/* 0x0d30 */ 48, 0,116, 45, 73,131,125, 40, 0,117, 14, 72,139,133,104,255, +/* 0x0d40 */ 255,255, 76,137, 32, 76,137,109,184, 72,139,125,192, 72,141,117, +/* 0x0d50 */ 200, 72,139,149,112,255,255,255, 72,139, 77, 16,232, 28,253,255, +/* 0x0d60 */ 255, 68,137,243,247,219, 72,129,227,255, 15, 0, 0,116, 12, 75, +/* 0x0d70 */ 141, 60, 52, 72,137,222,232,240, 1, 0, 0, 77,133,246,116, 23, +/* 0x0d80 */ 65,139, 85, 60, 76,137,231, 76,137,246,232,235, 1, 0, 0,133, +/* 0x0d90 */ 192, 15,133,163, 0, 0, 0, 72,139, 69,176, 72, 3, 69,168, 76, +/* 0x0da0 */ 1,243, 73, 1,220, 73, 57,196,115, 44, 77,133,228,116, 74, 72, +/* 0x0db0 */ 137,198, 76, 41,230, 65,139, 85, 60,185, 18, 16, 0, 0, 65,184, +/* 0x0dc0 */ 255,255,255,255, 69, 49,201, 76,137,231,232,191, 1, 0, 0, 73, +/* 0x0dd0 */ 57,196,116, 37,235,100, 72,131,125,192, 0,116, 28, 65,131,198, +/* 0x0de0 */ 3, 65,129,230,255, 15, 0, 0, 73,131,254, 3,119, 11, 76,137, +/* 0x0df0 */ 231, 76,137,246,232,133, 1, 0, 0, 65,139, 77, 4, 72,139, 69, +/* 0x0e00 */ 144,139, 88, 16, 72,191, 4, 0, 0, 0, 42, 0, 0, 0, 72,139, +/* 0x0e10 */ 69,160, 76,139, 69,152, 76,139, 77,184, 65,255,199,137,201, 73, +/* 0x0e20 */ 1,205, 65, 57,223, 15,130,217,253,255,255, 72,131,196,120, 91, +/* 0x0e30 */ 65, 92, 65, 93, 65, 94, 65, 95, 93,195,191,127, 0, 0, 0,232, +/* 0x0e40 */ 50, 1, 0, 0, 85, 72,137,229, 65, 87, 65, 86, 65, 85, 65, 84, +/* 0x0e50 */ 83, 72,129,236, 24, 8, 0, 0, 68,139,109, 8, 76,141,101, 16, +/* 0x0e60 */ 72,141, 5,221,255,255,255, 72, 37, 0, 0,255,255,139, 72, 16, +/* 0x0e70 */ 133,201,116, 72, 72,131,200, 32, 49,210, 72,190, 76, 73, 78, 75, +/* 0x0e80 */ 69, 68, 73, 84,131, 56, 25,117, 6, 72, 57,112, 10,116, 14,255, +/* 0x0e90 */ 194,139,120, 4, 72, 1,248, 57,202,114,233,235, 31, 72,139, 88, +/* 0x0ea0 */ 24, 68, 15,183, 3, 73, 1,216, 76,141, 75, 2, 68,139,115,252, +/* 0x0eb0 */ 72,131,195,252, 77,133,246,116,243, 76, 41,243, 76,137,224, 72, +/* 0x0ec0 */ 131,192,240, 72,137, 4, 36, 72,141,149,208,247,255,255,185, 0, +/* 0x0ed0 */ 8, 0, 0, 72,137,223, 76,137,246,232, 31,250,255,255, 73,137, +/* 0x0ee0 */ 199, 72,137,223, 76,137,246,232,146, 0, 0, 0, 73, 99,197, 73, +/* 0x0ef0 */ 137, 68, 36,248, 73,141,100, 36,240, 65,255,231, 49,192, 72,129, /* 0x0f00 */ 196, 24, 8, 0, 0, 91, 65, 92, 65, 93, 65, 94, 65, 95, 93,195, /* 0x0f10 */ 72,139, 15, 72, 57,209,114, 52, 72,139, 71, 8, 72,133,210,116, /* 0x0f20 */ 29, 72,137,209, 72,255,201, 68,138, 0, 72,141, 64, 1, 68,136, @@ -288,67 +288,67 @@ unsigned char stub_amd64_darwin_macho_upxmain_exe[5032] = { /* 0x0f90 */ 235, 2,176, 3, 15,182,192, 13, 0, 0, 0, 2, 73,137,202, 15, /* 0x0fa0 */ 5,115, 4, 72,131,200,255,195, 1, 0, 0, 0, 28, 0, 0, 0, /* 0x0fb0 */ 0, 0, 0, 0, 28, 0, 0, 0, 0, 0, 0, 0, 28, 0, 0, 0, -/* 0x0fc0 */ 2, 0, 0, 0,244, 8, 0, 0, 52, 0, 0, 0, 52, 0, 0, 0, +/* 0x0fc0 */ 2, 0, 0, 0,253, 8, 0, 0, 52, 0, 0, 0, 52, 0, 0, 0, /* 0x0fd0 */ 169, 15, 0, 0, 0, 0, 0, 0, 52, 0, 0, 0, 3, 0, 0, 0, -/* 0x0fe0 */ 12, 0, 3, 0, 24, 0, 3, 0, 0, 0, 0, 2, 28, 6, 0, 1, -/* 0x0ff0 */ 102, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1,209, 88, 5, 1, +/* 0x0fe0 */ 12, 0, 3, 0, 24, 0, 3, 0, 0, 0, 0, 2, 19, 6, 0, 1, +/* 0x0ff0 */ 93, 6, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1,209, 88, 5, 1, /* 0x1000 */ 0, 1, 95, 0, 5, 0, 10, 95, 0, 72,117,112,120, 95,109, 97, /* 0x1010 */ 105,110, 0,106,109, 0,111, 98, 0,148, 1,119,114,105,116,101, /* 0x1020 */ 0,179, 1,101,120,105,116, 0,184, 1,112,114,101, 97,100, 0, /* 0x1030 */ 199, 1, 99,108,111,115,101, 0,204, 1,111,112,101,110, 0,209, /* 0x1040 */ 1,114,101, 97,100, 0,219, 1, 0, 2,109,104, 95,101,120,101, /* 0x1050 */ 99,117,116,101, 95,104,101, 97,100,101,114, 0,102, 95, 98,122, -/* 0x1060 */ 101,114,111, 0,169, 1, 2, 0, 0, 0, 3, 0,244, 17, 0, 0, +/* 0x1060 */ 101,114,111, 0,169, 1, 2, 0, 0, 0, 3, 0,253, 17, 0, 0, /* 0x1070 */ 4, 97,105,110, 0,143, 1,112,114,111,116,101, 99,116, 0,189, /* 0x1080 */ 1,117,110,109, 97,112, 0,194, 1,109, 97,112, 0,214, 1, 3, -/* 0x1090 */ 0,187, 28, 0, 0, 2,115,119, 97,112, 0,164, 1,122,101,114, +/* 0x1090 */ 0,196, 28, 0, 0, 2,115,119, 97,112, 0,164, 1,122,101,114, /* 0x10a0 */ 111, 0,174, 1, 3, 0,218, 30, 0, 3, 0,235, 30, 0, 3, 0, /* 0x10b0 */ 235, 30, 0, 3, 0,242, 30, 0, 3, 0,246, 30, 0, 3, 0,250, /* 0x10c0 */ 30, 0, 3, 0,254, 30, 0, 3, 0,130, 31, 0, 3, 0,134, 31, /* 0x10d0 */ 0, 3, 0,138, 31, 0, 3, 0,142, 31, 0, 3, 0,146, 31, 0, -/* 0x10e0 */ 2, 0, 0, 0, 14, 1, 0, 0,116, 10, 0,240, 0, 0, 0, 0, -/* 0x10f0 */ 16, 0, 0, 0, 14, 1, 0, 0,138, 11, 0,240, 0, 0, 0, 0, -/* 0x1100 */ 25, 0, 0, 0, 14, 1, 0, 0, 16, 15, 0,240, 0, 0, 0, 0, -/* 0x1110 */ 32, 0, 0, 0, 2, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, -/* 0x1120 */ 41, 0, 0, 0, 2, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, -/* 0x1130 */ 50, 0, 0, 0, 2, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, -/* 0x1140 */ 60, 0, 0, 0, 2, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, -/* 0x1150 */ 69, 0, 0, 0, 2, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, -/* 0x1160 */ 79, 0, 0, 0, 2, 0, 0, 0, 73, 0, 0, 0, 0, 0, 0, 0, -/* 0x1170 */ 90, 0, 0, 0, 2, 0, 0, 0, 74, 0, 0, 0, 0, 0, 0, 0, -/* 0x1180 */ 103, 0, 0, 0, 2, 0, 0, 0,153, 0, 0, 0, 0, 0, 0, 0, -/* 0x1190 */ 113, 0, 0, 0, 2, 0, 0, 0,197, 0, 0, 0, 0, 0, 0, 0, -/* 0x11a0 */ 122, 0, 0, 0, 15, 1, 0, 0,107, 15, 0,240, 0, 0, 0, 0, -/* 0x11b0 */ 131, 0, 0, 0, 3, 1, 16, 0, 0, 0, 0,240, 0, 0, 0, 0, -/* 0x11c0 */ 151, 0, 0, 0, 15, 1, 0, 0, 90, 15, 0,240, 0, 0, 0, 0, -/* 0x11d0 */ 158, 0, 0, 0, 15, 1, 0, 0,107, 15, 0,240, 0, 0, 0, 0, -/* 0x11e0 */ 165, 0, 0, 0, 15, 1, 0, 0,134, 15, 0,240, 0, 0, 0, 0, -/* 0x11f0 */ 172, 0, 0, 0, 15, 1, 0, 0,118, 15, 0,240, 0, 0, 0, 0, -/* 0x1200 */ 178, 0, 0, 0, 15, 1, 0, 0, 59, 14, 0,240, 0, 0, 0, 0, -/* 0x1210 */ 184, 0, 0, 0, 15, 1, 0, 0,142, 15, 0,240, 0, 0, 0, 0, -/* 0x1220 */ 190, 0, 0, 0, 15, 1, 0, 0,122, 15, 0,240, 0, 0, 0, 0, -/* 0x1230 */ 200, 0, 0, 0, 15, 1, 0, 0,126, 15, 0,240, 0, 0, 0, 0, -/* 0x1240 */ 208, 0, 0, 0, 15, 1, 0, 0,138, 15, 0,240, 0, 0, 0, 0, -/* 0x1250 */ 214, 0, 0, 0, 15, 1, 0, 0,130, 15, 0,240, 0, 0, 0, 0, -/* 0x1260 */ 221, 0, 0, 0, 15, 1, 0, 0,146, 15, 0,240, 0, 0, 0, 0, -/* 0x1270 */ 227, 0, 0, 0, 15, 1, 0, 0,244, 8, 0,240, 0, 0, 0, 0, -/* 0x1280 */ 237, 0, 0, 0, 15, 1, 0, 0,114, 15, 0,240, 0, 0, 0, 0, -/* 0x1290 */ 244, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, -/* 0x12a0 */ 32, 0, 95,117,110,112, 97, 99,107, 69,120,116,101,110,116, 0, -/* 0x12b0 */ 95,100,111, 95,120,109, 97,112, 0, 95,120,114,101, 97,100, 0, -/* 0x12c0 */ 83, 89, 83, 95,101,120,105,116, 0, 83, 89, 83, 95,114,101, 97, -/* 0x12d0 */ 100, 0, 83, 89, 83, 95,119,114,105,116,101, 0, 83, 89, 83, 95, -/* 0x12e0 */ 111,112,101,110, 0, 83, 89, 83, 95, 99,108,111,115,101, 0, 83, -/* 0x12f0 */ 89, 83, 95,109,117,110,109, 97,112, 0, 83, 89, 83, 95,109,112, -/* 0x1300 */ 114,111,116,101, 99,116, 0, 83, 89, 83, 95,112,114,101, 97,100, -/* 0x1310 */ 0, 83, 89, 83, 95,109,109, 97,112, 0, 95, 95, 95, 98,122,101, -/* 0x1320 */ 114,111, 0, 95, 95,109,104, 95,101,120,101, 99,117,116,101, 95, -/* 0x1330 */ 104,101, 97,100,101,114, 0, 95, 98,115,119, 97,112, 0, 95, 98, -/* 0x1340 */ 122,101,114,111, 0, 95, 99,108,111,115,101, 0, 95,101,120,105, -/* 0x1350 */ 116, 0, 95,109, 97,105,110, 0, 95,109,109, 97,112, 0, 95,109, -/* 0x1360 */ 112,114,111,116,101, 99,116, 0, 95,109,117,110,109, 97,112, 0, -/* 0x1370 */ 95,111,112,101,110, 0, 95,112,114,101, 97,100, 0, 95,114,101, -/* 0x1380 */ 97,100, 0, 95,117,112,120, 95,109, 97,105,110, 0, 95,119,114, -/* 0x1390 */ 105,116,101, 0,100,121,108,100, 95,115,116,117, 98, 95, 98,105, -/* 0x13a0 */ 110,100,101,114, 0, 0, 0, 0 +/* 0x10e0 */ 141, 0, 0, 0, 14, 1, 0, 0,125, 10, 0,240, 0, 0, 0, 0, +/* 0x10f0 */ 155, 0, 0, 0, 14, 1, 0, 0,147, 11, 0,240, 0, 0, 0, 0, +/* 0x1100 */ 164, 0, 0, 0, 14, 1, 0, 0, 16, 15, 0,240, 0, 0, 0, 0, +/* 0x1110 */ 171, 0, 0, 0, 2, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, +/* 0x1120 */ 180, 0, 0, 0, 2, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, +/* 0x1130 */ 189, 0, 0, 0, 2, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, +/* 0x1140 */ 199, 0, 0, 0, 2, 0, 0, 0, 5, 0, 0, 0, 0, 0, 0, 0, +/* 0x1150 */ 208, 0, 0, 0, 2, 0, 0, 0, 6, 0, 0, 0, 0, 0, 0, 0, +/* 0x1160 */ 218, 0, 0, 0, 2, 0, 0, 0, 73, 0, 0, 0, 0, 0, 0, 0, +/* 0x1170 */ 229, 0, 0, 0, 2, 0, 0, 0, 74, 0, 0, 0, 0, 0, 0, 0, +/* 0x1180 */ 242, 0, 0, 0, 2, 0, 0, 0,153, 0, 0, 0, 0, 0, 0, 0, +/* 0x1190 */ 252, 0, 0, 0, 2, 0, 0, 0,197, 0, 0, 0, 0, 0, 0, 0, +/* 0x11a0 */ 2, 0, 0, 0, 15, 1, 0, 0,107, 15, 0,240, 0, 0, 0, 0, +/* 0x11b0 */ 11, 0, 0, 0, 3, 1, 16, 0, 0, 0, 0,240, 0, 0, 0, 0, +/* 0x11c0 */ 31, 0, 0, 0, 15, 1, 0, 0, 90, 15, 0,240, 0, 0, 0, 0, +/* 0x11d0 */ 38, 0, 0, 0, 15, 1, 0, 0,107, 15, 0,240, 0, 0, 0, 0, +/* 0x11e0 */ 45, 0, 0, 0, 15, 1, 0, 0,134, 15, 0,240, 0, 0, 0, 0, +/* 0x11f0 */ 52, 0, 0, 0, 15, 1, 0, 0,118, 15, 0,240, 0, 0, 0, 0, +/* 0x1200 */ 58, 0, 0, 0, 15, 1, 0, 0, 68, 14, 0,240, 0, 0, 0, 0, +/* 0x1210 */ 64, 0, 0, 0, 15, 1, 0, 0,142, 15, 0,240, 0, 0, 0, 0, +/* 0x1220 */ 70, 0, 0, 0, 15, 1, 0, 0,122, 15, 0,240, 0, 0, 0, 0, +/* 0x1230 */ 80, 0, 0, 0, 15, 1, 0, 0,126, 15, 0,240, 0, 0, 0, 0, +/* 0x1240 */ 88, 0, 0, 0, 15, 1, 0, 0,138, 15, 0,240, 0, 0, 0, 0, +/* 0x1250 */ 94, 0, 0, 0, 15, 1, 0, 0,130, 15, 0,240, 0, 0, 0, 0, +/* 0x1260 */ 101, 0, 0, 0, 15, 1, 0, 0,146, 15, 0,240, 0, 0, 0, 0, +/* 0x1270 */ 107, 0, 0, 0, 15, 1, 0, 0,253, 8, 0,240, 0, 0, 0, 0, +/* 0x1280 */ 117, 0, 0, 0, 15, 1, 0, 0,114, 15, 0,240, 0, 0, 0, 0, +/* 0x1290 */ 124, 0, 0, 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, +/* 0x12a0 */ 32, 0, 95, 95, 95, 98,122,101,114,111, 0, 95, 95,109,104, 95, +/* 0x12b0 */ 101,120,101, 99,117,116,101, 95,104,101, 97,100,101,114, 0, 95, +/* 0x12c0 */ 98,115,119, 97,112, 0, 95, 98,122,101,114,111, 0, 95, 99,108, +/* 0x12d0 */ 111,115,101, 0, 95,101,120,105,116, 0, 95,109, 97,105,110, 0, +/* 0x12e0 */ 95,109,109, 97,112, 0, 95,109,112,114,111,116,101, 99,116, 0, +/* 0x12f0 */ 95,109,117,110,109, 97,112, 0, 95,111,112,101,110, 0, 95,112, +/* 0x1300 */ 114,101, 97,100, 0, 95,114,101, 97,100, 0, 95,117,112,120, 95, +/* 0x1310 */ 109, 97,105,110, 0, 95,119,114,105,116,101, 0,100,121,108,100, +/* 0x1320 */ 95,115,116,117, 98, 95, 98,105,110,100,101,114, 0, 95,117,110, +/* 0x1330 */ 112, 97, 99,107, 69,120,116,101,110,116, 0, 95,100,111, 95,120, +/* 0x1340 */ 109, 97,112, 0, 95,120,114,101, 97,100, 0, 83, 89, 83, 95,101, +/* 0x1350 */ 120,105,116, 0, 83, 89, 83, 95,114,101, 97,100, 0, 83, 89, 83, +/* 0x1360 */ 95,119,114,105,116,101, 0, 83, 89, 83, 95,111,112,101,110, 0, +/* 0x1370 */ 83, 89, 83, 95, 99,108,111,115,101, 0, 83, 89, 83, 95,109,117, +/* 0x1380 */ 110,109, 97,112, 0, 83, 89, 83, 95,109,112,114,111,116,101, 99, +/* 0x1390 */ 116, 0, 83, 89, 83, 95,112,114,101, 97,100, 0, 83, 89, 83, 95, +/* 0x13a0 */ 109,109, 97,112, 0, 0, 0, 0 }; diff --git a/src/stub/src/amd64-darwin.macho-upxmain.c b/src/stub/src/amd64-darwin.macho-upxmain.c index 3de45d5d..167234f1 100644 --- a/src/stub/src/amd64-darwin.macho-upxmain.c +++ b/src/stub/src/amd64-darwin.macho-upxmain.c @@ -727,17 +727,15 @@ main(int argc, char *argv[]) for (j=0; j < mhdr0->ncmds; ++j, ptr = (Mach_command const *)(ptr->cmdsize + (char const *)ptr)) if (LC_SEGMENT_64==ptr->cmd) { - Mach_segment_command const *const segptr = (Mach_segment_command const *)ptr; - if ((long)0x0000545845545f5ful == *(long const *)segptr->segname) { // "__TEXT" - Mach_section_command const *const secptr = (Mach_section_command const *)(1+ segptr); - //if ((long)0x0000747865745f5ful == *(long const *)secptr->sectname) { // "__text" - f_unf = (f_unfilter *)(sizeof(unsigned short) + secptr->addr); - f_exp = (f_expand *)(*(unsigned short *)secptr->addr + secptr->addr); - //} - } - if ((long)0x415441445f585055ul == *(long const *)segptr->segname) { // "UPX_DATA" - payload = (char *)(segptr->vmaddr); - paysize = segptr->filesize; + Mach_segment_command const *const seg = (Mach_segment_command const *)ptr; + // Compare 8 characters + if (*(long const *)(&"__LINKEDIT"[2]) == *(long const *)(&seg->segname[2])) { + f_unf = (f_unfilter *)(sizeof(unsigned short) + seg->vmaddr); + f_exp = (f_expand *)(*(unsigned short const *)seg->vmaddr + seg->vmaddr); + unsigned const *q = (unsigned const *)seg->vmaddr; + while (!(paysize = *--q)) /*empty*/ ; + payload = (char *)(-paysize + (char const *)q); + break; } } char mhdr[2048]; From 48791a329d138567065c4b924fae35616e232554 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sat, 17 Sep 2016 16:16:41 -0700 Subject: [PATCH 28/29] overlay_offset for decompress changed src/p_mach.cpp --- src/p_mach.cpp | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/p_mach.cpp b/src/p_mach.cpp index 736600fc..449b0e5a 100644 --- a/src/p_mach.cpp +++ b/src/p_mach.cpp @@ -760,10 +760,16 @@ void PackMachAMD64::pack4(OutputFile *fo, Filter &ft) // append PackHeader + sizeof(N_Mach::Mach_function_starts_command) + sizeof(N_Mach::Mach_data_in_code_command) + sizeof(linfo); if (my_filetype==Mach_header::MH_EXECUTE) { - overlay_offset += sizeof(linkitem); + overlay_offset = PAGE_SIZE; // FIXME + overlay_offset += sizeof(linfo); } super::pack4(fo, ft); + if (my_filetype == Mach_header::MH_EXECUTE) { + unsigned long const zero = 0; + unsigned const len = fo->getBytesWritten(); + fo->write(&zero, 7& (0u-len)); + } unsigned const eofcmpr = fo->getBytesWritten(); segTEXT.vmaddr = segZERO.vmaddr + segZERO.vmsize; segTEXT.filesize = eofcmpr; @@ -1312,7 +1318,7 @@ void PackMachI386::pack3(OutputFile *fo, Filter &ft) // append loader void PackMachAMD64::pack3(OutputFile *fo, Filter &ft) // append loader { TE32 disp; - unsigned const zero = 0; + unsigned long const zero = 0; unsigned len = fo->getBytesWritten(); fo->write(&zero, 3& (0u-len)); len += (3& (0u-len)); // 0 mod 4 @@ -1328,6 +1334,8 @@ void PackMachAMD64::pack3(OutputFile *fo, Filter &ft) // append loader threado.state.rip = len + segTEXT.vmaddr; /* entry address */ super::pack3(fo, ft); + len = fo->getBytesWritten(); + fo->write(&zero, 7& (0u-len)); } void PackMachARMEL::pack3(OutputFile *fo, Filter &ft) // append loader From d4e55af2c20757ed21e994b97bc3234036a9de27 Mon Sep 17 00:00:00 2001 From: "jreiser@BitWagon.com" Date: Sat, 17 Sep 2016 16:40:07 -0700 Subject: [PATCH 29/29] Propagate LC_VERSION_MIN_MACOSX and LC_SOURCE_VERSION changed src/p_mach.cpp --- src/p_mach.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/p_mach.cpp b/src/p_mach.cpp index 449b0e5a..e5dda998 100644 --- a/src/p_mach.cpp +++ b/src/p_mach.cpp @@ -971,9 +971,17 @@ omit: goto next; goto done; } break; - case Mach_segment_command::LC_SOURCE_VERSION: { + case Mach_segment_command::LC_SOURCE_VERSION: { // copy from saved original + fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); + fo->rewrite(&cmdSRCVER, sizeof(cmdSRCVER)); + memcpy(ptr1, &cmdSRCVER, sizeof(cmdSRCVER)); goto omit; } break; + case Mach_segment_command::LC_VERSION_MIN_MACOSX: { // copy from saved original + fo->seek(sizeof(segXHDR) + ((char const *)ptr1 - (char const *)ptr0), SEEK_SET); + fo->rewrite(&cmdVERMIN, sizeof(cmdVERMIN)); + memcpy(ptr1, &cmdVERMIN, sizeof(cmdVERMIN)); + } break; } // end switch done: fo->seek(0, SEEK_END);