============================== Sample 1 ============================== ASM: ;************************************************************************************************************************************************************ ;* FUNCTION * ;************************************************************************************************************************************************************ ;undefined hdy_gtk_window_toggle_maximized() PUSH RBP MOV RBP,RDI CALL .plt:::gtk_window_is_maximized ;undefined gtk_window_is_maximized() MOV RDI,RBP TEST EAX,EAX JZ LAB_00114a20 POP RBP JMP .plt:LAB_00111140 ?? 66h f ?? 2Eh . ?? 0Fh ?? 1Fh ?? 84h ?? 00h ?? 00h ?? 00h ?? 00h ?? 00h LAB_00114a20: POP RBP JMP .plt:LAB_00111ce0 ?? 66h f Actual src: void hdy_gtk_window_toggle_maximized (GtkWindow *window) { if (gtk_window_is_maximized (window)) gtk_window_unmaximize (window); else gtk_window_maximize (window); } Predicted src: void gtk_window_is_visible (GtkWidget *widget) { if (gtk_window_is_visible (widget)) gtk_window_is_visible (widget); } ============================== Sample 2 ============================== ASM: ;************************************************************************************************************************************************************ ;* FUNCTION * ;************************************************************************************************************************************************************ ;undefined system_methodSignature() MOV R8,RDI LEA RDX,[.rodata:s_Not_Implemented_Yet_00443306] ;= "Not Implemented Yet" MOV RDI,RSI XOR EAX,EAX MOV RCX,qword ptr [R8] MOV ESI,0x1f4 JMP RCX ?? 0Fh Actual src: static void system_methodSignature(rpc_t* rpc, void* c) { rpc->fault(c, 500, "Not Implemented Yet"); } Predicted src: static int method_method(lua_State *L, PyObject *args, PyObject *kwds) { return mrb_method_method(L, "method", args, 0); } ============================== Sample 3 ============================== ASM: ;************************************************************************************************************************************************************ ;* FUNCTION * ;************************************************************************************************************************************************************ ;undefined e_attachment_bar_interface_init() LEA RAX,[attachment_bar_get_private] MOV qword ptr [RDI + 0x10],RAX=>attachment_bar_get_private LEA RAX,[attachment_bar_get_store] MOV qword ptr [RDI + 0x18],RAX=>attachment_bar_get_store LEA RAX,[attachment_bar_get_path_at_pos] MOV qword ptr [RDI + 0x20],RAX=>attachment_bar_get_path_at_pos LEA RAX,[attachment_bar_get_selected_paths] MOV qword ptr [RDI + 0x28],RAX=>attachment_bar_get_selected_paths LEA RAX,[attachment_bar_path_is_selected] MOV qword ptr [RDI + 0x30],RAX=>attachment_bar_path_is_selected LEA RAX,[attachment_bar_select_path] MOV qword ptr [RDI + 0x38],RAX=>attachment_bar_select_path LEA RAX,[attachment_bar_unselect_path] MOV qword ptr [RDI + 0x40],RAX=>attachment_bar_unselect_path LEA RAX,[attachment_bar_select_all] MOV qword ptr [RDI + 0x48],RAX=>attachment_bar_select_all LEA RAX,[attachment_bar_unselect_all] MOV qword ptr [RDI + 0x50],RAX=>attachment_bar_unselect_all LEA RAX,[attachment_bar_update_actions] MOV qword ptr [RDI + 0x78],RAX=>attachment_bar_update_actions RET ?? 90h Actual src: static void e_attachment_bar_interface_init (EAttachmentViewInterface *iface) { iface->get_private = attachment_bar_get_private; iface->get_store = attachment_bar_get_store; iface->get_path_at_pos = attachment_bar_get_path_at_pos; iface->get_selected_paths = attachment_bar_get_selected_paths; iface->path_is_selected = attachment_bar_path_is_selected; iface->select_path = attachment_bar_select_path; iface->unselect_path = attachment_bar_unselect_path; iface->select_all = attachment_bar_select_all; iface->unselect_all = attachment_bar_unselect_all; iface->update_actions = attachment_bar_update_actions; } Predicted src: static void e_mail_bar_store_iface_init (ETreeStoreIface *iface) { iface->get_selected = e_mail_bar_store_get_selected; iface->get_selected = e_mail_bar_store_get_selected; iface->get_selected = e_mail_bar_store_get_selected; iface->get_selected = e_mail_bar_store_get_selected; iface->get_selected = e_mail_bar_store_get_selected; iface->get_selected = e_mail_bar_store_get_selected; iface->get_selected = e_mail_bar_store_get_selected; } ============================== Sample 4 ============================== ASM: ;************************************************************************************************************************************************************ ;* FUNCTION * ;************************************************************************************************************************************************************ ;undefined norm0() MOVSD XMM0,qword ptr [.rodata:DAT_00102008] DIVSD XMM0,qword ptr [RDI] MOVSD qword ptr [RSI],XMM0 TEST EDX,EDX JLE LAB_001013a6 MOVSXD RDX,EDX JMP LAB_00101394 ?? 0Fh ?? 1Fh ?? 80h ?? 00h ?? 00h ?? 00h ?? 00h LAB_00101390: MOVSD XMM0,qword ptr [RSI] LAB_00101394: MULSD XMM0,qword ptr [RDI + RDX*0x8] MOVSD qword ptr [RSI + RDX*0x8],XMM0 SUB RDX,0x1 TEST EDX,EDX JG LAB_00101390 LAB_001013a6: RET ?? 66h f Actual src: void norm0(double *x, double *y, int m) { y[0] = 1 / x[0]; for (; m >= 1; m--) y[m] = x[m] * y[0]; return; } Predicted src: static void r(double *a, double *b, int n) { int i; for (i = 0; i < n; i++) a[i] = b[i]; } ============================== Sample 5 ============================== ASM: ;************************************************************************************************************************************************************ ;* FUNCTION * ;************************************************************************************************************************************************************ ;undefined check_build() PUSH R12 MOV R12,RSI PUSH RBP MOV RBP,RDI MOV RDI,RSI PUSH RBX CALL .plt:::strlen ;size_t strlen(char * __s) MOV RDI,RBP MOV RBX,RAX CALL .plt:::lax_json_eof ;undefined lax_json_eof() TEST EAX,EAX JNZ LAB_0010136e CMP dword ptr [.bss:out_buf_index],EBX JNZ LAB_001013c6 MOVSXD RDX,EBX LEA RBX,[.bss:out_buf] MOV RDI,R12 MOV RSI=>.bss:out_buf,RBX CALL .plt:::memcmp ;int memcmp(void * __s1, void * __s2,... TEST EAX,EAX JNZ LAB_0010139c POP RBX MOV RDI,RBP POP RBP POP R12 JMP .plt:LAB_00101070 LAB_0010136e: MOV EDI,EAX CALL .plt:::lax_json_str_err ;undefined lax_json_str_err() MOV RDI,qword ptr [.bss:stderr] MOV ESI,0x1 LEA RDX,[.rodata:s_%s_00103020+22] ;= "%s\n" MOV RCX,RAX XOR EAX,EAX CALL .plt:::__fprintf_chk ;undefined __fprintf_chk() MOV EDI,0x1 CALL .plt:::exit ;void exit(int __status) LAB_0010139c: MOV R8=>.bss:out_buf,RBX MOV RCX,R12 LEA RDX,[.rodata:s_EXPECTED:_---------_%s_RECEIVED:_00103288] ;= "EXPECTED:\n---------\n%s\nRECEIVE... LAB_001013a9: MOV RDI,qword ptr [.bss:stderr] MOV ESI,0x1 XOR EAX,EAX CALL .plt:::__fprintf_chk ;undefined __fprintf_chk() MOV EDI,0x1 CALL .plt:::exit ;void exit(int __status) LAB_001013c6: LEA R8,[.bss:out_buf] MOV RCX,R12 LEA RDX,[.rodata:s__EXPECTED:_---------_%s_RECEIVED_00103258] ;= "\nEXPECTED:\n---------\n%s\nRECEI... JMP LAB_001013a9 ?? 0Fh Actual src: static void check_build(struct LaxJsonContext *context, const char *output) { int expected_len = strlen(output); enum LaxJsonError err = lax_json_eof(context); if (err!= LaxJsonErrorNone) { fprintf(stderr, "%s\n", lax_json_str_err(err)); exit(1); } if (out_buf_index!= expected_len) { fprintf(stderr, "\n" "EXPECTED:\n" "---------\n" "%s\n" "RECEIVED:\n" "---------\n" "%s\n", output, out_buf); exit(1); } if (memcmp(output, out_buf, expected_len)!= 0) { fprintf(stderr, "EXPECTED:\n" "---------\n" "%s\n" "RECEIVED:\n" "---------\n" "%s\n", output, out_buf); exit(1); } lax_json_destroy(context); } Predicted src: static void str_out(int argc, char **argv) { char *s; int len; len = strlen(argv); len = strlen(s); if (len < 0) { fprintf(stderr, "%s: %s\n", s, len); exit(1); } else { fprintf(stderr, "%s\n", s); exit(1); } }