joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10031b10
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
sub esp, 0x14
push esi
mov esi, ecx
mov eax, dword [esi]
cmp eax, 0xffffffff
je 0x10031b6a
xor ecx, ecx
lea edx, [esp + 4]
mov dword [esp + 0xa], ecx
push edx
mov dword [esp + 0x12], ecx
mov word [esp + 0xc], 0
mov dword [esp + 0x16], ecx
mov dword [esp + 8], 0x10
mov word [esp + 0x1a], cx
lea ecx, [esp + 0xc]
push ecx
push eax
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x10031b6a
mov edx, dword [esp + 0xa]
push edx
call dword [sym.imp.WS2_32.dll_htons]
and eax, 0xffff
mov dword [esi + 0x88], eax
pop esi
add esp, 0x14
ret

Function at 0x10031d10
Capabilities:
Connect socket

Disassembly:
sub esp, 0x20
push ebx
push esi
mov esi, ecx
xor bl, bl
cmp dword [esi], 0xffffffff
jne 0x10031d2c
call fcn.10031a70
cmp eax, 0xffffffff
je 0x10031dd2
push 0
mov ecx, esi
call fcn.10031ae0
mov eax, dword [esp + 0x2c]
lea ecx, [esp + 0x18]
push eax
push ecx
call fcn.10034160
mov eax, dword [esp + 0x24]
xor edx, edx
mov dword [esp + 0x12], edx
add esp, 8
mov dword [esp + 0xe], edx
mov word [esp + 8], 0
mov dword [esp + 0x12], edx
test eax, eax
mov word [esp + 0x16], dx
jne 0x10031d6e
mov eax, dword [sym.imp.MSVCP60.dll_char_const__private:_static_char_const____cdecl_std::basic_string_char__struct_std::char_traits_char___class_std::allocator_char__::_Nullstr_void_::_2::_C]
mov ecx, dword [esp + 0x30]
lea edx, [esp + 8]
push ecx
push eax
push edx
call fcn.10031990
mov ecx, dword [esi]
add esp, 0xc
lea eax, [esp + 8]
push 0x10
push eax
push ecx
call dword [sym.imp.WS2_32.dll_connect]
test eax, eax
jne 0x10031da0
mov ecx, esi
call fcn.10031b10
mov bl, 1
jmp 0x10031da6
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ecx, dword [esp + 0x1c]
test ecx, ecx
je 0x10031dd2
mov al, byte [ecx - 1]
test al, al
je 0x10031dc8
cmp al, 0xff
je 0x10031dc8
dec al
pop esi
mov byte [ecx - 1], al
mov al, bl
pop ebx
add esp, 0x20
ret 8
dec ecx
push ecx
call fcn.1003ed30
add esp, 4
mov al, bl
pop esi
pop ebx
add esp, 0x20
ret 8
Function at 0x10031de0
Capabilities:
Send data
Send data on socket

Disassembly:
push ebp
mov ebp, ecx
cmp dword [ebp], 0xffffffff
jne 0x10031e04
mov eax, dword [ebp + 0x88]
add ebp, 5
push eax
push ebp
push str._comm__Socket__s:_d_::send_error:_Invalid_Socket.
push 0x100492a8
lea ecx, [esp + 0x18]
jmp 0x10031e25
mov eax, dword [esp + 8]
test eax, eax
jne 0x10031e3a
mov ecx, dword [ebp + 0x88]
add ebp, 5
push ecx
push ebp
push str._comm__Socket__s:_d_::send_error:_NULL_buffer.
push 0x100492e4
lea ecx, [esp + 0x18]
call fcn.1002ce00
push eax
call fcn.1002ce10
add esp, 0x10
or eax, 0xffffffff
pop ebp
ret 8
push ebx
push esi
push edi
mov edi, dword [esp + 0x18]
xor ebx, ebx
xor esi, esi
test edi, edi
jbe 0x10031eaf
mov edx, dword [esp + 0x14]
mov ecx, dword [ebp]
push 0
push edi
lea eax, [ebx + edx]
push eax
push ecx
call dword [sym.imp.WS2_32.dll_send]
mov esi, eax
cmp esi, 0xffffffff
je 0x10031e76
test esi, esi
je 0x10031e71
sub edi, esi
add ebx, esi
test edi, edi
ja 0x10031e49
cmp esi, 0xffffffff
jne 0x10031ead
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
call fcn.1002ba20
mov edx, dword [ebp + 0x88]
add esp, 4
add ebp, 5
lea ecx, [esp + 0x14]
push eax
push edx
push ebp
push str._comm__Socket__s:_d_::send_error:__s.
push 0x1004931c
call fcn.1002ce00
push eax
call fcn.1002ce10
add esp, 0x14
test edi, edi
mov eax, ebx
je 0x10031eb5
mov eax, esi
pop edi
pop esi
pop ebx
pop ebp
ret 8
Function at 0x10032170
Capabilities:
Receive data
Receive data on socket

Disassembly:
push edi
mov edi, ecx
mov eax, dword [edi]
cmp eax, 0xffffffff
jne 0x10032195
mov eax, dword [edi + 0x88]
add edi, 5
push eax
push edi
push str._comm__Socket__s:_d_::recv_error:_Invalid_Socket.
push 0x100493f4
lea ecx, [esp + 0x1c]
jmp 0x100321b6
mov edx, dword [esp + 8]
test edx, edx
jne 0x100321cb
mov ecx, dword [edi + 0x88]
add edi, 5
push ecx
push edi
push str._comm__Socket__s:_d_::recv_error:_NULL_buffer.
push 0x10049430
lea ecx, [esp + 0x1c]
call fcn.1002ce00
push eax
call fcn.1002ce10
add esp, 0x10
or eax, 0xffffffff
pop edi
ret 0xc
mov cl, byte [edi + 4]
push ebx
test cl, cl
push esi
je 0x100321f0
mov ebx, dword [esp + 0x14]
test ebx, ebx
mov ecx, ebx
jg 0x100321e3
mov ecx, 1
push 0
push ecx
push edx
push eax
call dword [sym.imp.WS2_32.dll_recv]
jmp 0x1003221c
mov ebx, dword [esp + 0x14]
mov dword [esp + 0x10], 0x10
test ebx, ebx
mov ecx, ebx
jg 0x10032207
mov ecx, 1
lea esi, [esp + 0x10]
push esi
mov esi, dword [esp + 0x1c]
push esi
push 0
push ecx
push edx
push eax
call dword [sym.imp.WS2_32.dll_recvfrom]
mov esi, eax
cmp esi, 0xffffffff
jne 0x10032262
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
call fcn.1002ba20
mov edx, dword [edi + 0x88]
add esp, 4
add edi, 5
lea ecx, [esp + 0x14]
push eax
push edx
push edi
push str._comm__Socket__s:_d_::recv_error:__s.
push 0x10049468
call fcn.1002ce00
push eax
call fcn.1002ce10
add esp, 0x14
mov eax, esi
pop esi
pop ebx
pop edi
ret 0xc
test esi, esi
jne 0x10032291
test ebx, ebx
jle 0x10032291
mov eax, dword [edi + 0x88]
add edi, 5
push eax
push edi
push str._comm__Socket__s:_d_::recv_info:_The_connection_has_been_gracefully_closed.
push 0x10049498
lea ecx, [esp + 0x24]
call fcn.1002ce00
push eax
call fcn.1002ce10
add esp, 0x10
mov eax, esi
pop esi
pop ebx
pop edi
ret 0xc
Function at 0x100322a0
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ecx
push ebx
mov ebx, ecx
cmp dword [ebx], 0xffffffff
jne 0x100322c4
mov eax, dword [ebx + 0x88]
add ebx, 5
push eax
push ebx
push str._comm__Socket__s:_d_::recv_all_error:_Invalid_Socket.
push 0x100494ec
lea ecx, [esp + 0x1c]
jmp 0x100322e5
mov eax, dword [esp + 0xc]
test eax, eax
jne 0x100322fb
mov ecx, dword [ebx + 0x88]
add ebx, 5
push ecx
push ebx
push str._comm__Socket__s:_d_::recv_all_error:_NULL_buffer.
push 0x1004952c
lea ecx, [esp + 0x1c]
call fcn.1002ce00
push eax
call fcn.1002ce10
add esp, 0x10
or eax, 0xffffffff
pop ebx
pop ecx
ret 0xc
push ebp
mov ebp, dword [esp + 0x14]
push esi
push edi
xor edi, edi
xor esi, esi
test ebp, ebp
mov dword [esp + 0x10], 0x10
jle 0x100323a2
jmp 0x1003231c
mov eax, dword [esp + 0x18]
mov cl, byte [ebx + 4]
test cl, cl
je 0x10032338
mov ecx, dword [ebx]
mov edx, ebp
sub edx, esi
push 0
add eax, esi
push edx
push eax
push ecx
call dword [sym.imp.WS2_32.dll_recv]
jmp 0x10032355
mov ecx, dword [esp + 0x20]
lea edx, [esp + 0x10]
push edx
mov edx, ebp
push ecx
mov ecx, dword [ebx]
sub edx, esi
push 0
add eax, esi
push edx
push eax
push ecx
call dword [sym.imp.WS2_32.dll_recvfrom]
mov edi, eax
test edi, edi
je 0x10032366
cmp edi, 0xffffffff
je 0x1003236b
add esi, edi
cmp esi, ebp
jl 0x10032318
cmp edi, 0xffffffff
jne 0x100323a2
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
call fcn.1002ba20
mov edx, dword [ebx + 0x88]
add esp, 4
add ebx, 5
lea ecx, [esp + 0x18]
push eax
push edx
push ebx
push str._comm__Socket__s:_d_::recv_all_error:__s.
push 0x10049568
call fcn.1002ce00
push eax
call fcn.1002ce10
add esp, 0x14
cmp esi, ebp
mov eax, esi
je 0x100323aa
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret 0xc
Function at 0x10035310
Capabilities:
Get common file path

Disassembly:
sub esp, 0x22c
mov eax, dword [0x10054588]
mov dword [esp], str.getaddrinfo
test eax, eax
mov dword [esp + 4], 0x10034890
mov dword [esp + 8], str.getnameinfo
mov dword [esp + 0xc], 0x10034fd0
mov dword [esp + 0x10], str.freeaddrinfo
mov dword [esp + 0x14], 0x10034840
je 0x1003536b
mov eax, dword [esp + 0x230]
and eax, 0xffff
mov eax, dword [eax*8 + 0x10049a2c]
add esp, 0x22c
ret 4
push ebx
push ebp
push esi
push edi
lea ecx, [esp + 0x134]
push 0x104
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
je 0x100354b4
lea edi, [esp + 0x134]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x28]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x28]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.ws2_32
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
mov ebx, dword [sym.imp.KERNEL32.dll_LoadLibraryA]
and ecx, 3
lea eax, [esp + 0x28]
rep movsb byte es:[edi], byte [esi]
push eax
call ebx
mov ebp, dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov esi, eax
test esi, esi
je 0x1003540c
push str.getaddrinfo
push esi
call ebp
test eax, eax
jne 0x10035484
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
lea edi, [esp + 0x134]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x28]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x28]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.wship6
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [esp + 0x28]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
call ebx
mov esi, eax
test esi, esi
je 0x100354b4
push str.getaddrinfo
push esi
call ebp
test eax, eax
jne 0x10035484
push esi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
jmp 0x100354b4
xor ebx, ebx
lea edi, [esp + 0x14]
mov ecx, dword [edi - 4]
push ecx
push esi
call ebp
test eax, eax
mov dword [edi], eax
je 0x1003547b
inc ebx
add edi, 8
cmp ebx, 3
jl 0x1003548a
xor eax, eax
mov edx, dword [esp + eax + 0x14]
mov dword [eax + 0x10049a2c], edx
add eax, 8
cmp eax, 0x18
jl 0x100354a2
mov eax, dword [esp + 0x240]
pop edi
and eax, 0xffff
pop esi
pop ebp
mov dword [0x10054588], 1
mov eax, dword [eax*8 + 0x10049a2c]
pop ebx
add esp, 0x22c
ret 4
Function at 0x10038e20
Capabilities:
Terminate thread

Disassembly:
push ecx
push ebx
push esi
mov esi, ecx
push edi
mov dword [esi], 0x10040708
call fcn.10038fb0
lea ecx, [esi + 0x94]
call fcn.10032460
mov eax, dword [esi + 8]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
xor ebx, ebx
mov dword [esi], 0x10040594
cmp eax, ebx
mov byte [esi + 0xc], bl
je 0x10038eb4
push 0x64
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x10038eb4
mov ecx, dword [esi + 8]
lea eax, [esp + 0xc]
push eax
push ecx
mov byte [esi + 0xc], bl
mov dword [esp + 0x14], ebx
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
cmp dword [esp + 0xc], 0x103
jne 0x10038eb4
mov edx, dword [esi + 8]
push 0xffffffffffffffff
push edx
call dword [sym.imp.KERNEL32.dll_TerminateThread]
mov eax, dword [esi + 8]
push eax
call edi
mov al, byte [esi + 0xd]
mov dword [esi + 4], ebx
cmp al, bl
je 0x10038eb4
cmp esi, ebx
je 0x10038eb4
mov ecx, esi
call fcn.1000ecb0
push esi
call fcn.1003ed30
add esp, 4
mov dword [esi + 8], ebx
mov dword [esi + 4], ebx
mov eax, dword [esi + 0x90]
cmp eax, ebx
je 0x10038ec7
push eax
call edi
mov dword [esi + 0x90], ebx
pop edi
pop esi
pop ebx
pop ecx
ret

Function at 0x10038ee0
Capabilities:
Create thread

Disassembly:
push ecx
mov eax, dword [esp + 8]
push ebx
push esi
mov esi, ecx
push edi
push 0x1004a164
lea edi, [esi + 0x94]
push eax
mov ecx, edi
call fcn.10031b70
lea ebx, [esi + 0xe]
mov ecx, edi
push ebx
mov dword [esi + 0x520], eax
call fcn.10031a40
mov al, byte [esi + 0xc]
test al, al
jne 0x10038f7d
lea ecx, [esp + 0x14]
mov dword [esp + 0x14], 0
push ecx
push 0
push esi
push 0x100087d0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov edx, dword [esp + 0x14]
mov dword [esi + 8], eax
test eax, eax
mov dword [esi + 4], edx
jne 0x10038f8e
push eax
call fcn.1002ba20
add esp, 4
lea ecx, [esp + 0xc]
push eax
push ebx
push str._comm__create_thread__s__failed:__s
push 0x10046650
call fcn.1002ce00
push eax
call fcn.1002ce10
mov ecx, dword [esi + 0x520]
add esp, 0x10
xor eax, eax
test ecx, ecx
pop edi
pop esi
setg al
pop ebx
pop ecx
ret 4
mov eax, dword [esi + 0x90]
test eax, eax
je 0x10038f8e
push eax
call dword [sym.imp.KERNEL32.dll_SetEvent]
mov ecx, dword [esi + 0x520]
xor eax, eax
test ecx, ecx
pop edi
pop esi
setg al
pop ebx
pop ecx
ret 4
Function at 0x1003a520
Capabilities:
Receive data
Receive data on socket

Disassembly:
sub esp, 0x10
push esi
mov esi, ecx
push edi
xor edi, edi
mov eax, dword [esi]
mov dword [esp + 0xc], edi
mov dword [esp + 8], edi
call dword [eax + 0x1c]
test eax, eax
jne 0x1003a5f7
cmp dword [esi + 0x10], 0xffffffff
je 0x1003a5f7
mov ecx, dword [esi + 8]
push ebx
mov dword [esi + 0x54], edi
call fcn.1003dcc0
mov ecx, dword [esi + 8]
mov ebx, eax
call fcn.1003d910
mov ecx, dword [esi + 8]
add ebx, eax
mov dword [esp + 0x18], ebx
call fcn.1003d910
mov ecx, dword [esi + 8]
mov ebx, eax
call fcn.1003d810
sub eax, ebx
lea ecx, [esi + 0x14]
mov dword [esp + 0x14], eax
push edi
lea edx, [esp + 0x14]
push ecx
lea eax, [esp + 0x14]
push edx
mov edx, dword [esi + 0x10]
push eax
lea ecx, [esp + 0x24]
push 1
push ecx
push edx
call dword [sym.imp.WS2_32.dll_WSARecv]
xor ecx, ecx
mov ebx, dword [sym.imp.KERNEL32.dll_SetEvent]
cmp eax, 0xffffffff
setne cl
mov eax, ecx
cmp eax, edi
mov dword [esi + 0x50], eax
je 0x1003a5c6
mov edx, dword [esp + 0xc]
mov ecx, dword [esi + 8]
push edx
call fcn.1003d990
mov eax, dword [esi + 0x24]
push eax
call ebx
cmp dword [esi + 0x50], edi
jne 0x1003a5ec
mov edi, dword [sym.imp.WS2_32.dll_WSAGetLastError]
call edi
cmp eax, 0x3e5
je 0x1003a5ec
mov dword [esi + 0xc], 1
call edi
mov ecx, dword [esi + 0x24]
mov dword [esi + 0x54], eax
push ecx
call ebx
mov eax, dword [esp + 0xc]
pop ebx
pop edi
pop esi
add esp, 0x10
ret
pop edi
or eax, 0xffffffff
pop esi
add esp, 0x10
ret
Function at 0x1003a750
Capabilities:
Receive data
Receive data on socket

Disassembly:
sub esp, 0x10
push esi
mov esi, ecx
push edi
mov dword [esp + 8], 0
mov eax, dword [esi]
call dword [eax + 0x1c]
test eax, eax
jne 0x1003a865
mov eax, dword [esi + 0x10]
cmp eax, 0xffffffff
je 0x1003a865
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x20]
mov dword [esp + 0x14], ecx
lea edi, [esi + 0x14]
mov dword [esp + 0x10], edx
push 0
lea ecx, [esp + 0x10]
push edi
lea edx, [esp + 0x10]
push ecx
push edx
lea ecx, [esp + 0x20]
push 1
push ecx
push eax
mov dword [esp + 0x28], 0
call dword [sym.imp.WS2_32.dll_WSARecv]
cmp eax, 0xffffffff
je 0x1003a7c9
mov edx, dword [esi + 0x24]
push edx
call dword [sym.imp.KERNEL32.dll_ResetEvent]
mov eax, dword [esp + 8]
pop edi
pop esi
add esp, 0x10
ret 0xc
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x3e5
je 0x1003a7f4
mov edx, dword [esi + 0x24]
mov dword [esp + 8], 0xfffffffe
push edx
call dword [sym.imp.KERNEL32.dll_ResetEvent]
mov eax, dword [esp + 8]
pop edi
pop esi
add esp, 0x10
ret 0xc
mov eax, dword [esp + 0x24]
mov ecx, dword [esi + 0x24]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x1003a82c
cmp eax, 0x102
jne 0x1003a84f
mov edx, dword [esi + 0x24]
mov dword [esp + 8], 0xfffffffc
push edx
call dword [sym.imp.KERNEL32.dll_ResetEvent]
mov eax, dword [esp + 8]
pop edi
pop esi
add esp, 0x10
ret 0xc
mov ecx, dword [esi + 0x10]
lea edx, [esp + 0xc]
push edx
lea eax, [esp + 0xc]
push 0
push eax
push edi
push ecx
call dword [sym.imp.WS2_32.dll_WSAGetOverlappedResult]
test eax, eax
jne 0x1003a84f
mov dword [esp + 8], 0xfffffffd
mov edx, dword [esi + 0x24]
push edx
call dword [sym.imp.KERNEL32.dll_ResetEvent]
mov eax, dword [esp + 8]
pop edi
pop esi
add esp, 0x10
ret 0xc
pop edi
or eax, 0xffffffff
pop esi
add esp, 0x10
ret 0xc
Function at 0x1003a870
Capabilities:
Send data
Send data on socket

Disassembly:
sub esp, 0x10
mov eax, dword [esp + 0x14]
push esi
mov esi, ecx
push edi
mov ecx, dword [esp + 0x20]
mov dword [esp + 8], 0
test eax, eax
mov dword [esp + 0xc], 0
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], ecx
je 0x1003a983
test ecx, ecx
jbe 0x1003a983
mov eax, dword [esi + 0x10]
cmp eax, 0xffffffff
je 0x1003a983
test eax, eax
je 0x1003a983
mov ecx, dword [esi + 8]
test ecx, ecx
jne 0x1003a8cf
pop edi
mov eax, 0xfffffffe
pop esi
add esp, 0x10
ret 0xc
lea edi, [esi + 0x28]
push 0
push edi
lea ecx, [esp + 0x10]
push 0
push ecx
lea edx, [esp + 0x20]
push 1
push edx
push eax
call dword [sym.imp.WS2_32.dll_WSASend]
cmp eax, 0xffffffff
jne 0x1003a954
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x3e5
je 0x1003a90d
mov dword [esi + 0xc], 1
mov dword [esp + 8], 0xfffffffe
jmp 0x1003a954
mov ecx, dword [esp + 0x24]
mov edx, dword [esi + 0x38]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x1003a931
cmp eax, 0x102
jne 0x1003a954
mov dword [esp + 8], 0xfffffffc
jmp 0x1003a954
mov edx, dword [esi + 0x10]
lea eax, [esp + 0xc]
push eax
lea ecx, [esp + 0xc]
push 0
push ecx
push edi
push edx
call dword [sym.imp.WS2_32.dll_WSAGetOverlappedResult]
test eax, eax
jne 0x1003a954
mov dword [esp + 8], 0xfffffffd
mov eax, dword [esi + 0x38]
push eax
call dword [sym.imp.KERNEL32.dll_ResetEvent]
mov ecx, dword [esp + 8]
test ecx, ecx
jle 0x1003a979
mov edi, dword [esi + 0x48]
mov eax, ecx
cdq
add edi, eax
mov dword [esi + 0x48], edi
mov eax, dword [esi + 0x4c]
adc eax, edx
mov dword [esi + 0x4c], eax
pop edi
mov eax, ecx
pop esi
add esp, 0x10
ret 0xc
pop edi
or eax, 0xffffffff
pop esi
add esp, 0x10
ret 0xc
Function at 0x401220
Capabilities:
Access peb ldr_data

Disassembly:
mov eax, dword fs:[0x30]
mov eax, dword [eax + 0xc]
mov eax, dword [eax + 0x14]
mov eax, dword [eax]
mov eax, dword [eax]
mov eax, dword [eax + 0x10]
ret
Function at 0x401a20
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x1c
push ebx
mov ebx, ecx
push esi
push edi
cmp dword [ebx + 0x38], 0
je 0x401a4c
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [ebp + 8]
call dword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::xsputn_char_const___long_long___int64__]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebx + 0x20]
mov esi, dword [ebp + 0xc]
mov edi, dword [ebp + 0x10]
mov dword [esp + 0x20], esi
mov ecx, dword [eax]
lea eax, [ebx + 0x30]
mov dword [esp + 0x24], edi
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x18], eax
test ecx, ecx
je 0x401a74
mov eax, dword [eax]
mov ecx, dword [eax]
jmp 0x401a7a
xor ecx, ecx
mov dword [esp + 0x18], eax
mov eax, ecx
cdq
mov dword [esp + 0x10], eax
mov ecx, edx
mov dword [esp + 0x14], ecx
test edi, edi
jl 0x401b04
jg 0x401a91
test esi, esi
je 0x401b04
test ecx, ecx
jl 0x401ae7
jg 0x401a9b
test eax, eax
je 0x401ae7
cmp edi, ecx
jg 0x401aaf
jl 0x401aa5
cmp esi, eax
jae 0x401aaf
mov eax, esi
mov dword [esp + 0x10], esi
mov dword [esp + 0x14], edi
push eax
push dword [ebp + 8]
push dword [esp + 0x24]
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [esp + 0x24]
add esp, 0xc
mov ecx, dword [esp + 0x10]
mov edx, dword [ebp + 8]
add edx, ecx
sub esi, ecx
mov eax, dword [eax]
sbb edi, dword [esp + 0x14]
sub dword [eax], ecx
mov eax, dword [ebx + 0x20]
add dword [eax], ecx
test edi, edi
jl 0x401b04
jg 0x401aea
test esi, esi
je 0x401b04
jmp 0x401aea
mov edx, dword [ebp + 8]
mov eax, dword [ebx + 0x4c]
test eax, eax
je 0x401b04
push eax
push esi
push 1
push edx
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
add esp, 0x10
sub esi, eax
sbb edi, 0
mov eax, dword [esp + 0x20]
mov edx, dword [esp + 0x24]
sub eax, esi
sbb edx, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x401b20
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, ecx
mov ecx, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 4], esi
test eax, eax
jg 0x401b4c
jl 0x401b40
test ecx, ecx
jne 0x401b4c
pop esi
xor eax, eax
xor edx, edx
pop ebx
mov esp, ebp
pop ebp
ret 0xc
cmp dword [ebx + 0x38], 0
je 0x401b65
push eax
push ecx
push esi
mov ecx, ebx
call dword [sym.imp.MSVCP140.dll_protected_virtual:_long_long___int64____thiscall_std::basic_streambuf_char__struct_std::char_traits_char__::xsgetn_char___long_long___int64__]
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [ebx + 0x1c]
push edi
mov edi, ecx
mov eax, dword [eax]
mov dword [ebp - 8], eax
test eax, eax
je 0x401bb3
mov eax, dword [ebx + 0x2c]
lea edx, [ebx + 0x2c]
mov dword [ebp - 0xc], edx
mov eax, dword [eax]
test eax, eax
je 0x401bb9
mov edi, dword [ebp - 4]
cmp eax, ecx
mov esi, ecx
cmovb esi, eax
push esi
push dword [ebp - 8]
push edi
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [ebx + 0x2c]
add edi, esi
mov dword [ebp - 4], edi
add esp, 0xc
mov edi, dword [ebp + 0xc]
sub edi, esi
sub dword [eax], esi
mov eax, dword [ebx + 0x1c]
add dword [eax], esi
mov esi, dword [ebp - 4]
jmp 0x401bb9
lea eax, [ebx + 0x2c]
mov dword [ebp - 0xc], eax
cmp dword [ebx + 0x4c], 0
je 0x401c26
mov ecx, dword [ebx + 0xc]
lea eax, [ebx + 0x3c]
cmp dword [ecx], eax
jne 0x401be2
mov eax, dword [ebx + 0xc]
mov edx, dword [ebx + 0x54]
mov ecx, dword [ebx + 0x50]
sub edx, ecx
mov dword [eax], ecx
mov eax, dword [ebx + 0x1c]
mov dword [eax], ecx
mov eax, dword [ebp - 0xc]
mov eax, dword [eax]
mov dword [eax], edx
mov eax, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
cmp edi, 0xfff
jbe 0x401c14
nop
push dword [ebx + 0x4c]
push 0xfff
push 1
push esi
call eax
add esp, 0x10
add esi, eax
sub edi, eax
cmp eax, 0xfff
jne 0x401c26
cmp edi, eax
mov eax, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
ja 0x401bf0
test edi, edi
je 0x401c26
push dword [ebx + 0x4c]
push edi
push 1
push esi
call eax
add esp, 0x10
sub edi, eax
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 0x10]
sub eax, edi
pop edi
pop esi
sbb edx, 0
pop ebx
mov esp, ebp
pop ebp
ret 0xc
Function at 0x401fa0
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x406040]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [ebp + 8]
push esi
mov esi, ecx
cmp ebx, 0xffffffff
jne 0x401fd0
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00402dee
mov esp, ebp
pop ebp
ret 4
mov eax, dword [esi + 0x20]
push edi
mov ecx, dword [eax]
test ecx, ecx
je 0x40200c
mov edx, dword [esi + 0x30]
mov edi, dword [edx]
lea eax, [edi + ecx]
cmp ecx, eax
jae 0x40200c
lea ecx, [edi - 1]
mov eax, ebx
mov dword [edx], ecx
mov edx, dword [esi + 0x20]
pop edi
mov esi, dword [edx]
lea ecx, [esi + 1]
mov dword [edx], ecx
mov byte [esi], bl
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00402dee
mov esp, ebp
pop ebp
ret 4
cmp dword [esi + 0x4c], 0
je 0x4020e3
mov edi, dword [esi + 0xc]
lea eax, [esi + 0x3c]
cmp dword [edi], eax
jne 0x402034
mov edx, dword [esi + 0x54]
mov ecx, dword [esi + 0x50]
sub edx, ecx
mov dword [edi], ecx
mov eax, dword [esi + 0x1c]
mov dword [eax], ecx
mov eax, dword [esi + 0x2c]
mov dword [eax], edx
mov ecx, dword [esi + 0x38]
test ecx, ecx
jne 0x402040
movsx eax, bl
jmp 0x402078
lea eax, [ebp - 0x2c]
mov byte [ebp - 0x25], bl
push eax
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x24]
push eax
lea eax, [ebp - 0x25]
push eax
lea eax, [esi + 0x40]
push eax
call dword [sym.imp.MSVCP140.dll_public:_int___thiscall_std::codecvt_char__char__struct__Mbstatet_::out_struct__Mbstatet___char_const___char_const___char_const____char___char___char___const]
sub eax, 0
je 0x4020a2
sub eax, 1
je 0x4020a2
sub eax, 2
jne 0x4020e3
movsx eax, byte [ebp - 0x25]
push dword [esi + 0x4c]
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fputc]
add esp, 8
or ecx, 0xffffffff
cmp eax, ecx
cmove ebx, ecx
pop edi
pop esi
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00402dee
mov esp, ebp
pop ebp
ret 4
mov edi, dword [ebp - 0x2c]
lea eax, [ebp - 0x24]
sub edi, eax
je 0x4020c0
push dword [esi + 0x4c]
push edi
push 1
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
add esp, 0x10
cmp edi, eax
jne 0x4020e3
lea ecx, [ebp - 0x25]
mov byte [esi + 0x3d], 1
or eax, 0xffffffff
cmp dword [ebp - 0x30], ecx
pop edi
pop esi
cmovne eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00402dee
mov esp, ebp
pop ebp
ret 4
mov ecx, dword [ebp - 4]
or eax, 0xffffffff
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00402dee
mov esp, ebp
pop ebp
ret 4