Function at 0x140387e00
Capabilities:
Encrypt data using aes via winapi

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x20], r9
mov qword [rsp + 0x10], rdx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
mov rbp, rsp
sub rsp, 0x50
xor ebx, ebx
mov r12, r8
mov dword [rbp - 0x1c], ebx
mov r13, rcx
mov qword [rbp - 8], rbx
mov r15d, ebx
mov dword [rbp - 0x20], ebx
mov qword [rbp - 0x10], rbx
test rdx, rdx
je 0x140388125
test r8, r8
je 0x140388125
test r9, r9
je 0x140388125
cmp dword [rcx + 0xc], 4
je 0x140387e65
mov edi, 0x80049e2f
jmp 0x14038812a
cmp qword [rcx + 0x30], rbx
je 0x14038811e
cmp qword [rcx + 0x38], rbx
je 0x14038811e
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
xor edx, edx
mov rcx, rax
lea r8d, [rdx + 0x48]
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov rsi, rax
test rax, rax
je 0x140388117
mov rcx, qword [r13 + 0x38]
lea rax, [0x1403cdd40]
mov qword [rsi], rax
test rcx, rcx
mov dword [rsi + 0xc], ebx
mov eax, 1
mov dword [rsi + 8], eax
cmovne eax, ebx
mov qword [rsi + 0x10], rbx
mov dword [rsi + 0x18], ebx
mov qword [rsi + 0x20], rbx
mov qword [rsi + 0x28], rbx
mov qword [rsi + 0x30], rbx
mov qword [rsi + 0x38], rcx
mov dword [rsi + 0x40], eax
mov rax, qword [r12]
mov rbx, qword [rax + 0x28]
mov rax, qword [0x1403cf6d0]
mov rcx, rbx
call rax
mov rax, rbx
lea rdx, [rbp - 0x1c]
xor r8d, r8d
mov rcx, r12
call rax
mov edi, eax
mov r14, rsi
test eax, eax
jne 0x1403880fa
mov ecx, dword [rbp - 0x1c]
lea eax, [rdi + 2]
mul rcx
mov rbx, rax
mov rax, 0xffffffffffffffff
cmovo rbx, rax
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, rbx
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov qword [rbp - 8], rax
mov rdi, rax
test rax, rax
jne 0x140387f44
mov edi, 0x8007000e
jmp 0x1403880fa
mov rax, qword [r12]
mov rbx, qword [rax + 0x28]
mov rax, qword [0x1403cf6d0]
mov rcx, rbx
call rax
mov rax, rbx
lea rdx, [rbp - 0x1c]
mov r8, rdi
mov rcx, r12
call rax
mov edi, eax
test eax, eax
jne 0x1403880fa
mov rcx, qword [rbp - 8]
lea rdx, str.http:__www.w3.org_2001_04_xmlencrsa_oaep_mgf1p
call sub.msvcrt.dll_wcscmp
test eax, eax
jne 0x1403880f5
mov rax, qword [r12]
mov rbx, qword [rax + 0x38]
mov rax, qword [0x1403cf6d0]
mov rcx, rbx
call rax
mov rax, rbx
lea rdx, [rbp - 0x20]
xor r8d, r8d
mov rcx, r12
call rax
mov edi, eax
test eax, eax
jne 0x1403880fa
mov eax, dword [rbp - 0x20]
add eax, 0xc
mov dword [rbp - 0x18], eax
mov ebx, eax
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8d, ebx
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapAlloc]
mov r15, rax
test rax, rax
je 0x140387f3a
mov rbx, qword [rbp + 0x48]
lea rdx, str.http:__www.w3.org_2001_04_xmlencaes128_cbc
mov rcx, rbx
mov dword [rax], 0x201
call sub.msvcrt.dll_wcscmp
test eax, eax
jne 0x14038800f
mov dword [r15 + 4], 0x660e
mov dword [rsi + 0xc], 1
jmp 0x140388059
lea rdx, str.http:__www.w3.org_2001_04_xmlencaes192_cbc
mov rcx, rbx
call sub.msvcrt.dll_wcscmp
test eax, eax
jne 0x140388033
mov dword [r15 + 4], 0x660f
mov dword [rsi + 0xc], 2
jmp 0x140388059
lea rdx, str.http:__www.w3.org_2001_04_xmlencaes256_cbc
mov rcx, rbx
call sub.msvcrt.dll_wcscmp
test eax, eax
jne 0x1403880f5
mov dword [r15 + 4], 0x6610
mov dword [rsi + 0xc], 3
mov dword [r15 + 8], 0xa400
mov rax, qword [r12]
mov rbx, qword [rax + 0x38]
mov rax, qword [0x1403cf6d0]
mov rcx, rbx
call rax
mov rax, rbx
lea r8, [r15 + 0xc]
lea rdx, [rbp - 0x20]
mov rcx, r12
call rax
xor ebx, ebx
mov edi, eax
test eax, eax
jne 0x1403880fa
mov r8d, dword [rbp - 0x20]
lea rdx, [r15 + 0xc]
call fcn.140387c38
mov edi, eax
test eax, eax
jne 0x1403880fa
mov r9, qword [r13 + 0x30]
lea rax, [rbp - 0x10]
mov r8d, dword [rbp - 0x18]
mov rdx, r15
mov rcx, qword [r13 + 0x38]
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], 0x40
call qword [sym.imp.ADVAPI32.dll_CryptImportKey]
test eax, eax
jne 0x1403880e0
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx edi, ax
or edi, 0x80070000
test eax, eax
cmovle edi, eax
jmp 0x1403880fa
mov rax, qword [rbp - 0x10]
mov qword [rsi + 0x30], rax
mov rax, qword [rbp + 0x58]
mov qword [rbp - 0x10], rbx
mov qword [rax], rsi
jmp 0x14038812a
mov edi, 0x80049e5b
mov rax, qword [r14]
mov rbx, qword [rax + 0x10]
mov rax, qword [0x1403cf6d0]
mov rcx, rbx
call rax
mov rax, rbx
mov rcx, r14
call rax
jmp 0x14038812a
mov edi, 0x8007000e
jmp 0x14038812a
mov edi, 0x80049e51
jmp 0x14038812a
mov edi, 0x80070057
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, qword [rbp - 8]
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
call qword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov r8, r15
xor edx, edx
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_HeapFree]
mov rcx, qword [rbp - 0x10]
test rcx, rcx
je 0x140388162
call qword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
mov rbx, qword [rsp + 0x90]
mov eax, edi
add rsp, 0x50
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret