Function at 0x476ed0
Capabilities:
Connect socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x170
mov eax, dword [0x4f7f44]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push esi
mov esi, dword [ecx]
mov dword [ebp - 0x154], edx
mov dword [edx], 0xffffffff
lea edx, [ebp - 0x150]
push edx
lea edx, [ebp - 0x144]
push edx
push eax
push ecx
mov dword [ebp - 0x148], ecx
mov dword [ebp - 0x158], 0
mov dword [ebp - 0x15c], esi
call fcn.00476cf0
add esp, 0x10
mov dword [ebp - 0x14c], eax
test eax, eax
je 0x476f3e
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a79cb
mov esp, ebp
pop ebp
ret
push ebx
push edi
lea ebx, [ebp - 0x160]
lea edi, [ebp - 0x34]
lea esi, [ebp - 0x134]
call fcn.00476790
test eax, eax
jne 0x476fb8
call fcn.004ad431
mov esi, eax
call fcn.004ad431
mov ecx, dword [esi]
mov edi, eax
push 0x80
lea eax, [ebp - 0xb4]
push eax
push ecx
call fcn.0049b060
mov edx, dword [edi]
push eax
mov eax, dword [ebp - 0x15c]
push edx
push str.sa_addr_inet_ntop___failed_with_errno__d:__s
push eax
call fcn.0046f330
mov ecx, dword [ebp - 0x150]
mov edx, dword [ebp - 0x148]
push ecx
push edx
call fcn.00476c70
add esp, 0x24
pop edi
pop ebx
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a79cb
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x160]
mov esi, dword [ebp - 0x15c]
push eax
lea ecx, [ebp - 0x34]
push ecx
push str.__Trying__s:_ld..._n
push esi
call fcn.0046f260
mov eax, dword [ebp - 0x144]
mov edi, dword [ebp - 0x150]
add esp, 0x10
cmp eax, 2
je 0x476fed
cmp eax, 0x17
jne 0x47701c
mov eax, 1
cmp dword [ebp - 0x140], eax
jne 0x47701c
test byte [esi + 0xaa0], 8
mov dword [ebp - 0x150], eax
je 0x477026
mov ebx, dword [ebp - 0x148]
push ebx
mov ecx, edi
call fcn.00476a40
add esp, 4
jmp 0x47702c
mov dword [ebp - 0x150], 0
mov ebx, dword [ebp - 0x148]
push edi
call fcn.00476ad0
add esp, 4
cmp dword [ebp - 0x150], 0
je 0x47704f
test dword [esi + 0xaa0], 0x1000
je 0x47704f
call fcn.00475f40
cmp dword [esi + 0x618], 0
je 0x477098
push 1
push esi
call fcn.00473730
mov edx, dword [esi + 0x61c]
mov eax, dword [esi + 0x618]
push 0
push edi
push edx
call eax
push 0
push esi
mov dword [ebp - 0x148], eax
call fcn.00473730
mov eax, dword [ebp - 0x148]
add esp, 0x1c
cmp eax, 2
jne 0x4770ff
mov dword [ebp - 0x158], 1
mov eax, dword [ebp - 0x144]
cmp eax, 2
je 0x4770a8
cmp eax, 0x17
jne 0x477123
lea ecx, [ebp - 0x134]
push ecx
call fcn.0049d1c0
mov edx, dword [ebp - 0x144]
push eax
push edx
push edi
push ebx
call fcn.00476170
add esp, 0x14
mov dword [ebp - 0x14c], eax
test eax, eax
je 0x477123
push edi
push ebx
call fcn.00476c70
mov eax, dword [ebp - 0x14c]
add esp, 8
cmp eax, 1
jne 0x477296
pop edi
pop ebx
mov eax, 7
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a79cb
mov esp, ebp
pop ebp
ret
test eax, eax
je 0x477098
push edi
push ebx
call fcn.00476c70
add esp, 8
pop edi
pop ebx
mov eax, 0x2a
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a79cb
mov esp, ebp
pop ebp
ret
push 1
push edi
call fcn.0049d630
lea eax, [ebp - 0x170]
push eax
call fcn.0048e730
mov ecx, dword [eax]
mov dword [ebx + 0x2a8], ecx
mov edx, dword [eax + 4]
mov dword [ebx + 0x2ac], edx
mov ecx, dword [eax + 8]
mov dword [ebx + 0x2b0], ecx
mov edx, dword [eax + 0xc]
add esp, 0xc
cmp dword [ebx + 0x2b8], 1
mov dword [ebx + 0x2b4], edx
jle 0x47717f
mov eax, dword [ebx + 0x2c4]
mov ecx, dword [ebx + 0x2c0]
push 3
push eax
push ecx
push esi
call fcn.00473490
add esp, 0x10
cmp dword [ebp - 0x158], 0
jne 0x47728c
cmp dword [ebx + 0x90], 1
jne 0x47728c
test dword [ebx + 0x2a4], 0x8000000
jne 0x4771c3
mov edx, dword [ebp - 0x138]
push edx
lea eax, [ebp - 0x134]
push eax
push edi
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
jne 0x477264
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [ebp - 0x148], eax
cmp eax, 0xb
je 0x47723b
cmp eax, 0x2732
jle 0x4771e2
cmp eax, 0x2734
jle 0x47723b
push 0x80
lea ecx, [ebp - 0xb4]
push ecx
push eax
call fcn.0049b060
push eax
lea edx, [ebp - 0x34]
push edx
push str.Immediate_connect_fail_for__s:__s_n
push esi
call fcn.0046f260
mov eax, dword [ebp - 0x148]
push edi
push ebx
mov dword [esi + 0xcbc], eax
call fcn.00476c70
add esp, 0x24
pop edi
mov dword [ebp - 0x14c], 7
mov eax, dword [ebp - 0x14c]
pop ebx
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a79cb
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 0x154]
mov dword [ecx], edi
pop edi
mov dword [ebp - 0x14c], 0
mov eax, dword [ebp - 0x14c]
pop ebx
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a79cb
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 0x14c], 0
jne 0x477275
mov ecx, dword [ebp - 0x154]
mov dword [ecx], edi
mov eax, dword [ebp - 0x14c]
pop edi
pop ebx
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004a79cb
mov esp, ebp
pop ebp
ret
mov edx, dword [ebp - 0x154]
mov dword [edx], edi
xor eax, eax
mov ecx, dword [ebp - 4]
pop edi
pop ebx
xor ecx, ebp
pop esi
call fcn.004a79cb
mov esp, ebp
pop ebp
ret