Function at 0x4b3870
Capabilities:
Create tcp socket
Create udp socket
Get local ipv4 addresses
Get socket information
Start tcp server

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
mov esi, eax
push ebx
mov ebx, edx
sub esp, 0x4c
mov edi, dword [eax + 4]
mov eax, dword [edx + 4]
mov dword [ebp - 0x30], 0xfffeffff
mov dword [ebp - 0x3c], 1
test eax, eax
je 0x4b3a54
mov eax, dword [ebx + 8]
mov edx, dword [ebx + 0xc]
cmp eax, 0xffffffff
je 0x4b3ab0
mov ecx, edx
xor ecx, eax
cmp ecx, 0x12345678
jne 0x4b3ab0
mov eax, dword [ebp - 0x3c]
test eax, eax
je 0x4b3be7
mov dword [ebp - 0x2c], 0x10
mov dword [esp + 8], 0
mov dword [esp + 4], 1
mov dword [esp], 2
call dword [sym.imp.WS2_32.dll_socket]
sub esp, 0xc
cmp eax, 0xffffffff
mov dword [ebp - 0x40], eax
je 0x4b3a70
xor ecx, ecx
mov edx, 2
mov word [ebp - 0x28], dx
mov word [ebp - 0x26], cx
mov dword [esp], str.127.0.0.1
call dword [sym.imp.WS2_32.dll_inet_addr]
lea edx, [ebp - 0x28]
mov dword [ebp - 0x44], edx
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x40]
sub esp, 4
mov dword [esp + 4], edx
mov dword [esp + 8], 0x10
mov dword [esp], eax
call dword [sym.imp.WS2_32.dll_bind]
mov edx, dword [ebp - 0x44]
sub esp, 0xc
test eax, eax
js 0x4b3ae0
lea eax, [ebp - 0x2c]
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x40]
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [sym.imp.WS2_32.dll_getsockname]
sub esp, 0xc
test eax, eax
js 0x4b39f0
mov eax, dword [ebp - 0x40]
mov dword [esp + 4], 1
mov dword [esp], eax
call dword [sym.imp.WS2_32.dll_listen]
sub esp, 8
test eax, eax
js 0x4b3c20
movzx eax, word [ebp - 0x26]
add edi, 0x1c
mov dword [esp], esi
mov byte [esi + 0x1c], al
movzx eax, ah
mov byte [esi + 0x1d], al
call fcn.004b5cc0
mov eax, dword [ebx + 8]
mov ecx, edi
mov edx, esi
call fcn.004b2a40
test eax, eax
js 0x4b3b24
mov edi, 0xffffffff
mov eax, dword [ebp - 0x40]
mov dword [ebp - 0x2c], 0x10
call fcn.004b37c0
test eax, eax
mov dword [ebp - 0x30], eax
je 0x4b3b50
mov eax, dword [ebp - 0x3c]
test eax, eax
jne 0x4b3a2d
mov dword [esp], esi
call fcn.004ebfd0
mov eax, dword [ebp - 0x30]
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov ebx, dword [sym.imp.WS2_32.dll_WSAGetLastError]
call ebx
mov dword [esp], eax
call fcn.004b5a60
mov edi, eax
call ebx
mov dword [esp + 0x10], edi
mov dword [esp + 8], str.TCP_getsockname
mov dword [esp + 4], str.dnssd_clientstub_deliver_request:__s_failed__d___s_
mov dword [esp], 0x1388
mov dword [esp + 0xc], eax
call fcn.004b26f0
mov edi, 0xffffffff
mov eax, dword [ebp - 0x40]
cmp eax, 0xffffffff
je 0x4b3a41
mov dword [esp], eax
call dword [sym.imp.WS2_32.dll_closesocket]
sub esp, 4
cmp edi, 0xffffffff
je 0x4b39d7
mov dword [esp], edi
call dword [sym.imp.WS2_32.dll_closesocket]
sub esp, 4
jmp 0x4b39d7
mov eax, dword [esi + 0xc]
and eax, 0xfffffff7
sub eax, 2
cmp eax, 1
setbe al
movzx eax, al
mov dword [ebp - 0x3c], eax
jmp 0x4b3899
mov ebx, dword [sym.imp.WS2_32.dll_WSAGetLastError]
call ebx
mov dword [esp], eax
call fcn.004b5a60
mov edi, eax
call ebx
mov dword [esp + 0x10], edi
mov dword [esp + 8], str.TCP_socket
mov dword [esp + 4], str.dnssd_clientstub_deliver_request:__s_failed__d___s_
mov dword [esp], 0x1388
mov dword [esp + 0xc], eax
call fcn.004b26f0
jmp 0x4b3a28
mov dword [esp + 0xc], eax
mov dword [esp + 8], ebx
mov dword [esp + 0x10], edx
mov dword [esp + 4], str.dnssd_clientstub_deliver_request:_invalid_DNSServiceRef__p__08X__08X
mov dword [esp], 0x1388
call fcn.004b26f0
lea esp, [ebp - 0xc]
mov eax, 0xfffefffb
pop ebx
pop esi
pop edi
pop ebp
ret
mov ebx, dword [sym.imp.WS2_32.dll_WSAGetLastError]
call ebx
mov dword [esp], eax
call fcn.004b5a60
mov edi, eax
call ebx
mov dword [esp + 0x10], edi
mov dword [esp + 8], str.TCP_bind
mov dword [esp + 4], str.dnssd_clientstub_deliver_request:__s_failed__d___s_
mov dword [esp], 0x1388
mov dword [esp + 0xc], eax
call fcn.004b26f0
jmp 0x4b3a28
mov dword [ebp - 0x40], 0xffffffff
mov dword [esp + 0xc], edi
mov eax, dword [ebx + 8]
mov edi, 0xffffffff
mov dword [esp + 4], str.dnssd_clientstub_deliver_request_ERROR:_write_all__d___lu_bytes__failed
mov dword [esp], 0x3e8
mov dword [esp + 8], eax
call fcn.004b26f0
jmp 0x4b39d0
lea eax, [ebp - 0x2c]
mov dword [esp + 8], eax
lea eax, [ebp - 0x28]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x40]
mov dword [esp], eax
call dword [sym.imp.WS2_32.dll_accept]
sub esp, 0xc
cmp eax, 0xffffffff
mov edi, eax
je 0x4b3c70
mov eax, dword [ebp - 0x40]
mov dword [esp], eax
call dword [sym.imp.WS2_32.dll_closesocket]
sub esp, 4
cmp dword [ebx + 0x18], 0x10
jne 0x4b3ba0
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x40], 0xffffffff
jmp 0x4b39d0
mov eax, edi
call fcn.004b37c0
mov dword [ebp - 0x40], 0xffffffff
test eax, eax
mov dword [ebp - 0x30], eax
jne 0x4b39d0
mov ecx, 4
mov eax, edi
lea edx, [ebp - 0x30]
call fcn.004b2930
test eax, eax
js 0x4b3c60
mov eax, dword [ebp - 0x30]
mov dword [esp], eax
call dword [sym.imp.WS2_32.dll_ntohl]
sub esp, 4
mov dword [ebp - 0x30], eax
jmp 0x4b39d0
mov dword [esp], esi
add edi, 0x1c
call fcn.004b5cc0
mov eax, dword [ebx + 8]
mov ecx, edi
mov edx, esi
call fcn.004b2a40
test eax, eax
js 0x4b3b1d
cmp dword [ebx + 0x18], 0x10
mov edi, dword [ebx + 8]
jne 0x4b3ba0
mov dword [ebp - 0x40], 0xffffffff
jmp 0x4b39b6
mov ebx, dword [sym.imp.WS2_32.dll_WSAGetLastError]
call ebx
mov dword [esp], eax
call fcn.004b5a60
mov edi, eax
call ebx
mov dword [esp + 0x10], edi
mov dword [esp + 8], str.TCP_listen
mov dword [esp + 4], str.dnssd_clientstub_deliver_request:__s_failed__d___s_
mov dword [esp], 0x1388
mov dword [esp + 0xc], eax
call fcn.004b26f0
jmp 0x4b3a28
mov dword [ebp - 0x30], 0xfffeffe5
jmp 0x4b39d0
mov ebx, dword [sym.imp.WS2_32.dll_WSAGetLastError]
call ebx
mov dword [esp], eax
call fcn.004b5a60
mov dword [ebp - 0x44], eax
call ebx
mov edx, dword [ebp - 0x44]
mov dword [esp + 8], str.accept
mov dword [esp + 4], str.dnssd_clientstub_deliver_request:__s_failed__d___s_
mov dword [esp], 0x1388
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], eax
call fcn.004b26f0
jmp 0x4b39d0