Function at 0x180039ff0
Capabilities:
Encode data using xor

Disassembly:
push rbp
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbx
sub rsp, 0x5e8
lea rbp, [rsp + 0x80]
mov qword [rbp + 0x560], 0xfffffffffffffffe
mov rsi, rcx
call fcn.180079440
mov qword [rbp + 0x540], rax
mov byte [rbp + 0x548], dl
lea rdi, [rbp - 0x40]
mov r8d, 0x4d0
mov rcx, rdi
xor edx, edx
call sub.VCRUNTIME140.dll_memset
mov rcx, rdi
call qword [sym.imp.kernel32.dll_RtlCaptureContext]
mov rdi, qword [rbp + 0xb8]
lea r12, [rbp + 0x4c0]
mov qword [rbp + 0x518], rsi
jmp 0x18003a063
mov rdi, rax
mov qword [rbp + 0x530], 0
mov rcx, rdi
lea rdx, [rbp + 0x530]
xor r8d, r8d
call qword [sym.imp.kernel32.dll_RtlLookupFunctionEntry]
test rax, rax
je 0x18003a42f
test rdi, rdi
je 0x18003a42f
mov qword [rbp + 0x520], rax
movzx eax, byte [0x18028ecd1]
mov ecx, 0x10
mov edx, 8
call fcn.18006a570
test rax, rax
je 0x18003a498
mov r9, rax
mov qword [rax], rdi
mov qword [rbp + 0x528], rdi
mov qword [rax + 8], rdi
xor edi, edi
xor r14d, r14d
mov qword [rbp + 0x550], rax
jmp 0x18003a119
mov rax, qword [rsi + 8]
lea rcx, [rbx + rbx*2]
mov rdx, qword [rbp + 0x558]
mov qword [rax + rcx*8], rdx
mov rdx, qword [rbp + 0x538]
mov qword [rax + rcx*8 + 8], rdx
mov qword [rax + rcx*8 + 0x10], r15
inc rbx
mov qword [rsi + 0x10], rbx
mov r9, qword [rbp + 0x550]
add r14, 8
inc rdi
cmp r14, 0x10
je 0x18003a3a0
mov r15, qword [r9 + r14]
xor eax, eax
test rdi, rdi
sete al
mov ecx, 1
lea rdx, [0x1801a40f0]
cmove rcx, rdx
mov qword [rbp + 0x4b0], rcx
mov qword [rbp + 0x4b8], rax
mov rax, qword [0x180277178]
movzx eax, byte [rax]
test al, al
je 0x18003a180
sub r15, qword [0x18028e9b0]
mov eax, 0xfffffffe
cmp r15, rax
ja 0x18003a112
jmp 0x18003a2bc
mov r13d, dword [0x18028e9b8]
test r13b, 1
jne 0x18003a2a0
mov rsi, r12
cmp r13d, 0x100
jae 0x18003a1bc
mov r12d, r13d
or r12d, 0x20000000
mov eax, r13d
lock cmpxchg dword [0x18028e9b8], r12d
lea rbx, [0x18028e9b8]
je 0x18003a207
mov r12, rsi
mov rcx, rsi
lea rdx, [0x18028e9b8]
lea r8, [rbp + 0x4f0]
lea r9, [0x18028e9b0]
call fcn.1801844d0
mov eax, dword [rbp + 0x4c0]
test eax, eax
je 0x18003a261
cmp eax, 2
je 0x18003a2a0
mov rbx, qword [rbp + 0x4c8]
mov r13d, dword [rbp + 0x4d0]
mov r12d, r13d
or r12d, 0x20000000
xor ecx, ecx
call sub.kernel32.dll_GetModuleHandleW
mov qword [0x18028e9b0], rax
mov eax, r12d
mov ecx, 1
lock cmpxchg dword [rbx], ecx
mov r12, rsi
je 0x18003a2a0
and r13d, 0xdfffffff
xor r13d, 0x20000001
mov eax, dword [rbx]
nop word cs:[rax + rax]
mov ecx, eax
xor ecx, r13d
lock cmpxchg dword [rbx], ecx
jne 0x18003a240
cmp eax, 0x40000000
jb 0x18003a2a0
xor eax, r13d
mov rcx, rbx
mov edx, eax
call fcn.18018f9c0
jmp 0x18003a2a0
mov rcx, qword [rbp + 0x4c8]
mov edx, 0xffffff00
lock xadd dword [rcx], edx
mov eax, edx
and eax, 0x3fffff00
cmp eax, 0x100
setne al
cmp edx, 0x40000000
setb r8b
or r8b, al
jne 0x18003a2a0
add edx, 0xffffff00
call fcn.18018f9c0
nop word [rax + rax]
mov r9, qword [rbp + 0x550]
sub r15, qword [0x18028e9b0]
mov eax, 0xfffffffe
cmp r15, rax
ja 0x18003a112
mov qword [rbp + 0x510], r15
lea rax, [rbp + 0x4b0]
mov qword [rbp + 0x4f0], rax
lea rax, [0x180067d10]
mov qword [rbp + 0x4f8], rax
lea rax, [rbp + 0x510]
mov qword [rbp + 0x500], rax
lea rax, [fcn.18017f800]
mov qword [rbp + 0x508], rax
lea rax, [0x1801a40f8]
mov qword [rbp + 0x4c0], rax
mov qword [rbp + 0x4c8], 2
mov qword [rbp + 0x4e0], 0
lea rax, [rbp + 0x4f0]
mov qword [rbp + 0x4d0], rax
mov qword [rbp + 0x4d8], 2
lea rcx, [rbp + 0x498]
mov rdx, r12
call fcn.1801776a0
mov rcx, qword [rbp + 0x498]
mov rax, rcx
neg rax
jo 0x18003a10b
mov qword [rbp + 0x558], rcx
mov rax, qword [rbp + 0x4a0]
mov qword [rbp + 0x538], rax
mov r15, qword [rbp + 0x4a8]
mov rsi, qword [rbp + 0x518]
mov rbx, qword [rsi + 0x10]
cmp rbx, qword [rsi]
jne 0x18003a0e0
mov rcx, rsi
call fcn.180014e80
jmp 0x18003a0e0
mov edx, 0x10
mov r8d, 8
mov rcx, r9
call fcn.18006a580
mov rdi, qword [rbp + 0x58]
mov qword [rbp + 0x4f0], 0
mov qword [rbp + 0x4c0], 0
mov rdx, qword [rbp + 0x530]
mov qword [rsp + 0x30], r12
lea rax, [rbp + 0x4f0]
mov qword [rsp + 0x28], rax
lea rax, [rbp - 0x40]
mov qword [rsp + 0x20], rax
mov qword [rsp + 0x38], 0
xor ecx, ecx
mov rsi, qword [rbp + 0x528]
mov r8, rsi
mov r9, qword [rbp + 0x520]
call qword [sym.imp.kernel32.dll_RtlVirtualUnwind]
mov rax, qword [rbp + 0xb8]
test rax, rax
je 0x18003a42f
cmp rax, rsi
jne 0x18003a060
cmp qword [rbp + 0x58], rdi
jne 0x18003a060
lea rcx, [rbp + 0x540]
call fcn.1800793a0
movzx eax, byte [rbp + 0x548]
cmp al, 2
je 0x18003a46b
mov rsi, qword [rbp + 0x540]
test al, 1
jne 0x18003a463
mov rax, qword [0x18028cba0]
mov rax, qword [rax]
shl rax, 1
test rax, rax
jne 0x18003a489
xor eax, eax
xchg byte [rsi], al
cmp al, 2
je 0x18003a47f
add rsp, 0x5e8
pop rbx
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
pop rbp
ret
mov rcx, rsi
call fcn.18019d380
jmp 0x18003a46b
call fcn.18019d1f0
test al, al
jne 0x18003a463
mov byte [rsi + 1], 1
jmp 0x18003a463
mov ecx, 8
mov edx, 0x10
call fcn.18019decf
ud2