Function at 0x402770
Capabilities:
Create thread
Resolve dns

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
mov edi, dword [eax]
push 0x38
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x10], ecx
mov dword [ebp - 0xc], edi
call fcn.0040ceba
mov esi, eax
xor ebx, ebx
add esp, 4
cmp esi, ebx
je 0x4027b6
call fcn.004041c0
mov dword [esi], vtable.CXSocket.0
mov dword [esi + 0x34], 0xffffffff
mov dword [esi + 0x18], ebx
mov dword [esi + 0x30], ebx
mov dword [ebp - 8], esi
jmp 0x4027bb
mov dword [ebp - 8], ebx
mov esi, ebx
mov ebx, esi
call fcn.00404630
mov dword [ebp - 4], eax
test eax, eax
je 0x402807
push 0x85
push str.XHttp.cpp
push str.FALSE
push str.code:__s_r_nfile:__s_r_nline:__d_r_n
push 0x440d40
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x14
push 0x200000
push str.DBG_ASSERT
push 0x440d40
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
jmp 0x40294e
movzx ebx, word [0x41cf50]
push str.127.0.0.1
call dword [sym.imp.WS2_32.dll_gethostbyname]
test eax, eax
jne 0x402825
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
jmp 0x40282c
push eax
push ebx
call fcn.00404910
mov dword [ebp - 4], eax
test eax, eax
jne 0x40294e
mov ecx, dword [ebp - 0xc]
mov edi, esi
call fcn.00403a40
mov edi, dword [sym.imp.USER32.dll_wsprintfA]
test eax, eax
je 0x402884
push 0x8f
push str.XHttp.cpp
push str.FALSE
push str.code:__s_r_nfile:__s_r_nline:__d_r_n
push 0x440940
call edi
mov esi, dword [sym.imp.USER32.dll_MessageBoxA]
add esp, 0x14
push 0x200000
push str.DBG_ASSERT
push 0x440940
push 0
call esi
jmp 0x40288a
mov esi, dword [sym.imp.USER32.dll_MessageBoxA]
mov ebx, dword [ebp - 8]
mov ecx, dword [ebp - 0xc]
push 0x419fdc
call fcn.00403b80
test eax, eax
je 0x4028d2
push 0x94
push str.XHttp.cpp
push str.FALSE
push str.code:__s_r_nfile:__s_r_nline:__d_r_n
push 0x440540
call edi
add esp, 0x14
push 0x200000
push str.DBG_ASSERT
push 0x440540
xor ebx, ebx
push ebx
call esi
jmp 0x4028d4
xor ebx, ebx
cmp dword [ebp + 0xc], ebx
jle 0x402a42
cmp dword [ebp - 0x10], ebx
je 0x402a42
mov ecx, dword [ebp - 8]
mov edx, dword [ecx]
mov edx, dword [edx + 0xc]
lea eax, [ebp + 0xc]
push eax
mov eax, dword [ebp + 0xc]
push eax
mov eax, dword [ebp - 0x10]
push eax
call edx
cmp eax, ebx
jne 0x40290d
mov ecx, dword [ebp - 8]
lea eax, [ebp + 0xc]
push eax
push ecx
call fcn.004043b0
mov dword [ebp - 4], eax
cmp eax, ebx
je 0x402a42
push 0x9b
push str.XHttp.cpp
push str.FALSE
push str.code:__s_r_nfile:__s_r_nline:__d_r_n
push 0x440140
call edi
add esp, 0x14
push 0x200000
push str.DBG_ASSERT
push 0x440140
push ebx
call esi
mov edi, dword [ebp - 0xc]
mov esi, dword [ebp - 8]
mov edx, dword [edi]
mov eax, dword [edx + 0x18]
mov ecx, edi
call eax
test eax, eax
je 0x402994
push 0xae
push str.XHttp.cpp
push str.FALSE
push str.code:__s_r_nfile:__s_r_nline:__d_r_n
push 0x43fd40
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x14
push 0x200000
push str.DBG_ASSERT
push 0x43fd40
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
mov edx, dword [esi]
mov eax, dword [edx + 0x18]
mov ecx, esi
call eax
test eax, eax
je 0x4029da
push 0xb3
push str.XHttp.cpp
push str.FALSE
push str.code:__s_r_nfile:__s_r_nline:__d_r_n
push 0x43f940
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x14
push 0x200000
push str.DBG_ASSERT
push 0x43f940
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
push 0x3e8
call dword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [edi + 0x2c]
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [edi], vtable.CXSo.0
test eax, eax
je 0x402a02
push eax
call ebx
mov dword [edi + 0x2c], 0
mov eax, dword [edi + 0x14]
test eax, eax
je 0x402a13
push eax
call ebx
mov dword [edi + 0x14], 0
push edi
call fcn.0040cf1f
add esp, 4
call fcn.004044d0
push esi
call fcn.0040cf1f
mov ecx, dword [ebp - 0x14]
add esp, 4
push ecx
call fcn.0040cf1f
mov eax, dword [ebp - 4]
add esp, 4
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
push 0x28
call fcn.0040ceba
add esp, 4
cmp eax, ebx
je 0x402a6a
mov dword [eax + 8], ebx
mov dword [eax + 0xc], ebx
mov dword [eax + 0x18], ebx
mov dword [eax + 0x1c], ebx
mov dword [eax + 0x10], ebx
mov dword [eax + 0x14], ebx
mov dword [eax + 0x20], ebx
mov dword [eax + 0x24], ebx
jmp 0x402a6c
xor eax, eax
mov edx, dword [ebp - 0xc]
mov ecx, dword [ebp - 8]
mov dword [eax], edx
lea edx, [ebp - 0x10]
push edx
push ebx
push eax
push 0x4067e0
push ebx
push ebx
mov dword [eax + 4], ecx
call dword [sym.imp.KERNEL32.dll_CreateThread]
cmp eax, ebx
je 0x402a97
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x402ad1
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, ebx
je 0x402ad1
push 0xa3
push str.XHttp.cpp
push str.FALSE
push str.code:__s_r_nfile:__s_r_nline:__d_r_n
push 0x43f540
call edi
add esp, 0x14
push 0x200000
push str.DBG_ASSERT
push 0x43f540
push ebx
call esi
mov eax, dword [ebp - 0x14]
push eax
call fcn.0040cf1f
mov eax, dword [ebp - 4]
add esp, 4
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8