joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10074235
Capabilities:
Link many functions at runtime
Print debug messages

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [0x1007d740]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_EncodePointer]
push esi
push edi
mov dword [ebp - 0x1c], eax
xor esi, esi
mov eax, dword [ebp + 0xc]
push esi
mov dword [ebp - 0x20], eax
call ebx
mov edi, eax
mov dword [ebp - 0x18], edi
call fcn.10065118
mov dword [ebp - 0x14], eax
cmp dword [0x1062089c], esi
jne 0x10074328
push 0x800
push esi
push 0x1000759c
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov edi, eax
test edi, edi
jne 0x100742b5
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x57
jne 0x10074408
push esi
push esi
push 0x1000759c
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov edi, eax
test edi, edi
je 0x10074408
push 0x100075b4
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x10074408
push eax
call ebx
push 0x100075c0
push edi
mov dword [0x1062089c], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call ebx
push 0x100075d0
push edi
mov dword [0x106208a0], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call ebx
push 0x100075e4
push edi
mov dword [0x106208a4], eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call ebx
mov dword [0x106208ac], eax
test eax, eax
je 0x10074325
push 0x10007600
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
push eax
call ebx
mov dword [0x106208a8], eax
mov edi, dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_IsDebuggerPresent]
test eax, eax
je 0x1007434d
mov eax, dword [ebp - 0x1c]
test eax, eax
je 0x10074340
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
cmp dword [ebp - 0x14], esi
je 0x10074362
push 4
pop eax
jmp 0x1007440a
cmp dword [ebp - 0x14], esi
je 0x10074362
push dword [0x1062089c]
call dword [sym.imp.KERNEL32.dll_DecodePointer]
push 3
jmp 0x10074347
mov eax, dword [0x106208a8]
mov ebx, dword [sym.imp.KERNEL32.dll_DecodePointer]
cmp eax, edi
je 0x100743c0
cmp dword [0x106208ac], edi
je 0x100743c0
push eax
call ebx
push dword [0x106208ac]
mov dword [ebp - 0x14], eax
call ebx
mov ecx, dword [ebp - 0x14]
mov dword [ebp - 0x18], eax
test ecx, ecx
je 0x100743c0
test eax, eax
je 0x100743c0
call ecx
test eax, eax
je 0x100743b5
lea ecx, [ebp - 0x24]
push ecx
push 0xc
lea ecx, [ebp - 0x10]
push ecx
push 1
push eax
call dword [ebp - 0x18]
test eax, eax
je 0x100743b5
test byte [ebp - 8], 1
jne 0x100743c0
mov edi, dword [ebp + 0x10]
or edi, 0x200000
jmp 0x100743f0
mov eax, dword [0x106208a0]
cmp eax, edi
je 0x100743ed
push eax
call ebx
test eax, eax
je 0x100743ed
call eax
mov esi, eax
test esi, esi
je 0x100743ed
mov eax, dword [0x106208a4]
cmp eax, edi
je 0x100743ed
push eax
call ebx
test eax, eax
je 0x100743ed
push esi
call eax
mov esi, eax
mov edi, dword [ebp + 0x10]
push dword [0x1062089c]
call ebx
test eax, eax
je 0x10074408
push edi
push dword [ebp - 0x20]
push dword [ebp - 0x1c]
push esi
call eax
jmp 0x1007440a
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.10062484
mov esp, ebp
pop ebp
ret
Function at 0x4056c9
Capabilities:
Set registry value

Disassembly:
cmp dword [esp + 8], 0
jne 0x4056da
push 0x80004005
call fcn.004055b2
push dword [esp + 8]
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea eax, [eax + eax + 2]
push eax
push dword [esp + 0xc]
mov eax, dword [esp + 0xc]
push 1
push 0
push 0x40b870
push dword [eax]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
ret 8

Function at 0x405a19
Capabilities:
Delete file
Move file

Disassembly:
push 0x2c
mov eax, 0x409b04
call fcn.00409219
mov esi, ecx
xor ebx, ebx
mov dword [ebp - 4], ebx
push dword [esi]
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
jne 0x405a4b
push dword [esi]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
neg eax
sbb eax, eax
neg eax
jmp 0x405ad4
push esi
lea eax, [ebp - 0x14]
push eax
call fcn.00403220
mov byte [ebp - 4], 1
mov eax, dword [ebp - 0x14]
mov edi, dword [eax - 0xc]
lea eax, [edi + 1]
mov dword [ebp - 0x18], eax
push eax
lea esi, [ebp - 0x14]
call fcn.004055ca
mov word [eax + edi*2], bx
mov eax, dword [ebp - 0x18]
mov edx, esi
call fcn.004052ba
push 0x1e
push ebx
lea eax, [ebp - 0x38]
push eax
call sub.MSVCR80.dll_memset
add esp, 0xc
mov dword [ebp - 0x38], ebx
mov dword [ebp - 0x34], 3
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x2c], ebx
mov word [ebp - 0x28], 0x614
mov dword [ebp - 0x26], ebx
lea eax, [ebp - 0x38]
push eax
call dword [sym.imp.SHELL32.dll_SHFileOperationW]
mov esi, eax
neg esi
sbb esi, esi
inc esi
mov byte [ebp - 4], bl
lea eax, [ebp - 0x14]
push eax
call fcn.00402659
mov eax, esi
jmp 0x405ad4
call fcn.00409285
ret
Function at 0x4010e0
Capabilities:
Check if file exists

Disassembly:
push ebx
push esi
push 0x208
mov esi, eax
push 0
push esi
call sub.MSVCR80.dll_memset
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x18]
mov ebx, dword [sym.imp.MSVCR80.dll_wcsncpy_s]
push eax
push ecx
push 0x104
push esi
call ebx
mov eax, edi
add esp, 0x1c
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x401111
sub eax, edx
sar eax, 1
push eax
push edi
add esi, 0x208
push 0x104
push esi
call ebx
add esp, 0x10
push esi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x401145
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
pop esi
pop ebx
ret 8
Function at 0x4021f0
Capabilities:
Resolve dns

Disassembly:
sub esp, 0x38
mov eax, dword [0x40a018]
xor eax, esp
mov dword [esp + 0x30], eax
push esi
mov esi, edx
test esi, esi
jne 0x40221a
mov eax, 0xfffffc18
pop esi
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.00404f8a
add esp, 0x38
ret
push 0xa
push 6
lea eax, [esp + 0x34]
movzx ecx, cx
push eax
push ecx
mov dword [esp + 0x18], 0
call dword [sym.imp.MSVCR80.dll__itoa_s]
xor eax, eax
add esp, 0x10
mov dword [esp + 0x10], eax
mov dword [esp + 0x14], eax
mov dword [esp + 0x18], eax
lea edx, [esp + 8]
push edx
mov dword [esp + 0x10], eax
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], eax
lea eax, [esp + 0x10]
push eax
lea ecx, [esp + 0x34]
push ecx
push esi
mov dword [esp + 0x20], 2
mov dword [esp + 0x24], 1
mov dword [esp + 0x28], 6
call dword [sym.imp.WS2_32.dll_getaddrinfo]
test eax, eax
jne 0x4022e9
mov edx, dword [esp + 8]
test edx, edx
jne 0x4022a9
mov eax, 0xfffffc1e
pop esi
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.00404f8a
add esp, 0x38
ret
cmp dword [edx + 0x10], 0x10
je 0x4022c4
mov eax, 0xfffffc19
pop esi
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.00404f8a
add esp, 0x38
ret
mov eax, dword [edx + 0x18]
mov esi, dword [eax]
lea ecx, [edi + 8]
mov dword [ecx], esi
mov esi, dword [eax + 4]
mov dword [ecx + 4], esi
mov esi, dword [eax + 8]
mov dword [ecx + 8], esi
mov eax, dword [eax + 0xc]
push edx
mov dword [ecx + 0xc], eax
call dword [sym.imp.WS2_32.dll_freeaddrinfo]
xor eax, eax
mov ecx, dword [esp + 0x34]
pop esi
xor ecx, esp
call fcn.00404f8a
add esp, 0x38
ret
Function at 0x402350
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Get socket status
Set socket configuration

Disassembly:
sub esp, 0x124
push ebx
push edi
push 6
push 1
push 2
mov ebx, eax
call dword [sym.imp.WS2_32.dll_socket]
cmp eax, 0xffffffff
mov dword [esi + 4], eax
jne 0x40237c
mov eax, 0xfffffc1a
pop edi
pop ebx
add esp, 0x124
ret
mov ecx, dword [ebx]
mov dword [esi + 8], ecx
mov edx, dword [ebx + 4]
lea edi, [esi + 8]
mov dword [edi + 4], edx
mov ecx, dword [ebx + 8]
mov dword [edi + 8], ecx
mov edx, dword [ebx + 0xc]
mov ebx, dword [sym.imp.WS2_32.dll_setsockopt]
push 4
lea ecx, [esi + 0xa8]
push ecx
push 0x1005
push 0xffff
push eax
mov dword [edi + 0xc], edx
call ebx
mov eax, dword [esi + 4]
push 4
lea edx, [esi + 0xa4]
push edx
push 0x1006
push 0xffff
push eax
call ebx
mov edx, dword [esi + 4]
mov ebx, dword [sym.imp.WS2_32.dll_ioctlsocket]
lea ecx, [esp + 0xc]
push ecx
push 0x8004667e
push edx
mov dword [esp + 0x18], 1
call ebx
mov eax, dword [esi + 4]
push 0x10
push edi
push eax
call dword [sym.imp.WS2_32.dll_connect]
test eax, eax
je 0x402496
mov eax, dword [esi + 0xa0]
cdq
mov ecx, 0x3e8
idiv ecx
lea ecx, [esp + 0x20]
mov dword [esp + 0x20], 1
imul edx, edx, 0x3e8
mov dword [esp + 0x1c], edx
lea edx, [esp + 0x18]
push edx
push 0
push ecx
mov dword [esp + 0x24], eax
mov eax, dword [esi + 4]
push 0
push eax
mov dword [esp + 0x38], eax
call dword [sym.imp.WS2_32.dll_select]
test eax, eax
jge 0x402451
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
pop edi
pop ebx
add esp, 0x124
ret
jne 0x402461
mov eax, 0x274c
pop edi
pop ebx
add esp, 0x124
ret
mov ecx, dword [esi + 4]
lea edx, [esp + 0x14]
push edx
lea eax, [esp + 0x14]
push eax
push 0x1007
push 0xffff
push ecx
mov dword [esp + 0x24], 0xffffffff
mov dword [esp + 0x28], 4
call dword [sym.imp.WS2_32.dll_getsockopt]
cmp dword [esp + 0x10], 0
jne 0x402442
mov eax, dword [esi + 4]
lea edx, [esp + 0xc]
push edx
push 0x8004667e
push eax
mov dword [esp + 0x18], 0
call ebx
pop edi
xor eax, eax
pop ebx
add esp, 0x124
ret
Function at 0x403ef0
Capabilities:
Send data
Send data on socket

Disassembly:
push ebx
push ebp
mov ebp, dword [esp + 0x10]
push esi
xor esi, esi
test edi, edi
jbe 0x403f22
mov ebx, dword [sym.imp.WS2_32.dll_send]
mov edx, dword [esp + 0x10]
push 0
mov eax, edi
sub eax, esi
push eax
mov eax, dword [edx + 4]
lea ecx, [esi + ebp]
push ecx
push eax
call ebx
test eax, eax
jle 0x403f2a
add esi, eax
cmp esi, edi
jb 0x403f03
pop esi
pop ebp
xor eax, eax
pop ebx
ret 8
pop esi
pop ebp
mov eax, 0xfffffc1e
pop ebx
ret 8

Function at 0x4042a0
Capabilities:
Access peb ldr_data

Disassembly:
push 0xffffffffffffffff
push 0x405ba9
mov eax, dword fs:[0]
push eax
sub esp, 0x24
mov eax, dword [0x40a018]
xor eax, esp
mov dword [esp + 0x20], eax
mov eax, dword [0x40a018]
xor eax, esp
push eax
lea eax, [esp + 0x28]
mov dword fs:[0], eax
push 0
push 0
lea ecx, [esp + 0x10]
call dword [sym.imp.MSVCP80.dll_protected:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::_Tidy_bool__unsigned_int_]
mov eax, dword [esp + 4]
push eax
lea ecx, [esp + 0xc]
push ecx
mov ecx, ebx
mov edx, edi
call fcn.00404350
mov dword [esp + 0x30], 0
mov eax, dword [esp + 0x48]
mov ecx, dword [esp + 0x44]
lea edx, [esp + 8]
push edx
mov edx, dword [esp + 0x44]
push eax
mov eax, dword [esp + 0x44]
push ecx
push edx
push eax
mov ecx, esi
call dword [sym.imp.MSVCP80.dll_public:_class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char______thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::replace_class_std::_String_iterator_char__struct_std::char_traits_char___class_std::allocator_char____class_std::_String_iterator_char__struct_std::char_traits_char___class_std::allocator_char____class_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char___const__]
lea ecx, [esp + 8]
mov dword [esp + 0x30], 0xffffffff
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
mov eax, esi
mov ecx, dword [esp + 0x28]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [esp + 0x20]
xor ecx, esp
call fcn.00404f8a
add esp, 0x30
ret 0x14
Function at 0x4046b0
Capabilities:
Initialize winsock library

Disassembly:
push 0xffffffffffffffff
push 0x4060ca
mov eax, dword fs:[0]
push eax
sub esp, 0x1c0
mov eax, dword [0x40a018]
xor eax, esp
mov dword [esp + 0x1b8], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x40a018]
xor eax, esp
push eax
lea eax, [esp + 0x1d4]
mov dword fs:[0], eax
mov ebp, dword [esp + 0x1e4]
lea eax, [esp + 0x3c]
push eax
push 0x202
mov edi, ecx
call dword [sym.imp.WS2_32.dll_WSAStartup]
push 0xac
mov dword [esp + 0x20], 2
call sub.MSVCR80.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
mov dword [esp + 0x18], eax
xor esi, esi
cmp eax, esi
mov dword [esp + 0x1dc], esi
je 0x404734
push eax
call fcn.00401fe0
mov ebx, eax
jmp 0x404736
xor ebx, ebx
cmp ebx, esi
mov dword [esp + 0x1dc], 0xffffffff
jne 0x40474f
mov eax, 2
jmp 0x404866
push esi
push 0x80
push 2
push esi
push 1
lea eax, [ebp + 0x208]
push 0x40000000
push eax
mov dword [esp + 0x34], eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
mov dword [ebp + 0x420], eax
je 0x404745
mov eax, edi
mov edi, ebx
mov dword [ebp + 0x418], esi
mov dword [ebp + 0x41c], esi
mov dword [ebp + 0x410], esi
mov dword [ebp + 0x414], esi
call fcn.00402140
mov eax, 0x2710
lea ecx, [esp + 0x20]
mov dword [ebx + 0xa0], eax
mov dword [ebx + 0xa4], eax
mov dword [ebx + 0xa8], eax
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::constructor_void_]
lea esi, [esp + 0x20]
mov edi, ebp
mov dword [esp + 0x1dc], 1
call fcn.00404ee0
mov ecx, fcn.00404640
test ecx, ecx
jne 0x4047e6
mov esi, 0xfffffc18
or edi, 0xffffffff
jmp 0x404812
push ebp
lea edx, [esp + 0x24]
mov ecx, ebx
call fcn.00403850
mov dword [ebx + 0x9c], eax
mov eax, dword [ebx + 4]
or edi, 0xffffffff
cmp eax, edi
je 0x40480c
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
mov dword [ebx + 4], edi
mov esi, dword [ebx + 0x9c]
mov edx, dword [ebp + 0x420]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
test esi, esi
je 0x404832
mov eax, dword [esp + 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov esi, dword [esp + 0x1c]
mov eax, dword [ebx + 4]
cmp eax, edi
je 0x404843
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
mov dword [ebx + 4], edi
mov edx, dword [ebx]
mov eax, dword [edx]
push 1
mov ecx, ebx
call eax
call dword [sym.imp.WS2_32.dll_WSACleanup]
lea ecx, [esp + 0x20]
mov dword [esp + 0x1dc], edi
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::destructor_void_]
mov eax, esi
mov ecx, dword [esp + 0x1d4]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x1b8]
xor ecx, esp
call fcn.00404f8a
add esp, 0x1cc
ret
Function at 0x404d00
Capabilities:
Encode data using base64

Disassembly:
mov ecx, dword [esp + 4]
push esi
mov esi, eax
test esi, esi
je 0x404e59
test ecx, ecx
jbe 0x404e59
mov eax, 0xaaaaaaab
mul ecx
mov eax, dword [esp + 0xc]
shr edx, 1
push ebp
lea edx, [edx + edx*2]
push edi
lea ebp, [edx + esi]
xor edi, edi
cmp esi, ebp
je 0x404dcb
push ebx
xor edi, edi
lea esp, [esp]
cmp esi, ebp
je 0x404dad
movzx ecx, byte [esi]
movzx ebx, byte [esi + 1]
add esi, 1
shl ecx, 8
or ecx, ebx
movzx ebx, byte [esi + 1]
add esi, 1
shl ecx, 8
or ecx, ebx
mov ebx, ecx
and ebx, 0x3f
movzx ebx, byte [ebx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov byte [eax + 3], bl
shr ecx, 6
mov ebx, ecx
and ebx, 0x3f
movzx ebx, byte [ebx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov byte [eax + 2], bl
shr ecx, 6
mov ebx, ecx
and ebx, 0x3f
movzx ebx, byte [ebx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
shr ecx, 6
mov byte [eax + 1], bl
mov cl, byte [ecx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov byte [eax], cl
add edi, 4
add esi, 1
add eax, 4
cmp edi, 0x4c
jb 0x404d40
jmp 0x404db2
cmp edi, 0x4c
jb 0x404dbe
mov byte [eax], 0xd
add eax, 1
mov byte [eax], 0xa
add eax, 1
cmp esi, ebp
jne 0x404d37
mov ecx, dword [esp + 0x14]
pop ebx
sub ecx, edx
sub ecx, 1
je 0x404e13
sub ecx, 1
jne 0x404e40
mov ch, byte [esi]
mov cl, byte [esi + 1]
add ecx, ecx
add ecx, ecx
mov edx, ecx
and edx, 0x3f
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov byte [eax + 2], dl
shr ecx, 6
mov edx, ecx
and edx, 0x3f
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
shr ecx, 6
mov byte [eax + 1], dl
movzx ecx, byte [ecx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov byte [eax], cl
mov byte [eax + 3], 0x3d
jmp 0x404e3a
movzx ecx, byte [esi]
shl ecx, 4
mov edx, ecx
and edx, 0x3f
mov dl, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
shr ecx, 6
mov byte [eax + 1], dl
mov cl, byte [ecx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov byte [eax], cl
mov cl, 0x3d
mov byte [eax + 2], cl
mov byte [eax + 3], cl
add eax, 4
add edi, 4
cmp edi, 0x4c
pop edi
pop ebp
jb 0x404e53
mov byte [eax], 0xd
add eax, 1
mov byte [eax], 0xa
add eax, 1
sub eax, dword [esp + 0xc]
pop esi
ret
xor eax, eax
pop esi
ret
Function at 0x402e90
Capabilities:
Contain obfuscated stackstrings

Disassembly:
push 0xffffffffffffffff
push 0x42fa48
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x10
push ebx
lea ecx, [esp + 0x24]
mov dword [esp + 0x1c], 0
mov byte [esp + 4], 0x30
mov byte [esp + 5], 0x31
mov byte [esp + 6], 0x32
mov byte [esp + 7], 0x33
mov byte [esp + 8], 0x34
mov byte [esp + 9], 0x35
mov byte [esp + 0xa], 0x36
mov byte [esp + 0xb], 0x37
mov byte [esp + 0xc], 0x38
mov byte [esp + 0xd], 0x39
mov byte [esp + 0xe], 0x41
mov byte [esp + 0xf], 0x42
mov byte [esp + 0x10], 0x43
mov byte [esp + 0x11], 0x44
mov byte [esp + 0x12], 0x45
mov byte [esp + 0x13], 0x46
call fcn.004257b8
mov edx, dword [esp + 0x24]
xor eax, eax
mov cl, byte [edx]
cmp cl, byte [esp + eax + 4]
je 0x402f24
inc eax
cmp eax, 0x10
jl 0x402f12
mov bl, byte [esp + 0x24]
jmp 0x402f2f
cmp dword [edx - 8], 1
jle 0x402f2d
shl al, 4
mov bl, al
cmp dword [edx - 8], 1
jle 0x402f4a
mov cl, byte [edx + 1]
xor eax, eax
cmp cl, byte [esp + eax + 4]
je 0x402f48
inc eax
cmp eax, 0x10
jl 0x402f3a
jmp 0x402f4a
add bl, al
lea ecx, [esp + 0x24]
mov dword [esp + 0x1c], 0xffffffff
call fcn.004253d4
mov ecx, dword [esp + 0x14]
mov al, bl
pop ebx
mov dword fs:[0], ecx
add esp, 0x1c
ret 4
Function at 0x41a2fa
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1a4
mov edx, dword [ebp + 8]
xor ecx, ecx
mov eax, 0x43e400
cmp edx, dword [eax]
je 0x41a31c
add eax, 8
inc ecx
cmp eax, 0x43e490
jl 0x41a30d
push esi
mov esi, ecx
shl esi, 3
cmp edx, dword [esi + 0x43e400]
jne 0x41a44a
mov eax, dword [0x440cf4]
cmp eax, 1
je 0x41a424
test eax, eax
jne 0x41a34d
cmp dword [0x43da54], 1
je 0x41a424
cmp edx, 0xfc
je 0x41a44a
lea eax, [ebp - 0x1a4]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x41a384
lea eax, [ebp - 0x1a4]
push str._program_name_unknown_
push eax
call fcn.0041a450
pop ecx
pop ecx
lea eax, [ebp - 0x1a4]
push edi
push eax
lea edi, [ebp - 0x1a4]
call fcn.0041a540
inc eax
pop ecx
cmp eax, 0x3c
jbe 0x41a3c7
lea eax, [ebp - 0x1a4]
push eax
call fcn.0041a540
mov edi, eax
lea eax, [ebp - 0x1a4]
sub eax, 0x3b
push 3
add edi, eax
push 0x434920
push edi
call fcn.0041d090
add esp, 0x10
lea eax, [ebp - 0xa0]
push str.Runtime_Error__n_nProgram:
push eax
call fcn.0041a450
lea eax, [ebp - 0xa0]
push edi
push eax
call fcn.0041a460
lea eax, [ebp - 0xa0]
push 0x434900
push eax
call fcn.0041a460
push dword [esi + 0x43e404]
lea eax, [ebp - 0xa0]
push eax
call fcn.0041a460
push 0x12010
lea eax, [ebp - 0xa0]
push str.Microsoft_Visual_C_Runtime_Library
push eax
call fcn.0041cff9
add esp, 0x2c
pop edi
jmp 0x41a44a
lea eax, [ebp + 8]
lea esi, [esi + 0x43e404]
push 0
push eax
push dword [esi]
call fcn.0041a540
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
pop esi
leave
ret
Function at 0x4221f0
Capabilities:
Get graphical window text

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
push ebx
push esi
push edi
mov esi, dword [ebp + 0x10]
push 0xf00021
mov edx, dword [esi + 4]
mov ecx, dword [esi]
mov eax, dword [esi + 0xc]
sub eax, edx
push eax
mov eax, dword [esi + 8]
sub eax, ecx
push eax
push edx
push ecx
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.GDI32.dll_PatBlt]
mov edi, dword [ebp + 8]
push edi
call dword [sym.imp.USER32.dll_GetWindowTextLengthA]
mov ebx, eax
lea eax, [eax + 5]
add eax, 3
and eax, 0xfffffffc
call fcn.00414970
mov dword [ebp - 4], esp
cmp dword [ebp - 4], 0
je 0x4222bb
add ebx, 2
mov eax, dword [ebp - 4]
push ebx
push eax
push edi
call dword [sym.imp.USER32.dll_GetWindowTextA]
test eax, eax
je 0x4222bb
mov bx, 0x140
mov edi, dword [ebp + 0x14]
mov eax, edi
and al, 0xf
cmp al, 0xc
je 0x42226e
mov ebx, edi
and bx, 0xf
or bx, 0x150
test edi, 0x80
je 0x422279
or bh, 8
and edi, 0x8000000
je 0x422294
mov eax, dword [0x44249c]
mov ecx, dword [ebp + 0xc]
push eax
push ecx
call dword [sym.imp.GDI32.dll_SetTextColor]
mov dword [ebp - 8], eax
mov ecx, dword [ebp - 4]
mov edx, dword [ebp + 0xc]
movzx eax, bx
push eax
push esi
push 0xffffffffffffffff
push ecx
push edx
call dword [sym.imp.USER32.dll_DrawTextA]
test edi, edi
je 0x4222bb
mov eax, dword [ebp - 8]
mov ecx, dword [ebp + 0xc]
push eax
push ecx
call dword [sym.imp.GDI32.dll_SetTextColor]
lea esp, [ebp - 0x14]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x422690
Capabilities:
Extract resource via kernel32 functions

Disassembly:
mov eax, dword [esp + 8]
sub esp, 4
push ebx
push esi
mov esi, dword [esp + 0x10]
push edi
push ebp
push 2
push eax
push esi
call dword [sym.imp.KERNEL32.dll_FindResourceA]
mov edi, eax
test edi, edi
jne 0x4226bb
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20
push edi
push esi
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ebx, eax
push edi
push esi
call dword [sym.imp.KERNEL32.dll_LoadResource]
mov esi, eax
test esi, esi
jne 0x4226df
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20
push ebx
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov ebp, eax
test ebp, ebp
jne 0x4226fa
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20
mov edi, ebp
mov ecx, ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [esp + 0x20]
xor ecx, ecx
mov cl, ah
mov edx, eax
mov dword [esp + 0x10], 0
shl ecx, 8
shr edx, 0x10
mov byte [esp + 0x10], dl
xor edx, edx
or ecx, dword [esp + 0x10]
mov dl, al
shl edx, 0x10
mov eax, dword [esp + 0x28]
or ecx, edx
mov edx, eax
shr edx, 0x10
mov dword [ebp + 0x28], ecx
mov dword [esp + 0x10], 0
xor ecx, ecx
mov byte [esp + 0x10], dl
mov cl, ah
xor edx, edx
shl ecx, 8
mov dl, al
shl edx, 0x10
or ecx, dword [esp + 0x10]
or ecx, edx
mov eax, dword [esp + 0x24]
mov edx, eax
mov dword [ebp + 0x44], ecx
shr edx, 0x10
xor ecx, ecx
mov dword [esp + 0x10], 0
mov cl, ah
mov byte [esp + 0x10], dl
shl ecx, 8
xor edx, edx
or ecx, dword [esp + 0x10]
mov dl, al
shl edx, 0x10
mov eax, dword [esp + 0x2c]
or ecx, edx
xor edx, edx
mov dl, al
mov dword [ebp + 0x48], ecx
shl edx, 0x10
xor ecx, ecx
mov cl, ah
shl ecx, 8
shr eax, 0x10
or ecx, edx
xor edx, edx
mov dl, al
mov eax, dword [esp + 0x30]
or ecx, edx
xor edx, edx
mov dl, al
mov dword [ebp + 0x64], ecx
shl edx, 0x10
xor ecx, ecx
mov cl, ah
shl ecx, 8
shr eax, 0x10
or ecx, edx
xor edx, edx
mov dl, al
mov eax, dword [esp + 0x34]
or ecx, edx
xor edx, edx
mov dl, al
mov dword [ebp + 0x54], ecx
shl edx, 0x10
xor ecx, ecx
mov cl, ah
shl ecx, 8
push 0
shr eax, 0x10
or ecx, edx
xor edx, edx
mov dl, al
or ecx, edx
mov dword [ebp + 0x50], ecx
call dword [sym.imp.USER32.dll_GetDC]
mov edi, eax
push 0
push ebp
lea ecx, [ebp + 0x68]
push ecx
push 4
push ebp
push edi
call dword [sym.imp.GDI32.dll_CreateDIBitmap]
mov esi, eax
push edi
push 0
call dword [sym.imp.USER32.dll_ReleaseDC]
push ebp
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov eax, esi
pop ebp
pop edi
pop esi
pop ebx
add esp, 4
ret 0x20

Function at 0x4266de
Capabilities:
Get graphical window text

Disassembly:
push esi
mov esi, ecx
mov ecx, dword [esi + 0x38]
test ecx, ecx
jne 0x426716
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextLengthA]
lea ecx, [eax + 1]
push ecx
mov ecx, dword [esp + 0xc]
push eax
call fcn.0042575d
push eax
push dword [esi + 0x1c]
call dword [sym.imp.USER32.dll_GetWindowTextA]
mov ecx, dword [esp + 8]
push 0xffffffffffffffff
call fcn.00425735
jmp 0x426722
mov eax, dword [ecx]
push dword [esp + 8]
call dword [eax + 0x88]
pop esi
ret 4