From bde03ac313ade2bbdcdbf3575a464db42397348a Mon Sep 17 00:00:00 2001 From: _xeroxz Date: Sat, 12 Jun 2021 21:47:10 -0700 Subject: [PATCH] updated deps, also made vtil lifting work even if all handlers/profiles arent defined... --- dependencies/vmprofiler | 2 +- src/main.cpp | 22 ++++++++-------------- 2 files changed, 9 insertions(+), 15 deletions(-) diff --git a/dependencies/vmprofiler b/dependencies/vmprofiler index 87acc28..e75104f 160000 --- a/dependencies/vmprofiler +++ b/dependencies/vmprofiler @@ -1 +1 @@ -Subproject commit 87acc2837b696d37a85663277be3a0ff726d4c31 +Subproject commit e75104fbb3b07540be51fcef169e9eaffd1cfee2 diff --git a/src/main.cpp b/src/main.cpp index 624393c..9a0c86d 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -212,14 +212,10 @@ int __cdecl main( int argc, const char *argv[] ) auto vinstr = &code_block->vinstr[ idx ]; if ( vinstr->mnemonic_t == vm::handler::INVALID ) { - std::printf( - "> unable to lift to VTIL... unknown virtual instruction handler #%d... " - "please define a vm handler profile for this virtual instruction and try again..." - " you can also create your first contribution to this open source project by submitting" - " a merge request with your changes! :)\n", - vinstr->opcode ); - - return -1; + std::printf( "[WARNING] vm handler #%d is not implimented, the VTIL output may be incorrect!\n", + vinstr->opcode ); + rtn->nop(); + continue; } const auto result = std::find_if( @@ -229,17 +225,15 @@ int __cdecl main( int argc, const char *argv[] ) if ( result == vm::lifters::all.end() ) { std::printf( - "> unable to lift to VTIL... unknown virtual instruction handler lifter for #%d... " - "please define a vm handler lifter for this vm handler and try again..." - " you can also create your first contribution to this open source project by submitting" - " a merge request with your changes! :)\n", + "[WARNING] vm handler #%d lifter is not implimented, the VTIL output may be incorrect!\n", vinstr->opcode ); - return -1; + rtn->nop(); + continue; } // lift the virtual instruction... - ( *result )->second( rtn, vinstr ); + ( *result )->second( rtn, vinstr, code_block ); } }