Function at 0x408df0
Capabilities:
Connect socket
Set socket configuration

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x43b78d
mov eax, dword fs:[0]
push eax
sub esp, 0xc8
mov eax, dword [0x447034]
xor eax, esp
mov dword [esp + 0xc0], eax
push ebx
push esi
push edi
mov eax, dword [0x447034]
xor eax, esp
push eax
lea eax, [esp + 0xd8]
mov dword fs:[0], eax
mov eax, dword [ebp + 0xc]
mov edi, dword [ebp + 8]
mov esi, dword [ebp + 0x10]
mov ebx, dword [ebp + 0x14]
mov dword [esp + 0x18], eax
mov eax, dword [edi]
cmp eax, 0xffffffff
mov dword [esp + 0x14], ecx
mov dword [esp + 0x10], edx
je 0x408e5c
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
mov dword [edi], 0xffffffff
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0x14]
push eax
push ebx
push esi
push ecx
lea edx, [esp + 0x6c]
push edx
mov dword [edi + 4], 0
call fcn.00409340
xor ebx, ebx
mov dword [esp + 0xe0], ebx
cmp dword [edi + 0x1018], ebx
je 0x408f42
mov edi, edi
mov ebx, dword [edi + 0x1014]
mov eax, dword [edi + 0x1018]
add eax, ebx
cmp ebx, eax
jbe 0x408ea7
call fcn.0042868a
mov ecx, dword [edi + 0x1018]
add ecx, dword [edi + 0x1014]
mov esi, ebx
mov eax, ebx
and eax, 3
shr esi, 2
cmp ebx, ecx
mov dword [esp + 0x10], eax
jb 0x408ece
call fcn.0042868a
mov eax, dword [esp + 0x10]
mov ecx, dword [edi + 0x1010]
cmp ecx, esi
ja 0x408eda
sub esi, ecx
mov edx, dword [edi + 0x100c]
mov ecx, dword [edx + esi*4]
mov eax, dword [ecx + eax*4]
xor esi, esi
cmp eax, esi
je 0x408ef6
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx]
push 1
call eax
mov eax, dword [edi + 0x1018]
cmp eax, esi
je 0x408f34
mov edx, dword [edi + 0x1010]
add dword [edi + 0x1014], 1
mov ecx, dword [edi + 0x1014]
add edx, edx
add edx, edx
cmp edx, ecx
ja 0x408f21
mov dword [edi + 0x1014], esi
add eax, 0xffffffff
cmp eax, esi
mov dword [edi + 0x1018], eax
jne 0x408f34
mov dword [edi + 0x1014], esi
cmp dword [edi + 0x1018], esi
jne 0x408e90
xor ebx, ebx
mov ecx, dword [edi + 0x1020]
cmp ecx, ebx
je 0x408f5a
mov eax, dword [ecx]
mov edx, dword [eax]
push 1
call edx
mov dword [edi + 0x1020], ebx
mov esi, dword [esp + 0x14]
xor eax, eax
mov dword [esp + 0x4e], eax
mov dword [esp + 0x52], eax
mov dword [esp + 0x56], eax
mov word [esp + 0x5a], ax
lea eax, [esp + 0x4c]
mov word [esp + 0x4c], bx
call fcn.004091a0
push ebx
push 1
push 2
call dword [sym.imp.WS2_32.dll_socket]
cmp eax, 0xffffffff
mov dword [edi], eax
jne 0x408fb6
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
lea eax, [esp + 0x24]
push eax
mov edi, 0x43fe1c
call fcn.00401040
push 0x4423e8
lea ecx, [esp + 0x24]
push ecx
call fcn.0042b0d1
push 4
lea edx, [esp + 0x20]
push edx
push 0x1005
push 0xffff
push eax
mov dword [esp + 0x30], 0x2bf20
call dword [sym.imp.WS2_32.dll_setsockopt]
lea eax, [edi + 0x101c]
push eax
lea ecx, [edi + 0x1008]
push ecx
lea ecx, [esp + 0x64]
call fcn.00409510
mov edx, dword [esp + 0x18]
mov eax, dword [edi]
push 0x12
push 0x4c8
push edx
push eax
call dword [sym.imp.WS2_32.dll_WSAAsyncSelect]
cmp eax, 0xffffffff
jne 0x40903b
mov ecx, dword [edi]
push ecx
call dword [sym.imp.WS2_32.dll_closesocket]
mov dword [edi], 0xffffffff
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
lea edx, [esp + 0x24]
push edx
mov edi, 0x43fe2c
call fcn.00401040
push 0x4423e8
lea eax, [esp + 0x24]
push eax
call fcn.0042b0d1
mov edx, dword [edi]
push 0x10
lea ecx, [esp + 0x50]
push ecx
push edx
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
jne 0x40908f
mov esi, dword [sym.imp.WS2_32.dll_WSAGetLastError]
call esi
cmp eax, 0x2733
je 0x40908f
mov eax, dword [edi]
push eax
call dword [sym.imp.WS2_32.dll_closesocket]
mov dword [edi], 0xffffffff
call esi
push eax
lea ecx, [esp + 0x24]
push ecx
mov edi, 0x43fe48
call fcn.00401040
push 0x4423e8
lea edx, [esp + 0x24]
push edx
call fcn.0042b0d1
lea eax, [esp + 0x5c]
push eax
mov dword [esp + 0xe4], 0xffffffff
call fcn.00409440
mov ecx, dword [esp + 0xd8]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0xc0]
xor ecx, esp
call fcn.004282a0
mov esp, ebp
pop ebp
ret 0x10