Function at 0x436c60
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Get socket status

Disassembly:
mov eax, 0x1238
call fcn.00467540
mov ecx, dword [esp + 0x123c]
xor eax, eax
mov dword [esp + 0xc], eax
push ebx
push ebp
mov dword [esp + 0x18], eax
push esi
push edi
mov dword [esp + 0x24], eax
push ecx
mov dword [esp + 0x1c], 4
mov byte [esp + 0x124b], 0
mov byte [esp + 0x24c], 0
mov dword [esp + 0x2c], eax
call dword [sym.imp.WS2_32.dll_inet_addr]
mov edx, dword [esp + 0x1250]
mov dword [esp + 0x20], eax
push edx
mov word [esp + 0x20], 2
call dword [sym.imp.WS2_32.dll_htons]
mov ebx, dword [sym.imp.WS2_32.dll_socket]
xor ebp, ebp
mov word [esp + 0x1e], ax
mov dword [esp + 0x40], ebp
mov dword [esp + 0x144], ebp
lea edi, [esp + 0x34]
push 6
push 1
push 2
call ebx
mov esi, eax
cmp esi, 0xffffffff
mov dword [edi], esi
je 0x436e1e
push esi
call fcn.0047c1ca
add esp, 4
cmp eax, 0xffffffff
je 0x436e80
mov edx, dword [esp + 0x40]
xor eax, eax
test edx, edx
jbe 0x436d1c
lea ecx, [esp + 0x44]
cmp dword [ecx], esi
je 0x436d1c
inc eax
add ecx, 4
cmp eax, edx
jb 0x436d10
cmp eax, edx
jne 0x436d32
cmp edx, 0x40
jae 0x436d32
mov dword [esp + eax*4 + 0x44], esi
mov eax, dword [esp + 0x40]
inc eax
mov dword [esp + 0x40], eax
mov edx, dword [esp + 0x144]
xor eax, eax
test edx, edx
jbe 0x436d52
lea ecx, [esp + 0x148]
cmp dword [ecx], esi
je 0x436d52
inc eax
add ecx, 4
cmp eax, edx
jb 0x436d46
cmp eax, edx
jne 0x436d71
cmp edx, 0x40
jae 0x436d71
mov dword [esp + eax*4 + 0x148], esi
mov eax, dword [esp + 0x144]
inc eax
mov dword [esp + 0x144], eax
inc ebp
add edi, 4
cmp ebp, 3
jl 0x436cdb
mov ebp, dword [sym.imp.WS2_32.dll_connect]
lea esi, [esp + 0x34]
mov edi, 3
mov ecx, dword [esi]
lea eax, [esp + 0x1c]
push 0x10
push eax
push ecx
call ebp
add esi, 4
dec edi
jne 0x436d8d
lea edx, [esp + 0x2c]
lea eax, [esp + 0x144]
push edx
lea ecx, [esp + 0x44]
xor ebp, ebp
push eax
push ecx
push ebp
push ebp
mov dword [esp + 0x40], 8
mov dword [esp + 0x44], ebp
call dword [sym.imp.WS2_32.dll_select]
cmp eax, 0xffffffff
jne 0x436edb
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push 0x4e5a38
lea edx, [esp + 0x250]
push 0xfff
push edx
call fcn.00466ca7
mov eax, dword [0x4d25a4]
push 0x14b
push str.ConnectToEcop__
lea ecx, [esp + 0x260]
push eax
push ecx
call fcn.0043c750
add esp, 0x20
mov eax, 0x1a
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1238
ret
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
push 0x4e5a08
lea eax, [esp + 0x250]
push 0xfff
push eax
call fcn.00466ca7
mov ecx, dword [0x4d25a4]
push 0x128
push str.ConnectToEcop__
lea edx, [esp + 0x260]
push ecx
push edx
call fcn.0043c750
add esp, 0x20
test ebp, ebp
jle 0x436e70
mov edi, dword [sym.imp.WS2_32.dll_closesocket]
mov esi, ebp
push 0xffffffffffffffff
call edi
dec esi
jne 0x436e69
pop edi
pop esi
pop ebp
mov eax, 0x1a
pop ebx
add esp, 0x1238
ret
push 0x4e59f0
lea eax, [esp + 0x24c]
push 0xfff
push eax
call fcn.00466ca7
mov ecx, dword [0x4d25a4]
push 0x133
push str.ConnectToEcop__
lea edx, [esp + 0x25c]
push ecx
push edx
call fcn.0043c750
add esp, 0x1c
test ebp, ebp
jl 0x436ecb
mov ebx, dword [sym.imp.WS2_32.dll_closesocket]
lea edi, [ebp + 1]
push esi
call ebx
dec edi
jne 0x436ec5
pop edi
pop esi
pop ebp
mov eax, 0x1a
pop ebx
add esp, 0x1238
ret
cmp eax, ebp
jne 0x436eef
pop edi
pop esi
pop ebp
mov eax, 0x1b
pop ebx
add esp, 0x1238
ret
mov esi, dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ebx, dword [sym.imp.WS2_32.dll_getsockopt]
lea edi, [esp + 0x34]
mov ecx, dword [edi]
lea edx, [esp + 0x18]
lea eax, [esp + 0x14]
push edx
push eax
push 0x1007
push 0xffff
push ecx
call ebx
cmp eax, 0xffffffff
jne 0x436f25
call esi
mov dword [esp + 0x14], eax
jmp 0x436f29
mov eax, dword [esp + 0x14]
cmp eax, 0x274c
jg 0x436f85
je 0x436f9a
test eax, eax
je 0x436fba
cmp eax, 0x2743
je 0x436f9a
call esi
push eax
push str.getsockopt
lea edx, [esp + 0x250]
push 0xfff
push edx
call fcn.00466ca7
mov eax, dword [0x4d25a4]
push 0x16b
push str.ConnectToEcop__
lea ecx, [esp + 0x260]
push eax
push ecx
call fcn.0043c750
add esp, 0x20
mov dword [esp + 0x10], 0x1a
jmp 0x436fac
cmp eax, 0x274d
je 0x436fa4
cmp eax, 0x274f
jle 0x436f41
cmp eax, 0x2751
jg 0x436f41
mov dword [esp + 0x10], 0x1b
jmp 0x436fac
mov dword [esp + 0x10], 0x18
inc ebp
add edi, 4
cmp ebp, 3
jge 0x436fc2
jmp 0x436eff
mov dword [esp + 0x10], 0
mov ebp, dword [sym.imp.WS2_32.dll_closesocket]
lea edi, [esp + 0x34]
mov ebx, 3
mov esi, dword [edi]
push 2
push esi
call dword [sym.imp.WS2_32.dll_shutdown]
push esi
call ebp
add edi, 4
dec ebx
jne 0x436fd1
mov eax, dword [esp + 0x10]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x1238
ret