joyce8/EMBER2024-capa huggingface dataset:
Function at 0x10c2c01
Capabilities:
Delete directory
Set file attributes

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
mov eax, dword [eax + 0x7c]
mov eax, dword [eax + 0x18]
push esi
xor esi, esi
push esi
push esi
lea ecx, [ebp - 4]
push ecx
push esi
push eax
push dword [ebp + 8]
mov dword [ebp - 4], eax
call fcn.010b51f9
test ax, ax
je 0x10c2c2e
or ax, 0xffff
jmp 0x10c2c62
push edi
push dword [ebp - 4]
mov edi, dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
call edi
test eax, eax
jne 0x10c2c56
push esi
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push dword [ebp - 4]
call edi
test eax, eax
jne 0x10c2c56
mov esi, 0xfffffe05
push dword [ebp + 8]
call fcn.010b4b1b
mov ax, si
pop edi
pop esi
leave
ret 4

Function at 0x10c2ec8
Capabilities:
Terminate thread

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x10
mov eax, dword [ebx + 0x10]
mov edx, dword [ebx + 0x14]
push esi
mov esi, dword [eax + 0x270]
xor ecx, ecx
push edi
push ecx
push 1
push dword [esi + 0xc]
mov dword [ebp - 4], ecx
mov dword [ebp - 0xc], eax
mov dword [ebp - 0x10], edx
mov word [esi + 8], 1
mov dword [esi + 0x18], ecx
mov dword [esi + 0x1c], ecx
call dword [sym.imp.KERNEL32.dll_ReleaseSemaphore]
mov edi, dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
jmp 0x10c2f18
push 0
push dword [esi]
call edi
test eax, eax
je 0x10c2f26
call fcn.01075a13
push 0x64
push dword [esi + 0x10]
call edi
cmp eax, 0x102
je 0x10c2f09
push 0x1388
push dword [esi]
call edi
cmp eax, 0x102
jne 0x10c2f42
push 0
push dword [esi]
call dword [sym.imp.KERNEL32.dll_TerminateThread]
jmp 0x10c2f58
and dword [ebp - 8], 0
lea eax, [ebp - 8]
push eax
push dword [esi]
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
cmp dword [ebp - 8], 0
je 0x10c2f5f
mov dword [ebp - 4], 0xfffffe36
push dword [esi + 4]
call dword [sym.imp.ADVAPI32.dll_CloseEncryptedFileRaw]
push dword [esi]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call edi
push dword [esi + 0xc]
call edi
push dword [esi + 0x10]
call edi
push esi
call dword [sym.imp.msvcrt.dll_free]
mov eax, dword [ebp - 0xc]
and dword [eax + 0x270], 0
cmp word [ebp - 4], 0
pop ecx
pop edi
pop esi
jne 0x10c2fb4
mov eax, dword [ebp - 0x10]
cmp byte [eax], 9
push 1
push eax
push ebx
push dword [ebx]
jne 0x10c2fac
call fcn.010ae1ed
jmp 0x10c2fb1
call fcn.010adba4
mov dword [ebp - 4], eax
mov ax, word [ebp - 4]
leave
ret
Function at 0x10c30fc
Capabilities:
Create thread

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xc
mov edx, dword [ebp + 0x14]
push ebx
mov ebx, eax
mov eax, dword [ebx]
push esi
mov dword [ebp - 8], eax
mov eax, dword [ebp + 0x10]
xor ecx, ecx
push edi
xor edi, edi
mov dword [ebx], edi
inc ecx
mov dword [eax], ecx
cmp dword [edx], edi
mov eax, dword [ebp + 8]
mov eax, dword [eax + 0x10]
mov dword [ebp - 0xc], edi
mov esi, dword [eax + 0x270]
mov dword [ebp - 4], edi
mov dword [ebp + 0x10], eax
je 0x10c3189
cmp dword [esi], edi
jne 0x10c3175
mov ebx, dword [sym.imp.KERNEL32.dll_CreateSemaphoreW]
push edi
push ecx
push edi
push edi
call ebx
push edi
push 1
push edi
push edi
mov dword [esi + 0xc], eax
call ebx
mov dword [esi + 0x10], eax
lea eax, [ebp - 0xc]
push eax
push edi
push esi
push 0x10c2ea8
push edi
push edi
call dword [sym.imp.KERNEL32.dll_CreateThread]
cmp eax, edi
mov dword [esi], eax
jne 0x10c3175
mov ax, 0xfe30
jmp 0x10c3220
mov eax, dword [ebp + 0x14]
cmp dword [eax], 0x4445544e
je 0x10c321c
jmp 0x10c3211
xor ecx, ecx
mov dword [ebp + 0x14], ecx
cmp ecx, dword [ebp - 8]
je 0x10c31f0
mov eax, dword [ebp + 0xc]
add eax, ecx
push edi
mov dword [esi + 0x1c], eax
mov eax, dword [ebp - 8]
push 1
push dword [esi + 0xc]
sub eax, ecx
mov dword [esi + 0x18], eax
call dword [sym.imp.KERNEL32.dll_ReleaseSemaphore]
push 0x64
push dword [esi + 0x10]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
cmp eax, 0x102
jne 0x10c31d5
push edi
push dword [esi]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x10c31e3
call fcn.01075a13
jmp 0x10c31af
mov eax, dword [esi + 0x18]
add dword [ebp + 0x14], eax
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp + 0x14]
jmp 0x10c318e
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp + 0x14]
mov dword [ebp - 4], 0xfffffe30
cmp word [ebp - 4], di
mov dword [ebx], ecx
jne 0x10c321c
test byte [eax + 0x228], 4
je 0x10c321c
mov edx, dword [eax + 0x238]
sub edx, dword [eax + 0x230]
cmp ecx, edx
jne 0x10c321c
mov ebx, dword [ebp + 8]
call fcn.010c2ec8
mov dword [ebp - 4], eax
mov ax, word [ebp - 4]
pop edi
pop esi
pop ebx
leave
ret 0x10
Function at 0x10c9200
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
and dword [ebp - 4], 0
push ebx
mov ebx, dword [ebp + 8]
cmp dword [ebx + 0x23e0], 0
jg 0x10c9224
mov dword [ebp - 4], 0xfffffdf3
jmp 0x10c9318
push esi
mov esi, dword [ebp + 0xc]
push edi
push dword [ebx]
mov edi, dword [sym.imp.msvcrt.dll_fread]
push 1
push 0x11
push esi
call edi
add esp, 0x10
cmp eax, 1
jne 0x10c9288
movzx eax, word [esi + 0xc]
lea ecx, [ebx + 0x2040]
cmp eax, dword [ecx]
jbe 0x10c9268
push eax
push ecx
lea eax, [ebx + 0x2044]
push eax
call fcn.010c8ac5
test ax, ax
mov dword [ebp - 4], eax
jne 0x10c9316
push dword [ebx]
movzx ecx, word [esi + 0xc]
mov eax, dword [ebx + 0x2044]
push ecx
push 1
push eax
mov dword [ebp - 8], eax
call edi
movzx ecx, word [esi + 0xc]
add esp, 0x10
cmp ecx, eax
je 0x10c9294
mov dword [ebp - 4], 0xfffffdf3
jmp 0x10c9316
movzx eax, word [esi + 0xe]
cmp eax, 1
lea edx, [ebx + 0x2058]
mov ecx, dword [edx]
mov edi, ecx
mov dword [ebp + 8], edi
jle 0x10c92ba
dec eax
jmp 0x10c92ae
inc edi
cmp byte [edi], 0
jne 0x10c92ad
inc edi
dec eax
jne 0x10c92ae
mov dword [ebp + 8], edi
mov eax, edi
sub eax, ecx
lea ecx, [ebx + 0x2054]
mov dword [ecx], eax
movzx edi, word [esi + 0xc]
lea eax, [edi + eax + 1]
mov dword [ecx], eax
lea ecx, [ebx + 0x205c]
cmp eax, dword [ecx]
jbe 0x10c92ea
push eax
push ecx
push edx
call fcn.010c8ac5
test ax, ax
mov dword [ebp - 4], eax
jne 0x10c9316
movzx ecx, word [esi + 0xc]
mov esi, dword [ebp - 8]
mov edi, dword [ebp + 8]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov eax, dword [ebp + 0xc]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
movzx eax, word [eax + 0xc]
mov ecx, dword [ebp + 8]
mov byte [eax + ecx], 0
dec dword [ebx + 0x23e0]
pop edi
pop esi
mov ax, word [ebp - 4]
pop ebx
leave
ret 8
Function at 0x10ca9c0
Capabilities:
Read file on windows

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov ax, word [ebp + 0xc]
push ebx
push esi
mov esi, dword [ebp + 8]
cmp word [esi + 0x394], ax
mov ebx, dword [esi + 0xf0]
push edi
mov dword [ebp + 8], ebx
jae 0x10caa4f
mov dx, word [esi + 0x394]
add dx, 0x200
cmp dx, ax
mov cx, dx
jb 0x10ca9e8
movzx eax, cx
push 1
push eax
mov word [esi + 0x394], dx
call dword [sym.imp.msvcrt.dll_calloc]
mov ebx, eax
test ebx, ebx
pop ecx
pop ecx
jne 0x10caa19
mov ax, 0xfdfc
jmp 0x10caacd
mov ax, word [esi + 0x39c]
test ax, ax
je 0x10caa39
movzx eax, ax
push eax
push dword [esi + 0x398]
push ebx
call dword [sym.imp.msvcrt.dll_memmove]
add esp, 0xc
lea edi, [esi + 0x390]
push dword [edi]
call dword [sym.imp.msvcrt.dll_free]
mov dword [edi], ebx
mov ebx, dword [ebp + 8]
pop ecx
jmp 0x10caa74
mov ax, word [esi + 0x39c]
test ax, ax
je 0x10caa74
movzx eax, ax
push eax
push dword [esi + 0x398]
push dword [esi + 0x390]
call dword [sym.imp.msvcrt.dll_memmove]
add esp, 0xc
movzx eax, word [esi + 0x39c]
movzx edi, word [esi + 0x394]
mov ecx, dword [esi + 0x390]
push ebx
sub edi, eax
push edi
add ecx, eax
push 1
push ecx
mov dword [esi + 0x398], ecx
call dword [sym.imp.msvcrt.dll_fread]
add esp, 0x10
cmp eax, edi
je 0x10caab7
mov ebx, dword [ebx + 0xc]
test bl, 0x20
jne 0x10caab1
test bl, 0x10
jne 0x10caab7
mov ax, 0xfde7
jmp 0x10caacd
mov ecx, dword [esi + 0x390]
add word [esi + 0x39c], ax
mov dword [esi + 0x398], ecx
xor ax, ax
pop edi
pop esi
pop ebx
pop ebp
ret 8
Function at 0x10cb17d
Capabilities:
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
push ecx
push ecx
push esi
lea eax, [ebp - 4]
push eax
push 0x20019
xor esi, esi
push esi
push 0x1012fa4
push 0x80000000
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
test eax, eax
jne 0x10cb1d5
lea eax, [ebp - 8]
push eax
push dword [ebp + 8]
mov dword [ebp - 8], 0x104
push esi
push esi
push 0x1009ac2
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x10cb1c8
inc esi
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, esi
jmp 0x10cb1d7
xor eax, eax
pop esi
leave
ret 4
Function at 0x4047fc
Capabilities:
Get geographical location

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffff0
push ebx
xor edx, edx
mov dword [ebp - 0x10], edx
xor edx, edx
push ebp
push 0x404862
push dword fs:[edx]
mov dword fs:[edx], esp
push 7
lea edx, [ebp - 0xb]
push edx
push 0x1004
push eax
call sub.kernel32.dll_GetLocaleInfoA
lea eax, [ebp - 0x10]
lea edx, [ebp - 0xb]
mov ecx, 7
call fcn.0040402c
mov eax, dword [ebp - 0x10]
lea edx, [ebp - 4]
call fcn.004030d4
mov ebx, eax
cmp dword [ebp - 4], 0
je 0x40484c
xor ebx, ebx
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x404869
lea eax, [ebp - 0x10]
call fcn.00403dcc
ret

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

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
mov dword [ebp - 4], edx
mov ebx, eax
mov eax, dword [ebp - 4]
call fcn.00404234
xor eax, eax
push ebp
push 0x404e9d
push dword fs:[eax]
mov dword fs:[eax], esp
push 0
mov eax, dword [ebp - 4]
call fcn.00404044
push eax
lea eax, [ebp - 4]
call fcn.0040429c
push eax
mov eax, dword [ebx + 0x30]
push eax
call sub.wsock32.dll_send
mov ebx, eax
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x404ea4
lea eax, [ebp - 4]
call fcn.00403dcc
ret
Function at 0x4070b8
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Connect udp socket
Create tcp socket
Create udp socket
Initialize winsock library

Disassembly:
push ebx
mov ebx, eax
lea eax, [ebx + 0x44]
push eax
mov dl, 1
mov al, 2
call fcn.00404c28
push eax
call sub.wsock32.dll_WSAStartup
push 0
push 1
push 2
call sub.wsock32.dll_socket
mov dword [ebx + 0x30], eax
mov word [ebx + 0x34], 2
mov ax, word [ebx + 4]
push eax
call sub.wsock32.dll_htons
mov word [ebx + 0x36], ax
mov eax, dword [ebx + 8]
call fcn.00404244
push eax
call sub.wsock32.dll_inet_addr
mov dword [ebx + 0x38], eax
push 0x10
lea eax, [ebx + 0x34]
push eax
mov eax, dword [ebx + 0x30]
push eax
call sub.wsock32.dll_connect
test eax, eax
jne 0x407122
mov eax, ebx
call fcn.00406fa4
mov eax, ebx
call fcn.00405244
call sub.wsock32.dll_WSACleanup
cmp dword [ebx + 0x2c], 0
jne 0x4070bb
pop ebx
ret
Function at 0x407764
Capabilities:
Copy file
Create directory

Disassembly:
push ebp
mov ebp, esp
xor ecx, ecx
push ecx
push ecx
push ecx
push ecx
push ecx
push ebx
xor eax, eax
push ebp
push 0x40783f
push dword fs:[eax]
mov dword fs:[eax], esp
push 0
lea edx, [ebp - 8]
mov eax, 0x407854
call fcn.00409064
mov eax, dword [ebp - 8]
call fcn.00404244
push eax
call sub.kernel32.dll_CreateDirectoryA
test eax, eax
je 0x4077a6
mov eax, dword [0x40b16c]
add dword [eax], 0xa
mov ebx, 0xa
lea edx, [ebp - 0xc]
mov eax, 0x407864
call fcn.00409064
push dword [ebp - 0xc]
lea eax, [ebp - 0x10]
call fcn.004079dc
push dword [ebp - 0x10]
push 0x407878
lea eax, [ebp - 4]
mov edx, 3
call fcn.00404104
push 0
mov eax, dword [ebp - 4]
call fcn.00404244
push eax
lea edx, [ebp - 0x14]
xor eax, eax
call fcn.00402774
mov eax, dword [ebp - 0x14]
call fcn.00404244
push eax
call sub.kernel32.dll_CopyFileA
mov eax, 0x64
call fcn.00402d58
cmp eax, 0x1e
jle 0x407821
mov eax, 5
call fcn.00402d58
mov edx, eax
shl edx, 0xa
mov eax, dword [ebp - 4]
call fcn.004086e0
dec ebx
jne 0x4077ab
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x407846
lea eax, [ebp - 0x14]
mov edx, 5
call fcn.00403df0
ret
Function at 0x408a30
Capabilities:
Check os version

Disassembly:
push ebx
add esp, 0xffffff6c
mov ebx, eax
mov eax, ebx
mov edx, 0x408b60
call fcn.00403e20
mov dword [esp], 0x94
push esp
call sub.kernel32.dll_GetVersionExA
test eax, eax
je 0x408b42
mov eax, dword [esp + 4]
mov edx, dword [esp + 8]
mov ecx, dword [esp + 0x10]
dec ecx
je 0x408aca
dec ecx
jne 0x408b34
cmp eax, 4
jg 0x408a86
mov eax, ebx
mov edx, 0x408b70
call fcn.00403e20
jmp 0x408b4e
cmp eax, 5
jne 0x408aa0
test edx, edx
jne 0x408aa0
mov eax, ebx
mov edx, 0x408b80
call fcn.00403e20
jmp 0x408b4e
cmp eax, 5
jne 0x408ab9
dec edx
jne 0x408ab9
mov eax, ebx
mov edx, 0x408b90
call fcn.00403e20
jmp 0x408b4e
mov eax, ebx
mov edx, 0x408b60
call fcn.00403e20
jmp 0x408b4e
cmp eax, 4
jne 0x408ae1
test edx, edx
jne 0x408ae1
mov eax, ebx
mov edx, 0x408ba0
call fcn.00403e20
jmp 0x408b4e
cmp eax, 4
jne 0x408b0e
cmp edx, 0xa
jne 0x408b0e
cmp byte [esp + 0x15], 0x41
jne 0x408b00
mov eax, ebx
mov edx, 0x408bb0
call fcn.00403e20
jmp 0x408b4e
mov eax, ebx
mov edx, 0x408bc0
call fcn.00403e20
jmp 0x408b4e
cmp eax, 4
jne 0x408b26
cmp edx, 0x5a
jne 0x408b26
mov eax, ebx
mov edx, 0x408bd0
call fcn.00403e20
jmp 0x408b4e
mov eax, ebx
mov edx, 0x408b60
call fcn.00403e20
jmp 0x408b4e
mov eax, ebx
mov edx, 0x408b60
call fcn.00403e20
jmp 0x408b4e
mov eax, ebx
mov edx, 0x408b60
call fcn.00403e20
add esp, 0x94
pop ebx
ret

Function at 0x408bd8
Capabilities:
Check internet connectivity via wininet

Disassembly:
push ebx
push ecx
mov ebx, eax
mov dword [esp], 2
push 0
lea eax, [esp + 4]
push eax
call sub.wininet.dll_InternetGetConnectedState
test eax, eax
je 0x408c0a
mov eax, dword [esp]
and eax, 2
cmp eax, 2
jne 0x408c0a
mov eax, ebx
mov edx, 0x408c44
call fcn.00403e20
mov dword [esp], 1
push 0
lea eax, [esp + 4]
push eax
call sub.wininet.dll_InternetGetConnectedState
test eax, eax
je 0x408c38
mov eax, dword [esp]
and eax, 1
cmp eax, 1
jne 0x408c38
mov eax, ebx
mov edx, 0x408c50
call fcn.00403e20
pop edx
pop ebx
ret
Function at 0x408c58
Capabilities:
Initialize winsock library
Resolve dns

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe64
push ebx
push esi
push edi
xor ecx, ecx
mov dword [ebp - 0x19c], ecx
mov dword [ebp - 0x198], ecx
mov edi, edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.00404234
xor eax, eax
push ebp
push 0x408d9f
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, edi
call fcn.00403dcc
lea eax, [ebp - 0x194]
push eax
push 0x101
call sub.wsock32.dll_WSAStartup
xor edx, edx
push ebp
push 0x408d6a
push dword fs:[edx]
mov dword fs:[edx], esp
mov eax, dword [ebp - 4]
call fcn.00404244
push eax
call sub.wsock32.dll_gethostbyname
test eax, eax
je 0x408d60
mov esi, dword [eax + 0xc]
xor ebx, ebx
jmp 0x408d56
cmp dword [ebp - 4], 0
jne 0x408d42
mov eax, dword [esi + ebx*4]
push dword [eax]
call sub.wsock32.dll_inet_ntoa
mov edx, eax
lea eax, [ebp - 0x198]
call fcn.00403fb4
mov edx, dword [ebp - 0x198]
mov eax, 0x408db8
call fcn.00404388
dec eax
je 0x408d55
mov eax, dword [esi + ebx*4]
push dword [eax]
call sub.wsock32.dll_inet_ntoa
mov edx, eax
lea eax, [ebp - 0x19c]
call fcn.00403fb4
mov edx, dword [ebp - 0x19c]
mov eax, 0x408dc4
call fcn.00404388
dec eax
je 0x408d55
mov eax, dword [esi + ebx*4]
push dword [eax]
call sub.wsock32.dll_inet_ntoa
mov edx, eax
mov eax, edi
call fcn.00403fb4
jmp 0x408d60
mov eax, dword [esi + ebx*4]
push dword [eax]
call sub.wsock32.dll_inet_ntoa
mov edx, eax
mov eax, edi
call fcn.00403fb4
inc ebx
cmp dword [esi + ebx*4], 0
jne 0x408cd3
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x408d74
call sub.wsock32.dll_WSACleanup
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x408da6
lea eax, [ebp - 0x19c]
mov edx, 2
call fcn.00403df0
lea eax, [ebp - 4]
call fcn.00403dcc
ret

Function at 0x408e18
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
push ecx
push ebx
mov ebx, edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.00404234
xor eax, eax
push ebp
push 0x408e6c
push dword fs:[eax]
mov dword fs:[eax], esp
xor eax, eax
mov al, bl
push eax
push 0
push 0
mov eax, dword [ebp - 4]
call fcn.00404244
push eax
push 0x408e78
push 0
call sub.shell32.dll_ShellExecuteA
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x408e73
lea eax, [ebp - 4]
call fcn.00403dcc
ret

Function at 0x408f14
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffef4
push ebx
xor ecx, ecx
mov dword [ebp - 0x10c], ecx
mov ebx, edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.00404234
xor eax, eax
push ebp
push 0x408fa3
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x105]
push eax
push pe_nt_image_headers32
call sub.kernel32.dll_GetTempPathA
lea eax, [ebp - 0x10c]
lea edx, [ebp - 0x105]
mov ecx, 0x101
call fcn.0040402c
push dword [ebp - 0x10c]
push 0x408fb8
push dword [ebp - 4]
mov eax, ebx
mov edx, 3
call fcn.00404104
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x408faa
lea eax, [ebp - 0x10c]
call fcn.00403dcc
lea eax, [ebp - 4]
call fcn.00403dcc
ret
Function at 0x408fbc
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffef4
push ebx
xor ecx, ecx
mov dword [ebp - 0x10c], ecx
mov ebx, edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.00404234
xor eax, eax
push ebp
push 0x40904b
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x105]
push eax
push pe_nt_image_headers32
call sub.kernel32.dll_GetCurrentDirectoryA
lea eax, [ebp - 0x10c]
lea edx, [ebp - 0x105]
mov ecx, 0x101
call fcn.0040402c
push dword [ebp - 0x10c]
push 0x409060
push dword [ebp - 4]
mov eax, ebx
mov edx, 3
call fcn.00404104
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x409052
lea eax, [ebp - 0x10c]
call fcn.00403dcc
lea eax, [ebp - 4]
call fcn.00403dcc
ret

Function at 0x409064
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffef4
push ebx
xor ecx, ecx
mov dword [ebp - 0x10c], ecx
mov ebx, edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.00404234
xor eax, eax
push ebp
push 0x4090f3
push dword fs:[eax]
mov dword fs:[eax], esp
push pe_nt_image_headers32
lea eax, [ebp - 0x105]
push eax
call sub.kernel32.dll_GetWindowsDirectoryA
lea eax, [ebp - 0x10c]
lea edx, [ebp - 0x105]
mov ecx, 0x101
call fcn.0040402c
push dword [ebp - 0x10c]
push 0x409108
push dword [ebp - 4]
mov eax, ebx
mov edx, 3
call fcn.00404104
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4090fa
lea eax, [ebp - 0x10c]
call fcn.00403dcc
lea eax, [ebp - 4]
call fcn.00403dcc
ret

Function at 0x40910c
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffef4
push ebx
xor ecx, ecx
mov dword [ebp - 0x10c], ecx
mov ebx, edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.00404234
xor eax, eax
push ebp
push 0x40919b
push dword fs:[eax]
mov dword fs:[eax], esp
push pe_nt_image_headers32
lea eax, [ebp - 0x105]
push eax
call sub.kernel32.dll_GetSystemDirectoryA
lea eax, [ebp - 0x10c]
lea edx, [ebp - 0x105]
mov ecx, 0x101
call fcn.0040402c
push dword [ebp - 0x10c]
push 0x4091b0
push dword [ebp - 4]
mov eax, ebx
mov edx, 3
call fcn.00404104
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4091a2
lea eax, [ebp - 0x10c]
call fcn.00403dcc
lea eax, [ebp - 4]
call fcn.00403dcc
ret
Function at 0x40970c
Capabilities:
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe6c
push ebx
xor edx, edx
mov dword [ebp - 0x194], edx
mov ebx, eax
xor eax, eax
push ebp
push 0x409781
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x190]
push eax
mov dl, 1
mov al, 1
call fcn.00404c28
push eax
call sub.wsock32.dll_WSAStartup
lea edx, [ebp - 0x194]
xor eax, eax
call fcn.00402774
mov edx, dword [ebp - 0x194]
mov ecx, dword [ebx + 4]
mov eax, ebx
call fcn.004093c0
call sub.wsock32.dll_WSACleanup
jmp 0x40972e

Function at 0x409884
Capabilities:
Initialize winsock library
Resolve dns

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffffe68
push ebx
push esi
push edi
xor edx, edx
mov dword [ebp - 0x198], edx
mov dword [ebp - 0x194], edx
mov edi, eax
xor eax, eax
push ebp
push 0x40999a
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x190]
push eax
push 0x101
call sub.wsock32.dll_WSAStartup
xor edx, edx
push ebp
push 0x40996d
push dword fs:[edx]
mov dword fs:[edx], esp
push 0
call sub.wsock32.dll_gethostbyname
test eax, eax
je 0x409963
mov esi, dword [eax + 0xc]
xor ebx, ebx
jmp 0x40995d
mov eax, dword [esi + ebx*4]
push dword [eax]
call sub.wsock32.dll_inet_ntoa
mov edx, eax
lea eax, [ebp - 0x194]
call fcn.00403fb4
mov edx, dword [ebp - 0x194]
mov eax, 0x4099b0
call fcn.00404388
dec eax
je 0x40995c
mov eax, dword [esi + ebx*4]
push dword [eax]
call sub.wsock32.dll_inet_ntoa
mov edx, eax
lea eax, [ebp - 0x198]
call fcn.00403fb4
mov edx, dword [ebp - 0x198]
mov eax, 0x4099bc
call fcn.00404388
dec eax
je 0x40995c
mov eax, dword [esi + ebx*4]
mov al, byte [eax]
mov byte [edi + 4], al
mov eax, dword [esi + ebx*4]
mov al, byte [eax + 1]
mov byte [edi + 5], al
mov eax, dword [esi + ebx*4]
mov al, byte [eax + 2]
mov byte [edi + 6], al
mov eax, dword [esi + ebx*4]
mov al, byte [eax + 3]
mov byte [edi + 7], al
jmp 0x409963
inc ebx
cmp dword [esi + ebx*4], 0
jne 0x4098e3
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x409977
call sub.wsock32.dll_WSACleanup
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4099a1
lea eax, [ebp - 0x198]
mov edx, 2
call fcn.00403df0
ret

Function at 0x4099e8
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebx
mov ebx, edx
mov eax, ebx
call fcn.00404244
push eax
call sub.kernel32.dll_GetFileAttributesA
cmp eax, 0xffffffff
je 0x409a05
and eax, 0x10
cmp eax, 0x10
je 0x409a09
xor eax, eax
jmp 0x409a0b
mov al, 1
neg al
sbb eax, eax
pop ebx
ret
Function at 0x40a23c
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket

Disassembly:
push ebx
push esi
push edi
push ebp
add esp, 0xfffffff0
mov ebx, eax
xor ebp, ebp
xor edi, edi
lea eax, [ebx + 0x10]
call fcn.00403dcc
cmp ebp, 1
sbb eax, eax
inc eax
cmp al, 1
jne 0x40a2a5
mov eax, dword [ebx + 0x10]
mov edx, 0x40a3d8
call fcn.00404190
jne 0x40a274
lea eax, [ebx + 0x10]
call fcn.00403dcc
jmp 0x40a2ad
mov eax, dword [ebx + 0x10]
mov edx, 0x40a3e4
call fcn.00404190
jne 0x40a290
lea eax, [ebx + 0x10]
mov edx, 0x40a3d8
call fcn.00403e20
cmp dword [ebx + 0x10], 0
jne 0x40a2ad
lea eax, [ebx + 0x10]
mov edx, 0x40a3e4
call fcn.00403e20
jmp 0x40a2ad
lea eax, [ebx + 0x10]
call fcn.00403dcc
mov eax, ebx
call fcn.0040a08c
mov eax, dword [0x40b158]
inc dword [eax]
push 6
push 1
push 2
call sub.wsock32.dll_socket
mov esi, eax
mov word [esp], 2
push 0x8b
call sub.wsock32.dll_htons
mov word [esp + 2], ax
mov eax, dword [ebx + 0x10]
call fcn.00404244
push eax
call sub.wsock32.dll_inet_addr
mov dword [esp + 4], eax
push 0x10
lea eax, [esp + 4]
push eax
push esi
call sub.wsock32.dll_connect
inc eax
je 0x40a307
or edi, 0xffffffff
jmp 0x40a394
mov eax, dword [0x40b170]
inc dword [eax]
mov word [esp], 2
push 0x1bd
call sub.wsock32.dll_htons
mov word [esp + 2], ax
mov eax, dword [ebx + 0x10]
call fcn.00404244
push eax
call sub.wsock32.dll_inet_addr
mov dword [esp + 4], eax
push 0x10
lea eax, [esp + 4]
push eax
push esi
call sub.wsock32.dll_connect
inc eax
je 0x40a34a
or edi, 0xffffffff
jmp 0x40a394
mov eax, dword [0x40b170]
inc dword [eax]
mov word [esp], 2
push 0x75d7
call sub.wsock32.dll_htons
mov word [esp + 2], ax
mov eax, dword [ebx + 0x10]
call fcn.00404244
push eax
call sub.wsock32.dll_inet_addr
mov dword [esp + 4], eax
push 0x10
lea eax, [esp + 4]
push eax
push esi
call sub.wsock32.dll_connect
inc eax
je 0x40a38d
or edi, 0xffffffff
jmp 0x40a394
mov eax, dword [0x40b170]
inc dword [eax]
test edi, edi
je 0x40a3b7
push esi
call sub.wsock32.dll_closesocket
lea eax, [ebx + 0x14]
mov ecx, dword [ebx + 0x10]
mov edx, 0x40a3f0
call fcn.00404090
mov eax, ebx
call fcn.00409f64
mov ebp, eax
push 0x200
call sub.kernel32.dll_Sleep
jmp 0x40a251