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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14c
push ebx
push esi
push edi
mov eax, dword [ebp + 8]
mov ecx, dword [eax]
mov dword [ebp - 0x108], ecx
mov edx, dword [ebp + 8]
cmp dword [edx + 0x8c], 2
jne 0x41d018
jmp 0x41d1fd
mov eax, dword [ebp + 8]
cmp dword [eax + 0x3a0], 0
jne 0x41d1f1
mov ecx, dword [ebp + 8]
cmp dword [ecx + 0x410], 0
jne 0x41d1f1
mov dword [ebp - 4], 0x80
lea edx, [ebp - 4]
push edx
lea eax, [ebp - 0x84]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.WS2_32.dll_getpeername]
test eax, eax
je 0x41d098
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0x10c], eax
mov edx, dword [ebp - 0x10c]
push edx
mov eax, dword [ebp + 8]
push eax
call fcn.004205c0
add esp, 8
push eax
mov ecx, dword [ebp - 0x10c]
push ecx
push str.getpeername___failed_with_errno__d:__s
mov edx, dword [ebp - 0x108]
push edx
call fcn.00418ad0
add esp, 0x10
jmp 0x41d1fd
mov dword [ebp - 4], 0x80
push 0x80
push 0
lea eax, [ebp - 0x104]
push eax
call sub.MSVCR100.dll_memset
add esp, 0xc
lea ecx, [ebp - 4]
push ecx
lea edx, [ebp - 0x104]
push edx
mov eax, dword [ebp + 0xc]
push eax
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x41d10e
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0x10c], eax
mov ecx, dword [ebp - 0x10c]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.004205c0
add esp, 8
push eax
mov eax, dword [ebp - 0x10c]
push eax
push str.getsockname___failed_with_errno__d:__s
mov ecx, dword [ebp - 0x108]
push ecx
call fcn.00418ad0
add esp, 0x10
jmp 0x41d1fd
mov edx, dword [ebp + 8]
add edx, 0x130
push edx
mov eax, dword [ebp + 8]
add eax, 0x102
push eax
lea ecx, [ebp - 0x84]
push ecx
call fcn.0041d210
add esp, 0xc
test eax, eax
jne 0x41d174
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10c], eax
mov edx, dword [ebp - 0x10c]
push edx
mov eax, dword [ebp + 8]
push eax
call fcn.004205c0
add esp, 8
push eax
mov ecx, dword [ebp - 0x10c]
push ecx
push str.ssrem_inet_ntop___failed_with_errno__d:__s
mov edx, dword [ebp - 0x108]
push edx
call fcn.00418ad0
add esp, 0x10
jmp 0x41d1fd
push 0x2e
mov eax, dword [ebp + 8]
add eax, 0x102
push eax
mov ecx, dword [ebp + 8]
add ecx, 0x58
push ecx
call sub.MSVCR100.dll_memcpy
add esp, 0xc
mov edx, dword [ebp + 8]
add edx, 0x164
push edx
mov eax, dword [ebp + 8]
add eax, 0x134
push eax
lea ecx, [ebp - 0x104]
push ecx
call fcn.0041d210
add esp, 0xc
test eax, eax
jne 0x41d1f1
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10c], eax
mov edx, dword [ebp - 0x10c]
push edx
mov eax, dword [ebp + 8]
push eax
call fcn.004205c0
add esp, 8
push eax
mov ecx, dword [ebp - 0x10c]
push ecx
push str.ssloc_inet_ntop___failed_with_errno__d:__s
mov edx, dword [ebp - 0x108]
push edx
call fcn.00418ad0
add esp, 0x10
jmp 0x41d1fd
mov eax, dword [ebp + 8]
push eax
call fcn.0041cf40
add esp, 4
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x41d900
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c
push ebx
push esi
push edi
mov eax, dword [ebp + 8]
mov ecx, dword [eax]
mov dword [ebp - 4], ecx
mov dword [ebp - 8], 1
mov dword [ebp - 0xc], 6
push 4
lea edx, [ebp - 8]
push edx
push 1
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jge 0x41d960
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
mov edx, dword [ebp + 8]
push edx
call fcn.004205c0
add esp, 8
push eax
push str.Could_not_set_TCP_NODELAY:__s_n
mov eax, dword [ebp - 4]
push eax
call fcn.00418a50
add esp, 0xc
jmp 0x41d971
push str.TCP_NODELAY_set_n
mov ecx, dword [ebp - 4]
push ecx
call fcn.00418a50
add esp, 8
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x41d980
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c
push ebx
push esi
push edi
mov dword [ebp - 4], 0x4020
mov dword [ebp - 8], 0
mov dword [ebp - 0xc], 4
cmp dword [0x46c7b8], 0
jne 0x41d9d1
push 3
push 2
push 0
push 6
call fcn.004281f0
add esp, 0x10
test eax, eax
je 0x41d9c7
mov dword [0x46c7b8], 2
jmp 0x41d9d1
mov dword [0x46c7b8], 1
cmp dword [0x46c7b8], 2
jne 0x41d9dc
jmp 0x41da20
lea eax, [ebp - 0xc]
push eax
lea ecx, [ebp - 8]
push ecx
push 0x1001
push 0xffff
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.WS2_32.dll_getsockopt]
test eax, eax
jne 0x41da06
mov eax, dword [ebp - 8]
cmp eax, dword [ebp - 4]
jle 0x41da06
jmp 0x41da20
push 4
lea ecx, [ebp - 4]
push ecx
push 0x1001
push 0xffff
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.WS2_32.dll_setsockopt]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x41de40
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
push ebx
push esi
push edi
mov eax, dword [ebp + 8]
xor ecx, ecx
cmp dword [eax + 0x528], 0
setne cl
mov dword [ebp - 4], ecx
push 4
lea edx, [ebp - 4]
push edx
push 8
push 0xffff
mov eax, dword [ebp + 0xc]
push eax
call dword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
jge 0x41de90
mov ecx, dword [ebp + 0xc]
push ecx
push str.Failed_to_set_SO_KEEPALIVE_on_fd__d_n
mov edx, dword [ebp + 8]
push edx
call fcn.00418a50
add esp, 0xc
jmp 0x41df26
mov dword [ebp - 0x10], 1
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x52c]
push ecx
call fcn.00427970
add esp, 4
mov dword [ebp - 4], eax
mov edx, dword [ebp - 4]
imul edx, edx, 0x3e8
mov dword [ebp - 4], edx
mov eax, dword [ebp - 4]
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x530]
push edx
call fcn.00427970
add esp, 4
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
imul eax, eax, 0x3e8
mov dword [ebp - 4], eax
mov ecx, dword [ebp - 4]
mov dword [ebp - 8], ecx
push 0
push 0
lea edx, [ebp - 0x14]
push edx
push 0
push 0
push 0xc
lea eax, [ebp - 0x10]
push eax
push 0x98000004
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.WS2_32.dll_WSAIoctl]
test eax, eax
je 0x41df26
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
mov edx, dword [ebp + 0xc]
push edx
push str.Failed_to_set_SIO_KEEPALIVE_VALS_on_fd__d:__d_n
mov eax, dword [ebp + 8]
push eax
call fcn.00418a50
add esp, 0x10
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x41e7a0
Capabilities:
Receive data
Receive data on socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
push ebx
push esi
push edi
mov eax, dword [ebp + 8]
cmp dword [eax + 0x1d8], 0
je 0x41e7cb
mov ecx, dword [ebp + 8]
push ecx
call fcn.00408ff0
add esp, 4
test eax, eax
jne 0x41e7c9
xor eax, eax
jmp 0x41e800
jmp 0x41e7fb
mov edx, dword [ebp + 8]
cmp dword [edx + 0x190], 0xffffffff
jne 0x41e7db
xor eax, eax
jmp 0x41e800
push 2
push 1
lea eax, [ebp - 4]
push eax
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x190]
push edx
call dword [sym.imp.WS2_32.dll_recv]
test eax, eax
jne 0x41e7fb
xor eax, eax
jmp 0x41e800
mov eax, 1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x41eae0
Capabilities:
Create thread

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
push ebx
push esi
push edi
push 0
push 0
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp + 8]
push ecx
push 0
push 0
call dword [sym.imp.MSVCR100.dll__beginthreadex]
add esp, 0x18
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
je 0x41eb11
cmp dword [ebp - 4], 0xffffffff
jne 0x41eb15
xor eax, eax
jmp 0x41eb18
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x41ee60
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x278
push ebx
push esi
push edi
mov dword [ebp - 4], 0
mov dword [ebp - 0x1c], str.getaddrinfo
mov dword [ebp - 0x18], 0x41f0f0
mov dword [ebp - 0x14], str.getnameinfo
mov dword [ebp - 0x10], 0x41f970
mov dword [ebp - 0xc], str.freeaddrinfo
mov dword [ebp - 8], fcn.0041f080
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x24], 0
cmp dword [0x46c7c0], 0
je 0x41eec8
mov eax, dword [ebp + 8]
and eax, 0xffff
mov eax, dword [eax*8 + 0x46c08c]
jmp 0x41f06b
push 0x104
lea ecx, [ebp - 0x12c]
push ecx
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
jne 0x41eee3
jmp 0x41efbd
lea edx, [ebp - 0x12c]
push edx
lea eax, [ebp - 0x238]
push eax
call sub.MSVCR100.dll_strcpy
add esp, 8
push str.ws2_32
lea ecx, [ebp - 0x238]
push ecx
call sub.MSVCR100.dll_strcat
add esp, 8
lea edx, [ebp - 0x238]
push edx
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
je 0x41ef4c
push str.getaddrinfo
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
jne 0x41ef4c
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov dword [ebp - 4], 0
cmp dword [ebp - 4], 0
je 0x41ef54
jmp 0x41efbd
lea edx, [ebp - 0x12c]
push edx
lea eax, [ebp - 0x238]
push eax
call sub.MSVCR100.dll_strcpy
add esp, 8
push str.wship6
lea ecx, [ebp - 0x238]
push ecx
call sub.MSVCR100.dll_strcat
add esp, 8
lea edx, [ebp - 0x238]
push edx
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
je 0x41efbd
push str.getaddrinfo
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
jne 0x41efbd
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov dword [ebp - 4], 0
cmp dword [ebp - 4], 0
je 0x41f052
mov dword [ebp - 0x24], 0
jmp 0x41efd9
mov edx, dword [ebp - 0x24]
add edx, 1
mov dword [ebp - 0x24], edx
mov eax, dword [ebp - 0x24]
cmp eax, dword [0x45ebc4]
jge 0x41f01c
mov ecx, dword [ebp - 0x24]
mov edx, dword [ebp + ecx*8 - 0x1c]
push edx
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov ecx, dword [ebp - 0x24]
mov dword [ebp + ecx*8 - 0x18], eax
mov edx, dword [ebp - 0x24]
cmp dword [ebp + edx*8 - 0x18], 0
jne 0x41f01a
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov dword [ebp - 4], 0
jmp 0x41f01c
jmp 0x41efd0
cmp dword [ebp - 4], 0
je 0x41f052
mov dword [ebp - 0x24], 0
jmp 0x41f034
mov ecx, dword [ebp - 0x24]
add ecx, 1
mov dword [ebp - 0x24], ecx
mov edx, dword [ebp - 0x24]
cmp edx, dword [0x45ebc4]
jge 0x41f052
mov eax, dword [ebp - 0x24]
mov ecx, dword [ebp - 0x24]
mov edx, dword [ebp + ecx*8 - 0x18]
mov dword [eax*8 + 0x46c08c], edx
jmp 0x41f02b
mov dword [0x46c7c0], 1
mov eax, dword [ebp + 8]
and eax, 0xffff
mov eax, dword [eax*8 + 0x46c08c]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
Function at 0x41f7b0
Capabilities:
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x50
push ebx
push esi
push edi
mov eax, dword [ebp + 0x1c]
mov dword [ebp - 4], eax
mov dword [ebp - 8], 0
mov ecx, dword [ebp - 4]
mov dword [ecx], 0
mov edx, dword [ebp + 0x18]
mov byte [edx], 0
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.WS2_32.dll_gethostbyname]
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
je 0x41f881
mov ecx, dword [ebp - 8]
movsx edx, word [ecx + 8]
cmp edx, 2
jne 0x41f85b
mov eax, dword [ebp - 8]
movsx ecx, word [eax + 0xa]
cmp ecx, 4
jne 0x41f85b
mov edx, dword [ebp - 8]
mov eax, dword [edx + 0xc]
mov dword [ebp - 0xc], eax
jmp 0x41f818
mov ecx, dword [ebp - 0xc]
add ecx, 4
mov dword [ebp - 0xc], ecx
mov edx, dword [ebp - 0xc]
cmp dword [edx], 0
je 0x41f85b
mov eax, dword [ebp - 0xc]
mov ecx, dword [eax]
mov edx, dword [ecx]
push edx
mov ax, word [ebp + 0x14]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.0041f580
mov ecx, dword [ebp - 4]
mov dword [ecx], eax
mov edx, dword [ebp - 4]
cmp dword [edx], 0
jne 0x41f84e
mov eax, 8
jmp 0x41f8c6
mov eax, dword [ebp - 4]
mov ecx, dword [eax]
add ecx, 0x1c
mov dword [ebp - 4], ecx
jmp 0x41f80f
push 0x400
mov edx, dword [ebp - 8]
mov eax, dword [edx]
push eax
mov ecx, dword [ebp + 0x18]
push ecx
call dword [sym.imp.MSVCR100.dll_strncpy]
add esp, 0xc
mov edx, dword [ebp + 0x18]
mov byte [edx + 0x400], 0
xor eax, eax
jmp 0x41f8c6
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
sub eax, 0x2af9
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 3
ja case.default.0x41f89e
mov ecx, dword [ebp - 0x10]
jmp dword [ecx*4 + 0x41f8cf]
mov eax, 0x2af9
jmp 0x41f8c6
mov eax, 0x2afa
jmp 0x41f8c6
mov eax, 0x2afb
jmp 0x41f8c6
mov eax, 0x2af9
jmp 0x41f8c6
mov eax, 0x2af9
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0x18

Function at 0x4260c0
Capabilities:
Generate random numbers via winapi

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
push ebx
push esi
push edi
mov dword [ebp - 4], 0
push 0xf0000040
push 1
push 0
push 0
lea eax, [ebp - 4]
push eax
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextA]
test eax, eax
jne 0x4260f0
mov eax, 2
jmp 0x426127
mov ecx, dword [ebp + 8]
push ecx
mov edx, dword [ebp + 0xc]
push edx
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.ADVAPI32.dll_CryptGenRandom]
test eax, eax
jne 0x426119
push 0
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov eax, 2
jmp 0x426127
push 0
mov edx, dword [ebp - 4]
push edx
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x4279c0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x40
push ebx
push esi
push edi
mov eax, dword [ebp + 0x10]
push eax
call fcn.00427900
add esp, 4
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.MSVCR100.dll__read]
add esp, 0xc
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x428370
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x60
push ebx
push esi
push edi
mov dword [ebp - 4], 0
mov dword [ebp - 8], 0
push str.kernel32
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0
jne 0x4283a2
xor eax, eax
jmp 0x4284f2
push str.LoadLibraryExA
mov eax, dword [ebp - 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 8], eax
push 0x4617b0
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.MSVCR100.dll_strpbrk]
add esp, 8
test eax, eax
je 0x4283f8
cmp dword [ebp - 8], 0
je 0x4283e0
push 8
push 0
mov edx, dword [ebp + 8]
push edx
call dword [ebp - 8]
mov dword [ebp - 0x1c], eax
jmp 0x4283ed
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov dword [ebp - 0x1c], eax
mov ecx, dword [ebp - 0x1c]
mov dword [ebp - 4], ecx
jmp 0x4284ef
cmp dword [ebp - 8], 0
je 0x428427
push str.AddDllDirectory
mov edx, dword [ebp - 0xc]
push edx
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x428427
push 0x800
push 0
mov eax, dword [ebp + 8]
push eax
call dword [ebp - 8]
mov dword [ebp - 4], eax
jmp 0x4284ef
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
je 0x4284ef
mov ecx, dword [ebp + 8]
push ecx
call sub.MSVCR100.dll_strlen
add esp, 4
mov dword [ebp - 0x14], eax
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 0x10]
lea ecx, [eax + edx + 1]
push ecx
call dword [0x46c030]
add esp, 4
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
je 0x4284e2
mov edx, dword [ebp - 0x10]
push edx
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
je 0x4284e2
push 0x46179c
mov ecx, dword [ebp - 0x18]
push ecx
call sub.MSVCR100.dll_strlen
add esp, 4
mov edx, dword [ebp - 0x18]
add edx, eax
push edx
call sub.MSVCR100.dll_strcpy
add esp, 8
mov eax, dword [ebp + 8]
push eax
mov ecx, dword [ebp - 0x18]
push ecx
call sub.MSVCR100.dll_strlen
add esp, 4
mov edx, dword [ebp - 0x18]
add edx, eax
push edx
call sub.MSVCR100.dll_strcpy
add esp, 8
cmp dword [ebp - 8], 0
je 0x4284cf
push 8
push 0
mov eax, dword [ebp - 0x18]
push eax
call dword [ebp - 8]
mov dword [ebp - 0x20], eax
jmp 0x4284dc
mov ecx, dword [ebp - 0x18]
push ecx
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov dword [ebp - 0x20], eax
mov edx, dword [ebp - 0x20]
mov dword [ebp - 4], edx
mov eax, dword [ebp - 0x18]
push eax
call dword [0x46c034]
add esp, 4
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x4371c0
Capabilities:
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1d8
push ebx
push esi
push edi
xor eax, eax
test eax, eax
jne 0x4371cc
mov word [ebp - 8], 2
lea ecx, [ebp - 0x198]
push ecx
mov dx, word [ebp - 8]
push edx
call dword [sym.imp.WS2_32.dll_WSAStartup]
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
je 0x43720f
mov eax, dword [ebp - 4]
push eax
push str.WSAStartup_failed___d_
mov ecx, dword [ebp + 8]
push ecx
call fcn.00418ad0
add esp, 0xc
mov eax, 2
jmp 0x437288
call dword [sym.imp.WS2_32.dll_WSACleanup]
mov edx, dword [ebp - 0x198]
and edx, 0xffff
and edx, 0xff
and edx, 0xff
mov eax, dword [ebp - 8]
and eax, 0xffff
and eax, 0xff
and eax, 0xff
cmp edx, eax
jne 0x43726e
mov ecx, dword [ebp - 0x198]
and ecx, 0xffff
shr ecx, 8
and ecx, 0xff
mov edx, dword [ebp - 8]
and edx, 0xffff
shr edx, 8
and edx, 0xff
cmp ecx, edx
je 0x437286
push str.insufficient_winsock_version_to_support_telnet
mov eax, dword [ebp + 8]
push eax
call fcn.00418ad0
add esp, 8
mov eax, 2
jmp 0x437288
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x50
push ebx
push esi
push edi
mov eax, dword [ebp + 8]
mov ecx, dword [eax]
mov dword [ebp - 0x10], ecx
mov byte [ebp - 4], 0xff
mov dl, byte [ebp + 0xc]
mov byte [ebp - 3], dl
mov al, byte [ebp + 0x10]
mov byte [ebp - 2], al
push 0
push 3
lea ecx, [ebp - 4]
push ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x190]
push eax
call dword [sym.imp.WS2_32.dll_send]
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
jge 0x4375a0
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp - 0xc]
push ecx
push str.Sending_data_failed___d_
mov edx, dword [ebp - 0x10]
push edx
call fcn.00418ad0
add esp, 0xc
mov eax, dword [ebp + 0x10]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
push str.SENT
mov edx, dword [ebp + 8]
mov eax, dword [edx]
push eax
call fcn.004375d0
add esp, 0x10
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x43cb90
Capabilities:
Check http status code

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x48
push ebx
push esi
push edi
mov dword [ebp - 4], 0
mov eax, dword [ebp + 8]
mov ecx, dword [eax]
mov dword [ebp - 8], ecx
mov eax, dword [ebp + 0xc]
cdq
mov ecx, 0x64
idiv ecx
cmp eax, 2
je 0x43cbd0
push str.Couldnt_set_desired_mode
mov edx, dword [ebp - 8]
push edx
call fcn.00418ad0
add esp, 8
mov eax, 0x11
jmp 0x43cc4b
cmp dword [ebp + 0xc], 0xc8
je 0x43cbee
mov eax, dword [ebp + 0xc]
push eax
push str.Got_a__03d_response_code_instead_of_the_assumed_200_n
mov ecx, dword [ebp - 8]
push ecx
call fcn.00418a50
add esp, 0xc
cmp dword [ebp + 0x10], 0x13
jne 0x43cc05
mov edx, dword [ebp + 8]
push edx
call fcn.0043ab20
add esp, 4
mov dword [ebp - 4], eax
jmp 0x43cc48
cmp dword [ebp + 0x10], 0x14
jne 0x43cc1c
mov eax, dword [ebp + 8]
push eax
call fcn.0043cc60
add esp, 4
mov dword [ebp - 4], eax
jmp 0x43cc48
cmp dword [ebp + 0x10], 0x15
jne 0x43cc33
mov ecx, dword [ebp + 8]
push ecx
call fcn.0043ce20
add esp, 4
mov dword [ebp - 4], eax
jmp 0x43cc48
cmp dword [ebp + 0x10], 0x16
jne 0x43cc48
mov edx, dword [ebp + 8]
push edx
call fcn.0043ce50
add esp, 4
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x43d710
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x64
push ebx
push esi
push edi
mov eax, dword [ebp + 8]
mov ecx, dword [eax]
mov dword [ebp - 4], ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x194]
mov dword [ebp - 8], eax
mov dword [ebp - 0xc], 0xffffffff
mov dword [ebp - 0x20], 0x10
lea ecx, [ebp - 0x20]
push ecx
lea edx, [ebp - 0x1c]
push edx
mov eax, dword [ebp - 8]
push eax
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x43d76d
mov dword [ebp - 0x20], 0x10
lea ecx, [ebp - 0x20]
push ecx
lea edx, [ebp - 0x1c]
push edx
mov eax, dword [ebp - 8]
push eax
call dword [sym.imp.WS2_32.dll_accept]
mov dword [ebp - 0xc], eax
mov ecx, dword [ebp - 8]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.0041e810
add esp, 8
cmp dword [ebp - 0xc], 0xffffffff
jne 0x43d79e
push str.Error_accept__ing_server_connect
mov eax, dword [ebp - 4]
push eax
call fcn.00418ad0
add esp, 8
mov eax, 0x1e
jmp 0x43d830
push str.Connection_accepted_from_server_n
mov ecx, dword [ebp - 4]
push ecx
call fcn.00418a50
add esp, 8
mov edx, dword [ebp + 8]
mov dword [edx + 0x3c8], 0
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0xc]
mov dword [eax + 0x194], ecx
push 1
mov edx, dword [ebp - 0xc]
push edx
call fcn.0044f0b0
add esp, 8
mov eax, dword [ebp + 8]
mov dword [eax + 0x1a4], 1
mov ecx, dword [ebp - 4]
cmp dword [ecx + 0x1a8], 0
je 0x43d82e
mov dword [ebp - 0x24], 0
push 1
mov edx, dword [ebp - 0xc]
push edx
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x1ac]
push ecx
mov edx, dword [ebp - 4]
call dword [edx + 0x1a8]
add esp, 0xc
mov dword [ebp - 0x24], eax
cmp dword [ebp - 0x24], 0
je 0x43d82e
mov eax, dword [ebp + 8]
push eax
call fcn.0043b940
add esp, 4
mov eax, 0x2a
jmp 0x43d830
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
Function at 0x44d3e0
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14c
push ebx
push esi
push edi
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.MSVCR100.dll_getenv]
add esp, 4
mov dword [ebp - 0x108], eax
mov byte [ebp - 0x104], 0
cmp dword [ebp - 0x108], 0
je 0x44d428
push 0x104
lea ecx, [ebp - 0x104]
push ecx
mov edx, dword [ebp - 0x108]
push edx
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsA]
movsx eax, byte [ebp - 0x104]
test eax, eax
je 0x44d44b
lea ecx, [ebp - 0x104]
push ecx
call dword [0x46c03c]
add esp, 4
mov dword [ebp - 0x10c], eax
jmp 0x44d455
mov dword [ebp - 0x10c], 0
mov eax, dword [ebp - 0x10c]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x44f0b0
Capabilities:
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
push ebx
push esi
push edi
xor eax, eax
cmp dword [ebp + 0xc], 0
setne al
mov dword [ebp - 4], eax
lea ecx, [ebp - 4]
push ecx
push 0x8004667e
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.WS2_32.dll_ioctlsocket]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret

Function at 0x452bb0
Capabilities:
Get hostname

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x48
push ebx
push esi
push edi
mov eax, dword [ebp + 8]
mov byte [eax], 0
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.WS2_32.dll_gethostname]
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
add eax, dword [ebp + 0xc]
mov byte [eax - 1], 0
cmp dword [ebp - 4], 0
je 0x452be5
mov eax, dword [ebp - 4]
jmp 0x452c05
push 0x2e
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.MSVCR100.dll_strchr]
add esp, 8
mov dword [ebp - 8], eax
cmp dword [ebp - 8], 0
je 0x452c03
mov edx, dword [ebp - 8]
mov byte [edx], 0
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret