Function at 0x1400111d0
Capabilities:
Get local ipv4 addresses
Get socket information
Resolve dns
Set socket configuration

Disassembly:
push rbp
push rbx
push rdi
lea rbp, [rsp - 0x47]
sub rsp, 0xc0
mov rax, qword [0x1400d1608]
xor rax, rsp
mov qword [rbp + 0x3f], rax
mov rdi, rcx
mov rcx, qword [rcx]
mov rbx, rdx
lea r8, [rbp - 0x31]
lea rdx, [rbp - 0x11]
mov dword [rbp - 0x31], reloc.WS2_32.dll_recv
mov dword [rbp - 0x2d], 1
call qword [sym.imp.WS2_32.dll_accept]
mov qword [rbp - 0x29], rax
cmp rax, 0xffffffffffffffff
je 0x140011453
mov ecx, dword [rbp - 0xd]
call qword [sym.imp.WS2_32.dll_ntohl]
mov rcx, rbx
mov edx, eax
call fcn.1400101e0
test eax, eax
jne 0x1400112ac
cmp word [rbp - 0x11], 2
mov byte [rbp + 7], al
jne 0x14001126a
xor eax, eax
mov dword [rsp + 0x30], 2
lea r8, [rbp + 7]
mov dword [rsp + 0x28], eax
lea r9d, [rax + 0x32]
lea edx, [rax + 0x10]
lea rcx, [rbp - 0x11]
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_getnameinfo]
lea rax, [rbx + 0xf0]
lea r9, [rbp + 7]
lea r8, str.accept_new_connection
lea rdx, str._s:__s_is_not_allowed_to_connect
lea rcx, [0x140233740]
mov qword [0x140234008], rbx
mov qword [0x140234010], rax
call fcn.14000e440
mov rcx, qword [rbp - 0x29]
call qword [sym.imp.WS2_32.dll_closesocket]
jmp 0x140011453
mov rcx, qword [rbp - 0x29]
xor r8d, r8d
mov qword [rsp + 0xf0], rsi
mov qword [rsp + 0xf8], r12
lea r12, [rbx + 0xf0]
lea edx, [r8 + 1]
mov qword [0x140234008], rbx
mov qword [0x140234010], r12
call qword [sym.imp.KERNEL32.dll_SetHandleInformation]
movzx edx, byte [rdi + 0x28]
movzx eax, byte [rdi + 0x29]
mov rcx, qword [rbp - 0x29]
mov byte [rbp - 1], dl
lea r8, [rbp - 0x31]
lea rdx, [rbp - 0x21]
mov byte [rbp], al
call qword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x14001133e
mov qword [0x140234008], rbx
mov qword [0x140234010], r12
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
call fcn.140073314
lea r8, str.accept_new_connection
lea rdx, str._s:_getsockname___failed:__s
lea rcx, [0x140233740]
mov r9, rax
call fcn.14000e440
mov rcx, qword [rbp - 0x29]
lea r9, [rbp - 0x2d]
mov edx, 0xffff
mov r8d, 8
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
je 0x14001139b
mov qword [0x140234008], rbx
mov qword [0x140234010], r12
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
call fcn.140073314
lea r8, str.accept_new_connection
lea rdx, str._s:_setsockopt_SOL_SOCKET_SO_KEEPALIVE__failed:__s
lea rcx, [0x140233740]
mov r9, rax
call fcn.14000e440
mov rsi, qword [rbx + 0x110]
test rsi, rsi
je 0x140011419
lea rdi, [0x1400a35e4]
mov ecx, 2
repe cmpsb byte [rsi], byte [rdi]
jne 0x140011419
mov rcx, qword [rbp - 0x29]
mov edx, 6
lea r9, [rbp - 0x39]
lea r8d, [rdx - 5]
mov dword [rbp - 0x39], 1
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
test eax, eax
je 0x140011419
mov qword [0x140234008], rbx
mov qword [0x140234010], r12
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
call fcn.140073314
lea r8, str.accept_new_connection
lea rdx, str._s:_setsockopt_IPPROTO_TCP_TCP_NODELAY__failed:__s
lea rcx, [0x140233740]
mov r9, rax
call fcn.14000e440
mov rcx, qword [rbp - 0x29]
lea r8, [rbp - 0x39]
mov edx, 0x8004667e
mov dword [rbp - 0x39], 1
call qword [sym.imp.WS2_32.dll_ioctlsocket]
lea rdx, [rbp - 0x29]
mov rcx, rbx
mov byte [rbp + 1], 0
call fcn.14000dd70
mov r12, qword [rsp + 0xf8]
mov rsi, qword [rsp + 0xf0]
mov rcx, qword [rbp + 0x3f]
xor rcx, rsp
call fcn.14006f1f0
add rsp, 0xc0
pop rdi
pop rbx
pop rbp
ret