Function at 0x40c6d6
Capabilities:
Connect socket
Get hostname

Disassembly:
push ebp
lea ebp, [esp - 0x4b4]
sub esp, 0x534
mov eax, dword [0x47e600]
xor eax, ebp
mov dword [ebp + 0x4b0], eax
push esi
mov esi, ecx
cmp dword [esi], 0xffffffff
push edi
mov edi, dword [ebp + 0x4bc]
je 0x40c704
xor eax, eax
jmp 0x40c73e
mov ecx, 0x47fc39
call fcn.0040bd4b
test al, al
je 0x40c700
push ebx
xor ebx, ebx
push ebx
push 1
push ebx
push ebx
push 0x19
push edi
lea ecx, [ebp - 0x50]
mov dword [ebp - 0x50], vtable.ATL::CSocketAddr.0
mov dword [ebp - 0x4c], ebx
call fcn.0040b610
test eax, eax
lea ecx, [ebp - 0x50]
je 0x40c757
call fcn.0040b59e
xor eax, eax
pop ebx
mov ecx, dword [ebp + 0x4b0]
pop edi
xor ecx, ebp
pop esi
call fcn.00448e39
add ebp, 0x4b4
leave
ret 8
mov dword [ebp - 0x44], ebx
mov dword [ebp - 0x48], ebx
push ebx
jmp 0x40c82b
inc dword [ebp - 0x48]
push 1
push ebx
push ebx
push dword [edi + 0xc]
push dword [edi + 8]
push dword [edi + 4]
call dword [sym.imp.WS2_32.dll_WSASocketA]
cmp eax, 0xffffffff
mov dword [esi], eax
je 0x40c938
mov dword [ebp - 0x44], ebx
call dword [sym.imp.WS2_32.dll_WSACreateEvent]
cmp eax, ebx
mov dword [ebp - 0x54], eax
je 0x40c810
push 0x10
push eax
push dword [esi]
call dword [sym.imp.WS2_32.dll_WSAEventSelect]
cmp eax, 0xffffffff
je 0x40c802
push ebx
push ebx
push ebx
push ebx
push dword [edi + 0x10]
push dword [edi + 0x18]
push dword [esi]
call dword [sym.imp.WS2_32.dll_WSAConnect]
test eax, eax
je 0x40c802
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x40c802
push dword [ebp + 0x4c0]
push dword [ebp - 0x54]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
jne 0x40c802
push 0x2c
lea eax, [ebp - 0x80]
push ebx
push eax
call fcn.00449160
add esp, 0xc
lea eax, [ebp - 0x80]
push eax
push ebx
push dword [esi]
call dword [sym.imp.WS2_32.dll_WSAEnumNetworkEvents]
cmp dword [ebp - 0x6c], ebx
jne 0x40c802
mov dword [ebp - 0x44], 1
push dword [ebp - 0x54]
call dword [sym.imp.WS2_32.dll_WSACloseEvent]
cmp dword [ebp - 0x44], ebx
jne 0x40c83c
push 2
push dword [esi]
call dword [sym.imp.WS2_32.dll_shutdown]
push dword [esi]
call dword [sym.imp.WS2_32.dll_closesocket]
or dword [esi], 0xffffffff
push dword [ebp - 0x48]
lea ecx, [ebp - 0x50]
call fcn.0040b673
mov edi, eax
cmp edi, ebx
jne 0x40c763
jmp 0x40c852
push ebx
push 1
push 1
push ebx
call dword [sym.imp.KERNEL32.dll_CreateEventA]
cmp eax, ebx
mov dword [esi + 0x14], eax
jne 0x40c852
mov dword [ebp - 0x44], ebx
cmp dword [ebp - 0x44], ebx
mov edi, 0x3e8
mov dword [ebp - 0x48], edi
je 0x40c912
lea eax, [esi + 4]
push eax
lea eax, [ebp - 0x48]
push eax
lea eax, [ebp - 0x40]
push eax
push dword [esi]
call fcn.0040bc5c
add esp, 0x10
cmp eax, ebx
mov dword [ebp - 0x44], eax
je 0x40c912
push 3
lea eax, [ebp - 0x40]
push 0x46b3a4
push eax
call fcn.0044b29c
add esp, 0xc
test eax, eax
je 0x40c89e
mov dword [ebp - 0x44], ebx
cmp dword [ebp - 0x44], ebx
je 0x40c912
push 0x100
lea eax, [ebp + 0x3ac]
push eax
call dword [sym.imp.WS2_32.dll_gethostname]
test eax, eax
je 0x40c8bc
mov dword [ebp - 0x44], ebx
cmp dword [ebp - 0x44], ebx
je 0x40c912
lea eax, [ebp + 0x3ac]
push eax
push str.HELO__s_r_n
lea eax, [ebp - 0x40]
push 0x3e9
push eax
call fcn.0044936e
add esp, 0x10
cmp eax, ebx
mov dword [ebp - 0x48], eax
jle 0x40c90a
lea eax, [esi + 4]
push eax
push 0x46b394
push edi
lea eax, [ebp - 0x48]
push eax
lea eax, [ebp - 0x40]
push eax
push dword [ebp - 0x48]
push eax
push dword [esi]
call fcn.0040bcf1
add esp, 0x20
mov dword [ebp - 0x44], eax
jmp 0x40c90d
mov dword [ebp - 0x44], ebx
cmp dword [ebp - 0x44], ebx
jne 0x40c935
mov eax, dword [esi + 0x14]
cmp eax, ebx
je 0x40c920
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 2
push dword [esi]
call dword [sym.imp.WS2_32.dll_shutdown]
push dword [esi]
call dword [sym.imp.WS2_32.dll_closesocket]
or dword [esi], 0xffffffff
mov ebx, dword [ebp - 0x44]
lea ecx, [ebp - 0x50]
call fcn.0040b59e
mov eax, ebx
jmp 0x40c73d