Function at 0x4c7b90
Capabilities:
Connect socket
Get socket status
Set socket configuration

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x224
mov eax, dword [esp + 0x23c]
mov esi, dword [esp + 0x238]
lea ebx, [esp + 0x1c]
mov dword [esp + 0x1c], 1
mov ebp, dword [eax]
push ebx
push 0x8004667e
push ebp
call dword [sym.imp.WS2_32.dll_ioctlsocket]
cmp eax, 0xffffffff
je 0x4c7cd3
mov eax, dword [esp + 0x240]
cmp word [eax], 0
je 0x4c7bf1
movups xmm0, xmmword [eax + 4]
mov edi, dword [eax + 0x18]
lea ecx, [eax + 0x14]
add eax, 0x1c
mov edx, 0x1c
mov si, 0x17
jmp 0x4c7c03
lea ecx, [eax + 2]
add eax, 6
mov edx, 0x10
mov si, 2
xorps xmm0, xmm0
movzx eax, word [eax]
mov ecx, dword [ecx]
mov word [esp + 0x1c], si
rol ax, 8
mov word [esp + 0x1e], ax
mov dword [esp + 0x20], ecx
movups xmmword [esp + 0x24], xmm0
mov dword [esp + 0x34], edi
push edx
push ebx
push ebp
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
je 0x4c7c62
mov byte [esp], 4
mov dword [esp + 0x1c], 0
push ebx
push 0x8004667e
push ebp
call dword [sym.imp.WS2_32.dll_ioctlsocket]
mov esi, dword [esp + 0x238]
cmp eax, 0xffffffff
je 0x4c7cd3
mov eax, dword [esp]
mov edi, dword [esp + 4]
jmp 0x4c7ce6
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov edi, eax
mov dword [esp + 4], eax
mov dword [esp], 0
mov dword [esp + 0x1c], 0
push ebx
push 0x8004667e
push ebp
call dword [sym.imp.WS2_32.dll_ioctlsocket]
mov esi, dword [esp + 0x238]
cmp eax, 0xffffffff
je 0x4c7cd3
mov ecx, esp
call fcn.00403230
cmp al, 0xd
jne 0x4c7ce4
mov esi, dword [esp + 0x244]
mov eax, dword [esp + 0x248]
mov ecx, dword [esp + 0x24c]
mov edx, esi
or edx, eax
jne 0x4c7cf8
test ecx, ecx
jne 0x4c7cf8
mov esi, dword [esp + 0x238]
mov byte [esi], 2
mov dword [esi + 4], 0x565a20
jmp 0x4c7ceb
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov dword [esi + 4], eax
mov dword [esi], 0
jmp 0x4c7ceb
xor eax, eax
mov dword [esi], eax
mov dword [esi + 4], edi
mov eax, esi
add esp, 0x224
pop esi
pop edi
pop ebx
pop ebp
ret
cmp esi, 0x7fffffff
mov edx, bind
cmovae esi, edx
test eax, eax
mov eax, ecx
cmovne esi, edx
mov edx, 0x10624dd3
mul edx
mov eax, 1
mov dword [esp + 0x14], esi
shr edx, 6
test esi, esi
cmovne eax, edx
cmp ecx, 0x3e8
cmovae eax, edx
mov dword [esp + 0x18], eax
lea eax, [esp + 0x24]
push 0xfc
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
lea eax, [esp + 0x128]
mov dword [esp + 0x120], 1
mov dword [esp + 0x124], ebp
push 0xfc
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
lea eax, [esp + 0x14]
mov dword [esp + 0x1c], 1
mov dword [esp + 0x20], ebp
lea ecx, [esp + 0x120]
push eax
push ebx
push ecx
push 0
push 1
call dword [sym.imp.WS2_32.dll_select]
test eax, eax
je 0x4c7dbe
mov esi, dword [esp + 0x238]
cmp eax, 0xffffffff
jne 0x4c7dd4
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov byte [esi], 0
mov byte [esi + 3], 0
mov word [esi + 1], 0
mov dword [esi + 4], eax
jmp 0x4c7ceb
mov esi, dword [esp + 0x238]
mov byte [esi], 2
mov dword [esi + 4], 0x565a40
jmp 0x4c7ceb
cmp dword [esp + 0x120], 1
jne 0x4c7de6
mov byte [esi], 4
jmp 0x4c7ceb
lea eax, [esp + 8]
push dword [esp + 0x23c]
push eax
call fcn.004c7e20
add esp, 8
cmp dword [esp + 8], 0
je 0x4c7e07
mov eax, dword [esp + 0xc]
jmp 0x4c7e0f
mov eax, dword [esp + 0xc]
cmp al, 4
je 0x4c7dde
mov ecx, dword [esp + 0x10]
mov dword [esi], eax
mov dword [esi + 4], ecx
jmp 0x4c7ceb