joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4070c0
Capabilities:
Access peb ldr_data
Get process heap flags

Disassembly:
push 0xffffffffffffffff
push 0x422918
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x18
push ebx
push ebp
push esi
mov esi, ecx
xor ebp, ebp
mov byte [esp + 0x18], 0
push edi
mov dword [esp + 0x10], ebp
mov dword [esp + 0x18], esi
mov byte [esp + 0x1c], 0
mov dword [esp + 0x30], ebp
lea ecx, [esp + 0x18]
call fcn.004051a0
mov dword [esp + 0x30], 1
cmp dword [esi + 0x20], ebp
lea ecx, [esp + 0x20]
lea edi, [esi + 0xc]
jbe 0x4071eb
mov eax, dword [esi + 0x1c]
mov eax, dword [eax]
mov ebx, dword [eax + 8]
lea eax, [esp + 0x10]
push eax
push ecx
mov ecx, edi
mov dword [esp + 0x18], ebx
call fcn.00405e60
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x20]
lea edx, [esp + 0x14]
push edx
push eax
push ecx
mov dword [esp + 0x20], ebp
call fcn.00405c90
mov eax, dword [esp + 0x20]
add esp, 0xc
cmp eax, ebp
je 0x407193
cmp dword [esi + 0x34], ebp
jbe 0x407187
call dword [sym.imp.KERNEL32.dll_GetTickCount]
lea edx, [esp + 0x10]
push edx
mov ecx, edi
mov ebp, eax
call fcn.00406dc0
mov ecx, dword [eax]
mov eax, dword [esi + 0x34]
sub ebp, ecx
cmp ebp, eax
jb 0x4071d1
lea eax, [esp + 0x10]
push eax
mov ecx, edi
call fcn.00406a40
xor ebp, ebp
jmp 0x407193
lea ecx, [esp + 0x10]
push ecx
mov ecx, edi
call fcn.00406a40
mov ecx, dword [esi + 0x1c]
mov eax, dword [ecx]
cmp eax, ecx
je 0x4071bb
mov ecx, dword [eax + 4]
mov edx, dword [eax]
mov dword [ecx], edx
mov ecx, dword [eax]
mov edx, dword [eax + 4]
push eax
mov dword [ecx + 4], edx
call sub.MFC71.DLL_operator_delete_1
mov eax, dword [esi + 0x20]
add esp, 4
dec eax
mov dword [esi + 0x20], eax
mov eax, dword [esi + 0x38]
cmp eax, ebp
je 0x40726a
push ebx
call eax
add esp, 4
jmp 0x40726a
push 0x1028
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ebx, eax
test ebx, ebx
jmp 0x40723f
lea eax, [esp + 0x10]
push eax
push ecx
mov ecx, edi
call fcn.00405e60
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x20]
lea edx, [esp + 0x14]
push edx
push eax
push ecx
mov dword [esp + 0x20], ebp
call fcn.00405c90
mov eax, dword [esp + 0x20]
add esp, 0xc
cmp eax, ebp
je 0x407227
lea edx, [esp + 0x10]
push edx
mov ecx, edi
call fcn.00406a40
push 0x1028
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ebx, eax
cmp ebx, ebp
jne 0x407267
mov dword [esp + 0x30], 0xffffffff
lea ecx, [esp + 0x18]
call fcn.004056e0
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
mov ecx, dword [esp + 0x18]
mov dword fs:[0], ecx
add esp, 0x24
ret
inc dword [esi + 0x28]
xor eax, eax
mov ecx, 0x40a
mov edi, ebx
rep stosd dword es:[edi], eax
inc dword [esi + 0x2c]
mov dword [esp + 0x30], 0xffffffff
mov al, byte [esp + 0x1c]
test al, al
je 0x407296
mov ecx, dword [esp + 0x18]
mov byte [esp + 0x1c], 0
call fcn.00404850
mov ecx, dword [esp + 0x28]
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
mov dword fs:[0], ecx
add esp, 0x24
ret
Function at 0x4075b0
Capabilities:
Access peb ldr_data
Get process heap flags

Disassembly:
push 0xffffffffffffffff
push 0x422918
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x18
push ebx
push ebp
push esi
mov esi, ecx
xor ebp, ebp
mov byte [esp + 0x18], 0
push edi
mov dword [esp + 0x10], ebp
mov dword [esp + 0x18], esi
mov byte [esp + 0x1c], 0
mov dword [esp + 0x30], ebp
lea ecx, [esp + 0x18]
call fcn.004051a0
mov dword [esp + 0x30], 1
cmp dword [esi + 0x20], ebp
lea ecx, [esp + 0x20]
lea edi, [esi + 0xc]
jbe 0x4076db
mov eax, dword [esi + 0x1c]
mov eax, dword [eax]
mov ebx, dword [eax + 8]
lea eax, [esp + 0x10]
push eax
push ecx
mov ecx, edi
mov dword [esp + 0x18], ebx
call fcn.00405e60
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x20]
lea edx, [esp + 0x14]
push edx
push eax
push ecx
mov dword [esp + 0x20], ebp
call fcn.00405c90
mov eax, dword [esp + 0x20]
add esp, 0xc
cmp eax, ebp
je 0x407683
cmp dword [esi + 0x34], ebp
jbe 0x407677
call dword [sym.imp.KERNEL32.dll_GetTickCount]
lea edx, [esp + 0x10]
push edx
mov ecx, edi
mov ebp, eax
call fcn.00406dc0
mov ecx, dword [eax]
mov eax, dword [esi + 0x34]
sub ebp, ecx
cmp ebp, eax
jb 0x4076c1
lea eax, [esp + 0x10]
push eax
mov ecx, edi
call fcn.00406ad0
xor ebp, ebp
jmp 0x407683
lea ecx, [esp + 0x10]
push ecx
mov ecx, edi
call fcn.00406ad0
mov ecx, dword [esi + 0x1c]
mov eax, dword [ecx]
cmp eax, ecx
je 0x4076ab
mov ecx, dword [eax + 4]
mov edx, dword [eax]
mov dword [ecx], edx
mov ecx, dword [eax]
mov edx, dword [eax + 4]
push eax
mov dword [ecx + 4], edx
call sub.MFC71.DLL_operator_delete_1
mov eax, dword [esi + 0x20]
add esp, 4
dec eax
mov dword [esi + 0x20], eax
mov eax, dword [esi + 0x38]
cmp eax, ebp
je 0x40775a
push ebx
call eax
add esp, 4
jmp 0x40775a
push 0x80
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ebx, eax
test ebx, ebx
jmp 0x40772f
lea eax, [esp + 0x10]
push eax
push ecx
mov ecx, edi
call fcn.00405e60
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x20]
lea edx, [esp + 0x14]
push edx
push eax
push ecx
mov dword [esp + 0x20], ebp
call fcn.00405c90
mov eax, dword [esp + 0x20]
add esp, 0xc
cmp eax, ebp
je 0x407717
lea edx, [esp + 0x10]
push edx
mov ecx, edi
call fcn.00406ad0
push 0x80
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ebx, eax
cmp ebx, ebp
jne 0x407757
mov dword [esp + 0x30], 0xffffffff
lea ecx, [esp + 0x18]
call fcn.004056e0
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
mov ecx, dword [esp + 0x18]
mov dword fs:[0], ecx
add esp, 0x24
ret
inc dword [esi + 0x28]
xor eax, eax
mov ecx, 0x20
mov edi, ebx
rep stosd dword es:[edi], eax
inc dword [esi + 0x2c]
mov dword [esp + 0x30], 0xffffffff
mov al, byte [esp + 0x1c]
test al, al
je 0x407786
mov ecx, dword [esp + 0x18]
mov byte [esp + 0x1c], 0
call fcn.00404850
mov ecx, dword [esp + 0x28]
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
mov dword fs:[0], ecx
add esp, 0x24
ret
Function at 0x407b40
Capabilities:
Create tcp socket
Create udp socket

Disassembly:
sub esp, 8
mov eax, dword [esp + 0xc]
test eax, eax
push ebx
push esi
push edi
mov dword [esp + 0xc], 0
jle 0x407bdd
mov ebx, dword [sym.imp.WS2_32.dll_WSASocketA]
mov ecx, 0x434928
call fcn.004070c0
mov esi, eax
test esi, esi
je 0x407be9
push 1
push 0
push 0
push 6
push 1
push 2
mov dword [esi + 0x101c], 2
call ebx
mov edi, eax
cmp edi, 0xffffffff
je 0x407bff
push esi
lea eax, [esp + 0x14]
push eax
push 0x20
push 0x20
push 0
lea ecx, [esi + 0x14]
push ecx
mov dword [esi + 0x1020], edi
mov edx, dword [0x43075c]
push edi
push edx
mov dword [esp + 0x30], 0
call dword [0x430774]
test eax, eax
jne 0x407bcc
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x3e5
jne 0x407c15
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 0x18]
inc eax
cmp eax, ecx
mov dword [esp + 0xc], eax
jl 0x407b60
pop edi
pop esi
mov eax, 1
pop ebx
add esp, 8
ret
push str.accept_exg_queue_io.pop____NULL.
call fcn.0040b4c0
add esp, 4
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 8
ret
push str.accept_exWSASocket_fail.
call fcn.0040b4c0
add esp, 4
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 8
ret
mov eax, dword [0x43075c]
push edi
push eax
push str.g_fn_AcceptEx_failedg_sck_listen__p___sck_client__p_.
call fcn.0040b4c0
push edi
call fcn.00405160
add esp, 0x10
push esi
mov ecx, 0x434928
call fcn.004077a0
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 8
ret
Function at 0x407cb0
Capabilities:
Get socket status
Send data
Send data on socket

Disassembly:
sub esp, 0x118
push ebx
push ebp
mov ebp, dword [sym.imp.WS2_32.dll_WSASend]
push esi
mov esi, dword [esp + 0x12c]
xor eax, eax
mov dword [esi + 0x101c], 1
push edi
mov edi, dword [esp + 0x12c]
mov ecx, esi
mov dword [ecx], eax
mov dword [ecx + 4], eax
mov dword [ecx + 8], eax
xor ebx, ebx
push ebx
mov dword [ecx + 0xc], eax
push esi
mov dword [ecx + 0x10], eax
mov eax, dword [esi + 0x1014]
push ebx
lea ecx, [esp + 0x1c]
push ecx
lea edx, [esi + 0x14]
mov dword [esp + 0x28], edx
push 1
lea edx, [esp + 0x28]
mov dword [esp + 0x28], eax
mov eax, dword [edi]
push edx
push eax
mov dword [esp + 0x2c], ebx
call ebp
cmp eax, 0xffffffff
jne 0x407dc7
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x3e5
je 0x407dc7
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x407dd7
push str.send_packetWSASend_fail_WSAEWOULDBLOCK_.
call fcn.0040b4c0
mov ecx, dword [edi]
add esp, 4
lea edx, [esp + 0x1c]
push edx
push ebx
lea eax, [esp + 0x2c]
push eax
push ebx
push ebx
mov dword [esp + 0x3c], ecx
mov dword [esp + 0x38], 1
mov dword [esp + 0x34], ebx
mov dword [esp + 0x30], 0x3c
call dword [sym.imp.WS2_32.dll_select]
cmp eax, 0xffffffff
jne 0x407d8e
push str.send_packeterror__select_SOCKET_ERROR__fail.
call fcn.0040b4c0
add esp, 4
jmp 0x407df0
cmp eax, ebx
jne 0x407da1
push str.send_packeterror__select_0__fail.
call fcn.0040b4c0
add esp, 4
jmp 0x407df0
mov eax, dword [edi]
push ebx
push esi
push ebx
lea ecx, [esp + 0x1c]
push ecx
push 1
lea edx, [esp + 0x28]
push edx
push eax
call ebp
cmp eax, 0xffffffff
jne 0x407dc7
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x3e5
jne 0x407df0
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x118
ret
mov ecx, dword [edi]
push ecx
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push 0xffffffffffffffff
push str.send_packetWSASend_failret_send:_d__error_code:_d__sck:_p.
call fcn.0040b4c0
add esp, 0x10
push esi
mov ecx, 0x434928
call fcn.004077a0
mov edx, dword [edi]
mov esi, dword [sym.imp.WS2_32.dll_closesocket]
push edx
call esi
push edi
mov ecx, 0x434964
call fcn.004077a0
mov edi, dword [edi + 0x78]
cmp edi, ebx
je 0x407e28
mov eax, dword [edi]
push eax
call esi
push edi
mov ecx, 0x434964
call fcn.004077a0
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
add esp, 0x118
ret
Function at 0x407e40
Capabilities:
Get socket status
Receive data
Receive data on socket

Disassembly:
sub esp, 0x11c
push ebx
push ebp
push esi
mov esi, dword [esp + 0x12c]
xor eax, eax
push edi
mov edi, dword [esp + 0x134]
xor ebx, ebx
mov dword [edi + 0x101c], ebx
mov ecx, edi
mov dword [ecx], eax
mov dword [ecx + 4], eax
mov dword [ecx + 8], eax
mov dword [ecx + 0xc], eax
mov dword [ecx + 0x10], eax
cmp dword [esp + 0x138], ebx
je 0x407e9c
mov dword [edi + 0x1014], ebx
mov dword [edi + 0x1018], ebx
cmp dword [esi + 0x74], 2
jne 0x407e9c
cmp dword [esi + 0x70], ebx
jne 0x407e9c
mov dword [edi + 0x1018], 9
mov ecx, dword [edi + 0x1014]
mov eax, dword [edi + 0x1018]
cmp eax, ebx
lea edx, [ecx + edi + 0x14]
mov dword [esp + 0x14], ebx
mov dword [esp + 0x10], ebx
mov dword [esp + 0x1c], edx
jne 0x407ec1
mov eax, 0x1000
mov ebp, dword [sym.imp.WS2_32.dll_WSARecv]
push ebx
sub eax, ecx
push edi
lea ecx, [esp + 0x18]
push ecx
mov ecx, dword [esi]
lea edx, [esp + 0x20]
push edx
mov dword [esp + 0x28], eax
push 1
lea eax, [esp + 0x2c]
push eax
push ecx
call ebp
cmp eax, 0xffffffff
jne 0x407f9b
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x3e5
je 0x407f9b
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x407fab
push str.recv_packetWSARecv_fail_WSAEWOULDBLOCK_.
call fcn.0040b4c0
mov edx, dword [esi]
add esp, 4
lea eax, [esp + 0x20]
push eax
push ebx
push ebx
lea ecx, [esp + 0x34]
push ecx
push ebx
mov dword [esp + 0x40], edx
mov dword [esp + 0x3c], 1
mov dword [esp + 0x38], ebx
mov dword [esp + 0x34], 0x3c
call dword [sym.imp.WS2_32.dll_select]
cmp eax, 0xffffffff
jne 0x407f5e
push str.recv_packeterror__select_SOCKET_ERROR__fail.
call fcn.0040b4c0
add esp, 4
jmp 0x407fc4
cmp eax, ebx
jne 0x407f71
push str.recv_packeterror__select_0__fail.
call fcn.0040b4c0
add esp, 4
jmp 0x407fc4
push ebx
push edi
lea edx, [esp + 0x18]
push edx
mov edx, dword [esi]
lea eax, [esp + 0x20]
push eax
push 1
lea ecx, [esp + 0x2c]
push ecx
push edx
call ebp
cmp eax, 0xffffffff
jne 0x407f9b
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x3e5
jne 0x407fc4
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x11c
ret
mov eax, dword [esi]
push eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push 0xffffffffffffffff
push str.recv_packetWSARecv_failret_recv:_d__error_code:_d__sck:_p.
call fcn.0040b4c0
add esp, 0x10
push edi
mov ecx, 0x434928
call fcn.004077a0
mov ecx, dword [esi]
mov edi, dword [sym.imp.WS2_32.dll_closesocket]
push ecx
call edi
push esi
mov ecx, 0x434964
call fcn.004077a0
mov esi, dword [esi + 0x78]
cmp esi, ebx
je 0x407ffc
mov edx, dword [esi]
push edx
call edi
push esi
mov ecx, 0x434964
call fcn.004077a0
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
add esp, 0x11c
ret
Function at 0x4087e0
Capabilities:
Set socket configuration

Disassembly:
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x18]
mov eax, dword [edi + 0x1020]
push 4
push 0x43075c
push 0x700b
push 0xffff
mov ebx, 1
push eax
mov ebp, ebx
call dword [sym.imp.WS2_32.dll_setsockopt]
mov ecx, dword [edi + 0x1020]
push 0x10000
push ecx
call fcn.00404f70
mov edx, dword [edi + 0x1020]
push 0x10000
push edx
call fcn.00405020
mov eax, dword [edi + 0x1020]
push eax
call fcn.004050d0
mov eax, dword [0x430908]
mov ecx, dword [esp + 0x28]
inc eax
push eax
push ecx
push str.handle_accept_eventpPerHandleContext:_p__g_acceptnum:_d.
mov dword [0x430908], eax
call fcn.0040b4c0
add esp, 0x20
mov ecx, 0x434964
call fcn.004075b0
mov esi, eax
test esi, esi
je 0x4088cb
mov edx, dword [edi + 0x1020]
push 0
mov dword [esi + 0x74], ebx
mov dword [esi + 0x6c], ebx
mov dword [esi], edx
mov dword [esi + 0x70], 0
mov eax, dword [0x430760]
push esi
mov ecx, edx
push eax
push ecx
mov ebx, eax
call dword [sym.imp.KERNEL32.dll_CreateIoCompletionPort]
cmp eax, ebx
je 0x4088b6
push str.handle_accept_eventassociate_completion_port_fail.
call fcn.0040b4c0
add esp, 4
push edi
push esi
xor ebx, ebx
call fcn.00407c50
add esp, 8
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
ret
push edi
push esi
mov dword [esi + 0x70], 2
call fcn.00408740
add esp, 8
test eax, eax
jne 0x4088de
push edi
push esi
xor ebx, ebx
call fcn.00407c50
add esp, 8
pop edi
pop esi
pop ebp
mov eax, ebx
pop ebx
ret
pop edi
pop esi
mov eax, ebp
pop ebp
pop ebx
ret
Function at 0x408ea0
Capabilities:
Parse pe header

Disassembly:
push ebp
mov ebp, dword [esp + 8]
test ebp, ebp
je 0x408f2b
test edi, edi
je 0x408f2b
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_IsBadReadPtr]
push 0x40
push edi
call ebx
test eax, eax
jne 0x408f26
cmp word [edi], 0x5a4d
jne 0x408f26
push esi
mov esi, dword [edi + 0x3c]
push 0xf8
add esi, edi
push esi
call ebx
test eax, eax
jne 0x408eec
cmp dword [esi], 0x4550
jne 0x408eec
mov esi, dword [esi + 0x80]
test esi, esi
jne 0x408ef2
pop esi
pop ebx
xor eax, eax
pop ebp
ret
mov eax, dword [esi + edi + 0xc]
add esi, edi
test eax, eax
je 0x408f19
mov ebx, dword [sym.imp.MSVCR71.dll__stricmp]
add eax, edi
push ebp
push eax
call ebx
add esp, 8
test eax, eax
je 0x408f19
mov eax, dword [esi + 0x20]
add esi, 0x14
test eax, eax
jne 0x408f02
mov eax, dword [esi + 0xc]
neg eax
sbb eax, eax
and eax, esi
pop esi
pop ebx
pop ebp
ret
pop ebx
xor eax, eax
pop ebp
ret
xor eax, eax
pop ebp
ret

Function at 0x4090b0
Capabilities:
Enumerate process modules

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x234
mov eax, dword [0x4306a0]
push ebx
push esi
mov dword [esp + 0x238], eax
push edi
xor eax, eax
mov ecx, 0x88
lea edi, [esp + 0x14]
mov dword [esp + 0x10], 0x224
rep stosd dword es:[edi], eax
mov eax, dword [ebp + 8]
test eax, eax
je 0x409158
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x409158
push 0
push 8
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov esi, eax
cmp esi, 0xffffffff
je 0x409158
lea eax, [esp + 0x10]
push eax
push esi
call sub.KERNEL32.dll_Module32First
test eax, eax
je 0x409139
mov edi, dword [ebp + 0x14]
mov ebx, dword [ebp + 0x10]
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp + 8]
mov eax, dword [esp + 0x2c]
push edi
push ebx
push ecx
push edx
push eax
call fcn.00408fa0
add esp, 0x14
lea ecx, [esp + 0x10]
push ecx
push esi
call sub.KERNEL32.dll_Module32Next
test eax, eax
jne 0x409113
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 1
mov ecx, dword [esp + 0x23c]
call fcn.00421871
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [esp + 0x23c]
xor eax, eax
call fcn.00421871
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x40ad50
Capabilities:
Check if file exists
Copy file
Delete file
Get file attributes
Set file attributes

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x114
mov eax, dword [0x4306a0]
push ebx
push esi
push edi
mov dword [esp + 0x11c], eax
mov eax, dword [ebp + 8]
push 0x427fb4
push eax
call dword [sym.imp.MSVCR71.dll_fopen]
mov ecx, dword [ebp + 0xc]
mov esi, eax
push esi
push ecx
call dword [sym.imp.MSVCR71.dll_fputs]
mov edi, dword [sym.imp.MSVCR71.dll_ftell]
push esi
call edi
push 2
push 0
push esi
mov ebx, eax
call dword [sym.imp.MSVCR71.dll_fseek]
push esi
call edi
push 0
push ebx
push esi
mov edi, eax
call dword [sym.imp.MSVCR71.dll_fseek]
push esi
call dword [sym.imp.MSVCR71.dll_fclose]
add esp, 0x34
cmp edi, 0x200000
jle 0x40ae62
mov esi, dword [ebp + 8]
xor eax, eax
mov byte [esp + 0x10], 0
mov ecx, 0x40
lea edi, [esp + 0x11]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea edx, [esp + 0x10]
stosb byte es:[edi], al
mov eax, esi
sub edx, esi
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x40ade2
lea eax, [esp + 0x10]
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x40adf3
sub eax, edx
lea edi, [esp + 0x10]
mov byte [esp + eax + 0xc], cl
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x40ae05
mov edx, dword [str._old_.log]
mov eax, dword [0x427fac]
mov cx, word [0x427fb0]
mov dword [edi], edx
push 0
lea edx, [esp + 0x14]
push edx
mov dword [edi + 4], eax
push esi
mov word [edi + 8], cx
call dword [sym.imp.KERNEL32.dll_CopyFileA]
test eax, eax
je 0x40ae62
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x40ae5b
mov ecx, eax
and ecx, 1
cmp cl, 1
jne 0x40ae5b
and eax, 0xfffffffe
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov ecx, dword [esp + 0x11c]
mov eax, 1
call fcn.00421871
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x40ea50
Capabilities:
Log keystrokes

Disassembly:
push esi
call dword [sym.imp.USER32.dll_GetForegroundWindow]
mov esi, eax
cmp esi, dword [esp + 8]
je 0x40eacc
push ebx
push ebp
push edi
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push 0
push esi
mov ebx, eax
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
push 1
mov ebp, eax
push ebp
push ebx
call dword [sym.imp.USER32.dll_AttachThreadInput]
mov edi, dword [esp + 0x18]
xor esi, esi
test edi, edi
jle 0x40eaad
lea esp, [esp]
mov eax, dword [esp + 0x14]
push eax
call dword [sym.imp.USER32.dll_SetForegroundWindow]
cmp eax, 1
je 0x40eaad
push 1
call dword [sym.imp.KERNEL32.dll_Sleep]
inc esi
cmp esi, edi
jl 0x40ea90
push 0
push ebp
push ebx
call dword [sym.imp.USER32.dll_AttachThreadInput]
cmp edi, esi
pop edi
pop ebp
pop ebx
jne 0x40eacc
push esi
push str.set_foreground_wndSetForegroundWindow_fail__cnt_attempt__:_d
call fcn.0040b4c0
add esp, 8
pop esi
ret
Function at 0x40ef70
Capabilities:
Get socket status
Receive data
Receive data on socket

Disassembly:
sub esp, 0x130
mov ecx, dword [esp + 0x134]
mov edx, dword [esp + 0x138]
xor eax, eax
mov dword [esp + 0x10], eax
push ebx
push esi
mov esi, dword [sym.imp.WS2_32.dll_WSARecv]
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], eax
push eax
mov dword [esp + 0x2c], eax
mov dword [esp + 0xc], eax
mov dword [esp + 0x10], eax
mov dword [esp + 0x18], ecx
lea eax, [esp + 0x1c]
push eax
lea ecx, [esp + 0x14]
push ecx
mov ecx, dword [0x430248]
mov dword [esp + 0x1c], edx
lea edx, [esp + 0x14]
push edx
push 1
lea eax, [esp + 0x24]
push eax
push ecx
call esi
cmp eax, 0xffffffff
jne 0x40f073
mov ebx, dword [sym.imp.WS2_32.dll_WSAGetLastError]
call ebx
cmp eax, 0x2733
jne 0x40f05f
mov edx, dword [0x430248]
push edx
push str.recv_packetWSARecv_fails_WSAEWOULDBLOCK_current_socket:__d
call fcn.0040b4c0
mov eax, dword [0x430248]
add esp, 8
lea ecx, [esp + 0x2c]
push ecx
push 0
push 0
lea edx, [esp + 0x40]
push edx
push 0
mov dword [esp + 0x4c], eax
mov dword [esp + 0x48], 1
mov dword [esp + 0x44], 0
mov dword [esp + 0x40], 0x1e
call dword [sym.imp.WS2_32.dll_select]
test eax, eax
jle 0x40f05f
push 0
lea eax, [esp + 0x1c]
push eax
lea ecx, [esp + 0x14]
push ecx
mov ecx, dword [0x430248]
lea edx, [esp + 0x14]
push edx
push 1
lea eax, [esp + 0x24]
push eax
push ecx
call esi
cmp eax, 0xffffffff
jne 0x40f073
call ebx
cmp eax, 0x3e5
je 0x40f071
mov edx, dword [0x430248]
push edx
jmp 0x40f0a3
call ebx
lea eax, [esp + 0xc]
push eax
mov eax, dword [0x430248]
push 1
lea ecx, [esp + 0x10]
push ecx
lea edx, [esp + 0x24]
push edx
push eax
call dword [sym.imp.WS2_32.dll_WSAGetOverlappedResult]
test eax, eax
je 0x40f09c
mov eax, dword [esp + 8]
test eax, eax
jne 0x40f0b5
mov ecx, dword [0x430248]
push ecx
call dword [sym.imp.WS2_32.dll_closesocket]
mov dword [0x430248], 0xffffffff
xor eax, eax
pop esi
pop ebx
add esp, 0x130
ret

Function at 0x40f5f0
Capabilities:
Encode data using xor

Disassembly:
mov dx, word [esp + 8]
test dx, dx
mov eax, 0x7fed7fed
mov ecx, 0xeeeeeeee
jbe 0x40f636
push ebx
push ebp
push esi
mov esi, dword [esp + 0x10]
push edi
mov edi, dword [esp + 0x1c]
shl edi, 8
movzx ebx, dx
movzx edx, byte [esi]
add eax, ecx
imul ecx, ecx, 0x21
lea ebp, [edx + edi]
xor eax, dword [ebp*4 + 0x435470]
add ecx, edx
inc esi
dec ebx
lea ecx, [ecx + eax + 3]
jne 0x40f616
pop edi
pop esi
pop ebp
pop ebx
ret
Function at 0x40f720
Capabilities:
Get socket status
Send data
Send data on socket

Disassembly:
sub esp, 0x110
push edi
mov edi, dword [esp + 0x120]
test edi, edi
mov eax, 1
mov dword [esp + 4], 0
jle 0x40f7e1
push ebx
mov ebx, dword [esp + 0x11c]
push ebp
mov ebp, dword [sym.imp.WS2_32.dll_send]
push esi
mov eax, dword [esp + 0x128]
mov ecx, dword [esp + 0x10]
push 0
push edi
lea esi, [ecx + eax]
push esi
push ebx
call ebp
cmp eax, 0xffffffff
jne 0x40f7bc
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x40f7dc
lea edx, [esp + 0x14]
push edx
push 0
lea eax, [esp + 0x24]
push eax
push 0
push 0
mov dword [esp + 0x34], ebx
mov dword [esp + 0x30], 1
mov dword [esp + 0x2c], 0
mov dword [esp + 0x28], 0xa
call dword [sym.imp.WS2_32.dll_select]
test eax, eax
jle 0x40f7dc
push 0
push edi
push esi
push ebx
call ebp
cmp eax, 0xffffffff
je 0x40f7dc
mov edx, dword [esp + 0x10]
add edx, eax
sub edi, eax
test edi, edi
mov dword [esp + 0x10], edx
jg 0x40f753
pop esi
pop ebp
pop ebx
mov eax, 1
pop edi
add esp, 0x110
ret
pop esi
pop ebp
xor eax, eax
pop ebx
pop edi
add esp, 0x110
ret

Function at 0x40f7f0
Capabilities:
Get socket status
Receive data
Receive data on socket

Disassembly:
sub esp, 0x10c
push ebx
mov ebx, dword [esp + 0x11c]
push ebp
mov ebp, dword [esp + 0x11c]
push esi
push edi
mov edi, dword [esp + 0x120]
push 0
push ebx
push ebp
push edi
call dword [sym.imp.WS2_32.dll_recv]
mov esi, eax
test esi, esi
jne 0x40f83a
push str.recv_tcp__socket_closed__ret__r__0.
call fcn.0040b250
add esp, 4
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x10c
ret
jge 0x40f8ae
cmp esi, 0xffffffff
jne 0x40f89a
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x40f89a
lea eax, [esp + 0x10]
push eax
push 0
push 0
lea ecx, [esp + 0x24]
push ecx
push 0
mov dword [esp + 0x30], edi
mov dword [esp + 0x2c], 1
mov dword [esp + 0x28], 0
mov dword [esp + 0x24], 0xa
call dword [sym.imp.WS2_32.dll_select]
test eax, eax
jle 0x40f8ae
push 0
push ebx
push ebp
push edi
call dword [sym.imp.WS2_32.dll_recv]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10c
ret
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push str.recv_tcp__ret__r___0__errcode:_d.
call fcn.0040b250
add esp, 8
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0x10c
ret