Function at 0x14001f860
Capabilities:
Resolve dns

Disassembly:
push rbp
push rsi
push rdi
push r12
push r14
push r15
lea rbp, [rsp - 0x3f8]
sub rsp, 0x4f8
mov rax, qword [0x1400e6470]
xor rax, rsp
mov qword [rbp + 0x3e0], rax
mov r12, qword [r8]
xor r15d, r15d
mov qword [rsp + 0x70], rcx
mov rsi, r9
mov r9, qword [rbp + 0x450]
mov r14, r8
mov dword [rsp + 0x60], r15d
mov rdi, rcx
test r12, r12
jne 0x14001f8c2
lea rcx, str.No_forward_host_name.
call fcn.140002d00
xor eax, eax
jmp 0x14001fd65
or rax, 0xffffffffffffffff
inc rax
cmp byte [r12 + rax], r15b
jne 0x14001f8c6
cmp rax, 0x401
jb 0x14001f8ea
lea rcx, str.Forward_host_name_too_long.
call fcn.140002d00
xor eax, eax
jmp 0x14001fd65
mov qword [rsp + 0x538], rbx
lea rdx, [rsp + 0x60]
xor r8d, r8d
mov qword [rsp + 0x4f0], r13
mov rcx, r12
call fcn.14001f6c0
mov ebx, dword [rsp + 0x60]
lea rcx, [0x1400c9a1c]
test rax, rax
lea rdx, str.channel_setup_fwd_listener_tcpip
mov r13, rax
mov r9d, ebx
cmove rax, rcx
mov r8d, ntohl
lea rcx, str._s:_type__d_wildcard__d_addr__s
mov qword [rsp + 0x20], rax
call fcn.140002e50
mov r9d, dword [r14 + 8]
lea r8, [0x1400c9a70]
xor eax, eax
mov edx, 0x20
mov qword [rsp + 0x78], rax
mov qword [rbp - 0x80], rax
mov qword [rbp - 0x78], rax
mov qword [rbp - 0x70], rax
mov qword [rbp - 0x68], rax
mov qword [rbp - 0x60], rax
mov rax, qword [rdi + 0x868]
mov ecx, dword [rax + 0x6c]
xor eax, eax
mov dword [rsp + 0x7c], ecx
test ebx, ebx
lea rcx, [rbp - 0x58]
mov dword [rbp - 0x80], 1
setne al
mov dword [rsp + 0x78], eax
call fcn.140002b20
lea r9, [rsp + 0x68]
mov rcx, r13
lea r8, [rsp + 0x78]
lea rdx, [rbp - 0x58]
call fcn.1400696a0
test eax, eax
je 0x14001f9f0
mov ecx, eax
call fcn.1400034f0
test r13, r13
jne 0x14001f9d0
mov rdx, rax
lea rcx, str.getaddrinfo:_fatal_error:__s
call fcn.140012580
xor eax, eax
jmp 0x14001fd55
mov r9, rax
lea rdx, str.channel_setup_fwd_listener_tcpip
mov r8, r13
lea rcx, str._s:_getaddrinfo__.64s_:__s
call fcn.140002d00
xor eax, eax
jmp 0x14001fd55
test rsi, rsi
je 0x14001f9f8
mov dword [rsi], r15d
mov rdi, qword [rsp + 0x68]
test rdi, rdi
je 0x14001fd31
mov eax, dword [rdi + 4]
cmp eax, 2
je 0x14001fa17
cmp eax, 0x17
jne 0x14001fd1f
cmp dword [r14 + 8], 0
mov rbx, qword [rdi + 0x20]
jne 0x14001fa39
test rsi, rsi
je 0x14001fa39
cmp dword [rsi], 0
jle 0x14001fa39
movzx ecx, word [rsi]
call qword [sym.imp.WS2_32.dll_htons]
mov word [rbx + 2], ax
mov edx, dword [rdi + 0x10]
lea rax, [rbp - 0x58]
mov rcx, qword [rdi + 0x20]
lea r8, [rbp - 0x30]
mov dword [rsp + 0x30], 0xa
mov r9d, 0x401
mov dword [rsp + 0x28], 0x20
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_getnameinfo]
test eax, eax
je 0x14001fa85
lea rdx, str.channel_setup_fwd_listener_tcpip
lea rcx, str._s:_getnameinfo_failed
call fcn.140002d00
jmp 0x14001fd1f
mov r8d, dword [rdi + 0xc]
mov edx, dword [rdi + 8]
mov ecx, dword [rdi + 4]
call fcn.140065d30
mov ebx, eax
test eax, eax
jns 0x14001fac2
call fcn.1400825b0
mov ecx, dword [rax]
call fcn.14005f2e0
mov r9, rax
lea r8, [rbp - 0x58]
lea rdx, [rbp - 0x30]
lea rcx, str.socket___s_:_s:__.100s
call fcn.140002dc0
jmp 0x14001fd1f
lea r9, [rsp + 0x60]
mov dword [rsp + 0x60], 1
mov edx, 0xffff
mov dword [rsp + 0x20], 4
mov r8d, 4
mov ecx, ebx
call fcn.140065b20
cmp eax, 0xffffffff
jne 0x14001fb0b
call fcn.1400825b0
mov ecx, dword [rax]
call fcn.14005f2e0
mov r8, rax
lea rcx, str.setsockopt_SO_REUSEADDR_fd__d:__s
mov edx, ebx
call fcn.140002d00
cmp dword [rdi + 4], 0x17
jne 0x14001fb6c
mov r8d, ebx
mov dword [rsp + 0x60], 1
lea rdx, str.sock_set_v6only
lea rcx, str._s:_set_socket__d_IPV6_V6ONLY
call fcn.140002e50
mov edx, 0x29
mov dword [rsp + 0x20], 4
lea r9, [rsp + 0x60]
mov ecx, ebx
lea r8d, [rdx - 0xe]
call fcn.140065b20
cmp eax, 0xffffffff
jne 0x14001fb6c
call fcn.1400825b0
mov ecx, dword [rax]
call fcn.14005f2e0
mov rdx, rax
lea rcx, str.setsockopt_IPV6_V6ONLY:__s
call fcn.140002d00
lea r8, [rbp - 0x58]
lea rdx, [rbp - 0x30]
lea rcx, str.Local_forwarding_listening_on__s_port__s.
call fcn.140002df0
mov r8d, dword [rdi + 0x10]
mov ecx, ebx
mov rdx, qword [rdi + 0x20]
call fcn.140063ac0
test eax, eax
jns 0x14001fbf8
cmp qword [rdi + 0x28], 0
jne 0x14001fbc9
call fcn.1400825b0
mov ecx, dword [rax]
call fcn.14005f2e0
mov r9, rax
lea r8, [rbp - 0x58]
lea rdx, [rbp - 0x30]
lea rcx, str.bind___s_:_s:__.100s
call fcn.140002d00
mov ecx, ebx
call fcn.140063bc0
jmp 0x14001fd1f
call fcn.1400825b0
mov ecx, dword [rax]
call fcn.14005f2e0
mov r9, rax
lea r8, [rbp - 0x58]
lea rdx, [rbp - 0x30]
lea rcx, str.bind___s_:_s:__.100s
call fcn.140002dc0
mov ecx, ebx
call fcn.140063bc0
jmp 0x14001fd1f
mov edx, 0x80
mov ecx, ebx
call fcn.140064760
test eax, eax
jns 0x14001fc52
call fcn.1400825b0
mov ecx, dword [rax]
call fcn.14005f2e0
mov rdx, rax
lea rcx, str.listen:__.100s
call fcn.140002d00
call fcn.1400825b0
mov ecx, dword [rax]
call fcn.14005f2e0
mov r9, rax
lea r8, [rbp - 0x58]
lea rdx, [rbp - 0x30]
lea rcx, str.listen___s_:_s:__.100s
call fcn.140002d00
mov ecx, ebx
call fcn.140063bc0
jmp 0x14001fd1f
cmp dword [r14 + 8], 0
jne 0x14001fc7f
test rsi, rsi
je 0x14001fc7f
cmp dword [rsi], 0
jne 0x14001fc7f
mov edx, 1
mov ecx, ebx
call fcn.14000d650
mov edx, eax
mov dword [rsi], eax
lea rcx, str.Allocated_listen_port__d
call fcn.140002df0
mov rcx, qword [rsp + 0x70]
lea rax, str.port_listener
mov dword [rsp + 0x50], 1
mov r9d, ebx
mov qword [rsp + 0x48], rax
mov r8d, ntohl
mov dword [rsp + 0x40], 0
mov rdx, rax
mov dword [rsp + 0x38], 0x8000
mov dword [rsp + 0x30], 0x200000
mov dword [rsp + 0x28], 0xffffffff
mov dword [rsp + 0x20], ebx
call fcn.1400195d0
mov rcx, r12
mov rbx, rax
call fcn.14000b9d0
mov qword [rbx + 0x68], rax
mov eax, dword [r14 + 0x20]
mov dword [rbx + 0x80], eax
test r13, r13
jne 0x14001fcef
xor eax, eax
jmp 0x14001fcf7
mov rcx, r13
call fcn.14000b9d0
mov qword [rbx + 0x78], rax
mov eax, dword [r14 + 8]
test eax, eax
jne 0x14001fd16
test rsi, rsi
je 0x14001fd16
test dword [0x1400e9db4], 0x8000000
jne 0x14001fd16
mov eax, dword [rsi]
mov dword [rbx + 0x70], eax
mov r15d, 1
mov rdi, qword [rdi + 0x28]
test rdi, rdi
jne 0x14001fa06
test r15d, r15d
jne 0x14001fd48
mov r8d, dword [r14 + 8]
lea rdx, str.channel_setup_fwd_listener_tcpip
lea rcx, str._s:_cannot_listen_to_port:__d
call fcn.140002d00
mov rcx, qword [rsp + 0x68]
call fcn.140069630
mov eax, r15d
mov rbx, qword [rsp + 0x538]
mov r13, qword [rsp + 0x4f0]
mov rcx, qword [rbp + 0x3e0]
xor rcx, rsp
call fcn.140075860
add rsp, 0x4f8
pop r15
pop r14
pop r12
pop rdi
pop rsi
pop rbp
ret