Function at 0x45c7e0
Capabilities:
Connect socket

Disassembly:
push 0xffffffffffffffff
push 0x507ae4
mov eax, dword fs:[0]
push eax
sub esp, 0xf4
mov eax, dword [0x5894dc]
xor eax, esp
mov dword [esp + 0xf0], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x5894dc]
xor eax, esp
push eax
lea eax, [esp + 0x108]
mov dword fs:[0], eax
mov eax, dword [esp + 0x130]
mov ebp, dword [esp + 0x118]
mov esi, dword [esp + 0x128]
mov ebx, dword [esp + 0x12c]
mov edi, ecx
lea ecx, [edi + 0x128]
mov dword [esp + 0x20], eax
mov dword [edi + 0x150], 0
call fcn.00407610
mov eax, dword [esp + 0x20]
test eax, eax
je 0x45d03d
cmp dword [esp + 0x120], 0
je 0x45d03d
test ebp, ebp
mov byte [ebx], 0
jne 0x45c892
mov dword [edi + 0x150], 1
mov edx, dword [esi]
mov eax, dword [edx + 0x10]
push str.Cannot_connect__hostname_is_NULL
mov ecx, esi
call eax
xor al, al
jmp 0x45d09c
push ebp
lea ecx, [esp + 0x54]
call fcn.00407f30
xor ebp, ebp
lea ecx, [esp + 0x50]
mov dword [esp + 0x110], ebp
call fcn.00407400
lea ecx, [esp + 0x50]
call fcn.0046fb80
test eax, eax
jne 0x45c8ee
mov dword [edi + 0x150], 1
mov edx, dword [esi]
mov eax, dword [edx + 0x10]
push str.Cannot_connect__hostname_is_zero_length
mov ecx, esi
call eax
lea ecx, [esp + 0x50]
mov dword [esp + 0x110], 0xffffffff
call fcn.00408310
xor al, al
jmp 0x45d09c
push str.localhost
lea ecx, [esp + 0x54]
call fcn.00409680
test al, al
je 0x45c91e
push str.127.0.0.1
lea ecx, [edi + 0x128]
call fcn.004091c0
push str.127.0.0.1
lea ecx, [esp + 0x54]
call fcn.004091c0
cmp byte [0x58134c], 0
je 0x45c92e
mov ecx, esi
call fcn.00457ca0
lea ecx, [esp + 0x7c]
call fcn.00408020
mov ebx, dword [esp + 0x11c]
push ebx
lea ecx, [esp + 0x80]
mov byte [esp + 0x114], 1
call fcn.00409ad0
xor eax, eax
mov dword [esp + 0x2c], eax
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], eax
lea ecx, [esp + 0x50]
mov dword [esp + 0x18], ebp
mov dword [esp + 0x38], eax
mov dword [esp + 0x3c], eax
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x2c], 0x80
mov dword [esp + 0x30], ebp
mov dword [esp + 0x34], 1
call fcn.004e81e0
lea ecx, [esp + 0xf4]
push ecx
push eax
call fcn.004578f0
add esp, 8
test al, al
je 0x45c9c4
mov edx, dword [esi]
mov eax, dword [edx + 0x14]
push str.This_is_an_IPV4_numeric_address.
mov ecx, esi
call eax
mov ebp, 2
mov dword [esp + 0x30], ebp
jmp 0x45c9fd
lea ecx, [esp + 0x50]
call fcn.004e81e0
lea ecx, [esp + 0xf4]
push ecx
push eax
call fcn.004579a0
add esp, 8
test al, al
mov ecx, esi
je 0x45ca52
mov edx, dword [esi]
mov eax, dword [edx + 0x14]
push str.This_is_an_IPV6_numeric_address.
call eax
mov dword [esp + 0x30], 0x17
mov ebp, 2
mov edx, dword [esi]
mov eax, dword [edx + 0x14]
or dword [esp + 0x2c], 4
push str.Hostname_to_IP_address_resolution_not_needed.
mov ecx, esi
call eax
lea ecx, [esp + 0x18]
push ecx
push esi
lea edx, [esp + 0x34]
push edx
push ebx
lea ecx, [esp + 0x60]
call fcn.004e81e0
push eax
call fcn.0045a330
add esp, 0x14
test al, al
jne 0x45cb6d
lea ecx, [esp + 0x7c]
mov dword [edi + 0x150], ebp
mov byte [esp + 0x110], 0
call fcn.00408310
jmp 0x45c8d3
mov eax, dword [esi]
mov edx, dword [eax + 0x14]
push str.Multi_threaded_hostname_to_IP_address_resolution
call edx
push 0x50
call fcn.004eceb1
add esp, 4
mov dword [esp + 0x28], eax
cmp eax, ebp
mov byte [esp + 0x110], 2
je 0x45ca81
mov ecx, eax
call fcn.004b6d50
mov ebp, eax
test ebp, ebp
mov byte [esp + 0x110], 1
jne 0x45cabb
mov eax, dword [esi]
mov edx, dword [eax + 0x10]
push str.Memory_allocation_failure.
mov ecx, esi
call edx
lea ecx, [esp + 0x7c]
mov dword [edi + 0x150], 5
mov byte [esp + 0x110], 0
call fcn.00408310
jmp 0x45c8d3
push 0x1446
mov ecx, ebp
call fcn.004b75a0
mov eax, dword [edi + 0x11c]
lea ecx, [esp + 0x16]
push ecx
lea edx, [esp + 0x1b]
push edx
lea ecx, [esp + 0x20]
push ecx
mov ecx, dword [esp + 0x2c]
lea edx, [esp + 0x38]
push edx
mov edx, dword [esp + 0x130]
push ecx
push esi
push edx
push eax
push ebx
lea ecx, [esp + 0x74]
mov byte [esp + 0x3b], 0
mov byte [esp + 0x3a], 0
call fcn.004e81e0
push eax
mov ecx, ebp
call fcn.004b6f10
mov bl, al
mov eax, dword [ebp]
mov edx, dword [eax]
mov ecx, ebp
call edx
test bl, bl
jne 0x45cb68
cmp byte [esp + 0x17], bl
je 0x45cb40
lea ecx, [esp + 0x7c]
mov dword [edi + 0x150], 4
mov byte [esp + 0x110], bl
call fcn.00408310
jmp 0x45c8d3
xor eax, eax
cmp byte [esp + 0x16], al
lea ecx, [esp + 0x7c]
setne al
mov byte [esp + 0x110], 0
add eax, 2
mov dword [edi + 0x150], eax
call fcn.00408310
jmp 0x45c8d3
mov ebp, 2
mov eax, dword [esp + 0x18]
test eax, eax
je 0x45ca36
mov edx, dword [esi]
cmp dword [eax + 4], ebp
mov eax, dword [edx + 0x14]
mov ecx, esi
jne 0x45cb8c
push str.Connecting_to_IPV4_address.
jmp 0x45cb91
push str.Connecting_to_IPV6_address.
call eax
mov eax, dword [esp + 0x18]
mov ecx, dword [eax + 4]
cmp ecx, ebp
mov eax, dword [eax + 0x18]
jne 0x45cba6
add eax, 4
jmp 0x45cba9
add eax, 8
lea ebx, [edi + 0x128]
push ebx
push eax
push ecx
call fcn.004578c0
mov ebp, dword [esi]
add esp, 0xc
mov ecx, ebx
add ebp, 0x28
call fcn.004e81e0
mov edx, dword [ebp]
push eax
push str.ipAddress
mov ecx, esi
call edx
mov eax, dword [esp + 0x18]
push 1
push esi
push eax
mov ecx, edi
call fcn.0045b0c0
test al, al
je 0x45d006
cmp dword [edi + 0xa4], 0xffffffff
je 0x45d006
mov ebx, dword [edi + 0x11c]
test ebx, ebx
je 0x45cc08
mov ecx, edi
call fcn.00457f00
mov dword [esp + 0x1c], 0
mov byte [esp + 0x17], 0
mov ebp, 0x64
lea ebx, [ebx]
call fcn.0041e170
cmp dword [esp + 0x1c], 0
mov dword [esp + 0x78], eax
je 0x45cc45
cmp ebx, ebp
jb 0x45cc3b
sub ebx, ebp
cmp ebx, 0x64
jae 0x45cc45
mov ebx, 0x64
mov byte [esp + 0x17], 1
mov eax, dword [esp + 0x18]
mov ecx, dword [eax + 0x10]
mov edx, dword [eax + 0x18]
mov eax, dword [edi + 0xa4]
push ecx
push edx
push eax
call dword [sym.imp.WS2_32.dll_connect]
test eax, eax
mov dword [esp + 0x28], eax
je 0x45ceeb
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ebp, eax
cmp ebp, 0x2733
mov dword [esp + 0x4c], ebp
je 0x45ccc9
cmp ebp, 0x2726
jne 0x45ccba
mov ebp, dword [esi]
lea ecx, [esp + 0x50]
add ebp, 0x28
call fcn.004e81e0
mov edx, dword [ebp]
push eax
push str.HostOrIpAddress
mov ecx, esi
call edx
mov ecx, dword [edi + 0xa4]
mov eax, dword [esi]
mov edx, dword [eax + 0x34]
push ecx
push str.SocketHandle
mov ecx, esi
call edx
mov ebp, dword [esp + 0x4c]
mov eax, dword [esi]
mov edx, dword [eax + 0x2c]
push ebp
push str.sockError
mov ecx, esi
call edx
test ebx, ebx
je 0x45cef6
cmp ebp, 0x2733
jne 0x45ceeb
lea eax, [esp + 0x27]
push eax
lea ecx, [esp + 0x2a]
push ecx
mov ecx, dword [esp + 0x28]
lea edx, [esp + 0x1e]
push edx
mov edx, dword [esp + 0x130]
lea eax, [esp + 0x31]
push eax
mov eax, dword [esp + 0x130]
push ecx
push esi
push 1
push ebx
push edx
push eax
mov ecx, edi
mov byte [esp + 0x3e], 0
call fcn.00458c40
test al, al
jne 0x45cd86
cmp byte [esp + 0x16], al
jne 0x45ce86
cmp byte [esp + 0x17], al
jne 0x45cebe
call fcn.0041e170
mov edx, dword [esp + 0x78]
cmp eax, edx
mov ecx, 0x64
jbe 0x45cd44
sub eax, edx
mov ecx, eax
cmp ebx, ecx
jbe 0x45ceeb
sub ebx, ecx
cmp ebx, 0x3e8
jbe 0x45cd6e
mov ebp, 0x3e8
push ebp
call fcn.0041e160
add esp, 4
add dword [esp + 0x1c], 1
jmp 0x45cc20
mov ebp, 0x64
push ebp
call fcn.0041e160
add esp, 4
add dword [esp + 0x1c], 1
jmp 0x45cc20
mov ecx, edi
call fcn.00457f30
lea ecx, [edi + 0xb0]
mov byte [edi + 0xa0], 1
call fcn.004b68d0
lea ecx, [edi + 0x10]
call fcn.004b6930
lea ecx, [edi + 0x58]
call fcn.004b6930
lea ecx, [esp + 0xa4]
call fcn.00408020
cmp dword [edi + 0xa8], 2
mov byte [esp + 0x110], 3
push esi
jne 0x45cde3
lea ecx, [esp + 0x20]
push ecx
lea edx, [esp + 0xac]
push edx
mov ecx, edi
call fcn.00459f30
jmp 0x45cdf7
lea eax, [esp + 0x20]
push eax
lea ecx, [esp + 0xac]
push ecx
mov ecx, edi
call fcn.0045a010
mov edi, dword [esi]
lea ecx, [esp + 0xa4]
add edi, 0x28
call fcn.004e81e0
mov edx, dword [edi]
push eax
push str.myIP_5
mov ecx, esi
call edx
mov ecx, dword [esp + 0x1c]
mov eax, dword [esi]
mov edx, dword [eax + 0x2c]
push ecx
push str.myPort_5
mov ecx, esi
call edx
mov eax, dword [esi]
mov edx, dword [eax + 0x14]
push str.connect_successful.
mov ecx, esi
call edx
mov ecx, dword [esp + 0x18]
call fcn.00457e70
mov dword [esp + 0x18], 0
lea ecx, [esp + 0xa4]
mov byte [esp + 0x110], 1
call fcn.00408310
lea ecx, [esp + 0x7c]
mov byte [esp + 0x110], 0
call fcn.00408310
lea ecx, [esp + 0x50]
mov dword [esp + 0x110], 0xffffffff
call fcn.00408310
mov al, 1
jmp 0x45d09c
mov ecx, edi
call fcn.00457f30
mov ecx, dword [esp + 0x18]
mov dword [edi + 0x150], 4
call fcn.00457e70
lea ecx, [esp + 0x7c]
mov dword [esp + 0x18], 0
mov byte [esp + 0x110], 0
call fcn.00408310
jmp 0x45c8d3
mov ecx, dword [edi + 0x11c]
mov dword [edi + 0x150], 6
mov eax, dword [esi]
mov edx, dword [eax + 0x2c]
push ecx
push str.ConnectTimeoutMs
mov ecx, esi
call edx
push esi
push 0x2733
call fcn.00458120
add esp, 8
test ebx, ebx
je 0x45cef6
mov ecx, edi
call fcn.00457f30
xor ebx, ebx
cmp dword [esp + 0x28], ebx
jne 0x45cfc3
lea ecx, [edi + 0xb0]
mov byte [edi + 0xa0], 1
call fcn.004b68d0
lea ecx, [edi + 0x10]
call fcn.004b6930
lea ecx, [edi + 0x58]
call fcn.004b6930
lea ecx, [esp + 0xcc]
call fcn.00408020
cmp dword [edi + 0xa8], 2
mov byte [esp + 0x110], 4
push esi
jne 0x45cf58
lea eax, [esp + 0x20]
push eax
lea ecx, [esp + 0xd4]
push ecx
mov ecx, edi
call fcn.00459f30
jmp 0x45cf6c
lea edx, [esp + 0x20]
push edx
lea eax, [esp + 0xd4]
push eax
mov ecx, edi
call fcn.0045a010
mov edi, dword [esi]
lea ecx, [esp + 0xcc]
add edi, 0x28
call fcn.004e81e0
mov edx, dword [edi]
push eax
push str.myIP_6
mov ecx, esi
call edx
mov ecx, dword [esp + 0x1c]
mov eax, dword [esi]
mov edx, dword [eax + 0x2c]
push ecx
push str.myPort_6
mov ecx, esi
call edx
mov eax, dword [esi]
mov edx, dword [eax + 0x14]
push str.connect_successful.
mov ecx, esi
call edx
mov ecx, dword [esp + 0x18]
call fcn.00457e70
mov dword [esp + 0x18], ebx
lea ecx, [esp + 0xcc]
jmp 0x45ce4d
cmp dword [edi + 0x150], ebx
jne 0x45cfd5
mov dword [edi + 0x150], 7
mov eax, dword [esi]
mov edx, dword [eax + 0x10]
push str.Connect_function_failed
mov ecx, esi
call edx
mov ecx, dword [esp + 0x18]
call fcn.00457e70
lea ecx, [esp + 0x7c]
mov dword [esp + 0x18], ebx
mov byte [esp + 0x110], 0
call fcn.00408310
jmp 0x45c8d3
mov dword [edi + 0x150], 5
mov eax, dword [esi]
mov edx, dword [eax + 0x10]
push str.Cannot_connect__invalid_socket__4_
mov ecx, esi
call edx
mov ecx, dword [esp + 0x18]
call fcn.00457e70
lea ecx, [esp + 0x7c]
mov byte [esp + 0x110], 0
call fcn.00408310
jmp 0x45c8d3
mov edx, dword [esp + 0x11c]
lea ecx, [esp + 0x16]
push ecx
push ebx
push eax
push esi
push edx
push ebp
mov ecx, edi
mov byte [esp + 0x2e], 0
call fcn.0045b960
test al, al
jne 0x45d09c
cmp byte [esp + 0x16], al
je 0x45d09c
mov eax, dword [esi]
mov edx, dword [eax + 0x20]
push 1
push str.IPV4_retry2
mov ecx, esi
call edx
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x11c]
push ebx
push eax
push esi
push ecx
push ebp
mov ecx, edi
call fcn.0045b2d0
mov edx, dword [esi]
mov byte [esp + 0x16], al
mov eax, dword [edx + 0x24]
mov ecx, esi
call eax
mov al, byte [esp + 0x16]
mov ecx, dword [esp + 0x108]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0xf0]
xor ecx, esp
call fcn.004ec47e
add esp, 0x100
ret 0x1c