Function at 0x4979a0
Capabilities:
Connect socket

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1ec
mov eax, dword [0x5a7774]
xor eax, ebp
mov dword [ebp - 4], eax
mov edx, dword [ebp + 0xc]
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp + 0x10]
add eax, 0x58
push ebx
mov ebx, dword [ebp + 8]
lea eax, [edx + eax*4]
push edi
mov dword [ebp - 0x1d8], eax
mov dword [eax], 0xffffffff
lea eax, [ebp - 0x1dc]
push eax
lea eax, [ebp - 0x1c4]
mov dword [ebp - 0x1cc], edx
push eax
push ecx
push ebx
mov byte [ebp - 0x1c5], 0
call fcn.00496fe0
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x497d33
push esi
lea eax, [ebp - 0x1d4]
push eax
lea eax, [ebp - 0x34]
push eax
push dword [ebp - 0x1b8]
lea eax, [ebp - 0x1b4]
push eax
call fcn.00496200
add esp, 0x10
test al, al
jne 0x497a7f
call fcn.0050e648
mov esi, eax
call fcn.0050e648
mov edi, eax
lea eax, [ebp - 0x134]
push 0x100
push eax
push dword [esi]
call fcn.004adc70
push eax
push dword [edi]
push str.sa_addr_inet_ntop___failed_with_errno__d:__s
push ebx
call fcn.00495900
push dword [ebp - 0x1dc]
mov eax, dword [ebp - 0x1cc]
push eax
push ebx
call fcn.004962a0
add esp, 0x28
xor eax, eax
pop esi
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0050bf8a
mov esp, ebp
pop ebp
ret
push dword [ebp - 0x1d4]
lea eax, [ebp - 0x34]
push eax
push str.__Trying__s:_ld..._n
push ebx
call fcn.00495a20
mov eax, dword [ebp - 0x1c4]
add esp, 0x10
cmp eax, 2
je 0x497aa7
cmp eax, 0x17
jne 0x497ab7
cmp dword [ebp - 0x1c0], 1
jne 0x497ab7
mov eax, 1
jmp 0x497ab9
xor eax, eax
mov esi, dword [ebp - 0x1dc]
test eax, eax
setne al
mov byte [ebp - 0x1cd], al
test al, al
je 0x497ae1
cmp byte [ebx + 0x6f6], 0
je 0x497ae1
push esi
push ebx
call fcn.00497e30
add esp, 8
push esi
call fcn.00496f40
add esp, 4
cmp byte [ebp - 0x1cd], 0
je 0x497b06
cmp byte [ebx + 0x6ff], 0
je 0x497b06
push esi
push ebx
call fcn.00497d50
add esp, 8
cmp dword [ebx + 0x1c8], 0
je 0x497b4b
push 1
push ebx
call fcn.004906a0
mov eax, dword [ebx + 0x1c8]
push 0
push esi
push dword [ebx + 0x1cc]
call eax
push 0
push ebx
mov dword [ebp - 0x1d4], eax
call fcn.004906a0
mov eax, dword [ebp - 0x1d4]
add esp, 0x1c
cmp eax, 2
jne 0x497bad
mov byte [ebp - 0x1c5], 1
mov eax, dword [ebp - 0x1c4]
cmp eax, 2
je 0x497b5b
cmp eax, 0x17
jne 0x497bd8
lea eax, [ebp - 0x1b4]
push eax
call fcn.004ae720
push eax
push dword [ebp - 0x1c4]
push esi
push ebx
call fcn.00497290
mov edi, eax
add esp, 0x14
test edi, edi
je 0x497bd8
mov eax, dword [ebp - 0x1cc]
push esi
push eax
push ebx
call fcn.004962a0
add esp, 0xc
mov eax, 7
cmp edi, 1
cmove edi, eax
pop esi
mov eax, edi
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0050bf8a
mov esp, ebp
pop ebp
ret
test eax, eax
je 0x497b4b
mov eax, dword [ebp - 0x1cc]
push esi
push eax
push ebx
call fcn.004962a0
add esp, 0xc
mov eax, 0x2a
pop esi
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0050bf8a
mov esp, ebp
pop ebp
ret
push 1
push esi
call fcn.004abbb0
lea eax, [ebp - 0x1ec]
push eax
call fcn.004a5c10
add esp, 0xc
movdqu xmm0, xmmword [eax]
mov eax, dword [ebp - 0x1cc]
cmp dword [eax + 0x270], 1
movdqu xmmword [eax + 0x278], xmm0
jle 0x497c41
push 3
push dword [eax + 0x28c]
push dword [eax + 0x288]
push ebx
call fcn.00490170
mov eax, dword [ebp - 0x1cc]
push 4
push dword [eax + 0x294]
push dword [eax + 0x290]
push ebx
call fcn.00490170
mov eax, dword [ebp - 0x1cc]
add esp, 0x20
cmp byte [ebp - 0x1c5], 0
jne 0x497d28
cmp dword [eax + 0x60], 4
je 0x497d28
cmp byte [eax + 0x266], 0
jne 0x497c9d
push dword [ebp - 0x1b8]
lea eax, [ebp - 0x1b4]
push eax
push esi
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
je 0x497c9d
test edi, edi
jne 0x497d15
mov eax, dword [ebp - 0x1d8]
mov dword [eax], esi
mov eax, edi
pop esi
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0050bf8a
mov esp, ebp
pop ebp
ret
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edi, eax
cmp edi, 0xb
je 0x497d0b
cmp edi, 0x2732
jle 0x497cba
cmp edi, 0x2734
jle 0x497d0b
push 0x100
lea eax, [ebp - 0x134]
push eax
push edi
call fcn.004adc70
push eax
lea eax, [ebp - 0x34]
push eax
push str.Immediate_connect_fail_for__s:__s_n
push ebx
call fcn.00495a20
mov eax, dword [ebp - 0x1cc]
push esi
push eax
push ebx
mov dword [ebx + 0x948], edi
call fcn.004962a0
add esp, 0x28
mov edi, 7
mov eax, edi
pop esi
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0050bf8a
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x1d8]
xor edi, edi
mov dword [eax], esi
pop esi
mov eax, edi
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0050bf8a
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x1d8]
mov dword [eax], esi
xor eax, eax
pop esi
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop ebx
call fcn.0050bf8a
mov esp, ebp
pop ebp
ret