Function at 0x140002070
Capabilities:
Encrypt data using dpapi

Disassembly:
push rbp
push r15
push r14
push r12
push rsi
push rdi
push rbx
sub rsp, 0x100
lea rbp, [rsp + 0x80]
mov qword [rbp + 0x78], 0xfffffffffffffffe
mov rdi, rdx
mov rsi, rcx
lea rdx, [0x1400ff843]
lea rcx, [rbp + 0x50]
mov r8d, 0x14
call fcn.14000b140
cmp byte [rbp + 0x68], 3
je 0x140002398
movups xmm0, xmmword [rbp + 0x50]
movups xmm1, xmmword [rbp + 0x60]
movaps xmmword [rbp - 0x10], xmm1
movaps xmmword [rbp - 0x20], xmm0
mov byte [rbp + 0x75], 1
lea rcx, [rbp - 0x20]
call fcn.14000bb70
mov r8, rdx
mov byte [rbp + 0x75], 1
mov qword [rsp + 0x20], 0xb
lea r9, str.Local_State
lea rcx, [rbp - 0x40]
mov rdx, rax
call fcn.14001e110
mov byte [rbp + 0x77], 1
mov byte [rbp + 0x76], 1
mov rcx, rdi
call fcn.1400241c0
mov rdi, rax
mov rbx, rdx
mov byte [rbp + 0x77], 1
mov byte [rbp + 0x76], 1
lea rcx, [rbp - 0x40]
call fcn.1400241c0
mov byte [rbp + 0x77], 1
mov byte [rbp + 0x76], 1
mov qword [rsp + 0x20], rdx
lea rcx, [rbp + 0x50]
mov rdx, rdi
mov r8, rbx
mov r9, rax
call fcn.140023440
cmp qword [rbp + 0x50], 0
jne 0x1400023cd
movups xmm0, xmmword [rbp - 0x40]
movups xmm1, xmmword [rbp - 0x30]
movaps xmmword [rbp + 0x60], xmm1
movaps xmmword [rbp + 0x50], xmm0
lea rcx, [rbp + 0x50]
call fcn.1400241c0
mov r8, rdx
lea rcx, [rbp + 0x20]
mov rdx, rax
call fcn.140018150
mov rdx, qword [rbp + 0x58]
test rdx, rdx
je 0x140002188
mov rcx, qword [rbp + 0x50]
mov r8d, 1
call fcn.1400017e0
mov rax, qword [rbp + 0x20]
mov qword [rbp + 0x18], rax
test rax, rax
je 0x140002402
mov rax, qword [rbp + 0x28]
mov qword [rbp + 0x10], rax
mov rdi, qword [rbp + 0x30]
movaps xmm0, xmmword [rbp - 0x20]
movaps xmm1, xmmword [rbp - 0x10]
movaps xmmword [rbp + 0x60], xmm1
movaps xmmword [rbp + 0x50], xmm0
lea rcx, [rbp + 0x50]
call fcn.14000bba0
test rax, rax
jne 0x140002437
lea rcx, [rbp + 0x20]
mov rdx, qword [rbp + 0x18]
mov r8, rdi
call fcn.14000f5a0
lea rcx, [rbp + 0x50]
lea rdx, [rbp + 0x20]
call fcn.1400052e0
cmp byte [rbp + 0x50], 6
je 0x140002468
movups xmm0, xmmword [rbp + 0x50]
movups xmm1, xmmword [rbp + 0x60]
movaps xmmword [rbp + 0x30], xmm1
movaps xmmword [rbp + 0x20], xmm0
lea rcx, str.os_cryptencrypted_keycalled__Option::unwrap____on_a__None__valueW
lea r8, [rbp + 0x20]
mov edx, 8
call fcn.1400105e0
test rax, rax
jne 0x14000221f
mov rax, qword [0x14012c3c0]
lea rcx, [0x1400ff950]
mov edx, 0xd
mov r8, rax
call fcn.1400105e0
test rax, rax
jne 0x14000223f
mov rax, qword [0x14012c3c0]
mov rcx, rax
call fcn.1400106f0
test rax, rax
je 0x14000249a
mov r8, rdx
lea rdi, [rbp + 0x50]
mov rcx, rdi
mov rdx, rax
mov r9d, 1
call fcn.140006ce0
mov r14, qword [rbp + 0x50]
test r14, r14
je 0x1400024b4
mov r15, qword [rbp + 0x58]
mov rbx, qword [rbp + 0x60]
cmp rbx, 4
jbe 0x1400024e5
add rbx, 0xfffffffffffffffb
je 0x1400022c9
js 0x140002503
movzx eax, byte [0x14012c4f1]
mov edx, 1
mov rcx, rbx
call fcn.1400017d0
mov r12, rax
test rax, rax
jne 0x1400022cf
mov qword [rbp + 0x48], r15
mov qword [rbp + 0x40], r14
mov ecx, 1
mov rdx, rbx
call fcn.1400fdfa0
jmp 0x140002510
mov r12d, 1
lea rdx, [r14 + 5]
mov rcx, r12
mov r8, rbx
call sub.VCRUNTIME140.dll_memcpy
test r15, r15
je 0x1400022f4
mov r8d, 1
mov rcx, r14
mov rdx, r15
call fcn.1400017e0
mov dword [rbp], ebx
mov qword [rbp + 0x48], r12
mov qword [rbp + 8], r12
mov dword [rbp + 0x50], 0
mov qword [rbp + 0x58], 0
mov qword [rsp + 0x30], rdi
mov dword [rsp + 0x28], 0
mov qword [rsp + 0x20], 0
mov rcx, rbp
xor edx, edx
xor r8d, r8d
xor r9d, r9d
mov qword [rbp + 0x40], rbx
call sub.CRYPT32.dll_CryptUnprotectData
mov rax, qword [rbp + 0x58]
mov ecx, dword [rbp + 0x50]
mov qword [rsi], rax
mov qword [rsi + 8], rcx
mov qword [rsi + 0x10], rcx
mov rdx, qword [rbp + 0x40]
test rdx, rdx
je 0x140002362
mov r8d, 1
mov rcx, qword [rbp + 0x48]
call fcn.1400017e0
lea rcx, [rbp + 0x20]
call fcn.140001c30
mov rdx, qword [rbp + 0x10]
test rdx, rdx
je 0x140002383
mov r8d, 1
mov rcx, qword [rbp + 0x18]
call fcn.1400017e0
mov rax, rsi
add rsp, 0x100
pop rbx
pop rdi
pop rsi
pop r12
pop r14
pop r15
pop rbp
ret
mov rax, qword [rbp + 0x50]
mov qword [rbp + 0x20], rax
lea rax, [0x1400ff8c0]
mov qword [rsp + 0x20], rax
lea rcx, [0x1400ff745]
lea r9, fcn.140001a60
lea r8, [rbp + 0x20]
mov edx, 0x2b
call fcn.1400fe3a0
jmp 0x140002510
mov rax, qword [rbp + 0x58]
mov qword [rbp + 0x20], rax
lea rax, [0x1400ff8e8]
mov qword [rsp + 0x20], rax
lea rcx, [0x1400ff745]
lea r9, fcn.140001a60
lea r8, [rbp + 0x20]
mov edx, 0x2b
call fcn.1400fe3a0
jmp 0x140002510
mov rax, qword [rbp + 0x28]
mov qword [rbp + 0x50], rax
lea rax, [0x1400ff900]
mov qword [rsp + 0x20], rax
lea rcx, [0x1400ff745]
lea r9, fcn.140001a60
lea r8, [rbp + 0x50]
mov edx, 0x2b
call fcn.1400fe3a0
jmp 0x140002510
mov qword [rbp + 0x50], rax
lea rax, [0x1400ff918]
mov qword [rsp + 0x20], rax
lea rcx, [0x1400ff745]
lea r9, fcn.140001a60
lea r8, [rbp + 0x50]
mov edx, 0x2b
call fcn.1400fe3a0
jmp 0x140002510
mov rax, qword [rbp + 0x58]
mov qword [rbp + 0x20], rax
lea rax, [0x1400ff930]
mov qword [rsp + 0x20], rax
lea rcx, [0x1400ff745]
lea r9, fcn.140001b20
lea r8, [rbp + 0x20]
mov edx, 0x2b
call fcn.1400fe3a0
jmp 0x140002510
lea rcx, [0x1400ff95d]
lea r8, [0x1400ff988]
mov edx, 0x2b
call fcn.1400fe0b0
jmp 0x140002510
movups xmm0, xmmword [rbp + 0x58]
movaps xmmword [rbp], xmm0
lea rax, [0x1400ff9a0]
mov qword [rsp + 0x20], rax
lea rcx, [0x1400ff745]
lea r9, [0x1400ff790]
mov r8, rbp
mov edx, 0x2b
call fcn.1400fe3a0
jmp 0x140002510
mov qword [rbp + 0x48], r15
mov qword [rbp + 0x40], r14
lea r8, [0x1400ff9b8]
mov ecx, 5
mov rdx, rbx
call fcn.1400fe430
jmp 0x140002510
mov qword [rbp + 0x48], r15
mov qword [rbp + 0x40], r14
call fcn.14002dfb0
ud2