Function at 0x4096a0
Capabilities:
Connect socket
Connect udp socket
Create udp socket
Get local ipv4 addresses
Get socket information

Disassembly:
sub esp, 0x34
mov eax, dword [0x698b9c]
xor eax, esp
mov dword [esp + 0x2c], eax
push ebx
mov ebx, dword [esp + 0x3c]
push ebp
mov ebp, dword [esp + 0x44]
push esi
push edi
push 0
push ebx
or edi, 0xffffffff
push 2
mov dword [esp + 0x24], edi
call sub.WS2_32.dll_socket
mov esi, eax
test esi, esi
jge 0x409709
cmp dword [0x69aaa4], 3
jg 0x4096f3
push str.Cant_create_listening_socket
push 0x283
push str....._base_srcwin32TSocket.c
push 3
call fcn.00401310
add esp, 0x10
or eax, 0xffffffff
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x2c]
xor ecx, esp
call fcn.005bfcb8
add esp, 0x34
ret
xor eax, eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], eax
mov eax, 2
push 0x7f000001
mov word [esp + 0x20], ax
call sub.WS2_32.dll_htonl
push 0x10
lea edx, [esp + 0x20]
push edx
xor ecx, ecx
push esi
mov dword [esp + 0x2c], eax
mov word [esp + 0x2a], cx
call sub.WS2_32.dll_bind
cmp eax, 0xffffffff
jne 0x409768
cmp dword [0x69aaa4], 3
jg 0x409895
push str.Cant_bind_address_lookback
push 0x28e
jmp 0x409886
push 1
push esi
call sub.WS2_32.dll_listen
cmp eax, 0xffffffff
jne 0x409791
cmp dword [0x69aaa4], 3
jg 0x409895
push str.Cant_listen_on_socket
push 0x294
jmp 0x409886
push 0
push ebx
push 2
call sub.WS2_32.dll_socket
mov edi, eax
test edi, edi
jge 0x4097bd
cmp dword [0x69aaa4], 3
jg 0x409895
push str.Cant_create_connect_socket
push 0x29b
jmp 0x409886
lea eax, [esp + 0x14]
push eax
lea ecx, [esp + 0x30]
push ecx
mov ebx, 0x10
push esi
mov dword [esp + 0x20], ebx
call sub.WS2_32.dll_getsockname
cmp eax, 0xffffffff
jne 0x4097f7
cmp dword [0x69aaa4], 3
jg 0x409895
push str.Cant_get_socket_name
push 0x2a2
jmp 0x409886
cmp dword [esp + 0x14], ebx
je 0x409816
cmp dword [0x69aaa4], 3
jg 0x409895
push str.socket_address_size_is_unexpect
push 0x2a7
jmp 0x409886
push ebx
lea edx, [esp + 0x30]
push edx
push edi
call sub.WS2_32.dll_connect
cmp eax, 0xffffffff
jne 0x40983c
cmp dword [0x69aaa4], 3
jg 0x409895
push str.Cant_connect_to_listener_socket
push 0x2ad
jmp 0x409886
lea eax, [esp + 0x14]
push eax
lea ecx, [esp + 0x20]
push ecx
push esi
mov dword [esp + 0x20], ebx
call sub.WS2_32.dll_accept
mov dword [esp + 0x18], eax
test eax, eax
jge 0x40986d
cmp dword [0x69aaa4], 3
jg 0x409895
push str.Cant_accept_socket
push 0x2b5
jmp 0x409886
cmp dword [esp + 0x14], ebx
je 0x4098d0
cmp dword [0x69aaa4], 3
jg 0x409895
push str.socket_address_size_is_unexpected._2
push 0x2ba
push str....._base_srcwin32TSocket.c
push 3
call fcn.00401310
add esp, 0x10
cmp esi, 0xffffffff
je 0x4098a0
push esi
call sub.WS2_32.dll_closesocket
cmp edi, 0xffffffff
je 0x4098ab
push edi
call sub.WS2_32.dll_closesocket
mov eax, dword [esp + 0x18]
cmp eax, 0xffffffff
je 0x4098ba
push eax
call sub.WS2_32.dll_closesocket
or eax, 0xffffffff
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x2c]
xor ecx, esp
call fcn.005bfcb8
add esp, 0x34
ret
push esi
call sub.WS2_32.dll_closesocket
mov edx, dword [esp + 0x18]
mov ecx, dword [esp + 0x3c]
mov dword [ebp], edi
pop edi
pop esi
mov dword [ebp + 4], edx
pop ebp
pop ebx
xor ecx, esp
xor eax, eax
call fcn.005bfcb8
add esp, 0x34
ret