Function at 0x537e10
Capabilities:
Get local ipv4 addresses
Get socket information

Disassembly:
mov r11, rsp
sub rsp, 0x298
mov rax, qword [0x005ca070]
mov qword [rsp + 0x250], rax
mov qword [r11 + 0x20], rbx
mov qword [r11 - 8], rbp
mov qword [r11 - 0x10], rsi
mov rsi, qword [rcx]
mov qword [r11 - 0x20], r12
mov qword [r11 - 0x28], r13
mov qword [r11 - 0x30], r14
mov qword [rsp + 0x40], rcx
xor r13d, r13d
mov qword [rsp + 0x38], r13
movzx ebx, word [rsi + 0x1a0]
mov ebp, dword [rsi + 0x1a4]
mov r12, qword [rsi + 0x3f8]
mov qword [r11 - 0x38], r15
mov r14d, r8d
mov r15, rdx
lea rcx, [r11 - 0x147]
mov r8d, 0xff
xor edx, edx
mov byte [r11 - 0x148], r13b
call sub.msvcrt.dll_memset
test r12, r12
jne 0x537e9b
test bx, bx
jne 0x537e9b
xor eax, eax
jmp 0x53815a
lea rcx, [rsp + 0x50]
xor edx, edx
mov r8d, 0x80
mov qword [rsp + 0x280], rdi
call sub.msvcrt.dll_memset
test r12, r12
je 0x538021
xor eax, eax
mov rcx, 0xffffffffffffffff
mov rdi, r12
repne scasb al, byte [rdi]
not rcx
dec rcx
cmp rcx, 0xff
jae 0x538021
lea r8, [rsp + 0x150]
mov r9d, 0x100
mov rdx, r12
mov ecx, r14d
call fcn.00556910
test rax, rax
je 0x537f21
lea r9, [rsp + 0x150]
lea rdx, str.Local_Interface__s_is_ip__s_using_address_family__i_n
mov r8, r12
mov rcx, rsi
mov dword [rsp + 0x20], r14d
call fcn.005373d0
jmp 0x537fd1
cmp r14d, 2
mov eax, dword [rsi + 0x360]
mov dword [rsp + 0x30], eax
jne 0x537f3b
mov dword [rsi + 0x360], 1
mov rdi, qword [rsp + 0x40]
lea r9, [rsp + 0x38]
xor r8d, r8d
mov rcx, rdi
mov rdx, r12
call fcn.0052c750
cmp eax, 1
jne 0x537f65
lea rdx, [rsp + 0x38]
mov rcx, rdi
call fcn.0053ab90
mov eax, dword [rsp + 0x30]
mov dword [rsi + 0x360], eax
mov rcx, qword [rsp + 0x38]
test rcx, rcx
je 0x53800a
mov rcx, qword [rcx]
lea rdx, [rsp + 0x150]
mov r8d, 0x100
call fcn.0052c490
mov rdx, qword [rsp + 0x38]
mov r9d, r14d
mov rax, qword [rdx]
lea rdx, str.Name__s_family__i_resolved_to__s_family__i_n
mov r8, r12
mov ecx, dword [rax + 4]
lea rax, [rsp + 0x150]
mov dword [rsp + 0x28], ecx
mov rcx, rsi
mov qword [rsp + 0x20], rax
call fcn.005373d0
mov rdx, qword [rsp + 0x38]
mov rcx, rsi
call fcn.0052c980
cmp r14d, 2
jne 0x538041
lea r8, [rsp + 0x54]
lea rdx, [rsp + 0x150]
mov ecx, r14d
call fcn.005568e0
test eax, eax
jle 0x538041
movzx ecx, bx
mov word [rsp + 0x50], r14w
call qword [sym.imp.WS2_32.dll_htons]
lea r13d, [r14 + 0xe]
mov word [rsp + 0x52], ax
jmp 0x538041
lea rdx, str.Couldnt_bind_to__s
mov r8, r12
mov rcx, rsi
call fcn.005374d0
jmp 0x53814d
cmp r14d, 2
jne 0x538041
movzx ecx, bx
mov word [rsp + 0x50], r14w
call qword [sym.imp.WS2_32.dll_htons]
mov r13d, reloc.WS2_32.dll_recv
mov word [rsp + 0x52], ax
lea rdx, [rsp + 0x50]
mov r8d, r13d
mov rcx, r15
call qword [sym.imp.WS2_32.dll_bind]
test eax, eax
jns 0x5380a1
dec ebp
test ebp, ebp
jle 0x53811e
lea rdx, str.Bind_to_local_port__hu_failed__trying_next_n
movzx r8d, bx
mov rcx, rsi
call fcn.005373d0
inc bx
cmp word [rsp + 0x50], 2
jne 0x53808c
movzx ecx, bx
call qword [sym.imp.WS2_32.dll_ntohs]
mov word [rsp + 0x52], ax
lea rdx, [rsp + 0x50]
mov r8d, r13d
mov rcx, r15
call qword [sym.imp.WS2_32.dll_bind]
test eax, eax
js 0x538056
lea rcx, [rsp + 0xd0]
xor edx, edx
mov r8d, 0x80
mov dword [rsp + 0x30], 0x80
call sub.msvcrt.dll_memset
lea r8, [rsp + 0x30]
lea rdx, [rsp + 0xd0]
mov rcx, r15
call qword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jns 0x5380fb
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov rcx, qword [rsp + 0x40]
mov edx, eax
mov edi, eax
mov dword [rsi + 0x86cc], eax
call fcn.0052a9d0
lea rdx, str.getsockname___failed_with_errno__d:__s
jmp 0x53813f
lea rdx, str.Local_port:__hu_n
movzx r8d, bx
mov rcx, rsi
call fcn.005373d0
mov rcx, qword [rsp + 0x40]
xor eax, eax
mov byte [rcx + 0x1b7], 1
jmp 0x538152
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov rcx, qword [rsp + 0x40]
mov edx, eax
mov edi, eax
mov dword [rsi + 0x86cc], eax
call fcn.0052a9d0
lea rdx, str.bind_failed_with_errno__d:__s
mov r9, rax
mov r8d, edi
mov rcx, rsi
call fcn.005374d0
mov eax, 0x2d
mov rdi, qword [rsp + 0x280]
mov r15, qword [rsp + 0x260]
mov r14, qword [rsp + 0x268]
mov r13, qword [rsp + 0x270]
mov r12, qword [rsp + 0x278]
mov rsi, qword [rsp + 0x288]
mov rbp, qword [rsp + 0x290]
mov rbx, qword [rsp + 0x2b8]
mov rcx, qword [rsp + 0x250]
call fcn.0055e990
add rsp, 0x298
ret