joyce8/EMBER2024-capa huggingface dataset:
Function at 0x407190
Capabilities:
Write file on windows

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x447fa2
push eax
mov dword fs:[0], esp
push ebp
push esi
mov esi, dword [esp + 0x18]
test esi, esi
push edi
mov edi, ecx
je 0x40725a
push esi
call fcn.00406eb0
test al, al
je 0x40725a
mov ebp, dword [sym.imp.MSVCR71.dll_fclose]
push esi
call ebp
mov eax, dword [esp + 0x24]
add esp, 4
push eax
lea ecx, [esp + 0x20]
call dword [sym.imp.MFC71.DLL_ATL::CStringT::CStringT_2]
push 0x2e
lea ecx, [esp + 0x20]
mov dword [esp + 0x18], 0
call dword [sym.imp.MFC71.DLL_ATL::CStringT::ReverseFind]
push eax
lea ecx, [esp + 0x24]
push ecx
lea ecx, [esp + 0x24]
call dword [sym.imp.MFC71.DLL_ATL::CStringT::Left]
push eax
lea ecx, [esp + 0x20]
mov byte [esp + 0x18], 1
call dword [sym.imp.MFC71.DLL_ATL::CStringT::operator]
lea ecx, [esp + 0x20]
mov byte [esp + 0x14], 0
call dword [0x45017c]
push 0x450e14
lea ecx, [esp + 0x20]
call dword [0x4501a0]
push 0x450c30
lea ecx, [esp + 0x20]
call dword [sym.imp.MFC71.DLL_ATL::CSimpleStringT::operator_char_const_]
push eax
call dword [sym.imp.MSVCR71.dll_fopen]
mov esi, eax
add esp, 8
test esi, esi
jne 0x407270
lea ecx, [esp + 0x1c]
call dword [0x45017c]
xor al, al
mov ecx, dword [esp + 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebp
add esp, 0xc
ret 8
mov edx, dword [edi + 4]
mov eax, dword [edi]
push esi
push edx
push 1
push eax
call dword [sym.imp.MSVCR71.dll_fwrite]
push esi
call ebp
add esp, 0x14
lea ecx, [esp + 0x1c]
call dword [0x45017c]
mov ecx, dword [esp + 0xc]
pop edi
pop esi
mov al, 1
mov dword fs:[0], ecx
pop ebp
add esp, 0xc
ret 8

Function at 0x407740
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x448019
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x1c
mov eax, dword [esp + 0x2c]
push esi
mov esi, ecx
push eax
lea ecx, [esp + 8]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_char_const__]
push eax
lea ecx, [esp + 0x34]
push ecx
lea ecx, [esi + 8]
mov dword [esp + 0x30], 0
call fcn.004076a0
lea ecx, [esp + 4]
mov dword [esp + 0x28], 0xffffffff
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
mov ecx, dword [esi + 0xc]
mov eax, dword [esp + 0x30]
cmp ecx, eax
pop esi
je 0x4077b2
mov eax, dword [eax + 0x28]
mov ecx, dword [esp + 0x1c]
mov dword fs:[0], ecx
add esp, 0x28
ret 4
mov ecx, dword [esp + 0x1c]
xor eax, eax
mov dword fs:[0], ecx
add esp, 0x28
ret 4
Function at 0x407a60
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x4480d3
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x66c
push edi
mov edi, ecx
lea ecx, [esp + 4]
call dword [sym.imp.MFC71.DLL_ATL::CStringT::CStringT]
push str..bin
lea eax, [esp + 8]
push eax
lea ecx, [edi + 4]
push 0x450e14
push ecx
mov dword [esp + 0x688], 0
call fcn.0040e930
add esp, 0x10
lea ecx, [esp + 8]
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_void_]
mov byte [esp + 0x678], 1
call fcn.004099c0
push eax
lea ecx, [esp + 0xc]
call dword [0x450374]
lea ecx, [esp + 4]
call dword [sym.imp.MFC71.DLL_ATL::CSimpleStringT::GetString]
push eax
lea ecx, [esp + 0xc]
call dword [0x450374]
lea ecx, [esp + 0x24]
call fcn.0040f2d0
push 0x200
push str.AnimContainer
lea ecx, [esp + 0x2c]
mov byte [esp + 0x680], 2
call fcn.0040f310
push 0
lea ecx, [esp + 0xc]
call dword [sym.imp.MSVCP71.dll_public:_char_const____thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::c_str_void_const]
push eax
push 1
lea ecx, [esp + 0x30]
call fcn.0040f3b0
test eax, eax
lea ecx, [esp + 0x24]
jne 0x407b6d
mov byte [esp + 0x678], 1
call fcn.0040f090
lea ecx, [esp + 8]
mov byte [esp + 0x678], 0
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
lea ecx, [esp + 4]
call dword [0x45017c]
mov eax, 0x80004005
pop edi
mov ecx, dword [esp + 0x66c]
mov dword fs:[0], ecx
add esp, 0x678
ret
mov eax, dword [edi + 0x350]
mov edx, dword [esp + 0x24]
push ebp
push esi
push eax
mov dword [esp + 0x3c], 0x13
call dword [edx + 0x68]
mov ebp, dword [edi + 0x34c]
mov esi, dword [ebp]
cmp esi, ebp
je 0x407ba5
mov ecx, dword [esi + 8]
lea eax, [esp + 0x2c]
push eax
call fcn.00407970
mov esi, dword [esi]
cmp esi, ebp
jne 0x407b92
mov eax, dword [edi + 0x344]
mov edx, dword [esp + 0x2c]
push eax
lea ecx, [esp + 0x30]
call dword [edx + 0x68]
mov edi, dword [edi + 0x340]
mov esi, dword [edi]
cmp esi, edi
je 0x407bd6
mov ecx, dword [esi + 8]
lea eax, [esp + 0x2c]
push eax
call fcn.00407970
mov esi, dword [esi]
cmp esi, edi
jne 0x407bc3
lea ecx, [esp + 0x2c]
mov byte [esp + 0x680], 1
call fcn.0040f090
lea ecx, [esp + 0x10]
mov byte [esp + 0x680], 0
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
lea ecx, [esp + 0xc]
call dword [0x45017c]
mov ecx, dword [esp + 0x678]
pop esi
pop ebp
xor eax, eax
pop edi
mov dword fs:[0], ecx
add esp, 0x678
ret
Function at 0x40e250
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x449868
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
mov ecx, dword [esp + 0x30]
test ecx, ecx
mov dword [esp + 0xc], 0
je 0x40e2b6
mov eax, dword [ecx + 4]
mov edx, dword [eax]
push esi
push edi
lea esi, [ecx + 4]
push eax
push edx
lea eax, [esp + 0x10]
push eax
mov edi, ecx
call fcn.0040dd80
mov eax, dword [esi]
push eax
call sub.MFC71.DLL_operator_delete_1
push edi
mov dword [esi], 0
mov dword [edi + 8], 0
call sub.MFC71.DLL_operator_delete_1
add esp, 8
pop edi
mov dword [esp + 0x34], 0
pop esi
lea ecx, [esp + 0x14]
mov dword [esp + 0xc], 0xffffffff
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
mov ecx, dword [esp + 4]
mov dword fs:[0], ecx
add esp, 0x10
ret 0x20

Function at 0x40f850
Capabilities:
Hash data using sha256

Disassembly:
mov eax, ecx
xor ecx, ecx
mov dword [eax], 0x6a09e667
mov dword [eax + 4], 0xbb67ae85
mov dword [eax + 8], 0x3c6ef372
mov dword [eax + 0xc], 0xa54ff53a
mov dword [eax + 0x10], 0x510e527f
mov dword [eax + 0x14], 0x9b05688c
mov dword [eax + 0x18], 0x1f83d9ab
mov dword [eax + 0x1c], 0x5be0cd19
mov dword [eax + 0x20], ecx
mov dword [eax + 0x24], ecx
ret
Function at 0x413040
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x449a5e
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
push ebp
push esi
mov esi, ecx
push edi
xor edi, edi
lea ebp, [esi + 0x1174]
mov ecx, ebp
mov dword [esp + 0xc], esi
mov dword [esi], 0x456718
mov dword [esi + 4], edi
mov dword [esi + 8], edi
mov dword [esi + 0xc], edi
mov dword [esi + 0x10], edi
mov dword [esi + 0x14], edi
mov dword [esi + 0x18], edi
mov dword [esi + 0x1c], edi
mov dword [esi + 0x20], 6
mov dword [esi + 0x24], 0x16
mov dword [esi + 0x40], edi
mov dword [esi + 0x44], edi
mov dword [esi + 0x48], edi
mov dword [esi + 0x4c], edi
mov dword [esi + 0x50], edi
mov dword [esi + 0x54], edi
mov dword [esi + 0x58], edi
mov dword [esi + 0x5c], edi
mov dword [esi + 0x60], edi
mov dword [esi + 0x64], edi
mov dword [esi + 0x68], edi
call fcn.00412b90
mov dword [ebp + 4], eax
mov byte [eax + 0xe], 1
mov eax, dword [ebp + 4]
mov dword [eax + 4], eax
mov eax, dword [ebp + 4]
mov dword [eax], eax
mov eax, dword [ebp + 4]
mov dword [eax + 8], eax
mov dword [ebp + 8], edi
lea ebp, [esi + 0x1198]
mov ecx, ebp
mov dword [esp + 0x18], edi
call fcn.00412b90
mov dword [ebp + 4], eax
mov ecx, dword [esp + 0x10]
mov byte [eax + 0xe], 1
mov eax, dword [ebp + 4]
mov dword [eax + 4], eax
mov eax, dword [ebp + 4]
mov dword [eax], eax
mov eax, dword [ebp + 4]
mov dword [eax + 8], eax
mov dword [ebp + 8], edi
mov dword [esi + 0x11c8], edi
mov dword [esi + 0x11cc], edi
mov dword [esi + 0x11d0], edi
mov dword [esi + 0x28], edi
mov dword [esi + 0x2c], edi
mov dword [esi + 0x30], edi
mov dword [esi + 0x34], edi
mov dword [esi + 0x38], edi
mov dword [esi + 0x3c], edi
pop edi
mov eax, esi
pop esi
pop ebp
mov dword fs:[0], ecx
add esp, 0x10
ret
Function at 0x41f8f0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x449dd9
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x1c
push esi
push edi
push 0x8b10b0
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov esi, dword [esp + 0x34]
mov edx, dword [esi + 0x44]
mov eax, dword [esp + 0x38]
mov edi, dword [esi + 0x48]
inc edx
push eax
lea ecx, [esp + 0xc]
mov dword [esi + 0x44], edx
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_char_const__]
lea ecx, [esp + 8]
push ecx
mov ecx, 0x8b11f8
mov dword [esp + 0x30], 0
call fcn.0041f5b0
lea ecx, [esp + 8]
mov dword [eax], esi
mov dword [esp + 0x2c], 0xffffffff
call dword [sym.imp.MSVCP71.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
push 0x8b10b0
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov ecx, dword [esp + 0x24]
mov eax, edi
pop edi
pop esi
mov dword fs:[0], ecx
add esp, 0x28
ret
Function at 0x420c80
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x449e99
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
push esi
mov esi, dword [esp + 0x1c]
push edi
xor edi, edi
mov ecx, esi
mov dword [esp + 8], edi
call dword [sym.imp.MFC71.DLL_ATL::CSimpleStringT::GetManager]
push eax
lea ecx, [esp + 0xc]
call dword [sym.imp.MFC71.DLL_ATL::CStringT::CStringT_3]
mov dword [esp + 0x14], edi
mov edi, dword [esp + 0x24]
push edi
call dword [sym.imp.MFC71.DLL_ATL::CSimpleStringT::StringLength]
add esp, 4
push eax
push edi
mov ecx, esi
call dword [sym.imp.MFC71.DLL_ATL::CSimpleStringT::GetLength]
push eax
mov ecx, esi
call dword [sym.imp.MFC71.DLL_ATL::CSimpleStringT::operator_char_const_]
push eax
lea eax, [esp + 0x18]
push eax
call dword [sym.imp.MFC71.DLL_ATL::CSimpleStringT::Concatenate]
mov esi, dword [esp + 0x30]
add esp, 0x14
lea ecx, [esp + 8]
push ecx
mov ecx, esi
call dword [sym.imp.MFC71.DLL_ATL::CStringT::CStringT_1]
lea ecx, [esp + 8]
call dword [0x45017c]
mov ecx, dword [esp + 0xc]
pop edi
mov eax, esi
pop esi
mov dword fs:[0], ecx
add esp, 0x10
ret
Function at 0x426b90
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov eax, dword [esp + 0xc]
sub esp, 0x48
cmp eax, 1
push ebx
push ebp
mov ebx, ecx
push esi
push edi
mov dword [ebx + 0x7c], eax
mov dword [ebx + 0x80], 0
jne 0x426d12
mov edi, dword [esp + 0x5c]
test edi, edi
jne 0x426bca
pop edi
pop esi
pop ebp
mov eax, 0x80070057
pop ebx
add esp, 0x48
ret 0xc
mov eax, dword [ebx]
test eax, eax
je 0x426bdf
push eax
call sub.MFC71.DLL_operator_delete
add esp, 4
mov dword [ebx], 0
mov esi, dword [sym.imp.WINMM.dll_mmioOpenA]
push 0
push 0
push edi
call esi
test eax, eax
mov dword [ebx + 4], eax
je 0x426d2b
push 0
push eax
call dword [sym.imp.WINMM.dll_mmioClose]
push 0x10000
push 0
push edi
call esi
test eax, eax
mov dword [ebx + 4], eax
jne 0x426cd2
mov ebp, dword [sym.imp.KERNEL32.dll_FindResourceA]
push str.WAVE
push edi
push eax
call ebp
mov esi, eax
test esi, esi
jne 0x426c3d
push 0x4580a4
push edi
push eax
call ebp
mov esi, eax
test esi, esi
je 0x426d2b
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov edi, eax
test edi, edi
je 0x426d2b
push esi
push 0
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ebp, eax
test ebp, ebp
je 0x426d2b
push edi
call dword [sym.imp.KERNEL32.dll_LockResource]
mov esi, eax
test esi, esi
je 0x426d2b
push ebp
call sub.MFC71.DLL_operator_new_1
mov dword [ebx + 0x90], eax
mov edi, eax
mov ecx, ebp
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
add esp, 4
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea eax, [esp + 0x10]
mov ecx, 0x48
mov edi, edi
mov byte [eax], 0
inc eax
dec ecx
jne 0x426ca0
mov ecx, dword [ebx + 0x90]
push 0x10000
lea edx, [esp + 0x14]
push edx
push 0
mov dword [esp + 0x20], 0x204d454d
mov dword [esp + 0x30], ebp
mov dword [esp + 0x34], ecx
call dword [sym.imp.WINMM.dll_mmioOpenA]
mov dword [ebx + 4], eax
mov ecx, ebx
call fcn.00426370
mov esi, eax
test esi, esi
jge 0x426cf7
mov eax, dword [ebx + 4]
push 0
push eax
call dword [sym.imp.WINMM.dll_mmioClose]
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x48
ret 0xc
mov ecx, ebx
call fcn.004264f0
test eax, eax
jl 0x426d6b
mov ecx, dword [ebx + 0xc]
pop edi
pop esi
pop ebp
mov dword [ebx + 0x30], ecx
pop ebx
add esp, 0x48
ret 0xc
mov edx, dword [esp + 0x5c]
push 0x11002
push 0
push edx
call dword [sym.imp.WINMM.dll_mmioOpenA]
test eax, eax
mov dword [ebx + 4], eax
jne 0x426d3a
pop edi
pop esi
pop ebp
mov eax, 0x80004005
pop ebx
add esp, 0x48
ret 0xc
mov eax, dword [esp + 0x60]
push eax
mov ecx, ebx
call fcn.00426820
mov esi, eax
test esi, esi
jge 0x426d64
mov ecx, dword [ebx + 4]
push 0
push ecx
call dword [sym.imp.WINMM.dll_mmioClose]
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x48
ret 0xc
mov ecx, ebx
call fcn.004264f0
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x48
ret 0xc
Function at 0x44409d
Capabilities:
Parse pe header
Terminate process

Disassembly:
push 0x74
push 0x470840
call fcn.004446b0
xor ebx, ebx
mov dword [ebp - 0x20], ebx
push ebx
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
call edi
cmp word [eax], 0x5a4d
jne 0x4440dd
mov ecx, dword [eax + 0x3c]
add ecx, eax
cmp dword [ecx], 0x4550
jne 0x4440dd
movzx eax, word [ecx + 0x18]
cmp eax, 0x10b
je 0x4440f5
cmp eax, 0x20b
je 0x4440e2
mov dword [ebp - 0x1c], ebx
jmp 0x444109
cmp dword [ecx + 0x84], 0xe
jbe 0x4440dd
xor eax, eax
cmp dword [ecx + 0xf8], ebx
jmp 0x444103
cmp dword [ecx + 0x74], 0xe
jbe 0x4440dd
xor eax, eax
cmp dword [ecx + 0xe8], ebx
setne al
mov dword [ebp - 0x1c], eax
mov dword [ebp - 4], ebx
push 2
call dword [sym.imp.MSVCR71.dll___set_app_type]
pop ecx
or dword [0x1f4b2ec], 0xffffffff
or dword [0x1f4b2f0], 0xffffffff
call dword [sym.imp.MSVCR71.dll___p__fmode]
mov ecx, dword [0x1f4aea0]
mov dword [eax], ecx
call dword [sym.imp.MSVCR71.dll___p__commode]
mov ecx, dword [0x1f4ae9c]
mov dword [eax], ecx
mov eax, dword [sym.imp.MSVCR71.dll__adjust_fdiv]
mov eax, dword [eax]
mov dword [0x1f4b2e8], eax
call fcn.004447ae
call fcn.0044484e
cmp dword [0x4a6990], ebx
jne 0x444169
push fcn.0044484e
call dword [sym.imp.MSVCR71.dll___setusermatherr]
pop ecx
call fcn.0044483c
push 0x477488
push 0x477484
call sub.MSVCR71.dll__initterm
push 0x4447f2
call fcn.00443f25
mov eax, dword [0x1f4ae98]
mov dword [ebp - 0x28], eax
lea eax, [ebp - 0x28]
push eax
push dword [0x1f4ae94]
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x34]
push eax
lea eax, [ebp - 0x38]
push eax
call dword [sym.imp.MSVCR71.dll___getmainargs]
add esp, 0x20
mov dword [ebp - 0x3c], eax
cmp eax, ebx
jge 0x4441bd
push 8
call sub.MSVCR71.dll__amsg_exit
pop ecx
push 0x477480
push section..data
call sub.MSVCR71.dll__initterm
pop ecx
pop ecx
mov eax, dword [sym.imp.MSVCR71.dll__acmdln]
mov esi, dword [eax]
mov dword [ebp - 0x24], esi
mov al, byte [esi]
cmp al, 0x20
ja 0x44423b
cmp al, bl
je 0x4441e7
cmp dword [ebp - 0x20], ebx
jne 0x44423b
mov al, byte [esi]
cmp al, bl
je 0x4441f7
cmp al, 0x20
ja 0x4441f7
inc esi
mov dword [ebp - 0x24], esi
jmp 0x4441e7
mov dword [ebp - 0x58], ebx
lea eax, [ebp - 0x84]
push eax
call dword [sym.imp.KERNEL32.dll_GetStartupInfoA]
test byte [ebp - 0x58], 1
je 0x444213
movzx eax, word [ebp - 0x54]
jmp 0x444216
push 0xa
pop eax
push eax
push esi
push ebx
push ebx
call edi
push eax
call fcn.00447661
mov esi, eax
mov dword [ebp - 0x40], esi
cmp dword [ebp - 0x1c], ebx
jne 0x444233
push esi
call dword [sym.imp.MSVCR71.dll_exit]
call dword [sym.imp.MSVCR71.dll__cexit]
jmp 0x444290
cmp al, 0x22
jne 0x44424a
xor ecx, ecx
cmp dword [ebp - 0x20], ebx
sete cl
mov dword [ebp - 0x20], ecx
movzx eax, al
push eax
call dword [sym.imp.MSVCR71.dll__ismbblead]
pop ecx
test eax, eax
je 0x44425d
inc esi
mov dword [ebp - 0x24], esi
inc esi
jmp 0x4441d5
or dword [ebp - 4], 0xffffffff
mov eax, esi
call fcn.004446eb
ret
Function at 0x46a4cc
Capabilities:
Decompress data using aplib

Disassembly:
push ebp
mov ebp, esp
mov esi, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
cld
mov dl, 0x80
movsb byte es:[edi], byte [esi]
call fcn.0046a54b
jae 0x46a4d8
xor ecx, ecx
call fcn.0046a54b
jae 0x46a502
xor eax, eax
call fcn.0046a54b
jae 0x46a513
mov al, 0x10
call fcn.0046a54b
adc al, al
jae 0x46a4f4
jne 0x46a540
stosb byte es:[edi], al
jmp 0x46a4d9
call fcn.0046a557
dec ecx
loop 0x46a51f
mov eax, ebp
call fcn.0046a555
jmp 0x46a541
lodsb al, byte [esi]
shr eax, 1
je 0x46a567
adc ecx, 2
mov ebp, eax
jmp 0x46a541
xchg ecx, eax
dec eax
shl eax, 8
lodsb al, byte [esi]
mov ebp, eax
call fcn.0046a555
cmp eax, 0x7d00
jae 0x46a53f
cmp eax, 0x500
jae 0x46a540
cmp eax, 0x7f
ja 0x46a541
inc ecx
inc ecx
push esi
mov esi, edi
sub esi, eax
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x46a4d9
pop ebp
ret 8

Function at 0x4bf4bf
Capabilities:
Decompress data using aplib

Disassembly:
push ebp
mov ebp, esp
mov esi, dword [ebp + 8]
mov edi, dword [ebp + 0xc]
cld
mov dl, 0x80
movsb byte es:[edi], byte [esi]
call fcn.004bf53e
jae 0x4bf4cb
xor ecx, ecx
call fcn.004bf53e
jae 0x4bf4f5
xor eax, eax
call fcn.004bf53e
jae 0x4bf506
mov al, 0x10
call fcn.004bf53e
adc al, al
jae 0x4bf4e7
jne 0x4bf533
stosb byte es:[edi], al
jmp 0x4bf4cc
call fcn.004bf54a
dec ecx
loop 0x4bf512
mov eax, ebp
call fcn.004bf548
jmp 0x4bf534
lodsb al, byte [esi]
shr eax, 1
je 0x4bf55a
adc ecx, 2
mov ebp, eax
jmp 0x4bf534
xchg ecx, eax
dec eax
shl eax, 8
lodsb al, byte [esi]
mov ebp, eax
call fcn.004bf548
cmp eax, 0x7d00
jae 0x4bf532
cmp eax, 0x500
jae 0x4bf533
cmp eax, 0x7f
ja 0x4bf534
inc ecx
inc ecx
push esi
mov esi, edi
sub esi, eax
rep movsb byte es:[edi], byte [esi]
pop esi
jmp 0x4bf4cc
pop ebp
ret 8
Function at 0x402dc0
Capabilities:
Create thread

Disassembly:
sub esp, 0x10
push ebx
push ebp
push esi
mov esi, dword [esp + 0x20]
push edi
push esi
call dword [sym.imp.lua54.dll_lua_gettop]
mov ebx, dword [esp + 0x30]
add esp, 4
mov ebp, dword [sym.imp.lua54.dll_lua_tolwstring]
cmp eax, 1
jle 0x402df2
push 0
push 2
push esi
call ebp
add esp, 0xc
mov edi, eax
jmp 0x402df4
mov edi, ebx
push 0
push 1
push esi
call dword [sym.imp.lua54.dll_luaL_tolstring]
push 0
push 0xffffffffffffffff
push esi
call ebp
add esp, 0x18
mov dword [esp + 0x2c], 0
mov ebp, eax
lea eax, [esp + 0x2c]
push eax
push 0x402ed0
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
call dword [sym.imp.USER32.dll_EnumThreadWindows]
push 0
push 0
push 0x7f
push dword [esp + 0x38]
call dword [sym.imp.USER32.dll_SendMessageA]
mov dword [0x41cdc0], eax
test eax, eax
jne 0x402e58
push 0x65
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.USER32.dll_LoadIconA]
mov dword [0x41cdc0], eax
mov eax, dword [esp + 0x28]
push 0xffffffffffffffff
push 0
or eax, 0x1000
mov dword [esp + 0x1c], edi
push 0
mov dword [esp + 0x24], eax
lea eax, [esp + 0x1c]
push eax
push 0x402800
push 0
push 0
mov dword [esp + 0x2c], ebp
call dword [sym.imp.KERNEL32.dll_CreateThread]
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp edi, ebx
mov ebx, dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
je 0x402e9e
push edi
call ebx
add esp, 4
push ebp
call ebx
mov eax, dword [esp + 0x20]
push dword [eax*4 + 0x41c018]
push esi
call dword [sym.imp.lua54.dll_lua_pushstring]
add esp, 0xc
mov eax, 1
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10
ret

Function at 0x403320
Capabilities:
Create thread

Disassembly:
sub esp, 0x14
lea eax, [esp]
mov dword [esp], 0
push eax
push 0x402ed0
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
call dword [sym.imp.USER32.dll_EnumThreadWindows]
push 0
push 0
push 0x7f
push dword [esp + 0xc]
call dword [sym.imp.USER32.dll_SendMessageA]
mov dword [0x41cdc0], eax
test eax, eax
jne 0x40336e
push 0x65
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.USER32.dll_LoadIconA]
mov dword [0x41cdc0], eax
mov eax, dword [esp + 0x18]
mov dword [esp + 8], eax
mov eax, dword [esp + 0x20]
push 0xffffffffffffffff
or eax, 0x1000
push 0
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x24]
push 0
mov dword [esp + 0x10], eax
lea eax, [esp + 0x10]
push eax
push 0x402800
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
mov eax, dword [esp + 0x10]
add esp, 0x14
ret
Function at 0x406930
Capabilities:
Get graphical window text

Disassembly:
push ebp
push esi
push edi
push dword [esp + 0x14]
call dword [sym.imp.USER32.dll_GetWindowTextLengthW]
mov ebp, eax
lea esi, [ebp*2]
lea ecx, [esi + 2]
push ecx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
add esp, 4
lea ecx, [ebp + 1]
mov edi, eax
push ecx
push edi
push dword [esp + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextW]
push esi
push edi
push dword [esp + 0x18]
call dword [sym.imp.lua54.dll_lua_pushlstring]
push edi
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 0x10
mov eax, ebp
pop edi
pop esi
pop ebp
ret
Function at 0x4092b0
Capabilities:
Get file attributes
Get file system object information

Disassembly:
sub esp, 0x2c0
mov eax, dword [0x41caf8]
xor eax, esp
mov dword [esp + 0x2bc], eax
push ebx
push edi
mov edi, dword [esp + 0x2cc]
push 0
mov dword [esp + 0xc], 0
mov dword [esp + 0x10], 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push 0x2b4
mov ebx, eax
lea eax, [esp + 0x14]
push 0
push eax
call sub.VCRUNTIME140.dll_memset
push edi
call dword [sym.imp.lua54.dll_lua_gettop]
add esp, 0x10
cmp eax, 1
jle 0x409459
push 2
push edi
call dword [sym.imp.lua54.dll_lua_type]
add esp, 8
test eax, eax
je 0x409459
push esi
cmp eax, 5
jne 0x4093a2
lea eax, [esp + 0x10]
push eax
push 2
push edi
call dword [sym.imp.lua54.dll_lua_tocinstance]
mov ecx, dword [sym.imp.lua54.dll_TBuffer]
add esp, 0xc
mov esi, dword [esp + 0x10]
mov edx, eax
cmp esi, dword [ecx]
jne 0x409377
push 0
push 0x10
push 0x10
push 0x30000
push 1
push dword [edx + 4]
push dword [edx + 8]
call dword [sym.imp.USER32.dll_CreateIconFromResourceEx]
pop esi
pop edi
pop ebx
mov ecx, dword [esp + 0x2bc]
xor ecx, esp
call fcn.00414d65
add esp, 0x2c0
ret
mov eax, dword [sym.imp.lua54.dll_TWidget]
cmp esi, dword [eax]
jne 0x4093a2
push dword [edx + 0x30]
push ebx
call dword [sym.imp.SHELL32.dll_DuplicateIcon]
pop esi
pop edi
pop ebx
mov ecx, dword [esp + 0x2bc]
xor ecx, esp
call fcn.00414d65
add esp, 0x2c0
ret
push 2
push edi
call dword [sym.imp.lua54.dll_luaL_checkFilename]
mov esi, eax
add esp, 8
mov edx, esi
lea eax, [edx + 2]
mov cx, word [edx]
add edx, 2
test cx, cx
jne 0x4093b5
push 1
sub edx, eax
lea eax, [esp + 0x10]
push eax
push 0
push 0
sar edx, 1
push 1
push 3
push edi
movzx ebx, word [esi + edx*2 - 2]
call dword [sym.imp.lua54.dll_luaL_optinteger]
add esp, 0x10
dec eax
push eax
push esi
call dword [sym.imp.SHELL32.dll_ExtractIconExW]
test eax, eax
je 0x4093f4
cmp eax, 0xffffffff
jne 0x409433
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp ebx, 0x5c
je 0x40940f
cmp ebx, 0x2f
je 0x40940f
xor ecx, ecx
cmp eax, 0xffffffff
cmove eax, ecx
jmp 0x409414
mov eax, 0x10
push 0x111
push 0x2b4
lea ecx, [esp + 0x1c]
push ecx
push eax
push esi
call dword [sym.imp.SHELL32.dll_SHGetFileInfoW]
mov eax, dword [esp + 0x14]
mov dword [esp + 0xc], eax
push esi
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov eax, dword [esp + 0x10]
add esp, 4
pop esi
pop edi
pop ebx
mov ecx, dword [esp + 0x2bc]
xor ecx, esp
call fcn.00414d65
add esp, 0x2c0
ret
mov ecx, dword [esp + 0x2c4]
mov eax, dword [esp + 8]
pop edi
pop ebx
xor ecx, esp
call fcn.00414d65
add esp, 0x2c0
ret