Function at 0x14004bc50
Capabilities:
Resolve dns

Disassembly:
mov qword [rsp + 0x18], r8
push rbp
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x1f]
sub rsp, 0xa8
mov qword [rbp + 7], 0xfffffffffffffffe
mov rdi, rdx
mov r14, rcx
xor r13d, r13d
mov dword [rbp + 0x6f], r13d
mov qword [rbp - 0x59], r13
mov rbx, qword [0x140104018]
mov qword [rbp - 0x51], rbx
test rdx, rdx
je 0x14004bcb2
mov rax, rdx
shr rax, 0x10
test ax, ax
jne 0x14004bcce
movzx edx, di
lea rcx, [rbp - 0x51]
call fcn.140001ff0
mov rbx, qword [rbp - 0x51]
mov rax, qword [0x140104018]
mov qword [rbp - 0x29], rax
mov r15d, 0xffffffff
cmp dword [rbx - 8], 0
jg 0x14004bd0d
mov eax, r15d
jmp 0x14004bd2a
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_lstrlenW]
movsxd rsi, eax
test eax, eax
je 0x14004bcb2
mov edx, esi
lea rcx, [rbp - 0x51]
call fcn.140001970
test eax, eax
je 0x14004bcae
mov r9, rsi
add r9, r9
lea eax, [rsi + 1]
movsxd rdx, eax
add rdx, rdx
mov r8, rdi
mov rbx, qword [rbp - 0x51]
mov rcx, rbx
call fcn.1400029b0
jmp 0x14004bcb2
mov edx, reloc.OLEAUT32.dll_VarI4FromDisp
mov rcx, rbx
call sub.VCRUNTIME140.dll_wcschr
test rax, rax
jne 0x14004bd24
mov eax, r15d
jmp 0x14004bd2a
sub rax, rbx
sar rax, 1
lea rcx, [rbx - 0xc]
mov qword [rbp - 1], rcx
mov ecx, dword [rbx - 8]
mov r12d, r13d
add eax, 1
cmovns r12d, eax
mov r8d, r13d
sub ecx, eax
cmovns r8d, ecx
mov edx, dword [rbx - 8]
lea eax, [r8 + r12]
mov ecx, edx
sub ecx, r12d
cmp eax, edx
cmovle ecx, r8d
mov esi, r13d
cmp r12d, edx
cmovle esi, ecx
mov rdi, qword [0x140104018]
mov qword [rbp - 0x49], rdi
mov dword [rbp + 0x6f], 2
test esi, esi
jne 0x14004bd7f
mov qword [rbp - 0x49], rdi
jmp 0x14004bdb1
mov edx, esi
lea rcx, [rbp - 0x49]
call fcn.140001970
mov rdi, qword [rbp - 0x49]
test eax, eax
je 0x14004bdb1
movsxd r9, esi
add r9, r9
movsxd rax, r12d
lea r8, [rbx + rax*2]
lea eax, [rsi + 1]
movsxd rdx, eax
add rdx, rdx
mov rcx, rdi
call fcn.1400029b0
nop
lea rdx, [rbp - 0x49]
lea rcx, [rbp - 0x29]
call fcn.1400063d0
nop
lea rcx, [rdi - 0xc]
cmp rcx, qword [0x140104010]
je 0x14004bddd
mov eax, r15d
lock xadd dword [rcx], eax
sub eax, 1
jg 0x14004bddd
call fcn.1400bf5e4
mov rax, qword [0x140104018]
mov qword [rbp - 0x39], rax
mov r8, qword [rbp - 0x29]
lea rdx, [0x1400d4ea8]
lea rcx, [rbp - 0x39]
call fcn.1400086c0
mov rdx, qword [rbp - 0x39]
lea r12, [rdx - 0xc]
mov qword [rbp - 9], r12
cmp dword [r12], 0
jl 0x14004be1a
mov qword [rbp - 0x41], rdx
lock inc dword [r12]
jmp 0x14004be2e
mov rax, qword [0x140104018]
mov qword [rbp - 0x41], rax
lea rcx, [rbp - 0x41]
call fcn.140006470
mov r9b, 1
mov r8d, 2
lea rdx, [rbp - 0x41]
mov rcx, qword [r14 + 0x28]
call fcn.140002330
mov edx, reloc.WS2_32.dll_ntohs
mov qword [rsp + 0x28], r13
lea rax, [rbp - 0x59]
mov qword [rsp + 0x20], rax
xor r9d, r9d
xor r8d, r8d
mov rcx, qword [rbp - 0x29]
call sub.DNSAPI.dll_DnsQuery_W
mov rcx, qword [rbp - 0x59]
mov qword [rbp - 0x21], rcx
test eax, eax
jne 0x14004c073
test rcx, rcx
je 0x14004c067
mov r12, qword [rbp + 0x77]
nop dword [rax]
nop word [rax + rax]
mov rax, qword [rbp - 0x59]
cmp word [rax + 0x10], 0xf
jne 0x14004c04b
mov rdi, qword [rax + 0x20]
mov rbx, qword [0x140104018]
mov qword [rbp + 0x7f], rbx
test rdi, rdi
je 0x14004becf
mov rax, rdi
shr rax, 0x10
test ax, ax
jne 0x14004befc
movzx edx, di
lea rcx, [rbp + 0x7f]
call fcn.140001ff0
mov rbx, qword [rbp + 0x7f]
mov r8, qword [rbp - 0x59]
add r8, 0x28
mov rdx, qword [r12]
mov rdi, rdx
mov rax, qword [rdx + 8]
cmp byte [rax + 0x19], 0
jne 0x14004bf52
movzx ecx, word [r8]
nop dword [rax]
cmp word [rax + 0x20], cx
jae 0x14004bf3b
mov rax, qword [rax + 0x10]
jmp 0x14004bf41
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_lstrlenW]
movsxd rsi, eax
test eax, eax
je 0x14004becf
mov edx, esi
lea rcx, [rbp + 0x7f]
call fcn.140001970
test eax, eax
je 0x14004becb
mov r9, rsi
add r9, r9
lea eax, [rsi + 1]
movsxd rdx, eax
add rdx, rdx
mov r8, rdi
mov rbx, qword [rbp + 0x7f]
mov rcx, rbx
call fcn.1400029b0
jmp 0x14004becf
mov rdi, rax
mov rax, qword [rax]
cmp byte [rax + 0x19], 0
je 0x14004bef0
cmp rdi, rdx
je 0x14004bf52
cmp cx, word [rdi + 0x20]
jae 0x14004bf89
mov qword [rbp - 0x19], r8
lea r9, [rbp + 0x67]
lea r8, [rbp - 0x19]
lea rdx, [0x1400d4ab0]
mov rcx, r12
call fcn.14004a480
lea r9, [rax + 0x20]
mov qword [rsp + 0x20], rax
mov r8, rdi
lea rdx, [rbp - 0x11]
mov rcx, r12
call fcn.14004a900
mov rdi, qword [rbp - 0x11]
lea rsi, [rdi + 0x28]
mov rcx, qword [rsi]
cmp rcx, rbx
je 0x14004c02d
add rcx, 0xfffffffffffffff4
cmp dword [rcx], 0
jge 0x14004bfab
cmp rcx, qword [0x140104010]
jne 0x14004bfb4
lea rdi, [rbx - 0xc]
cmp dword [rdi], 0
jge 0x14004bff4
movsxd r14, dword [rbx - 8]
mov edx, r14d
mov rcx, rsi
call fcn.140021d50
test eax, eax
je 0x14004c02d
lea rdi, [r14 + r14]
lea eax, [r14 + 1]
movsxd rdx, eax
add rdx, rdx
mov r9, rdi
mov r8, rbx
mov rcx, qword [rsi]
call fcn.1400029b0
mov rax, qword [rsi]
mov dword [rax - 8], r14d
mov rax, qword [rsi]
mov word [rdi + rax], r13w
jmp 0x14004c02d
cmp rcx, qword [0x140104010]
je 0x14004c023
mov eax, r15d
lock xadd dword [rcx], eax
sub eax, 1
jg 0x14004c015
mov rcx, qword [rsi]
sub rcx, 0xc
call fcn.1400bf5e4
mov rax, qword [0x140104018]
mov qword [rsi], rax
mov rbx, qword [rbp + 0x7f]
mov qword [rsi], rbx
lock inc dword [rdi]
mov rbx, qword [rbp + 0x7f]
lea rcx, [rbx - 0xc]
cmp rcx, qword [0x140104010]
je 0x14004c04b
mov eax, r15d
lock xadd dword [rcx], eax
sub eax, 1
jg 0x14004c04b
call fcn.1400bf5e4
mov rax, qword [rbp - 0x59]
mov rax, qword [rax]
mov qword [rbp - 0x59], rax
test rax, rax
jne 0x14004be90
mov r12, qword [rbp - 9]
mov rcx, qword [rbp - 0x21]
mov edx, 1
call sub.DNSAPI.dll_DnsFree
jmp 0x14004c0d0
mov r8d, eax
lea rdx, [0x1400d4ee8]
lea rcx, [rbp - 0x39]
call fcn.1400086c0
mov rdx, qword [rbp - 0x39]
lea r12, [rdx - 0xc]
cmp dword [r12], 0
jl 0x14004c0a0
mov qword [rbp - 0x31], rdx
lock inc dword [r12]
jmp 0x14004c0b4
mov rax, qword [0x140104018]
mov qword [rbp - 0x31], rax
lea rcx, [rbp - 0x31]
call fcn.140006470
mov r9b, 1
mov r8d, 2
lea rdx, [rbp - 0x31]
mov rcx, qword [r14 + 0x28]
call fcn.140002330
mov r13d, 1
cmp r12, qword [0x140104010]
je 0x14004c0f0
mov eax, r15d
lock xadd dword [r12], eax
sub eax, 1
jg 0x14004c0f0
mov rcx, r12
call fcn.1400bf5e4
nop
mov rcx, qword [rbp - 0x29]
add rcx, 0xfffffffffffffff4
cmp rcx, qword [0x140104010]
je 0x14004c113
mov eax, r15d
lock xadd dword [rcx], eax
sub eax, 1
jg 0x14004c113
call fcn.1400bf5e4
nop
mov rax, qword [rbp - 1]
cmp rax, qword [0x140104010]
je 0x14004c133
lock xadd dword [rax], r15d
sub r15d, 1
jg 0x14004c133
mov rcx, rax
call fcn.1400bf5e4
mov eax, r13d
add rsp, 0xa8
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret