Function at 0x4e9700
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Create tcp socket
Get local ipv4 addresses
Get socket information
Get socket status
Receive data
Receive data on socket
Send data
Send data on socket
Set socket configuration
Start tcp server

Disassembly:
sub esp, 0x168
mov eax, dword [0x557200]
xor eax, esp
mov dword [esp + 0x164], eax
mov eax, dword [esp + 0x170]
push ebx
push esi
push edi
mov edi, dword [esp + 0x178]
mov dword [esp + 0xc], edi
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], 0x10
mov dword [edi], 0xffffffff
mov dword [esp + 0x20], 0x10
mov dword [esp + 0x14], 1
mov dword [eax], 0xffffffff
call sub.KERNEL32.dll_GetCurrentProcessId
mov esi, dword [sym.imp.WS2_32.dll_socket]
mov dword [esp + 0x24], eax
mov eax, dword [0x560f8c]
push 6
mov dword [esp + 0x2c], eax
inc eax
push 1
push 2
mov dword [0x560f8c], eax
call esi
mov ebx, eax
mov dword [esp + 0x10], ebx
cmp ebx, 0xffffffff
jne 0x4e97c5
mov esi, dword [sym.imp.WS2_32.dll_WSAGetLastError]
call esi
test eax, eax
jne 0x4e97a6
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x164]
xor ecx, esp
call fcn.004b4f32
add esp, 0x168
ret
call esi
pop edi
pop esi
add eax, 0xafc80
pop ebx
mov ecx, dword [esp + 0x164]
xor ecx, esp
call fcn.004b4f32
add esp, 0x168
ret
push ebp
push str.127.0.0.1
mov dword [esp + 0x44], 2
call dword [sym.imp.WS2_32.dll_inet_addr]
mov dword [esp + 0x44], eax
lea eax, [esp + 0x40]
push 0x10
push eax
push ebx
call dword [sym.imp.WS2_32.dll_bind]
mov ebp, dword [sym.imp.WS2_32.dll_closesocket]
cmp eax, 0xffffffff
jne 0x4e9816
mov esi, dword [sym.imp.WS2_32.dll_WSAGetLastError]
call esi
test eax, eax
jne 0x4e9809
xor esi, esi
jmp 0x4e9a09
call esi
lea esi, [eax + 0xafc80]
jmp 0x4e9a09
lea eax, [esp + 0x20]
push eax
lea eax, [esp + 0x54]
push eax
push ebx
call dword [sym.imp.WS2_32.dll_getsockname]
cmp eax, 0xffffffff
je 0x4e97f6
push 1
push ebx
call dword [sym.imp.WS2_32.dll_listen]
cmp eax, 0xffffffff
je 0x4e97f6
push 6
push 1
push 2
call esi
mov esi, dword [esp + 0x1c]
mov dword [esi], eax
cmp eax, 0xffffffff
je 0x4e97f6
push 0x10
lea ecx, [esp + 0x54]
push ecx
push eax
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
je 0x4e97f6
push 0
push 8
lea eax, [esp + 0x30]
push eax
push dword [esi]
call dword [sym.imp.WS2_32.dll_send]
cmp eax, 8
je 0x4e989c
mov esi, dword [sym.imp.WS2_32.dll_WSAGetLastError]
call esi
test eax, eax
je 0x4e9892
call esi
mov esi, eax
add esi, 0xafc80
jne 0x4e9a09
mov esi, 0x16
jmp 0x4e9a09
lea eax, [esp + 0x18]
push eax
push 0x8004667e
push ebx
call dword [sym.imp.WS2_32.dll_ioctlsocket]
cmp eax, 0xffffffff
je 0x4e97f6
mov ebx, dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov esi, edi
mov ebp, dword [sym.imp.KERNEL32.dll_Sleep]
mov eax, dword [esp + 0x14]
xor edi, edi
mov dword [esp + 0x74], eax
lea eax, [esp + 0x30]
push eax
push edi
push edi
lea eax, [esp + 0x7c]
mov dword [esp + 0x7c], 1
push eax
push edi
mov dword [esp + 0x44], 1
mov dword [esp + 0x48], edi
call dword [sym.imp.WS2_32.dll_select]
cmp eax, 0xffffffff
jne 0x4e9900
push 0x64
call ebp
jmp 0x4e98c4
test eax, eax
je 0x4e98c4
lea eax, [esp + 0x24]
push eax
lea eax, [esp + 0x64]
push eax
push dword [esp + 0x1c]
call dword [sym.imp.WS2_32.dll_accept]
mov dword [esi], eax
cmp eax, 0xffffffff
jne 0x4e9934
call ebx
test eax, eax
jne 0x4e99f3
xor esi, esi
jmp 0x4e99fb
mov esi, dword [esp + 0x10]
mov eax, edi
inc edi
test eax, eax
je 0x4e993f
push 1
call ebp
push 0
push 8
lea eax, [esp + 0x40]
push eax
push dword [esi]
call dword [sym.imp.WS2_32.dll_recv]
cmp eax, 0xffffffff
jne 0x4e999a
call ebx
test eax, eax
je 0x4e9929
call ebx
lea esi, [eax + 0xafc80]
cmp esi, 0xb
je 0x4e9930
cmp esi, 0xafd68
je 0x4e9930
cmp esi, 0xafcd9
je 0x4e9930
cmp esi, 0xafd57
je 0x4e9930
cmp esi, 0xafd24
je 0x4e9930
cmp esi, 0xafca1
je 0x4e9930
cmp esi, 0xb23b3
jne 0x4e99fb
jmp 0x4e9930
cmp eax, 8
jne 0x4e99b5
lea ecx, [esp + 0x28]
mov eax, dword [ecx]
lea edx, [esp + 0x38]
cmp eax, dword [edx]
jne 0x4e99b5
mov eax, dword [ecx + 4]
cmp eax, dword [edx + 4]
je 0x4e99c2
push dword [esi]
call dword [sym.imp.WS2_32.dll_closesocket]
jmp 0x4e98c4
lea eax, [esp + 0x18]
mov dword [esp + 0x18], 0
push eax
push 0x8004667e
push dword [esi]
call dword [sym.imp.WS2_32.dll_ioctlsocket]
cmp eax, 0xffffffff
je 0x4e991f
push dword [esp + 0x14]
call dword [sym.imp.WS2_32.dll_closesocket]
xor eax, eax
jmp 0x4e9a36
call ebx
lea esi, [eax + 0xafc80]
mov ebp, dword [sym.imp.WS2_32.dll_closesocket]
mov ebx, dword [esp + 0x14]
mov edi, dword [esp + 0x10]
mov eax, dword [edi]
cmp eax, 0xffffffff
je 0x4e9a13
push eax
call ebp
mov eax, dword [esp + 0x1c]
mov eax, dword [eax]
cmp eax, 0xffffffff
je 0x4e9a21
push eax
call ebp
mov eax, dword [esp + 0x1c]
mov dword [edi], 0xffffffff
push ebx
mov dword [eax], 0xffffffff
call ebp
mov eax, esi
mov ecx, dword [esp + 0x174]
pop ebp
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.004b4f32
add esp, 0x168
ret