Function at 0x51a9b0
Capabilities:
Connect socket

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x60bcb3
mov eax, dword fs:[0]
push eax
sub esp, 0xb8
mov eax, dword [0x70635c]
xor eax, ebp
mov dword [ebp - 0x3c], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0xc4], ecx
mov eax, dword [ebp + 0x18]
movzx ecx, byte [eax + 0x48]
push ecx
push str.connect
mov edx, dword [ebp + 0x18]
push edx
lea ecx, [ebp - 0x20]
call fcn.004f5440
mov dword [ebp - 4], 0
mov eax, dword [ebp - 0xc4]
cmp dword [eax + 0xa4], 0xffffffff
jne 0x51aa4d
mov ecx, dword [ebp + 0x14]
mov dword [ecx + 0x1c], 5
push str.Cannot_connect__invalid_socket
mov edx, dword [ebp + 0x18]
mov eax, dword [edx]
mov ecx, dword [ebp + 0x18]
mov edx, dword [eax + 0x14]
call edx
mov byte [ebp - 0xb9], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x20]
call fcn.004f54a0
mov al, byte [ebp - 0xb9]
jmp 0x51ad6b
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0xb54]
mov dword [ebp - 0x14], ecx
cmp dword [ebp - 0x14], 0
jne 0x51aa66
mov dword [ebp - 0x14], 0x1499700
mov ecx, dword [ebp - 0xc4]
call fcn.00517fd0
call fcn.004f3ed0
mov dword [ebp - 0x24], eax
mov edx, dword [ebp + 0x10]
push edx
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp - 0xc4]
mov edx, dword [ecx + 0xa4]
push edx
call dword [sym.imp.WS2_32.dll_connect]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
je 0x51ac7e
call fcn.0051a480
mov dword [ebp - 0x28], eax
cmp dword [ebp - 0x28], 0x2733
jne 0x51ac34
mov eax, dword [ebp + 0x18]
movzx ecx, byte [eax + 0x48]
test ecx, ecx
je 0x51aad3
push str.Waiting_for_the_connect_to_complete...
mov edx, dword [ebp + 0x18]
mov eax, dword [edx]
mov ecx, dword [ebp + 0x18]
mov edx, dword [eax + 0x18]
call edx
mov byte [ebp - 0x29], 0
mov byte [ebp - 0x2b], 1
mov eax, dword [ebp + 0x18]
push eax
mov ecx, dword [ebp + 0x14]
push ecx
movzx edx, byte [ebp - 0x2b]
push edx
movzx eax, byte [ebp - 0x29]
push eax
mov ecx, dword [ebp - 0x14]
push ecx
mov ecx, dword [ebp - 0xc4]
call fcn.0051c560
mov byte [ebp - 0x2a], al
movzx edx, byte [ebp - 0x2a]
test edx, edx
je 0x51abbd
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x38], 4
lea eax, [ebp - 0x38]
push eax
lea ecx, [ebp - 0x34]
push ecx
push 0x1007
push 0xffff
mov edx, dword [ebp - 0xc4]
mov eax, dword [edx + 0xa4]
push eax
call dword [sym.imp.WS2_32.dll_getsockopt]
mov dword [ebp - 0x30], eax
cmp dword [ebp - 0x30], 0
jne 0x51aba9
cmp dword [ebp - 0x34], 0
je 0x51aba7
push str.getsockopt_indicates_an_error.
mov ecx, dword [ebp + 0x18]
mov edx, dword [ecx]
mov ecx, dword [ebp + 0x18]
mov eax, dword [edx + 0x14]
call eax
mov ecx, dword [ebp + 0x18]
push ecx
push 0
mov edx, dword [ebp - 0x34]
push edx
call fcn.00518ef0
add esp, 0xc
mov eax, dword [ebp + 0x14]
mov dword [eax + 0x1c], 7
mov ecx, dword [ebp - 0xc4]
call fcn.0051d5b0
mov byte [ebp - 0xba], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x20]
call fcn.004f54a0
mov al, byte [ebp - 0xba]
jmp 0x51ad6b
jmp 0x51abbb
push str.Failed_to_get_SO_ERROR_on_socket.
mov ecx, dword [ebp + 0x18]
mov edx, dword [ecx]
mov ecx, dword [ebp + 0x18]
mov eax, dword [edx + 0x14]
call eax
jmp 0x51ac32
mov ecx, dword [ebp + 0x14]
movzx edx, byte [ecx + 0xd]
test edx, edx
je 0x51abd4
mov eax, dword [ebp + 0x14]
mov dword [eax + 0x1c], 4
jmp 0x51abf5
mov ecx, dword [ebp + 0x14]
movzx edx, byte [ecx + 0xc]
test edx, edx
je 0x51abeb
mov eax, dword [ebp + 0x14]
mov dword [eax + 0x1c], 6
jmp 0x51abf5
mov ecx, dword [ebp + 0x14]
mov dword [ecx + 0x1c], 7
mov edx, dword [ebp + 0x18]
push edx
push str.failedWaitToConnect
mov ecx, dword [ebp + 0x14]
call fcn.005405f0
mov ecx, dword [ebp - 0xc4]
call fcn.0051d5b0
mov byte [ebp - 0xbb], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x20]
call fcn.004f54a0
mov al, byte [ebp - 0xbb]
jmp 0x51ad6b
jmp 0x51ac7e
mov eax, dword [ebp + 0x14]
mov dword [eax + 0x1c], 7
mov ecx, dword [ebp + 0x18]
push ecx
mov edx, dword [ebp + 0x14]
push edx
mov eax, dword [ebp - 0x28]
push eax
call fcn.00518ef0
add esp, 0xc
mov ecx, dword [ebp - 0xc4]
call fcn.0051d5b0
mov byte [ebp - 0xbc], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x20]
call fcn.004f54a0
mov al, byte [ebp - 0xbc]
jmp 0x51ad6b
mov ecx, dword [ebp - 0xc4]
call fcn.00518010
mov ecx, dword [ebp - 0xc4]
mov byte [ecx + 0xa0], 1
mov edx, dword [ebp + 0x18]
movzx eax, byte [edx + 0x48]
test eax, eax
je 0x51ad0e
lea ecx, [ebp - 0xb4]
call fcn.004ecd60
mov byte [ebp - 4], 1
mov ecx, dword [ebp + 0x18]
push ecx
lea edx, [ebp - 0xb8]
push edx
lea eax, [ebp - 0xb4]
push eax
mov ecx, dword [ebp - 0xc4]
call fcn.005195b0
lea ecx, [ebp - 0xb4]
call fcn.005d1cb0
push eax
push str.myIP
mov ecx, dword [ebp + 0x18]
mov edx, dword [ecx]
mov ecx, dword [ebp + 0x18]
mov eax, dword [edx + 0x2c]
call eax
mov ecx, dword [ebp - 0xb8]
push ecx
push str.myPort
mov ecx, dword [ebp + 0x18]
call fcn.004f50b0
mov byte [ebp - 4], 0
lea ecx, [ebp - 0xb4]
call fcn.004eceb0
mov edx, dword [ebp + 0x18]
push edx
mov ecx, dword [ebp - 0xc4]
add ecx, 0x10
call fcn.0058f190
mov eax, dword [ebp + 0x18]
push eax
mov ecx, dword [ebp - 0xc4]
add ecx, 0x58
call fcn.0058f190
mov ecx, dword [ebp + 0x18]
movzx edx, byte [ecx + 0x48]
test edx, edx
je 0x51ad4f
push str.socket_connect_successful.
mov eax, dword [ebp + 0x18]
mov edx, dword [eax]
mov ecx, dword [ebp + 0x18]
mov eax, dword [edx + 0x18]
call eax
mov byte [ebp - 0xbd], 1
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x20]
call fcn.004f54a0
mov al, byte [ebp - 0xbd]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x3c]
xor ecx, ebp
call fcn.00606c9e
mov esp, ebp
pop ebp
ret 0x14