Function at 0x4eb270
Capabilities:
Act as tcp client
Connect socket
Connect tcp socket
Connect udp socket
Create tcp socket
Create udp socket
Get local ipv4 addresses
Get socket information
Set socket configuration
Start tcp server

Disassembly:
sub esp, 0x34
mov eax, dword [0x630160]
xor eax, esp
mov dword [esp + 0x30], eax
push ebx
mov ebx, dword [sym.imp.WS2_32.dll_socket]
push esi
mov esi, dword [esp + 0x4c]
push edi
push 6
push 1
push 2
mov dword [esp + 0x18], 0x10
mov dword [esp + 0x24], 1
call ebx
mov edi, eax
cmp edi, 0xffffffff
jne 0x4eb2be
pop edi
pop esi
or eax, eax
pop ebx
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.00418878
add esp, 0x34
ret
xor eax, eax
mov dword [esp + 0x1c], eax
push ebp
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], eax
mov eax, 2
push 0x7f000001
mov word [esp + 0x24], ax
call dword [sym.imp.WS2_32.dll_htonl]
push 4
lea edx, [esp + 0x20]
push edx
push 4
push 0xffff
xor ecx, ecx
push edi
mov dword [esp + 0x38], eax
mov word [esp + 0x36], cx
mov dword [esi + 4], 0xffffffff
mov dword [esi], 0xffffffff
call dword [sym.imp.WS2_32.dll_setsockopt]
cmp eax, 0xffffffff
je 0x4eb468
push 0x10
lea eax, [esp + 0x24]
push eax
push edi
call dword [sym.imp.WS2_32.dll_bind]
cmp eax, 0xffffffff
je 0x4eb468
mov ebp, dword [sym.imp.WS2_32.dll_getsockname]
lea ecx, [esp + 0x10]
push ecx
lea edx, [esp + 0x24]
push edx
push edi
call ebp
cmp eax, 0xffffffff
je 0x4eb468
cmp dword [esp + 0x10], 0x10
jl 0x4eb468
push 1
push edi
call dword [sym.imp.WS2_32.dll_listen]
cmp eax, 0xffffffff
je 0x4eb468
push 0
push 1
push 2
call ebx
mov dword [esi], eax
cmp eax, 0xffffffff
je 0x4eb468
mov ebx, 0x10
push ebx
lea ecx, [esp + 0x24]
push ecx
push eax
call dword [sym.imp.WS2_32.dll_connect]
cmp eax, 0xffffffff
je 0x4eb468
push 1
push edi
call fcn.004eb240
add esp, 8
test eax, eax
jl 0x4eb468
xor eax, eax
push eax
mov edx, 1
push 0x2710
push edx
lea ecx, [esp + 0x20]
push ecx
mov dword [esp + 0x24], edi
mov word [esp + 0x28], dx
mov word [esp + 0x2a], ax
call fcn.004c8940
add esp, 0x10
push 0
push 0
push edi
call dword [sym.imp.WS2_32.dll_accept]
mov dword [esi + 4], eax
cmp eax, 0xffffffff
je 0x4eb468
mov ecx, dword [esi]
lea edx, [esp + 0x10]
push edx
lea eax, [esp + 0x24]
push eax
push ecx
mov dword [esp + 0x1c], ebx
call ebp
cmp eax, 0xffffffff
je 0x4eb468
cmp dword [esp + 0x10], ebx
jl 0x4eb468
mov ecx, dword [esi + 4]
lea edx, [esp + 0x10]
push edx
lea eax, [esp + 0x34]
push eax
push ecx
mov dword [esp + 0x1c], ebx
call dword [sym.imp.WS2_32.dll_getpeername]
cmp eax, 0xffffffff
je 0x4eb468
cmp dword [esp + 0x10], ebx
jl 0x4eb468
mov dx, word [esp + 0x20]
cmp dx, word [esp + 0x30]
jne 0x4eb468
mov eax, dword [esp + 0x24]
cmp eax, dword [esp + 0x34]
jne 0x4eb468
mov cx, word [esp + 0x22]
cmp cx, word [esp + 0x32]
jne 0x4eb468
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
pop ebp
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [esp + 0x30]
xor ecx, esp
call fcn.00418878
add esp, 0x34
ret
push edi
mov edi, dword [sym.imp.WS2_32.dll_closesocket]
call edi
mov edx, dword [esi]
push edx
call edi
mov eax, dword [esi + 4]
push eax
call edi
mov ecx, dword [esp + 0x40]
pop ebp
pop edi
pop esi
pop ebx
xor ecx, esp
or eax, 0xffffffff
call fcn.00418878
add esp, 0x34
ret