joyce8/EMBER2024-capa huggingface dataset:
Function at 0x40258d
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x434
mov eax, dword [0x422044]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
push dword [ebp + 0xc]
mov dword [ebp - 0x430], eax
push eax
call fcn.004083a5
xor edi, edi
cmp eax, edi
pop ecx
pop ecx
mov dword [ebp - 0x42c], eax
jne 0x402708
mov esi, 0x206
push esi
lea eax, [ebp - 0x21e]
push edi
push eax
mov word [ebp - 0x220], di
call fcn.00408c40
add esp, 0xc
push esi
lea eax, [ebp - 0x426]
push edi
push eax
mov word [ebp - 0x428], di
call fcn.00408c40
add esp, 0xc
lea edi, [ebp - 0x220]
call fcn.00402863
push 0x41dc18
mov ebx, 0x104
mov eax, edi
push ebx
push eax
call fcn.00408d30
mov byte [ebp - 0x18], 0
add esp, 0xc
xor eax, eax
lea edi, [ebp - 0x17]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosw word es:[edi], ax
mov esi, 0x424788
stosb byte es:[edi], al
mov edi, esi
cmp word [edi], 0
je 0x402692
lea eax, [ebp - 0x220]
push eax
lea eax, [ebp - 0x428]
push ebx
push eax
call fcn.00409115
add esp, 0xc
push edi
lea eax, [ebp - 0x428]
push ebx
push eax
call fcn.00408d30
lea eax, [ebp - 0x428]
add esp, 0xc
push eax
lea ecx, [ebp - 0x18]
call fcn.004046ef
test eax, eax
pop ecx
je 0x402692
push 0x14
lea eax, [edi + 0x104]
push eax
lea eax, [ebp - 0x18]
push eax
call fcn.00409d00
add esp, 0xc
test eax, eax
jne 0x402692
and word [edi], ax
add edi, 0x118
cmp edi, 0x424d00
jl 0x402634
cmp word [esi], 0
je 0x4026c3
push dword [ebp + 0xc]
mov eax, dword [esi + 0x100]
push dword [ebp - 0x430]
mov ecx, esi
mov dword [0x42477c], eax
call fcn.004085cf
pop ecx
pop ecx
add esi, 0x118
cmp esi, 0x424d00
jl 0x4026a0
push 0x4253c8
lea eax, [ebp - 0x220]
push ebx
push eax
call fcn.00408d30
add esp, 0xc
lea eax, [ebp - 0x220]
push eax
call dword [sym.imp.kernel32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x402702
mov dword [ebp - 0x42c], 2
mov eax, dword [ebp - 0x42c]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00408c2e
leave
ret

Function at 0x402971
Capabilities:
Extract resource via kernel32 functions

Disassembly:
push ebx
push ebp
push edi
xor edi, edi
push edi
call dword [sym.imp.kernel32.dll_GetModuleHandleW]
push 0x41dd58
mov ebx, eax
push 0x83
push ebx
call dword [sym.imp.kernel32.dll_FindResourceW]
mov ebp, eax
cmp ebp, edi
je 0x4029de
push esi
push ebp
push ebx
call dword [sym.imp.kernel32.dll_SizeofResource]
push ebp
push ebx
mov esi, eax
call dword [sym.imp.kernel32.dll_LoadResource]
mov ebx, eax
push ebx
call dword [sym.imp.kernel32.dll_SetHandleCount]
mov ebp, eax
mov eax, dword [esp + 0x14]
push esi
mov dword [eax], esi
call fcn.0040b581
push esi
mov edi, eax
push 0
push edi
call fcn.00408c40
push esi
push ebp
push edi
call fcn.00408db0
add esp, 0x1c
push ebx
call dword [sym.imp.kernel32.dll_FreeResource]
pop esi
mov eax, edi
pop edi
pop ebp
pop ebx
ret
Function at 0x402b03
Capabilities:
Get mac address on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x40
mov eax, dword [0x422044]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
or dword [ebp - 0x2c], 0xffffffff
push ebx
mov dword [ebp - 0x38], eax
mov eax, dword [ebp + 0xc]
push esi
push edi
mov dword [ebp - 0x3c], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x40], eax
push 7
xor ebx, ebx
mov word [ebp - 0x24], bx
pop ecx
xor eax, eax
lea edi, [ebp - 0x22]
rep stosd dword es:[edi], eax
mov esi, 0x288
push esi
stosw word es:[edi], ax
call fcn.00409657
pop ecx
lea ecx, [ebp - 0x30]
push ecx
push eax
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x30], esi
call sub.iphlpapi.dll_GetAdaptersInfo
cmp eax, 0x6f
jne 0x402b74
push dword [ebp - 0x28]
call fcn.00409c6d
push dword [ebp - 0x30]
call fcn.00409657
pop ecx
pop ecx
mov dword [ebp - 0x28], eax
mov edi, dword [ebp - 0x28]
lea eax, [ebp - 0x30]
push eax
push edi
call sub.iphlpapi.dll_GetAdaptersInfo
test eax, eax
jne 0x402c2e
cmp edi, ebx
mov dword [ebp - 0x34], edi
je 0x402c2e
jmp 0x402b99
mov edi, dword [ebp - 0x34]
inc dword [ebp - 0x2c]
cmp dword [ebp - 0x38], 0
je 0x402bb6
push 6
lea eax, [edi + 0x194]
push eax
push dword [ebp - 0x38]
call fcn.00408db0
add esp, 0xc
lea esi, [edi + 0x1ac]
test esi, esi
je 0x402c1d
lea edi, [esi + 4]
push edi
call fcn.0040b5f0
cmp eax, 0x10
pop ecx
jle 0x402bd2
push 0x10
pop eax
xor ecx, ecx
test eax, eax
jl 0x402bf1
cmp ecx, eax
jne 0x402be2
and word [ebp + ecx*2 - 0x24], 0
movsx dx, byte [edi + ecx]
mov word [ebp + ecx*2 - 0x24], dx
inc ecx
cmp ecx, eax
jle 0x402bda
lea eax, [ebp - 0x24]
push eax
call fcn.00402ced
test eax, eax
pop ecx
je 0x402c13
lea eax, [ebp - 0x24]
push eax
mov eax, dword [ebp - 0x3c]
push 0x10
push dword [eax + ebx*4]
call fcn.00409115
add esp, 0xc
mov esi, dword [esi]
inc ebx
test esi, esi
jne 0x402bc0
mov edi, dword [ebp - 0x34]
test ebx, ebx
jg 0x402c2e
mov edi, dword [edi]
test edi, edi
mov dword [ebp - 0x34], edi
jne 0x402b96
cmp dword [ebp - 0x28], 0
mov eax, dword [ebp - 0x40]
pop edi
pop esi
mov dword [eax], ebx
pop ebx
je 0x402c45
push dword [ebp - 0x28]
call fcn.00409c6d
pop ecx
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 0x2c]
xor ecx, ebp
call fcn.00408c2e
leave
ret

Function at 0x402e73
Capabilities:
Check os version

Disassembly:
push ebp
lea ebp, [esp - 0xa0]
sub esp, 0x120
mov eax, dword [0x422044]
xor eax, ebp
mov dword [ebp + 0x9c], eax
push esi
push 0x118
xor esi, esi
lea eax, [ebp - 0x7c]
push esi
push eax
call fcn.00408c40
add esp, 0xc
lea eax, [ebp - 0x80]
push eax
mov dword [ebp - 0x80], 0x11c
call dword [sym.imp.kernel32.dll_GetVersionExW]
test eax, eax
je 0x402ef7
cmp dword [ebp - 0x7c], 5
mov eax, dword [ebp - 0x78]
jne 0x402ee1
test eax, eax
jne 0x402ed0
cmp word [ebp + 0x94], 4
jb 0x402ef7
inc esi
cmp eax, 2
jne 0x402ed7
push eax
pop esi
jae 0x402ede
cmp eax, 1
jne 0x402ef7
push 3
pop esi
cmp dword [ebp - 0x7c], 6
jne 0x402ef7
test eax, eax
jne 0x402eef
push 4
jmp 0x402ef6
cmp eax, 1
jne 0x402ef7
push 5
pop esi
mov ecx, dword [ebp + 0x9c]
mov eax, esi
xor ecx, ebp
pop esi
call fcn.00408c2e
add ebp, 0xa0
leave
ret
Function at 0x402f0f
Capabilities:
Get file size

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
push esi
push edi
xor eax, eax
push eax
push eax
push 3
push eax
push 3
push 0x80000000
push dword [ebp + 8]
or esi, 0xffffffff
mov ebx, esi
call dword [sym.imp.kernel32.dll_CreateFileW]
mov edi, eax
cmp edi, esi
jne 0x402f3e
mov edx, esi
jmp 0x402f5d
lea eax, [ebp - 0xc]
push eax
push edi
call dword [sym.imp.kernel32.dll_GetFileSizeEx]
cmp eax, 1
jne 0x402f54
mov esi, dword [ebp - 0xc]
mov ebx, dword [ebp - 8]
push edi
call dword [sym.imp.kernel32.dll_CloseHandle]
mov edx, ebx
pop edi
mov eax, esi
pop esi
pop ebx
leave
ret

Function at 0x403032
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20c
mov eax, dword [0x422044]
xor eax, ebp
mov dword [ebp - 4], eax
and word [ebp - 0x20c], 0
push 0x206
lea eax, [ebp - 0x20a]
push 0
push eax
call fcn.00408c40
add esp, 0xc
cmp dword [0x4230a0], 3
lea eax, [ebp - 0x20c]
jne 0x403098
push esi
mov esi, 0x104
push esi
push eax
call dword [sym.imp.kernel32.dll_GetSystemDirectoryW]
push 0x41dc18
lea eax, [ebp - 0x20c]
push esi
push eax
call fcn.00408d30
add esp, 0xc
pop esi
jmp 0x4030a4
push eax
push 0x104
call dword [sym.imp.kernel32.dll_GetTempPathW]
push edi
lea eax, [ebp - 0x20c]
push eax
push 0x41ddbc
push ebx
call dword [sym.imp.user32.dll_wsprintfW]
mov ecx, dword [ebp - 4]
xor ecx, ebp
add esp, 0x10
call fcn.00408c2e
leave
ret
Function at 0x403139
Capabilities:
Create process on windows
Get common file path
Write and execute a file
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x29c]
sub esp, 0x31c
mov eax, dword [0x422044]
xor eax, ebp
mov dword [ebp + 0x298], eax
push ebx
push esi
lea eax, [ebp + 0x194]
push eax
mov esi, 0x104
xor ebx, ebx
push esi
mov dword [ebp - 0x80], ebx
call dword [sym.imp.kernel32.dll_GetTempPathA]
push 0x41ddd0
lea eax, [ebp + 0x194]
push esi
push eax
call fcn.0040be29
add esp, 0xc
push esi
lea eax, [ebp + 0x90]
push eax
push ebx
call dword [sym.imp.kernel32.dll_GetModuleFileNameA]
lea eax, [ebp + 0x90]
push eax
lea eax, [ebp - 0x74]
push esi
push eax
call fcn.0040ba13
lea eax, [ebp - 0x74]
push 0x5c
push eax
call fcn.0040bde0
add esp, 0x14
cmp eax, ebx
je 0x4031b7
mov byte [eax], bl
push ebx
push 0x80
push 2
push ebx
push ebx
push 0x40000000
lea eax, [ebp + 0x194]
push eax
call dword [sym.imp.kernel32.dll_CreateFileA]
cmp eax, 0xffffffff
mov dword [ebp - 0x7c], eax
je 0x403285
lea eax, [ebp + 0x90]
push edi
push eax
call fcn.0040b5f0
mov esi, eax
mov edi, 0x423660
imul esi, esi, 3
push edi
call fcn.0040b5f0
add esi, eax
lea eax, [ebp + 0x194]
push eax
call fcn.0040b5f0
lea eax, [eax + esi + 0x32]
push eax
mov dword [ebp - 0x78], eax
call fcn.0040b581
push dword [ebp - 0x78]
mov esi, eax
push ebx
push esi
call fcn.00408c40
lea eax, [ebp + 0x194]
push eax
lea eax, [ebp - 0x74]
push eax
lea eax, [ebp + 0x90]
push eax
push eax
push edi
push dword [ebp - 0x78]
push esi
call fcn.0040be0d
add esp, 0x38
push ebx
lea eax, [ebp - 0x80]
push eax
push esi
call fcn.0040b5f0
pop ecx
push eax
push esi
push dword [ebp - 0x7c]
call dword [sym.imp.kernel32.dll_WriteFile]
push dword [ebp - 0x7c]
call dword [sym.imp.kernel32.dll_CloseHandle]
push ebx
push ebx
push ebx
lea eax, [ebp + 0x194]
push eax
push 0x41dddc
push ebx
call dword [sym.imp.SHELL32.dll_ShellExecuteA]
cmp esi, ebx
pop edi
je 0x403285
push esi
call fcn.00409cfb
pop ecx
mov ecx, dword [ebp + 0x298]
pop esi
xor ecx, ebp
pop ebx
call fcn.00408c2e
add ebp, 0x29c
leave
ret

Function at 0x40329c
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push edi
xor ecx, ecx
xor eax, eax
cmp dword [ebp + 8], 0xffffffff
mov dword [ebp - 0x18], ecx
lea edi, [ebp - 0x14]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
mov dword [ebp - 4], ecx
je 0x4032e5
mov eax, dword [ebp + 0xc]
mov ecx, 0x200
mul ecx
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 4]
push eax
push 0x400
push dword [ebp + 0x10]
mov dword [ebp - 0xc], edx
push dword [ebp + 8]
call dword [sym.imp.kernel32.dll_ReadFile]
mov ecx, eax
mov eax, ecx
pop edi
leave
ret
Function at 0x403469
Capabilities:
Get disk information via ioctl

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x18
push ebx
push esi
push edi
push 0x64
call dword [sym.imp.kernel32.dll_Sleep]
xor edi, edi
xor esi, esi
cmp dword [ebp + 8], 0xffffffff
mov dword [ebp - 8], edi
mov dword [ebp - 0x18], edi
mov dword [ebp - 0x14], edi
je 0x403513
mov ebx, 0xc00
push ebx
call fcn.0040b581
pop ecx
mov dword [ebp - 4], eax
xor eax, eax
push eax
lea ecx, [ebp - 0xc]
push ecx
push ebx
push dword [ebp - 4]
push eax
push eax
push 0x70050
push dword [ebp + 8]
call dword [sym.imp.kernel32.dll_DeviceIoControl]
test eax, eax
je 0x403504
mov eax, dword [ebp - 4]
push 4
add eax, 0x38
pop ebx
mov edx, dword [eax + 4]
cmp edx, dword [ebp - 0x14]
mov ecx, dword [eax]
jl 0x4034e5
jg 0x4034d9
cmp ecx, dword [ebp - 0x18]
jbe 0x4034e5
mov esi, dword [eax + 8]
mov edi, dword [eax + 0xc]
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x14], edx
add eax, 0x90
dec ebx
jne 0x4034c8
add esi, dword [ebp - 0x18]
push 0
adc edi, dword [ebp - 0x14]
push 0x200
push edi
push esi
call fcn.00416eb0
mov dword [ebp - 8], eax
cmp dword [ebp - 4], 0
je 0x403513
push dword [ebp - 4]
call fcn.00409cfb
pop ecx
push 0x64
call dword [sym.imp.kernel32.dll_Sleep]
mov eax, dword [ebp - 8]
pop edi
pop esi
pop ebx
leave
ret

Function at 0x40360b
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x218
mov eax, dword [0x422044]
xor eax, ebp
mov dword [ebp - 4], eax
and word [ebp - 0x210], 0
push 0x206
lea eax, [ebp - 0x20e]
push 0
push eax
call fcn.00408c40
and dword [ebp - 0x214], 0
add esp, 0xc
push 0x104
lea eax, [ebp - 0x210]
push eax
call dword [sym.imp.kernel32.dll_GetSystemDirectoryW]
lea eax, [ebp - 0x214]
push eax
movzx eax, word [ebp - 0x210]
sub eax, 0x41
push eax
call fcn.0040337c
push dword [ebp - 0x214]
call fcn.004032ea
add esp, 0xc
cmp eax, 0xffffffff
jne 0x403683
xor eax, eax
jmp 0x40368c
push edi
push eax
call fcn.0040353b
pop ecx
pop ecx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00408c2e
leave
ret

Function at 0x40455d
Capabilities:
Hash data using sha1

Disassembly:
and dword [eax + 4], 0
and dword [eax], 0
mov dword [eax + 8], 0x67452301
mov dword [eax + 0xc], 0xefcdab89
mov dword [eax + 0x10], 0x98badcfe
mov dword [eax + 0x14], 0x10325476
mov dword [eax + 0x18], 0xc3d2e1f0
ret
Function at 0x4047ff
Capabilities:
Connect socket
Initialize winsock library
Resolve dns

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x9b8
mov eax, dword [0x422044]
xor eax, esp
mov dword [esp + 0x9b4], eax
mov eax, dword [ebp + 8]
and word [esp + 0x1b0], 0
push esi
push edi
push 0x7fe
mov dword [esp + 0x18], eax
lea eax, [esp + 0x1be]
push 0
push eax
mov esi, ecx
call fcn.00408c40
xor eax, eax
add esp, 0xc
cmp esi, eax
lea edi, [esp + 0x1b8]
je 0x404853
mov edi, esi
mov word [edi], ax
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], eax
lea eax, [esp + 0x28]
push eax
push 0x101
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x4048a5
push 0x41de28
mov esi, 0x3ff
push esi
push edi
call fcn.00409115
push 0x41de48
push esi
push edi
call fcn.00408d30
push 0x41de4c
push esi
push edi
call fcn.00408d30
add esp, 0x24
xor eax, eax
jmp 0x404929
push 6
xor esi, esi
inc esi
push esi
push 2
call dword [sym.imp.WS2_32.dll_socket]
cmp eax, 0xffffffff
mov dword [ebx], eax
je 0x404872
push dword [esp + 0x14]
call dword [sym.imp.WS2_32.dll_gethostbyname]
test eax, eax
jne 0x40493d
push dword [esp + 0x14]
call dword [sym.imp.WS2_32.dll_inet_addr]
push 2
mov dword [esp + 0x14], eax
push 4
lea eax, [esp + 0x18]
push eax
call dword [sym.imp.WS2_32.dll_gethostbyaddr]
test eax, eax
jne 0x40493d
push 0x41de28
mov esi, 0x3ff
push esi
push edi
call fcn.00409115
push 0x41de48
push esi
push edi
call fcn.00408d30
push 0x41de4c
push esi
push edi
call fcn.00408d30
mov eax, dword [ebx]
add esp, 0x24
test eax, eax
je 0x404925
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
and dword [ebx], 0
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 0x9bc]
pop edi
pop esi
xor ecx, esp
call fcn.00408c2e
mov esp, ebp
pop ebp
ret
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
mov eax, dword [eax]
push dword [ebp + 0xc]
mov dword [esp + 0x20], eax
mov word [esp + 0x1c], 2
call dword [sym.imp.WS2_32.dll_ntohs]
mov word [esp + 0x1a], ax
push 0x10
lea eax, [esp + 0x1c]
push eax
push dword [ebx]
call dword [sym.imp.WS2_32.dll_connect]
test eax, eax
je 0x40497a
push 0x41de8c
jmp 0x4048ee
mov dword [esp + 0xc], esi
jmp 0x404925

Function at 0x40499b
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
push ecx
mov eax, dword [ebp + 8]
xor ecx, ecx
cmp dword [eax], ecx
push ebx
push esi
mov dword [ebp - 4], ecx
je 0x404a0f
cmp edi, ecx
jle 0x4049bd
mov eax, dword [ebp + 0xc]
add eax, ecx
not byte [eax]
inc ecx
cmp ecx, edi
jl 0x4049b1
lea ebx, [edi + 7]
push ebx
call fcn.0040b581
mov esi, eax
lea eax, [edi + 5]
push 5
mov word [esi], ax
lea eax, [esi + 2]
push 0x423120
push eax
call fcn.00408db0
push edi
push dword [ebp + 0xc]
lea eax, [esi + 7]
push eax
call fcn.00408db0
mov eax, dword [ebp + 8]
add esp, 0x1c
push 0
push ebx
push esi
push dword [eax]
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
je 0x404a12
cmp eax, ebx
jne 0x404a12
mov dword [ebp - 4], 1
jmp 0x404a12
mov esi, dword [ebp + 8]
test esi, esi
je 0x404a1d
push esi
call fcn.00409cfb
pop ecx
mov eax, dword [ebp - 4]
pop esi
pop ebx
leave
ret
Function at 0x406ebd
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push edi
mov edi, dword [ebp + 0xc]
imul edi, dword [ebp + 0x10]
cmp byte [esi], 0
je 0x406eed
push 0
lea eax, [ebp + 0x10]
push eax
push edi
push dword [ebp + 8]
push dword [esi + 4]
call dword [sym.imp.kernel32.dll_ReadFile]
test eax, eax
jne 0x406ee8
mov byte [esi + 8], 1
mov eax, dword [ebp + 0x10]
jmp 0x406f15
mov ecx, dword [esi + 0x1c]
mov eax, dword [esi + 0x18]
lea edx, [ecx + edi]
cmp edx, eax
jbe 0x406efe
sub eax, ecx
mov edi, eax
mov eax, dword [esi + 0x14]
push edi
add eax, ecx
push eax
push dword [ebp + 8]
call fcn.00408db0
add esp, 0xc
add dword [esi + 0x1c], edi
mov eax, edi
xor edx, edx
div dword [ebp + 0xc]
pop edi
pop ebp
ret
Function at 0x407b50
Capabilities:
Get common file path

Disassembly:
push ecx
push ebx
xor ebx, ebx
cmp dword [esi], ebx
push edi
jne 0x407bd7
cmp dword [esi + 4], 0xffffffff
jne 0x407bd7
lea edi, [esi + 0x244]
push edi
push 0x104
call dword [sym.imp.kernel32.dll_GetCurrentDirectoryW]
push edi
call fcn.00409c28
movzx eax, word [esi + eax*2 + 0x242]
cmp ax, 0x5c
pop ecx
je 0x407b99
cmp ax, 0x2f
je 0x407b99
push 0x41dc18
push edi
call fcn.00408cea
pop ecx
pop ecx
push 0x20
call fcn.0040b581
pop ecx
mov ecx, dword [esp + 0x10]
mov dword [eax + 0x14], ecx
mov ecx, dword [esp + 0x14]
push eax
mov byte [eax], bl
mov byte [eax + 1], 1
mov byte [eax + 0x10], bl
mov dword [eax + 0x18], ecx
mov dword [eax + 0x1c], ebx
mov dword [eax + 0xc], ebx
call fcn.00407136
mov dword [esi], eax
neg eax
sbb eax, eax
and eax, 0xfffffe00
pop ecx
add eax, 0x200
jmp 0x407bdc
mov eax, 0x1000000
pop edi
pop ebx
pop ecx
ret 8

Function at 0x4087ed
Capabilities:
Get common file path
Write file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x190]
sub esp, 0x210
mov eax, dword [0x422044]
xor eax, ebp
mov dword [ebp + 0x18c], eax
push esi
xor esi, esi
and word [ebp - 0x7c], si
push 0x206
lea eax, [ebp - 0x7a]
push esi
push eax
call fcn.00408c40
add esp, 0xc
test ebx, ebx
je 0x4088a3
and dword [ebp - 0x80], esi
mov esi, 0x41dd90
push esi
call fcn.00409c28
test eax, eax
pop ecx
jbe 0x40884c
push 0x41dc3c
lea eax, [ebp - 0x80]
push esi
push eax
call fcn.004092a6
add esp, 0xc
jmp 0x408880
lea eax, [ebp - 0x7c]
push eax
mov esi, 0x104
push esi
call dword [sym.imp.kernel32.dll_GetTempPathW]
push 0x41ff6c
lea eax, [ebp - 0x7c]
push esi
push eax
call fcn.00408d30
push 0x41dc3c
lea eax, [ebp - 0x7c]
push eax
lea eax, [ebp - 0x80]
push eax
call fcn.004092a6
add esp, 0x18
xor esi, esi
inc esi
cmp dword [ebp - 0x80], 0
je 0x4088a3
push dword [ebp - 0x80]
push esi
push 0x200
push ebx
call fcn.00409b9b
push dword [ebp - 0x80]
call fcn.00409a05
add esp, 0x14
mov ecx, dword [ebp + 0x18c]
mov eax, esi
xor ecx, ebp
pop esi
call fcn.00408c2e
add ebp, 0x190
leave
ret
Function at 0x4088bb
Capabilities:
Get common file path
Read file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x198]
sub esp, 0x218
mov eax, dword [0x422044]
xor eax, ebp
mov dword [ebp + 0x194], eax
push ebx
push esi
xor ebx, ebx
push 0x206
lea eax, [ebp - 0x72]
mov esi, ecx
push ebx
push eax
mov dword [ebp - 0x80], esi
mov dword [ebp - 0x7c], ebx
mov word [ebp - 0x74], bx
call fcn.00408c40
add esp, 0xc
cmp esi, ebx
mov dword [ebp - 0x78], ebx
je 0x408991
push edi
mov edi, 0x41dc78
push edi
call fcn.00409c28
test eax, eax
pop ecx
je 0x408990
cmp dword [0x4230a0], 3
mov esi, 0x104
lea eax, [ebp - 0x74]
jne 0x408941
push esi
push eax
call dword [sym.imp.kernel32.dll_GetSystemDirectoryW]
push 0x41dc18
lea eax, [ebp - 0x74]
push esi
push eax
call fcn.00408d30
add esp, 0xc
jmp 0x408949
push eax
push esi
call dword [sym.imp.kernel32.dll_GetTempPathW]
push edi
lea eax, [ebp - 0x74]
push esi
push eax
call fcn.00408d30
push 0x41dc34
lea eax, [ebp - 0x74]
push eax
lea eax, [ebp - 0x78]
push eax
call fcn.004092a6
add esp, 0x18
cmp dword [ebp - 0x78], ebx
je 0x408990
push dword [ebp - 0x78]
xor esi, esi
inc esi
push esi
push 0x200
push dword [ebp - 0x80]
call fcn.00409977
push dword [ebp - 0x78]
call fcn.00409a05
add esp, 0x14
mov dword [ebp - 0x7c], esi
pop edi
mov ecx, dword [ebp + 0x194]
mov eax, dword [ebp - 0x7c]
pop esi
xor ecx, ebp
pop ebx
call fcn.00408c2e
add ebp, 0x198
leave
ret

Function at 0x4089ab
Capabilities:
Get common file path
Read file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x198]
sub esp, 0x218
mov eax, dword [0x422044]
xor eax, ebp
mov dword [ebp + 0x194], eax
push ebx
push esi
xor ebx, ebx
push 0x206
lea eax, [ebp - 0x72]
mov esi, ecx
push ebx
push eax
mov dword [ebp - 0x80], esi
mov dword [ebp - 0x7c], ebx
mov word [ebp - 0x74], bx
call fcn.00408c40
add esp, 0xc
cmp esi, ebx
mov dword [ebp - 0x78], ebx
je 0x408a58
push edi
mov edi, 0x41ff6c
push edi
call fcn.00409c28
test eax, eax
pop ecx
je 0x408a57
lea eax, [ebp - 0x74]
push eax
mov esi, 0x104
push esi
call dword [sym.imp.kernel32.dll_GetTempPathW]
push edi
lea eax, [ebp - 0x74]
push esi
push eax
call fcn.00408d30
push 0x41dc34
lea eax, [ebp - 0x74]
push eax
lea eax, [ebp - 0x78]
push eax
call fcn.004092a6
add esp, 0x18
cmp dword [ebp - 0x78], ebx
je 0x408a57
push dword [ebp - 0x78]
xor esi, esi
inc esi
push esi
push 0x200
push dword [ebp - 0x80]
call fcn.00409977
push dword [ebp - 0x78]
call fcn.00409a05
add esp, 0x14
mov dword [ebp - 0x7c], esi
pop edi
mov ecx, dword [ebp + 0x194]
mov eax, dword [ebp - 0x7c]
pop esi
xor ecx, ebp
pop ebx
call fcn.00408c2e
add ebp, 0x198
leave
ret
Function at 0x408b67
Capabilities:
Check if file exists
Get file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
push dword [ebp + 8]
xor esi, esi
call dword [sym.imp.kernel32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x408b87
mov eax, dword [ebp + 8]
call fcn.00408bd2
test eax, eax
je 0x408bcd
push edi
push esi
push esi
push 2
push esi
push 1
push 0x40000000
push dword [ebp + 8]
call dword [sym.imp.kernel32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x408bcc
push esi
lea eax, [ebp + 0xc]
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push edi
call dword [sym.imp.kernel32.dll_WriteFile]
neg eax
sbb eax, eax
and eax, dword [ebp + 0xc]
cmp eax, dword [ebp + 0x10]
jne 0x408bc5
xor esi, esi
inc esi
push edi
call dword [sym.imp.kernel32.dll_CloseHandle]
pop edi
mov eax, esi
pop esi
pop ebp
ret

Function at 0x408bd2
Capabilities:
Check if file exists
Delete file
Get file attributes
Set file attributes

Disassembly:
push esi
mov esi, eax
push esi
call dword [sym.imp.kernel32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x408be5
xor eax, eax
pop esi
ret
test al, 1
je 0x408bec
xor eax, 1
test al, 4
je 0x408bf3
xor eax, 4
test al, 2
je 0x408bfa
xor eax, 2
test al, 0x20
je 0x408c01
xor eax, 0x20
push eax
push esi
call dword [sym.imp.kernel32.dll_SetFileAttributesW]
push esi
call dword [sym.imp.kernel32.dll_DeleteFileW]
mov esi, eax
call dword [sym.imp.kernel32.dll_GetLastError]
mov eax, esi
pop esi
ret

Function at 0x408c2e
Capabilities:
Terminate process

Disassembly:
cmp ecx, dword [0x422044]
jne 0x408c38
repz ret
jmp fcn.0040c9f3