Function at 0x4028d9
Capabilities:
Connect socket
Create thread
Resolve dns
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x44
mov eax, dword [0x574e04]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
mov ebx, ecx
push dword [ebx + 4]
mov dword [ebp - 0x28], eax
call dword [sym.imp.KERNEL32.dll_ResetEvent]
xor esi, esi
lea eax, [ebx + 0x18]
push esi
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
call dword [sym.imp.WINMM.dll_timeGetTime]
mov dword [ebx + 0x14], eax
xor eax, eax
lea edi, [ebx + 0x20]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosw word es:[edi], ax
mov eax, dword [ebx + 0x14]
push 6
xor edi, edi
inc edi
mov dword [ebx + 0x20], eax
mov eax, dword [ebx + 0x18]
push edi
push 2
mov dword [ebx + 0x24], eax
mov word [ebx + 0x28], 0xca
call dword [sym.imp.WS2_32.dll_socket]
mov dword [ebx + 0x64], eax
cmp eax, 0xffffffff
jne 0x40294b
xor al, al
jmp 0x402b09
push esi
push esi
push esi
push esi
push dword [ebp - 0x28]
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
push dword [ebp - 0x28]
push esi
push esi
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov dword [ebp - 0x24], eax
inc eax
push eax
call fcn.0040633e
pop ecx
push esi
push esi
push dword [ebp - 0x24]
mov dword [ebp - 0x30], eax
push eax
push dword [ebp - 0x28]
call dword [sym.imp.KERNEL32.dll_lstrlenW]
push eax
push dword [ebp - 0x28]
push esi
push esi
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
mov eax, dword [ebp - 0x30]
mov ecx, dword [ebp - 0x24]
push eax
mov byte [eax + ecx], 0
call dword [sym.imp.WS2_32.dll_gethostbyname]
push dword [ebp - 0x30]
mov dword [ebp - 0x24], eax
call fcn.00406333
pop ecx
cmp dword [ebp - 0x24], esi
je 0x402944
mov esi, dword [sym.imp.KERNEL32.dll_Sleep]
push 2
pop eax
push edi
mov word [ebp - 0x20], ax
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push edi
call esi
push dword [ebp + 0xc]
call dword [sym.imp.WS2_32.dll_htons]
mov word [ebp - 0x1e], ax
mov eax, dword [ebp - 0x24]
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
mov eax, dword [eax]
mov dword [ebp - 0x1c], eax
push 0x10
lea eax, [ebp - 0x20]
push eax
push dword [ebx + 0x64]
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
je 0x402944
mov esi, dword [sym.imp.WS2_32.dll_setsockopt]
push 4
lea eax, [ebp - 0x2c]
push eax
push 0x1001
push 0xffff
push dword [ebx + 0x64]
mov dword [ebp - 0x2c], 0x40000
call esi
push 4
lea eax, [ebp - 0x2c]
push eax
push 0x1002
push 0xffff
push dword [ebx + 0x64]
mov dword [ebp - 0x2c], 0x40000
call esi
push 4
lea eax, [ebp - 0x3c]
push eax
push 0x1006
push 0xffff
push dword [ebx + 0x64]
mov dword [ebp - 0x3c], 0x7530
call esi
push 4
lea eax, [ebp - 0x34]
push eax
push 8
push 0xffff
push dword [ebx + 0x64]
mov dword [ebp - 0x34], edi
call esi
xor esi, esi
test eax, eax
jne 0x402acc
push esi
push esi
lea eax, [ebp - 0x44]
push eax
push esi
push esi
push 0xc
lea eax, [ebp - 0x10]
push eax
push 0x98000004
push dword [ebx + 0x64]
mov dword [ebp - 0x10], edi
mov dword [ebp - 0xc], 0x2bf20
mov dword [ebp - 8], 0x1388
call dword [sym.imp.WS2_32.dll_WSAIoctl]
push edi
lea eax, [ebx + 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedExchange]
lea eax, [ebp - 0x38]
push eax
push esi
push ebx
push 0x402b1a
push esi
push esi
mov dword [ebp - 0x38], esi
call fcn.0050513b
mov dword [ebx + 0x5c], eax
lea eax, [ebp - 0x40]
push eax
push esi
push ebx
push 0x402c0f
push esi
push esi
call fcn.0050513b
mov dword [ebx + 0x60], eax
add esp, 0x30
mov al, 1
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.005047ac
leave
ret 8