Function at 0x1400057f0
Capabilities:
Get local ipv4 addresses
Get socket information
Set socket configuration

Disassembly:
push rbx
push rsi
push r14
push r15
sub rsp, 0x58
mov rax, qword [0x140113480]
xor rax, rsp
mov qword [rsp + 0x48], rax
mov rsi, rcx
mov r15, r8
mov ecx, 0x2b18
mov r14, rdx
call qword [sub.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov rbx, rax
test rax, rax
jne 0x140005833
call qword [0x140113538]
xor eax, eax
jmp 0x140005bce
mov qword [rsp + 0x90], rbp
xor edx, edx
mov r8d, 0x2b18
mov qword [rsp + 0x98], rdi
mov rcx, rbx
call sub.VCRUNTIME140.dll_memset
imul rbp, r14, 0x1d8
mov rcx, rbp
call qword [sub.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov rdi, rax
test rax, rax
jne 0x140005885
call qword [0x140113538]
mov rcx, rbx
mov qword [rbx + 0x28], rdi
call qword [fcn.1400d23da]
xor eax, eax
jmp 0x140005bbe
mov r8, rbp
mov qword [rsp + 0x50], r12
xor edx, edx
mov qword [rbx + 0x28], rdi
mov rcx, rdi
call sub.VCRUNTIME140.dll_memset
mov r12d, 2
xor r8d, r8d
mov edx, r12d
mov ecx, r12d
call qword [sym.imp.WS2_32.dll_socket]
mov qword [rbx], rax
mov rdi, rax
cmp rax, 0xffffffffffffffff
je 0x140005b95
xor ebp, ebp
test rsi, rsi
je 0x140005904
movzx ecx, word [rsi + 4]
mov qword [rsp + 0x40], rbp
mov word [rsp + 0x38], r12w
call qword [sym.imp.WS2_32.dll_htons]
mov word [rsp + 0x3a], ax
mov r8d, reloc.WS2_32.dll_recv
mov eax, dword [rsi]
lea rdx, [rsp + 0x38]
mov rcx, rdi
mov dword [rsp + 0x3c], eax
call qword [sym.imp.WS2_32.dll_bind]
cmp eax, 0xffffffff
je 0x140005b95
mov rcx, qword [rbx]
lea r8, [rsp + 0x30]
mov edi, 1
mov edx, 0x8004667e
mov dword [rsp + 0x30], edi
call qword [sym.imp.WS2_32.dll_ioctlsocket]
mov rcx, qword [rbx]
lea r9, [rsp + 0x30]
mov edx, 0xffff
mov dword [rsp + 0x30], edi
mov r8d, reloc.WLDAP32.dll_Ordinal_32
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
mov rcx, qword [rbx]
lea r9, [rsp + 0x30]
mov edx, 0xffff
mov dword [rsp + 0x30], 0x40000
mov r8d, 0x1002
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
mov rcx, qword [rbx]
lea r9, [rsp + 0x30]
mov edx, 0xffff
mov dword [rsp + 0x30], 0x40000
mov r8d, 0x1001
mov dword [rsp + 0x20], 4
call qword [sym.imp.WS2_32.dll_setsockopt]
test rsi, rsi
je 0x1400059db
mov rcx, qword [rbx]
lea r8, [rsp + 0x30]
lea rdx, [rsp + 0x38]
mov dword [rsp + 0x30], reloc.WS2_32.dll_recv
call qword [sym.imp.WS2_32.dll_getsockname]
cmp eax, 0xffffffff
je 0x1400059d4
mov eax, dword [rsp + 0x3c]
movzx ecx, word [rsp + 0x3a]
mov dword [rbx + 8], eax
call qword [sym.imp.WS2_32.dll_ntohs]
mov word [rbx + 0xc], ax
jmp 0x1400059db
mov rax, qword [rsi]
mov qword [rbx + 8], rax
mov dword [rbx + 0x20], ebx
call qword [sym.imp.WINMM.dll_timeGetTime]
mov edx, dword [rbx + 0x20]
add edx, eax
mov qword [rbx + 0x30], r14
ror edx, 0x10
lea rax, [rbx + 0x48]
cmp r15, rdi
mov qword [rax], rax
mov qword [rax + 8], rax
cmovae rdi, r15
mov dword [rbx + 0x20], edx
imul rax, qword [rbx + 0x30], 0x1d8
mov qword [rbx + 0x38], rdi
mov rdi, qword [rbx + 0x28]
add rax, rdi
mov qword [rbx + 0x10], rbp
mov dword [rbx + 0x18], ebp
mov dword [rbx + 0x24], ebp
mov dword [rbx + 0x1c], 0x578
mov qword [rbx + 0x670], rbp
mov qword [rbx + 0xa88], rbp
mov qword [rbx + 0xa90], rbp
mov dword [rbx + 0x2ab8], ebp
mov word [rbx + 0x2abc], bp
mov qword [rbx + 0x2ac0], rbp
mov qword [rbx + 0x2ac8], rbp
mov qword [rbx + 0x2ad0], rbp
mov qword [rbx + 0x2ad8], rbp
mov qword [rbx + 0x2ae8], rbp
mov qword [rbx + 0x2af0], rbp
mov qword [rbx + 0x2af8], 0xfff
mov qword [rbx + 0x2b00], 0x2000000
mov qword [rbx + 0x2b08], 0x2000000
mov qword [rbx + 0xa98], rbp
mov qword [rbx + 0xaa0], rbp
mov qword [rbx + 0xaa8], rbp
mov qword [rbx + 0xab0], rbp
mov qword [rbx + 0x2ae0], rbp
cmp rdi, rax
jae 0x140005b90
add rdi, 0xf8
movabs rsi, 0x8ad8f2fba9386823
nop dword [rax]
nop word [rax + rax]
mov qword [rdi - 0xe8], rbx
lea rcx, [rdi - 0xf8]
sub rcx, qword [rbx + 0x28]
mov rax, rsi
imul rcx
mov word [rdi - 0xd8], 0xffff
add rdx, rcx
mov qword [rdi - 0xc8], rbp
sar rdx, 8
lea rcx, [rdi - 0xf8]
mov rax, rdx
shr rax, 0x3f
add rdx, rax
lea rax, [rdi - 0x18]
mov qword [rax], rax
mov qword [rdi - 0x10], rax
lea rax, [rdi - 8]
mov qword [rax], rax
mov qword [rdi], rax
lea rax, [rdi + 8]
mov qword [rax], rax
mov qword [rdi + 0x10], rax
lea rax, [rdi + 0x18]
mov qword [rax], rax
mov qword [rdi + 0x20], rax
lea rax, [rdi + 0x28]
mov qword [rax], rax
mov qword [rdi + 0x30], rax
lea rax, [rdi + 0x38]
mov qword [rax], rax
mov qword [rdi + 0x40], rax
mov word [rdi - 0xde], dx
call fcn.140006a30
imul rcx, qword [rbx + 0x30], 0x1d8
lea rdi, [rdi + 0x1d8]
add rcx, qword [rbx + 0x28]
lea rax, [rdi - 0xf8]
cmp rax, rcx
jb 0x140005ae0
mov rax, rbx
jmp 0x140005bb9
mov rcx, qword [rbx]
cmp rcx, 0xffffffffffffffff
je 0x140005ba4
call qword [sym.imp.WS2_32.dll_closesocket]
mov rcx, qword [rbx + 0x28]
call qword [fcn.1400d23da]
mov rcx, rbx
call qword [fcn.1400d23da]
xor eax, eax
mov r12, qword [rsp + 0x50]
mov rbp, qword [rsp + 0x90]
mov rdi, qword [rsp + 0x98]
mov rcx, qword [rsp + 0x48]
xor rcx, rsp
call fcn.1400d0f00
add rsp, 0x58
pop r15
pop r14
pop rsi
pop rbx
ret