Function at 0x140005548
Capabilities:
Encrypt or decrypt data via bcrypt

Disassembly:
mov rax, rsp
mov qword [rax + 8], rbx
mov qword [rax + 0x18], r8
mov dword [rax + 0x10], edx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rax - 0x5f]
sub rsp, 0xb0
movdqa xmm0, xmmword [str.EEEEEEEEEEEEEEEE]
lea rdi, [rbp - 9]
movups xmm1, xmmword [0x14003ba80]
xor ebx, ebx
mov r12, rcx
and qword [rbp - 0x31], rbx
xor eax, eax
and qword [rbp - 0x39], rbx
movdqa xmm2, xmm0
and dword [rbp + 0x6f], ebx
xor r8d, r8d
lea ecx, [rbx + 0x2e]
xor edx, edx
rep stosb byte [rdi], al
movups xmmword [rbp - 3], xmm0
lea r15d, [rbx + 0x20]
mov r13, r9
movups xmmword [rbp + 0x12], xmm0
lea rdi, [rbp - 0x29]
mov ecx, r15d
rep stosb byte [rdi], al
movq rax, xmm0
lea edi, [rbx + 0x15]
movups xmm0, xmmword [str.C110DD4FE9434147B92A5A1E3FDBF29A]
xor ecx, ecx
xor r14d, r14d
movups xmmword [rbp - 0x19], xmm1
mov dword [rbp - 7], edi
movups xmmword [rbp - 0x29], xmm0
mov dword [rbp + 0xd], eax
movdqu xmmword [rbp - 0x1c], xmm2
mov byte [rbp + 0x11], al
call qword [sym.imp.KERNEL32.dll_HeapCreate]
mov rsi, rax
test rax, rax
je 0x1400056c7
xor r9d, r9d
lea rdx, [0x14003ba98]
xor r8d, r8d
lea rcx, [rbp - 0x31]
call qword [sym.imp.bcrypt.dll_BCryptOpenAlgorithmProvider]
test eax, eax
js 0x1400056c7
and dword [rsp + 0x30], ebx
lea rax, [rbp - 0x29]
mov rcx, qword [rbp - 0x31]
lea rdx, [rbp - 0x39]
mov dword [rsp + 0x28], r15d
xor r9d, r9d
xor r8d, r8d
mov qword [rsp + 0x20], rax
call qword [sym.imp.bcrypt.dll_BCryptGenerateSymmetricKey]
test eax, eax
js 0x1400056c7
mov r8d, edi
lea edx, [rbx + 8]
mov rcx, rsi
mov r15d, edi
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rdi, rax
test rax, rax
je 0x1400056c7
mov r8d, r15d
lea rdx, [rbp - 3]
mov rcx, rax
call fcn.14002cc30
lea r15d, [rbx + 0x60]
mov rcx, rsi
mov r8d, r15d
lea edx, [rbx + 8]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov r14, rax
test rax, rax
je 0x1400056c7
mov rcx, qword [rbp - 0x39]
lea rax, [rbp + 0x6f]
mov dword [rsp + 0x48], 1
lea r8d, [rbx + 0x20]
mov qword [rsp + 0x40], rax
xor r9d, r9d
mov dword [rsp + 0x38], r15d
mov rdx, r12
mov qword [rsp + 0x30], r14
mov dword [rsp + 0x28], 0x15
mov qword [rsp + 0x20], rdi
call qword [sym.imp.bcrypt.dll_BCryptEncrypt]
mov ebx, eax
not ebx
shr ebx, 0x1f
mov rcx, qword [rbp - 0x39]
test rcx, rcx
je 0x1400056d6
call qword [sym.imp.bcrypt.dll_BCryptDestroyKey]
mov rcx, qword [rbp - 0x31]
test rcx, rcx
je 0x1400056e7
xor edx, edx
call qword [sym.imp.bcrypt.dll_BCryptCloseAlgorithmProvider]
test ebx, ebx
je 0x140005770
mov eax, dword [rbp + 0x6f]
test eax, eax
je 0x140005770
test r14, r14
je 0x140005770
lea r15d, [rax + 0x34]
mov edx, 8
mov rax, qword gs:[0x30]
mov r8d, r15d
mov rcx, qword [rax + 0x60]
mov rcx, qword [rcx + 0x30]
call qword [sym.imp.ntdll.dll_RtlAllocateHeap]
mov rdi, rax
test rax, rax
je 0x140005770
movups xmm0, xmmword [rbp - 9]
lea rcx, [rdi + 0x2e]
mov rdx, r14
movups xmm1, xmmword [rbp + 7]
movups xmmword [rax], xmm0
movsd xmm0, qword [rbp + 0x17]
movups xmmword [rax + 0x10], xmm1
movsd qword [rax + 0x20], xmm0
mov eax, dword [rbp + 0x1f]
mov dword [rdi + 0x28], eax
movzx eax, word [rbp + 0x23]
mov word [rdi + 0x2c], ax
mov r8d, dword [rbp + 0x6f]
call fcn.14002cc30
mov rax, qword [rbp + 0x77]
mov ecx, dword [rbp + 0x6f]
mov dword [r15 + rdi - 6], ecx
mov dword [r13], r15d
mov qword [rax], rdi
test rsi, rsi
je 0x14000577e
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_HeapDestroy]
mov eax, ebx
mov rbx, qword [rsp + 0xf0]
add rsp, 0xb0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret