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

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x258
mov rsi, qword [rcx + 0x728]
mov r12d, dword [rcx + 0x228]
mov r13, rdx
xor edx, edx
test rsi, rsi
mov qword [rsp + 0x2b0], r8
sete r14b
test r12w, r12w
mov qword [rsp + 0x48], rdx
mov rbx, rcx
sete al
mov ebp, r9d
xor r15d, r15d
and r14b, al
jne 0x1403c07c8
mov ax, word [rcx + 0x22a]
mov ecx, 0x20
mov word [rsp + 0x3e], ax
lea rax, [rsp + 0x50]
mov rdi, rax
mov qword [rsp + 0x30], rax
mov eax, r15d
rep stosd dword [rdi], eax
test rsi, rsi
je 0x1403c065d
mov rcx, rsi
call sub.msvcrt.dll_strlen
cmp rax, 0xfe
ja 0x1403c065d
xor eax, eax
mov ecx, 0x3c
mov r8d, 3
mov rdx, rsi
mov qword [rsp + 0x150], rax
lea rdi, [rsp + 0x160]
mov qword [rsp + 0x158], rax
mov eax, r15d
rep stosd dword [rdi], eax
lea rcx, [0x140613ca1]
call sub.msvcrt.dll_strncmp
test eax, eax
jne 0x1403c0449
add rsi, 3
mov r14b, 1
jmp 0x1403c0468
mov r8d, 5
mov rdx, rsi
lea rcx, str.host_
call sub.msvcrt.dll_strncmp
test eax, eax
jne 0x1403c0468
add rsi, 5
jmp 0x1403c04e2
lea rdi, [rsp + 0x150]
mov dword [rsp + 0x28], 0x100
mov r9, rsi
mov ecx, ebp
mov qword [rsp + 0x20], rdi
mov edx, dword [rsp + 0x2c0]
mov r8d, dword [r13 + 0x500]
call fcn.14032bf20
cmp eax, 1
je 0x1403c059f
cmp eax, 2
je 0x1403c04bb
test eax, eax
jne 0x1403c04d9
mov r8, rsi
lea rdx, str.Couldnt_bind_to_interface__s
test r14b, r14b
je 0x1403c04e2
jmp 0x1403c05bb
mov dword [rsp + 0x20], ebp
mov r9, rdi
mov r8, rsi
mov rcx, rbx
lea rdx, str.Local_Interface__s_is_ip__s_using_address_family__i
call fcn.14032c350
jmp 0x1403c05c8
test r14b, r14b
jne 0x1403c05aa
mov dil, byte [r13 + 0x50c]
cmp ebp, 2
jne 0x1403c04f8
mov byte [r13 + 0x50c], 1
jmp 0x1403c0505
cmp ebp, 0x17
jne 0x1403c0505
mov byte [r13 + 0x50c], 2
lea r14, [rsp + 0x48]
xor r9d, r9d
mov rdx, rsi
mov rcx, rbx
mov qword [rsp + 0x20], r14
mov r8d, 0x50
call fcn.140332b50
dec eax
jne 0x1403c0532
mov rdx, r14
mov rcx, rbx
call fcn.140333630
mov rax, qword [rsp + 0x48]
mov byte [r13 + 0x50c], dil
test rax, rax
je 0x1403c05aa
mov rcx, qword [rax]
lea rdi, [rsp + 0x150]
mov r8d, 0x100
mov rdx, rdi
call fcn.140331640
mov rax, qword [rsp + 0x48]
mov r9d, ebp
mov r8, rsi
lea rdx, str.Name__s_family__i_resolved_to__s_family__i
mov rcx, rbx
mov rax, qword [rax]
mov eax, dword [rax + 4]
mov qword [rsp + 0x20], rdi
mov dword [rsp + 0x28], eax
call fcn.14032c350
mov rdx, qword [rsp + 0x48]
mov rcx, rbx
call fcn.140333090
mov rax, qword [rsp + 0x48]
mov rax, qword [rax]
cmp dword [rax + 4], ebp
je 0x1403c05c8
mov r15d, 1
jmp 0x1403c07c8
and byte [rbx + 0x12bc], 0xf7
mov r8, rsi
lea rdx, str.Couldnt_bind_to__s
mov rcx, rbx
call fcn.140324010
jmp 0x1403c07c2
cmp ebp, 0x17
jne 0x1403c0637
lea rdi, [rsp + 0x150]
mov edx, 0x25
mov rcx, rdi
call sub.msvcrt.dll_strchr
mov rsi, rax
test rax, rax
je 0x1403c05f0
mov byte [rax], 0
inc rsi
lea r8, [rsp + 0x58]
mov rdx, rdi
mov ecx, 0x17
call fcn.14032c180
test eax, eax
jle 0x1403c0678
mov word [rsp + 0x50], 0x17
movzx ecx, r12w
call qword [sym.imp.ws2_32.dll_htons]
mov word [rsp + 0x52], ax
test rsi, rsi
je 0x1403c0678
mov r8d, 0xa
xor edx, edx
mov rcx, rsi
call sub.msvcrt.dll_strtoul
mov dword [rsp + 0x68], eax
jmp 0x1403c0678
cmp ebp, 2
je 0x1403c0640
xor esi, esi
jmp 0x1403c06a1
lea rdx, [rsp + 0x150]
lea r8, [rsp + 0x54]
mov ecx, 2
call fcn.14032c180
test eax, eax
jle 0x1403c063c
jmp 0x1403c0686
cmp ebp, 0x17
jne 0x1403c067f
mov word [rsp + 0x50], 0x17
movzx ecx, r12w
call qword [sym.imp.ws2_32.dll_htons]
mov word [rsp + 0x52], ax
mov esi, 0x1c
jmp 0x1403c06a1
xor esi, esi
cmp ebp, 2
jne 0x1403c06a1
mov word [rsp + 0x50], 2
movzx ecx, r12w
mov esi, 0x10
call qword [sym.imp.ws2_32.dll_htons]
mov word [rsp + 0x52], ax
movzx r15d, word [rsp + 0x3e]
mov rbp, qword [sym.imp.ws2_32.dll_bind]
lea r14, str.Bind_to_local_port__d_failed__trying_next
mov rdx, qword [rsp + 0x30]
mov rcx, qword [rsp + 0x2b0]
mov r8d, esi
call rbp
test eax, eax
js 0x1403c0757
lea rdx, [rsp + 0xd0]
xor eax, eax
mov ecx, 0x20
mov dword [rsp + 0x44], pe_nt_image_headers64
mov rdi, rdx
lea r8, [rsp + 0x44]
rep stosd dword [rdi], eax
mov rcx, qword [rsp + 0x2b0]
call qword [sym.imp.ws2_32.dll_getsockname]
test eax, eax
jns 0x1403c0737
call qword [sym.imp.ws2_32.dll_WSAGetLastError]
lea rdx, [rsp + 0x150]
mov r8d, 0x100
mov dword [rbx + 0xce4], eax
mov ecx, eax
mov esi, eax
call fcn.140335b60
mov r8d, esi
lea rdx, str.getsockname___failed_with_errno__d:__s
mov r9, rax
jmp 0x1403c07ba
movzx r8d, r12w
lea rdx, str.Local_port:__hu
mov rcx, rbx
xor r15d, r15d
call fcn.14032c350
or byte [r13 + 0x2ca], 4
jmp 0x1403c07c8
dec r15d
test r15d, r15d
jle 0x1403c078a
inc r12w
je 0x1403c078a
movzx edi, r12w
mov rdx, r14
mov rcx, rbx
lea r8d, [rdi - 1]
call fcn.14032c350
mov ecx, edi
call qword [sym.imp.ws2_32.dll_ntohs]
mov word [rsp + 0x52], ax
jmp 0x1403c06b5
call qword [sym.imp.ws2_32.dll_WSAGetLastError]
lea rdx, [rsp + 0x150]
mov r8d, 0x100
mov dword [rbx + 0xce4], eax
mov ecx, eax
mov esi, eax
call fcn.140335b60
mov r8d, esi
lea rdx, str.bind_failed_with_errno__d:__s
mov r9, rax
mov rcx, rbx
call fcn.140324010
mov r15d, 0x2d
mov eax, r15d
add rsp, 0x258
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret