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

Disassembly:
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x160]
sub rsp, 0x260
mov rax, qword [0x140177090]
xor rax, rsp
mov qword [rbp + 0x150], rax
mov r15, qword [rcx]
movzx eax, byte [0x1401d1f77]
mov qword [rsp + 0x30], rcx
movzx edi, word [r15 + 0x288]
mov r14d, dword [r15 + 0x28c]
mov rsi, qword [r15 + 0x578]
mov r13d, r8d
mov qword [rsp + 0x40], rdx
lea rcx, [rbp + 0x51]
xor r12d, r12d
xor edx, edx
mov r8d, 0xff
mov byte [rbp + 0x50], al
mov qword [rsp + 0x38], r12
call sub.MSVCR120.dll_memset
test rsi, rsi
jne 0x14004faf6
test di, di
jne 0x14004faf6
xor eax, eax
jmp 0x14004fece
lea rcx, [rsp + 0x50]
xor edx, edx
mov r8d, 0x80
mov qword [rsp + 0x2b8], rbx
call sub.MSVCR120.dll_memset
test rsi, rsi
je 0x14004fd6c
or rbx, 0xffffffffffffffff
mov rax, rbx
inc rax
cmp byte [rsi + rax], r12b
jne 0x14004fb20
cmp rax, 0xff
jae 0x14004fd6c
lea r12, [0x140177c64]
mov r8, rbx
nop
inc r8
cmp byte [r12 + r8], 0
jne 0x14004fb40
mov rdx, rsi
mov rcx, r12
call qword [sym.imp.MSVCR120.dll_strncmp]
test eax, eax
jne 0x14004fb89
nop word [rax + rax]
cmp byte [r12 + rbx + 1], 0
lea rbx, [rbx + 1]
jne 0x14004fb60
lea r8, [rbx + rsi]
lea rdx, str.Couldnt_bind_to_interface__s
mov rcx, r15
call fcn.140052c80
mov eax, 0x2d
jmp 0x14004fec6
lea r12, str.host_
mov r8, rbx
inc r8
cmp byte [r12 + r8], 0
jne 0x14004fb93
mov rdx, rsi
mov rcx, r12
call qword [sym.imp.MSVCR120.dll_strncmp]
test eax, eax
jne 0x14004fbbd
nop dword [rax]
inc rbx
cmp byte [r12 + rbx], 0
jne 0x14004fbb0
add rsi, rbx
mov rax, qword [rsp + 0x30]
mov ebx, 2
mov r12d, dword [rax + 0x330]
cmp r13d, ebx
jne 0x14004fbdf
mov dword [rax + 0x330], 1
jmp 0x14004fbeb
cmp r13d, 0x17
jne 0x14004fbeb
mov dword [rax + 0x330], ebx
lea r9, [rsp + 0x38]
xor r8d, r8d
mov rdx, rsi
mov rcx, rax
call fcn.1400515a0
cmp eax, 1
jne 0x14004fc12
mov rcx, qword [rsp + 0x30]
lea rdx, [rsp + 0x38]
call fcn.140051fa0
mov rax, qword [rsp + 0x30]
mov dword [rax + 0x330], r12d
mov r12, qword [rsp + 0x38]
test r12, r12
je 0x14004fd50
mov rcx, qword [r12]
mov eax, dword [rcx + 4]
cmp eax, ebx
je 0x14004fc46
cmp eax, 0x17
jne 0x14004fc84
mov rcx, qword [rcx + 0x20]
add rcx, 8
jmp 0x14004fc4e
mov rcx, qword [rcx + 0x20]
add rcx, 4
cmp eax, ebx
je 0x14004fc75
cmp eax, 0x17
je 0x14004fc64
mov ecx, 0x273f
call qword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x14004fc84
lea rdx, [rbp + 0x50]
mov r8d, 0x100
call fcn.140064350
jmp 0x14004fc84
lea rdx, [rbp + 0x50]
mov r8d, 0x100
call fcn.140064280
mov rax, qword [r12]
lea rdx, str.Name__s_family__i_resolved_to__s_family__i_n
mov r9d, r13d
mov ecx, dword [rax + 4]
lea rax, [rbp + 0x50]
mov r8, rsi
mov dword [rsp + 0x28], ecx
mov rcx, r15
mov qword [rsp + 0x20], rax
call fcn.140052ba0
mov rdx, r12
mov rcx, r15
call fcn.140051760
cmp r13d, 0x17
jne 0x14004fd1e
lea edx, [r13 + 0xe]
lea rcx, [rbp + 0x50]
call qword [sym.imp.MSVCR120.dll_strchr]
mov rbx, rax
test rax, rax
je 0x14004fcda
mov byte [rax], 0
inc rbx
lea rdx, [rsp + 0x58]
lea rcx, [rbp + 0x50]
call fcn.140064050
test eax, eax
jle 0x14004fd16
mov eax, reloc.WS2_32.dll_socket
movzx ecx, di
mov word [rsp + 0x50], ax
call qword [sym.imp.WS2_32.dll_htons]
mov word [rsp + 0x52], ax
test rbx, rbx
je 0x14004fd16
mov rcx, rbx
call qword [sym.imp.MSVCR120.dll_atoi]
mov dword [rsp + 0x68], eax
mov r12d, 0x1c
jmp 0x14004fd9c
cmp r13d, ebx
jne 0x14004fd99
lea rdx, [rsp + 0x54]
lea rcx, [rbp + 0x50]
call fcn.140063f70
test eax, eax
jle 0x14004fd99
movzx ecx, di
mov word [rsp + 0x50], bx
call qword [sym.imp.WS2_32.dll_htons]
mov r12d, reloc.WS2_32.dll_recv
mov word [rsp + 0x52], ax
jmp 0x14004fd9c
lea rdx, str.Couldnt_bind_to__s
mov r8, rsi
mov rcx, r15
call fcn.140052c80
mov eax, 0x2d
jmp 0x14004fec6
cmp r13d, 0x17
jne 0x14004fd8e
mov eax, r13d
movzx ecx, di
mov word [rsp + 0x50], ax
call qword [sym.imp.WS2_32.dll_htons]
lea r12d, [r13 + 5]
mov word [rsp + 0x52], ax
jmp 0x14004fd9c
cmp r13d, 2
jne 0x14004fd9c
mov ebx, r13d
jmp 0x14004fd35
xor r12d, r12d
mov rbx, qword [rsp + 0x40]
lea rdx, [rsp + 0x50]
mov r8d, r12d
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_bind]
test eax, eax
jns 0x14004fe05
nop word [rax + rax]
dec r14d
test r14d, r14d
jle 0x14004fe6b
lea rdx, str.Bind_to_local_port__hu_failed__trying_next_n
movzx r8d, di
mov rcx, r15
call fcn.140052ba0
inc di
movzx ecx, di
call qword [sym.imp.WS2_32.dll_ntohs]
lea rdx, [rsp + 0x50]
mov r8d, r12d
mov rcx, rbx
mov word [rsp + 0x52], ax
call qword [sym.imp.WS2_32.dll_bind]
test eax, eax
js 0x14004fdc0
lea rcx, [rbp - 0x30]
xor edx, edx
mov r8d, 0x80
mov dword [rsp + 0x38], 0x80
call sub.MSVCR120.dll_memset
lea r8, [rsp + 0x38]
lea rdx, [rbp - 0x30]
mov rcx, rbx
call qword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jns 0x14004fea2
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov rcx, qword [rsp + 0x30]
mov edx, eax
mov ebx, eax
mov dword [r15 + 0x88d4], eax
call fcn.1400649c0
lea rdx, [0x140178490]
mov r8d, ebx
mov r9, rax
mov rcx, r15
call fcn.140052c80
mov eax, 0x2d
jmp 0x14004fec6
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov rcx, qword [rsp + 0x30]
mov edx, eax
mov ebx, eax
mov dword [r15 + 0x88d4], eax
call fcn.1400649c0
lea rdx, str.bind_failed_with_errno__d:__s
mov r8d, ebx
mov r9, rax
mov rcx, r15
call fcn.140052c80
mov eax, 0x2d
jmp 0x14004fec6
lea rdx, str.Local_port:__hu_n
movzx r8d, di
mov rcx, r15
call fcn.140052ba0
mov rax, qword [rsp + 0x30]
mov dword [rax + 0x304], 1
xor eax, eax
mov rbx, qword [rsp + 0x2b8]
mov rcx, qword [rbp + 0x150]
xor rcx, rsp
call fcn.140129b50
add rsp, 0x260
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret