Function at 0x1400513e0
Capabilities:
Encode data using xor
Query or enumerate registry value

Disassembly:
mov rax, rsp
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rax - 0xc08]
sub rsp, 0xce0
mov qword [rbp - 0x60], 0xfffffffffffffffe
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
mov rax, qword [0x1401c3e90]
xor rax, rsp
mov qword [rbp + 0xbd0], rax
mov r13, rcx
mov qword [rbp - 0x68], rcx
xor r14d, r14d
mov dword [rsp + 0x38], r14d
mov qword [rsp + 0x40], r14
mov dword [rsp + 0x48], r14d
mov qword [rsp + 0x50], r14
mov qword [rbp - 0x78], r14
lea rax, [rbp - 0x78]
mov qword [rsp + 0x20], rax
lea r9d, [r14 + 1]
xor r8d, r8d
lea rdx, str.SoftwareMozillaMozilla_Firefox
mov rcx, 0xffffffff80000001
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
or r15, 0xffffffffffffffff
test eax, eax
jne 0x140051486
mov dword [rsp + 0x48], r14d
mov rsi, qword [rbp - 0x78]
mov qword [rsp + 0x40], rsi
mov ebx, dword [0x1401cbd80]
jmp 0x1400516c1
mov qword [rsp + 0x78], r14
lea rax, [rsp + 0x78]
mov qword [rsp + 0x20], rax
mov r9d, 1
xor r8d, r8d
lea rdx, str.SoftwareMozillaMozilla_Firefox
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x1400514d0
mov dword [rsp + 0x48], r14d
mov rsi, qword [rsp + 0x78]
mov qword [rsp + 0x40], rsi
mov ebx, dword [0x1401cbd80]
jmp 0x1400516c1
lea rcx, [0x1401c39a8]
mov rax, qword [0x1401c39a8]
call qword [rax + 0x18]
add rax, 0x18
mov qword [rsp + 0x68], rax
lea rdx, str.MozillaMozilla_Firefox
test rdx, 0xffffffffffff0000
jne 0x14005151b
movzx ebx, dx
mov ecx, ebx
call fcn.1400019e0
test rax, rax
je 0x140051526
mov r8d, ebx
mov rdx, rax
lea rcx, [rsp + 0x68]
call fcn.1400025b0
jmp 0x140051526
lea rcx, [rsp + 0x68]
call fcn.140003350
nop
lea rcx, [0x1401c39a8]
mov rax, qword [0x1401c39a8]
call qword [rax + 0x18]
add rax, 0x18
mov qword [rsp + 0x60], rax
lea rdx, str.SoftwareWow6432Node_
test rdx, 0xffffffffffff0000
jne 0x140051571
movzx ebx, dx
mov ecx, ebx
call fcn.1400019e0
test rax, rax
je 0x140051582
mov r8d, ebx
mov rdx, rax
lea rcx, [rsp + 0x60]
call fcn.1400025b0
jmp 0x140051582
mov r8d, 0x15
lea rcx, [rsp + 0x60]
call fcn.1400022c0
nop
lea r8, [rsp + 0x68]
lea rdx, [rsp + 0x60]
lea rcx, [rbp - 0x70]
call fcn.140010500
nop
mov qword [rbp - 0x80], r14
lea rcx, [rbp - 0x80]
mov qword [rsp + 0x20], rcx
mov r9d, 1
xor r8d, r8d
mov rdx, qword [rax]
mov rcx, 0xffffffff80000002
call qword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov r12d, eax
test eax, eax
jne 0x1400515d4
mov dword [rsp + 0x48], r14d
mov r12d, r14d
mov rax, qword [rbp - 0x80]
mov qword [rsp + 0x40], rax
mov rdx, qword [rbp - 0x70]
add rdx, 0xffffffffffffffe8
lock add dword [rdx + 0x10], 0xffffffff
jg 0x1400515ed
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rsp + 0x60]
add rdx, 0xffffffffffffffe8
lock add dword [rdx + 0x10], 0xffffffff
jg 0x140051607
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rsp + 0x68]
add rdx, 0xffffffffffffffe8
lock add dword [rdx + 0x10], 0xffffffff
jg 0x140051620
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov ebx, dword [0x1401cbd80]
lea ecx, [rbx + 2]
lea eax, [rbx + 1]
imul ecx, eax
imul ecx, ebx
mov eax, 0x2e8ba2e9
imul ecx
sar edx, 1
mov eax, edx
shr eax, 0x1f
add edx, eax
imul edx, edx, 0xb
sub ecx, edx
cmp ecx, 3
jne 0x1400516a2
lea rsi, [rbp - 0x50]
xor r8d, r8d
lea edi, [r8 + 1]
lea ecx, [r14 + 1]
mov eax, ebx
cdq
idiv ecx
mov ecx, edx
mov eax, ebx
sub eax, r14d
imul ecx, eax
mov eax, ebx
cdq
idiv edi
add ecx, eax
sub ecx, r8d
mov dword [rsi], ecx
mov edx, ecx
lea rcx, [0x140153c68]
call fcn.1400d1f8c
mov r8d, edi
add rsi, 4
mov ebx, dword [0x1401cbd80]
cmp edi, 9
jl 0x140051653
inc r14d
cmp r14d, 0x1d
jl 0x140051650
xor r14d, r14d
test r12d, r12d
je 0x1400516bc
mov rcx, r13
call fcn.140052160
mov dword [rsp + 0x38], 1
jmp 0x140051b82
mov rsi, qword [rsp + 0x40]
mov word [rbp + 0x3d0], r14w
xor edx, edx
mov r8d, 0x7fe
lea rcx, [rbp + 0x3d2]
call fcn.1400d6ac0
imul ebx, ebx
mov eax, 0x38e38e39
imul ebx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rdx + rdx*8]
add eax, eax
sub ebx, eax
cmp ebx, 3
jne 0x140051708
call fcn.1400d2038
mov dword [0x1401cbd80], eax
lea rcx, [0x1401c39a8]
mov rax, qword [0x1401c39a8]
call qword [rax + 0x18]
lea rbx, [rax + 0x18]
mov qword [rsp + 0x30], rbx
lea r12, [0x140158fc0]
test r12, 0xffffffffffff0000
jne 0x140051754
movzx edi, r12w
mov ecx, edi
call fcn.1400019e0
test rax, rax
je 0x14005176c
mov r8d, edi
mov rdx, rax
lea rcx, [rsp + 0x30]
call fcn.1400025b0
jmp 0x140051767
mov r8d, 3
mov rdx, r12
lea rcx, [rsp + 0x30]
call fcn.1400022c0
mov rbx, qword [rsp + 0x30]
mov r8d, dword [0x1401cbd80]
mov ecx, r8d
imul ecx, r8d
mov eax, 0x88888889
imul ecx
add edx, ecx
sar edx, 3
mov eax, edx
shr eax, 0x1f
add edx, eax
imul edx, edx, 0xf
sub ecx, edx
cmp ecx, 8
jne 0x1400517d5
mov eax, 0x51eb851f
imul r8d
sar edx, 5
mov eax, edx
shr eax, 0x1f
add edx, eax
imul edx, edx, 0x64
sub r8d, edx
add r8d, 0x2f4
movsxd rcx, r8d
mov eax, 4
mul rcx
cmovo rax, r15
mov rcx, rax
call fcn.1400d0cc8
mov rcx, rax
call fcn.1400d272c
mov dword [rsp + 0x58], 0x800
lea rax, [rsp + 0x58]
mov qword [rsp + 0x28], rax
lea rax, [rbp + 0x3d0]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x70]
xor r8d, r8d
lea rdx, str.CurrentVersion
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov r10d, eax
test eax, eax
jne 0x140051852
mov eax, dword [rsp + 0x70]
dec eax
cmp eax, 1
jbe 0x140051825
mov r10d, 0xd
jmp 0x140051852
mov eax, dword [rsp + 0x58]
test eax, eax
je 0x140051847
test al, 1
jne 0x14005183f
shr rax, 1
cmp word [rbp + rax*2 + 0x3ce], 0
je 0x14005184f
mov r10d, 0xd
jmp 0x140051852
mov word [rbp + 0x3d0], r14w
mov r10d, r14d
mov r9d, dword [0x1401cbd80]
lea r8d, [r9 + 2]
lea ecx, [r9 + 1]
imul r8d, ecx
imul r8d, r9d
mov eax, 0x2e8ba2e9
imul r8d
sar edx, 2
mov eax, edx
shr eax, 0x1f
add edx, eax
imul edx, edx, 0x16
sub r8d, edx
cmp r8d, 0xe
jne 0x1400518f0
mov ecx, r14d
mov eax, 0x44d72045
imul r9d
sar edx, 5
mov eax, edx
shr eax, 0x1f
add edx, eax
imul edx, edx, 0x77
mov eax, r9d
sub eax, edx
cmp eax, 5
je 0x1400518e7
nop dword [rax]
mov eax, r9d
or eax, 0xffffff2e
add r9d, eax
inc ecx
mov eax, r9d
imul eax, r9d
cmp ecx, eax
jg 0x1400518e7
mov eax, 0x44d72045
imul r9d
sar edx, 5
mov eax, edx
shr eax, 0x1f
add edx, eax
imul edx, edx, 0x77
mov eax, r9d
sub eax, edx
cmp eax, 5
jne 0x1400518b0
mov r9d, ecx
mov dword [0x1401cbd80], ecx
test r10d, r10d
jne 0x140051a0f
lea rax, [rbp + 0x3d0]
mov rdi, r15
inc rdi
cmp word [rax + rdi*2], 0
jne 0x140051903
test edi, edi
jne 0x140051972
lea rdx, [rbx - 0x18]
mov rdi, qword [rdx]
cmp dword [rdx + 8], 0
je 0x140051a0f
cmp dword [rdx + 0x10], 0
jge 0x140051946
cmp dword [rbx - 0xc], 0
jge 0x140051939
mov ecx, 0x80070057
call fcn.140001920
int3
mov dword [rbx - 0x10], r14d
mov word [rbx], r14w
jmp 0x140051a08
lock add dword [rdx + 0x10], 0xffffffff
jg 0x140051956
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
mov rax, qword [rdi]
mov rcx, rdi
call qword [rax + 0x18]
lea rbx, [rax + 0x18]
mov qword [rsp + 0x30], rbx
mov rsi, qword [rsp + 0x40]
jmp 0x140051a08
mov r12d, dword [rbx - 0x10]
lea r14, [rbp + 0x3d0]
sub r14, rbx
sar r14, 1
test edi, edi
jns 0x140051992
mov ecx, 0x80070057
call fcn.140001920
int3
mov ecx, 1
sub ecx, dword [rbx - 8]
mov eax, dword [rbx - 0xc]
sub eax, edi
or eax, ecx
jge 0x1400519b4
mov edx, edi
lea rcx, [rsp + 0x30]
call fcn.1400023b0
mov rbx, qword [rsp + 0x30]
movsxd rax, edi
movsxd rdx, dword [rbx - 0xc]
mov rcx, rbx
add rdx, rdx
cmp r14, r12
lea r12, [rax + rax]
mov r9, r12
ja 0x1400519d8
lea r8, [rbx + r14*2]
call fcn.1400d1ea4
jmp 0x1400519e4
lea r8, [rbp + 0x3d0]
call fcn.1400d2064
cmp edi, dword [rbx - 0xc]
jg 0x1400519fd
mov dword [rbx - 0x10], edi
xor r14d, r14d
mov word [r12 + rbx], r14w
lea r12, [0x140158fc0]
jmp 0x140051a08
mov ecx, 0x80070057
call fcn.140001920
int3
mov r9d, dword [0x1401cbd80]
test rsi, rsi
je 0x140051a29
mov rcx, rsi
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov qword [rsp + 0x40], r14
mov r9d, dword [0x1401cbd80]
mov dword [rsp + 0x48], r14d
lea ecx, [r9 + 2]
lea eax, [r9 + 1]
imul ecx, eax
imul ecx, r9d
mov eax, 0x55555556
imul ecx
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rdx + rdx*2]
sub ecx, eax
cmp ecx, 2
jne 0x140051afa
mov edx, r14d
nop dword [rax]
mov ecx, edx
and ecx, 1
dec ecx
not ecx
and ecx, r9d
mov eax, edx
sar eax, 1
xor ecx, eax
mov eax, ecx
and eax, 1
dec eax
not eax
and eax, r9d
sar ecx, 1
xor eax, ecx
mov ecx, eax
and ecx, 1
dec ecx
not ecx
and ecx, r9d
sar eax, 1
xor ecx, eax
mov eax, ecx
and eax, 1
dec eax
not eax
and eax, r9d
sar ecx, 1
xor eax, ecx
mov ecx, eax
and ecx, 1
dec ecx
not ecx
and ecx, r9d
sar eax, 1
xor ecx, eax
mov eax, ecx
and eax, 1
dec eax
not eax
and eax, r9d
sar ecx, 1
xor eax, ecx
mov ecx, eax
and ecx, 1
dec ecx
not ecx
and ecx, r9d
sar eax, 1
xor ecx, eax
mov eax, ecx
and eax, 1
dec eax
not eax
and eax, r9d
sar ecx, 1
xor eax, ecx
add r9d, eax
inc edx
cmp edx, 0x100
jl 0x140051a60
mov dword [0x1401cbd80], r9d
cmp dword [rbx - 0x10], 0
je 0x140051b5d
mov rcx, r14
nop word [rax + rax]
movzx eax, word [rbx + rcx*2]
inc rcx
cmp ax, word [r12 + rcx*2 - 2]
jne 0x140051b2a
cmp rcx, 4
jne 0x140051b10
mov eax, r14d
jmp 0x140051b2f
sbb eax, eax
or eax, 1
test eax, eax
je 0x140051b5d
lea rcx, [rbx - 0x18]
call fcn.140002410
add rax, 0x18
mov qword [r13], rax
mov dword [rsp + 0x38], 1
lock add dword [rbx - 8], 0xffffffff
jg 0x140051b82
mov rcx, qword [rbx - 0x18]
lea rdx, [rbx - 0x18]
jmp 0x140051b7b
mov rcx, r13
call fcn.140052160
mov dword [rsp + 0x38], 1
lea rdx, [rbx - 0x18]
lock add dword [rdx + 0x10], 0xffffffff
jg 0x140051b82
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rcx, qword [rsp + 0x40]
test rcx, rcx
je 0x140051b97
call qword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov qword [rsp + 0x40], r14
mov dword [rsp + 0x48], r14d
mov rax, r13
mov rcx, qword [rbp + 0xbd0]
xor rcx, rsp
call fcn.1400d1680
lea r11, [rsp + 0xce0]
mov rbx, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret