joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4135d0
Capabilities:
Terminate thread

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
mov ebx, ecx
mov ecx, dword [ebp + 8]
imul ecx, ecx, 0x64
push esi
push edi
mov edi, dword [ebx + 0x9c]
mov esi, dword [edi + 0x1c]
sub ecx, esi
mov eax, 0x51eb851f
imul ecx
sar edx, 5
cmp dword [edi + 0x18], 2
jne 0x413619
mov eax, edx
shr eax, 0x1f
add eax, edx
cdq
sub eax, edx
sar eax, 1
cmp dword [edi + 0x14], 0
jne 0x413610
add esi, eax
jmp 0x413622
lea eax, [esi + eax + 0x32]
mov dword [ebp - 4], eax
jmp 0x413625
mov ecx, edx
shr ecx, 0x1f
add ecx, edx
add esi, ecx
mov dword [ebp - 4], esi
mov esi, 0x64
cmp dword [ebp + 8], esi
jne 0x413632
inc dword [edi + 0x14]
cmp dword [ebp + 0x10], 0xffffffff
jne 0x413669
mov edx, dword [ebx + 0x7c]
mov dword [edx + 0x24], 1
mov esi, dword [ebx + 0x9c]
mov eax, dword [esi + 0xc]
xor edi, edi
cmp eax, 0xffffffff
je 0x413661
push edi
push eax
call dword [sym.imp.KERNEL32.dll_TerminateThread]
mov dword [esi + 0xc], 0xffffffff
mov eax, dword [ebx + 0x68]
mov dword [eax + 0x24], edi
jmp 0x41369f
fild dword [ebp - 4]
fmul qword [0x48dcc8]
fidiv dword [ebp + 0xc]
call fcn.00431c80
mov edi, dword [ebx + 0x8c]
cmp eax, esi
jle 0x413689
mov dword [edi + 0x38], esi
jmp 0x413696
xor ecx, ecx
test eax, eax
sets cl
dec ecx
and ecx, eax
mov dword [edi + 0x38], ecx
mov dword [edi + 0x3c], 1
xor edi, edi
mov eax, dword [ebx + 0x9c]
mov edx, dword [eax + 0x18]
cmp edx, dword [eax + 0x14]
jne 0x41379e
mov esi, dword [ebx + 0xa4]
mov edx, dword [esi + 4]
mov eax, dword [esi + 8]
sub eax, edx
sar eax, 2
xor ecx, ecx
cmp eax, edi
jbe 0x4136e6
cmp eax, ecx
jbe 0x4137b0
mov eax, dword [edx + ecx*4]
mov dword [eax + 0x24], edi
mov edx, dword [esi + 4]
mov eax, dword [esi + 8]
sub eax, edx
inc ecx
sar eax, 2
cmp eax, ecx
ja 0x4136d0
mov esi, dword [ebx + 0xa8]
mov edx, dword [esi + 4]
mov eax, dword [esi + 8]
sub eax, edx
sar eax, 2
xor ecx, ecx
cmp eax, edi
jbe 0x41371b
cmp eax, ecx
jbe 0x4137b0
mov edx, dword [edx + ecx*4]
mov dword [edx + 0x24], edi
mov edx, dword [esi + 4]
mov eax, dword [esi + 8]
sub eax, edx
inc ecx
sar eax, 2
cmp eax, ecx
ja 0x413705
mov esi, dword [ebx + 0xac]
mov edx, dword [esi + 4]
mov eax, dword [esi + 8]
sub eax, edx
sar eax, 2
xor ecx, ecx
cmp eax, edi
jbe 0x41374c
cmp eax, ecx
jbe 0x4137b0
mov eax, dword [edx + ecx*4]
mov dword [eax + 0x24], edi
mov edx, dword [esi + 4]
mov eax, dword [esi + 8]
sub eax, edx
inc ecx
sar eax, 2
cmp eax, ecx
ja 0x413736
mov esi, dword [ebx + 0xb0]
mov edx, dword [esi + 4]
mov eax, dword [esi + 8]
sub eax, edx
sar eax, 2
xor ecx, ecx
cmp eax, edi
jbe 0x413781
cmp eax, ecx
jbe 0x4137b0
mov edx, dword [edx + ecx*4]
mov dword [edx + 0x24], 1
mov edx, dword [esi + 4]
mov eax, dword [esi + 8]
sub eax, edx
inc ecx
sar eax, 2
cmp eax, ecx
ja 0x413767
mov eax, dword [ebx + 0xa0]
mov dword [eax + 0x40], 3
mov ecx, dword [ebx + 0x68]
mov dword [ecx + 0x24], edi
mov dword [ebx + 0xc0], 1
push edi
lea esi, [ebx - 0xc]
call fcn.004130e0
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
push str.invalid_vector_T__subscript
call fcn.0042bbe0
int3
Function at 0x4137d0
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push ecx
push ebx
mov ebx, dword [0x499794]
add eax, 0xfffffb9c
push esi
push edi
cmp eax, 9
ja case.0x4137ee.1128
jmp dword [eax*4 + 0x413a38]
mov eax, dword [ebx + 0x84]
mov dword [eax + 0x24], 1
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov ecx, dword [ebx + 0x98]
mov dword [ecx + 0x24], 1
mov edx, dword [ebx + 0x98]
mov dword [edx + 0x38], 0
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
cmp dword [ebx + 0xa8], 0
je case.0x4137ee.1128
xor edi, edi
cmp dword [ebx + 0xc0], edi
je 0x4138aa
mov esi, dword [ebx + 0xb0]
call fcn.00411840
mov esi, dword [ebx + 0xb8]
call fcn.00411840
mov eax, dword [ebx + 0x74]
mov dword [eax + 0x24], edi
mov esi, dword [ebx + 0xb4]
mov edi, 1
call fcn.00411840
mov ecx, dword [ebx + 0x98]
mov dword [ecx + 0x38], 0
mov esi, dword [ebx + 0xa8]
call fcn.00415940
call fcn.0040efd0
mov ecx, eax
call fcn.004146b0
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov esi, dword [ebx + 0xb4]
call fcn.00411840
mov esi, dword [ebx + 0xb8]
xor edi, edi
call fcn.00411840
mov esi, dword [ebx + 0xb0]
mov edi, 1
call fcn.00411840
push 0
mov esi, ebx
call fcn.004130e0
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
push 0
push 0x48c250
push 0x48c258
jmp 0x413a1f
call fcn.00411b30
push 0
push 0
push eax
push 0x40b560
push 0
push 0
call fcn.0043000f
add esp, 0x18
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov edx, dword [ebx + 0x74]
mov dword [edx + 0x24], 1
mov eax, dword [ebx + 0x74]
mov edx, dword [ebp + 8]
mov dword [eax + 0x40], str.ck_W_vN
mov ecx, dword [ebx + 0x98]
push 0
mov esi, ebx
mov dword [ecx + 0x38], edx
call fcn.004130e0
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
test ecx, ecx
jne 0x413993
mov eax, dword [ebx + 0x74]
mov dword [eax + 0x40], str.ck_WSq
mov ecx, dword [ebx + 0x98]
mov dword [ecx + 0x38], 0x64
mov edx, dword [ebx + 0x74]
push 0
mov esi, ebx
mov dword [edx + 0x24], 1
call fcn.004130e0
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
cmp ecx, 1
jne 0x4139bf
mov eax, dword [ebx + 0x74]
mov dword [eax + 0x24], ecx
mov ecx, dword [ebx + 0x74]
push 0
mov esi, ebx
mov dword [ecx + 0x40], str.ck_W
call fcn.004130e0
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
cmp ecx, 2
jne 0x4139ce
mov edx, dword [ebx + 0x74]
mov dword [edx + 0x24], 0
push 0
mov esi, ebx
call fcn.004130e0
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
cmp ecx, 1
jne case.0x4137ee.1128
mov eax, dword [ebx + 0x98]
push 0
mov esi, ebx
mov dword [eax + 0x24], 0
call fcn.004130e0
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
cmp ecx, 0xffffffff
jne case.0x4137ee.1128
push 0
push 0x48c250
push 0x48c2b8
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
pop edi
pop esi
mov eax, 1
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x413a60
Capabilities:
Create process on windows
Extract resource via kernel32 functions
Get common file path
Write and execute a file
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x108
mov eax, dword [0x496684]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push 0x48c2fc
push 0x95
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.dll_FindResourceW]
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0x103
lea eax, [ebp - 0x107]
push 0
push eax
mov byte [ebp - 0x108], 0
call fcn.004316d0
add esp, 0xc
lea ecx, [ebp - 0x108]
push ecx
push 0
push 0
push 0x1a
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathA]
lea eax, [ebp - 0x108]
dec eax
mov edi, edi
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x413ad0
mov edx, dword [str.pcduoduo.exe]
mov ecx, dword [0x48c308]
mov dword [eax], edx
mov edx, dword [0x48c30c]
mov dword [eax + 4], ecx
mov cx, word [0x48c310]
mov dword [eax + 8], edx
mov word [eax + 0xc], cx
test esi, esi
jne 0x413b12
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042ca72
mov esp, ebp
pop ebp
ret
push ebx
push esi
push 0
call dword [sym.imp.KERNEL32.dll_SizeofResource]
mov ebx, eax
test ebx, ebx
je 0x413b2f
push esi
push 0
call dword [sym.imp.KERNEL32.dll_LoadResource]
test eax, eax
jne 0x413b41
pop ebx
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042ca72
mov esp, ebp
pop ebp
ret
push edi
push eax
call dword [sym.imp.KERNEL32.dll_LockResource]
mov edi, eax
test edi, edi
jne 0x413b60
pop edi
pop ebx
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042ca72
mov esp, ebp
pop ebp
ret
lea edx, [ebp - 0x108]
push 0x48c314
push edx
call fcn.0042d99d
mov esi, eax
add esp, 8
test esi, esi
je 0x413b8d
push esi
push 1
push ebx
push edi
call fcn.0042f6d0
push esi
call fcn.0042dc88
add esp, 0x14
push 5
push 0
push 0
lea eax, [ebp - 0x108]
push eax
push 0
push 0
call dword [sym.imp.SHELL32.dll_ShellExecuteA]
mov ecx, dword [ebp - 4]
pop edi
pop ebx
xor ecx, ebp
mov eax, 1
pop esi
call fcn.0042ca72
mov esp, ebp
pop ebp
ret

Function at 0x413bf0
Capabilities:
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x198
mov eax, dword [0x496684]
xor eax, ebp
mov dword [ebp - 4], eax
xor eax, eax
mov dword [esi + 5], eax
mov byte [esi + 4], al
lea eax, [ebp - 0x198]
push eax
push 0x101
mov dword [esi], vtable.CPing.0
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x413c44
push str._nError_initializing_WinSock_n
call fcn.00413eb0
add esp, 4
mov eax, esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042ca72
mov esp, ebp
pop ebp
ret
mov ecx, 0x101
cmp word [ebp - 0x198], cx
je 0x413c6f
push str._nWinSock_version_not_supported_n
call fcn.00413eb0
add esp, 4
mov eax, esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042ca72
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
xor ecx, ebp
mov byte [esi + 4], 1
mov eax, esi
call fcn.0042ca72
mov esp, ebp
pop ebp
ret
Function at 0x413ce0
Capabilities:
Create raw socket
Get socket status
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x148
mov eax, dword [0x496684]
xor eax, ebp
mov dword [ebp - 4], eax
cmp byte [edi + 4], 0
push ebx
push esi
mov esi, ecx
jne 0x413d1a
push str._nWinSock_must_be_initializing_n
call fcn.00413eb0
add esp, 4
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042ca72
mov esp, ebp
pop ebp
ret
push 1
push 3
push 2
call dword [sym.imp.WS2_32.dll_socket]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x413d3e
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.socket___error:__d_n
jmp 0x413e97
push esi
call dword [sym.imp.WS2_32.dll_gethostbyname]
test eax, eax
jne 0x413d54
push esi
push str._nHost_not_found:__s_n
jmp 0x413e97
mov eax, dword [eax + 0xc]
mov ecx, dword [eax]
mov eax, dword [ecx]
push 0x20
push eax
mov dword [ebp - 0x11c], eax
mov dword [ebp - 0x120], 2
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
push esi
push str._nPinging__s___s__with__d_bytes_of_data:_n
call fcn.00413eb0
add esp, 0x10
xor esi, esi
mov dword [edi + 5], esi
mov dword [ebp - 0x138], esi
jmp 0x413d92
xor esi, esi
lea edx, [ebp - 0x120]
push edx
push ebx
call fcn.00413f20
lea eax, [ebp - 0x144]
push eax
push esi
push esi
lea ecx, [ebp - 0x110]
push ecx
push 1
mov dword [ebp - 0x110], 1
mov dword [ebp - 0x10c], ebx
mov dword [ebp - 0x144], 5
mov dword [ebp - 0x140], esi
call dword [sym.imp.WS2_32.dll_select]
cmp eax, 0xffffffff
je 0x413e4c
cmp eax, esi
je 0x413e62
lea edx, [ebp - 0x130]
push edx
push ebx
lea esi, [ebp - 0x131]
call fcn.00414000
mov dword [ebp - 0x13c], eax
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, dword [ebp - 0x12c]
mov esi, eax
movzx eax, byte [ebp - 0x131]
sub esi, dword [ebp - 0x13c]
push eax
push esi
push 0x20
push ecx
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
push str._nReply_from:__s:_bytes_d_time_ldms_TTL_d
call fcn.00413eb0
mov eax, dword [ebp - 0x138]
add dword [edi + 5], esi
inc eax
add esp, 0x14
mov dword [ebp - 0x138], eax
cmp eax, 2
jl 0x413d90
jmp 0x413e72
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.select___error:__d_n
call fcn.00413eb0
add esp, 8
jmp 0x413e6f
push str._nTimeOut
call fcn.00413eb0
add esp, 4
mov dword [edi + 5], esi
push 0x48c498
call fcn.00413eb0
add esp, 4
push ebx
call dword [sym.imp.WS2_32.dll_closesocket]
cmp eax, 0xffffffff
jne 0x413e9f
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.closesocket___error:__d_n
call fcn.00413eb0
add esp, 8
mov ecx, dword [ebp - 4]
pop esi
xor ecx, ebp
pop ebx
call fcn.0042ca72
mov esp, ebp
pop ebp
ret

Function at 0x413eb0
Capabilities:
Print debug messages

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x2004
call fcn.00444f60
mov eax, dword [0x496684]
xor eax, ebp
mov dword [ebp - 4], eax
push 0x2000
lea eax, [ebp - 0x2004]
push 0
push eax
call fcn.004316d0
mov edx, dword [ebp + 8]
lea ecx, [ebp + 0xc]
push ecx
push edx
lea eax, [ebp - 0x2004]
push 0x2000
push eax
call fcn.00430ab9
add esp, 0x1c
lea ecx, [ebp - 0x2004]
push ecx
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042ca72
mov esp, ebp
pop ebp
ret
Function at 0x413f20
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, esp
push ecx
mov ax, word [0x4982c8]
mov word [0x499ed0], ax
inc ax
mov word [0x4982c8], ax
mov ax, word [0x4982cc]
mov word [0x499ed2], ax
inc ax
mov word [0x4982cc], ax
mov dword [0x499ecc], 8
xor eax, eax
jmp 0x413f60
lea ecx, [eax + 0x20]
mov byte [eax + 0x499ed9], cl
inc eax
cmp eax, 0x20
jl 0x413f60
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [0x499ed5], eax
xor eax, eax
mov ecx, 0x499ecc
lea edx, [eax + 0x16]
push esi
movzx esi, word [ecx]
add eax, esi
add ecx, 2
dec edx
jne 0x413f85
mov dword [ebp - 4], edx
mov dl, byte [ecx]
mov byte [ebp - 4], dl
movzx ecx, word [ebp - 4]
add eax, ecx
mov ecx, eax
sar ecx, 0x10
and eax, 0xffff
add ecx, eax
mov eax, dword [ebp + 0xc]
push 0x10
push eax
mov edx, ecx
push 0
sar edx, 0x10
push 0x2d
add edx, ecx
mov ecx, dword [ebp + 8]
push 0x499ecc
not edx
push ecx
mov word [0x499ece], dx
call dword [sym.imp.WS2_32.dll_sendto]
mov esi, eax
cmp esi, 0xffffffff
jne 0x413ff0
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.sendto___error:__d_n
call fcn.00413eb0
add esp, 8
mov eax, esi
pop esi
mov esp, ebp
pop ebp
ret 8

Function at 0x414000
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14c
mov eax, dword [0x496684]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
lea ecx, [ebp - 0x14c]
push ecx
push eax
mov eax, dword [ebp + 8]
push 0
push 0x141
lea edx, [ebp - 0x148]
push edx
push eax
mov dword [ebp - 0x14c], 0x10
call dword [sym.imp.WS2_32.dll_recvfrom]
cmp eax, 0xffffffff
jne 0x414077
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.recvfrom___error:__d_n
call fcn.00413eb0
mov cl, byte [ebp - 0x140]
mov eax, dword [ebp - 0x12b]
add esp, 8
mov byte [esi], cl
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042ca72
mov esp, ebp
pop ebp
ret 8
mov ecx, dword [ebp - 4]
mov dl, byte [ebp - 0x140]
mov eax, dword [ebp - 0x12b]
xor ecx, ebp
mov byte [esi], dl
call fcn.0042ca72
mov esp, ebp
pop ebp
ret 8
Function at 0x415920
Capabilities:
Terminate thread

Disassembly:
mov eax, dword [esi + 0xc]
cmp eax, 0xffffffff
je 0x415938
push 0
push eax
call dword [sym.imp.KERNEL32.dll_TerminateThread]
mov dword [esi + 0xc], 0xffffffff
mov eax, 1
ret

Function at 0x415940
Capabilities:
Create thread

Disassembly:
lea eax, [esi + 0x10]
push eax
push 0
push esi
push 0x4156d0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov dword [esi + 0xc], eax
mov eax, 1
ret
Function at 0x417720
Capabilities:
Encode data using xor
Hash data with crc32

Disassembly:
test ecx, ecx
jne 0x417727
xor eax, eax
ret
push esi
not eax
cmp edx, 8
jb 0x4177fd
mov esi, edx
shr esi, 3
push edi
lea esp, [esp]
movzx edi, byte [ecx]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x48ac98]
movzx edi, byte [ecx + 1]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x48ac98]
movzx edi, byte [ecx + 2]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x48ac98]
movzx edi, byte [ecx + 3]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x48ac98]
movzx edi, byte [ecx + 4]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x48ac98]
movzx edi, byte [ecx + 5]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x48ac98]
movzx edi, byte [ecx + 6]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x48ac98]
movzx edi, byte [ecx + 7]
xor edi, eax
and edi, 0xff
shr eax, 8
xor eax, dword [edi*4 + 0x48ac98]
add ecx, 8
sub edx, 8
dec esi
jne 0x417740
pop edi
test edx, edx
je 0x41781a
movzx esi, byte [ecx]
xor esi, eax
and esi, 0xff
shr eax, 8
xor eax, dword [esi*4 + 0x48ac98]
inc ecx
dec edx
jne 0x417801
not eax
pop esi
ret

Function at 0x417f50
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push esi
mov esi, ebx
imul esi, dword [ebp + 0xc]
cmp byte [edi], 0
je 0x417f86
mov ecx, dword [ebp + 8]
mov edx, dword [edi + 4]
push 0
lea eax, [ebp + 0xc]
push eax
push esi
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x417f7c
mov byte [edi + 8], 1
mov eax, dword [ebp + 0xc]
xor edx, edx
div ebx
pop esi
pop ebp
ret
mov ecx, dword [edi + 0x18]
mov eax, dword [edi + 0x14]
lea edx, [ecx + esi]
cmp edx, eax
jbe 0x417f97
sub eax, ecx
mov esi, eax
mov eax, dword [edi + 0x10]
add eax, ecx
mov ecx, dword [ebp + 8]
push esi
push eax
push ecx
call fcn.00431360
add dword [edi + 0x18], esi
add esp, 0xc
mov eax, esi
xor edx, edx
div ebx
pop esi
pop ebp
ret

Function at 0x417fc0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 8
cmp byte [esi], 0
push edi
mov edi, 1
je 0x417ff3
mov edx, dword [esi + 4]
push 0
lea eax, [ebp - 8]
push eax
push edi
lea ecx, [ebp - 1]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x417fee
mov byte [esi + 8], 1
mov edi, dword [ebp - 8]
jmp 0x41801e
mov eax, dword [esi + 0x14]
push ebx
mov ebx, dword [esi + 0x18]
lea ecx, [ebx + 1]
cmp ecx, eax
jbe 0x418005
sub eax, ebx
mov edi, eax
mov edx, dword [esi + 0x10]
push edi
add edx, ebx
push edx
lea eax, [ebp - 1]
push eax
call fcn.00431360
add esp, 0xc
add ebx, edi
mov dword [esi + 0x18], ebx
pop ebx
cmp edi, 1
pop edi
jne 0x418033
movzx ecx, byte [ebp - 1]
mov edx, dword [ebp + 8]
mov dword [edx], ecx
xor eax, eax
mov esp, ebp
pop ebp
ret
cmp byte [esi], 0
je 0x41802d
cmp byte [esi + 8], 0
je 0x41802d
or eax, 0xffffffff
mov esp, ebp
pop ebp
ret
Function at 0x4180d0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
cmp byte [esi], 0
je 0x418117
cmp byte [esi + 1], 0
je 0x41811f
mov eax, dword [esi + 4]
push 2
push 0
push 0
push eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp byte [esi], 0
push ebx
je 0x418131
cmp byte [esi + 1], 0
je 0x418125
mov edx, dword [esi + 4]
push 1
push 0
push 0
push edx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov ebx, eax
sub ebx, dword [esi + 0xc]
mov dword [ebp - 4], ebx
jmp 0x418139
mov ecx, dword [esi + 0x14]
mov dword [esi + 0x18], ecx
jmp 0x4180f1
xor eax, eax
mov esp, ebp
pop ebp
ret
mov dword [ebp - 4], 0
mov ebx, dword [ebp - 4]
jmp 0x418139
mov eax, dword [esi + 0x18]
mov dword [ebp - 4], eax
mov ebx, eax
push edi
mov edi, 0xffff
mov dword [ebp - 8], edi
cmp ebx, edi
jae 0x41814b
mov dword [ebp - 8], ebx
mov edi, ebx
push 0x404
call fcn.0042d673
add esp, 4
mov dword [ebp - 0x10], eax
test eax, eax
jne 0x418165
pop edi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, 4
mov dword [ebp - 0x14], 0
cmp edi, eax
jbe 0x418279
jmp 0x418189
mov edi, dword [ebp - 8]
mov eax, dword [ebp - 0xc]
mov ebx, dword [ebp - 4]
add eax, 0x400
mov dword [ebp - 0xc], edi
cmp eax, edi
ja 0x418198
mov dword [ebp - 0xc], eax
mov eax, ebx
sub eax, dword [ebp - 0xc]
sub ebx, eax
mov dword [ebp - 0x1c], eax
cmp ebx, 0x404
jbe 0x4181af
mov ebx, 0x404
cmp byte [esi], 0
je 0x4181d4
cmp byte [esi + 1], 0
je 0x418279
mov ecx, dword [esi + 0xc]
mov edx, dword [esi + 4]
push 0
push 0
add ecx, eax
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
jmp 0x4181d7
mov dword [esi + 0x18], eax
cmp byte [esi], 0
mov edi, ebx
je 0x418200
mov ecx, dword [ebp - 0x10]
mov edx, dword [esi + 4]
push 0
lea eax, [ebp - 0x18]
push eax
push ebx
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x4181fb
mov byte [esi + 8], 1
mov eax, dword [ebp - 0x18]
jmp 0x418229
mov eax, dword [esi + 0x18]
mov ecx, dword [esi + 0x14]
lea edx, [eax + ebx]
cmp edx, ecx
jbe 0x418211
sub ecx, eax
mov edi, ecx
mov ecx, dword [esi + 0x10]
mov edx, dword [ebp - 0x10]
push edi
add ecx, eax
push ecx
push edx
call fcn.00431360
add esp, 0xc
add dword [esi + 0x18], edi
mov eax, edi
xor edx, edx
div ebx
cmp eax, 1
jne 0x418279
lea eax, [ebx - 3]
test eax, eax
jle 0x41826d
lea esp, [esp]
mov ecx, dword [ebp - 0x10]
dec eax
cmp byte [eax + ecx], 0x50
jne 0x41825f
cmp byte [eax + ecx + 1], 0x4b
jne 0x41825f
cmp byte [eax + ecx + 2], 5
jne 0x41825f
cmp byte [eax + ecx + 3], 6
je 0x418265
test eax, eax
jg 0x418240
jmp 0x41826d
add eax, dword [ebp - 0x1c]
mov dword [ebp - 0x14], eax
jne 0x418279
mov edx, dword [ebp - 8]
cmp dword [ebp - 0xc], edx
jb 0x418180
mov eax, dword [ebp - 0x10]
push eax
call fcn.0042efdd
mov eax, dword [ebp - 0x14]
add esp, 4
pop edi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x418f40
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
cmp dword [esi], 0
push edi
jne 0x418fa8
cmp dword [esi + 4], 0xffffffff
jne 0x418fa8
lea edi, [esi + 0x138]
push edi
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryW]
add edi, 0xfffffffe
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x418f64
mov eax, dword [str._r_]
mov dword [edi], eax
mov eax, dword [ebp + 8]
lea edi, [ebp + 8]
call fcn.00417eb0
test eax, eax
jne 0x418f8e
mov eax, dword [ebp + 8]
pop edi
pop ebp
ret 4
call fcn.00418290
mov dword [esi], eax
neg eax
sbb eax, eax
and eax, 0xfffc0000
add eax, 0x40000
pop edi
pop ebp
ret 4
mov eax, 0x1000000
pop edi
pop ebp
ret 4

Function at 0x419640
Capabilities:
Create directory

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x108
mov eax, dword [0x496684]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, edi
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x419658
sub eax, edx
cmp eax, 0x104
ja 0x419700
mov eax, edi
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x419671
push ebx
sub eax, edx
push 0x103
mov ebx, eax
lea eax, [ebp - 0x107]
push 0
push eax
mov byte [ebp - 0x108], cl
call fcn.004316d0
push 0x5c
push edi
call fcn.00430db0
add esp, 0x14
test eax, eax
je 0x4196f6
push esi
mov esi, edi
push 0x5c
push esi
call fcn.00430db0
add esp, 8
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x4196b6
sub eax, edx
mov esi, ebx
sub esi, eax
inc esi
push esi
lea ecx, [ebp - 0x108]
push edi
push ecx
call fcn.0042f2a0
add esp, 0xc
push 0
lea edx, [ebp - 0x108]
push edx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
add esi, edi
push 0x5c
push esi
call fcn.00430db0
add esp, 8
test eax, eax
jne 0x4196a8
pop esi
push 0
push edi
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0042ca72
mov esp, ebp
pop ebp
ret