Function at 0x599830
Capabilities:
Create tcp socket
Create udp socket
Initialize winsock library

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1b8
mov eax, dword [0x83e264]
xor eax, ebp
mov dword [ebp - 4], eax
cmp byte [0x85a7a4], 0
push edi
jne 0x599a40
push esi
call fcn.004db1d0
mov esi, eax
test esi, esi
je 0x599888
mov ecx, dword [esi]
push 0x402
push esi
mov ecx, dword [ecx + 4]
call ecx
add esp, 8
cmp eax, 4
jl 0x599888
mov eax, dword [esi]
push str.static:_initializing_WinSock
push 0x402
push 4
mov eax, dword [eax]
push esi
call eax
add esp, 0x10
lea eax, [ebp - 0x1b4]
push eax
push 0x202
call dword [sym.imp.WS2_32.dll_WSAStartup]
test eax, eax
je 0x5998e0
call fcn.004db1d0
mov edi, eax
test edi, edi
je 0x599a8c
mov ecx, dword [edi]
push 0x402
push edi
mov ecx, dword [ecx + 4]
call ecx
add esp, 8
cmp eax, 1
jl 0x599a8c
mov esi, dword [edi]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.static:_WinSock_initialization_failed_with_error__d
push 0x402
push 1
jmp 0x599a84
push 0
push 1
push 2
call dword [sym.imp.WS2_32.dll_socket]
mov edi, eax
call fcn.004db1d0
mov esi, eax
test esi, esi
je 0x599924
mov ecx, dword [esi]
push 0x402
push esi
mov ecx, dword [ecx + 4]
call ecx
add esp, 8
cmp eax, 4
jl 0x599924
mov eax, dword [esi]
push str.static:_loading_WSAID_CONNECTEX_function
push 0x402
push 4
mov eax, dword [eax]
push esi
call eax
add esp, 0x10
push 0
push 0
lea eax, [ebp - 0x1b8]
mov dword [ebp - 0x14], 0x25a207b9
push eax
push 4
push 0x85a79c
push 0x10
lea eax, [ebp - 0x14]
mov dword [ebp - 0x10], 0x4660ddf3
push eax
push 0xc8000006
push edi
mov dword [ebp - 0xc], 0xe576e98e
mov dword [ebp - 8], 0x3e06748c
mov dword [ebp - 0x1b8], 0
call dword [sym.imp.WS2_32.dll_WSAIoctl]
test eax, eax
je 0x5999ad
call fcn.004db1d0
mov edi, eax
test edi, edi
je 0x599a8c
mov ecx, dword [edi]
push 0x402
push edi
mov ecx, dword [ecx + 4]
call ecx
add esp, 8
cmp eax, 2
jl 0x599a8c
mov esi, dword [edi]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.static:_failed_to_load_WSAID_CONNECTEX_function_with_error__d
jmp 0x599a7d
call fcn.004db1d0
mov esi, eax
test esi, esi
je 0x5999e3
mov ecx, dword [esi]
push 0x402
push esi
mov ecx, dword [ecx + 4]
call ecx
add esp, 8
cmp eax, 4
jl 0x5999e3
mov eax, dword [esi]
push str.static:_loading_WSAID_ACCEPTEX_function
push 0x402
push 4
mov eax, dword [eax]
push esi
call eax
add esp, 0x10
push 0
push 0
lea eax, [ebp - 0x1b8]
mov dword [ebp - 0x24], 0xb5367df1
push eax
push 4
push 0x85a7a0
push 0x10
lea eax, [ebp - 0x24]
mov dword [ebp - 0x20], 0x11cfcbac
push eax
push 0xc8000006
push edi
mov dword [ebp - 0x1c], 0x8000ca95
mov dword [ebp - 0x18], 0x92a1485f
mov dword [ebp - 0x1b8], 0
call dword [sym.imp.WS2_32.dll_WSAIoctl]
test eax, eax
jne 0x599a4f
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
mov byte [0x85a7a4], 1
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop edi
call fcn.0051deb6
mov esp, ebp
pop ebp
ret
call fcn.004db1d0
mov edi, eax
test edi, edi
je 0x599a8c
mov ecx, dword [edi]
push 0x402
push edi
mov ecx, dword [ecx + 4]
call ecx
add esp, 8
cmp eax, 2
jl 0x599a8c
mov esi, dword [edi]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.static:_failed_to_load_WSAID_ACCEPTEX_function_with_error__d
push 0x402
push 2
mov eax, dword [esi]
push edi
call eax
add esp, 0x14
push 0xffffffffffffffff
call fcn.005424ff
int3