Function at 0x140165010
Capabilities:
Create new key via cryptacquirecontext

Disassembly:
push rbp
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0xa8]
sub rsp, 0x1a8
mov qword [rsp + 0x40], 0xfffffffffffffffe
mov rax, qword [0x14026be10]
xor rax, rsp
mov qword [rbp + 0x90], rax
movzx r13d, r9b
movzx r14d, r8b
mov byte [rsp + 0x30], r14b
mov rdi, rdx
mov rbx, rcx
mov rsi, qword [rbp + 0x110]
xor eax, eax
mov qword [rsp + 0x50], rax
mov qword [rsp + 0x58], rax
mov qword [rsp + 0x60], rax
lea r8, str.acquireCSP
mov rdx, rsi
lea rcx, [rsp + 0x50]
call fcn.140071270
nop
mov rax, qword [rsi]
mov r8, rbx
lea rdx, str.providerName
mov rcx, rsi
call qword [rax + 0x58]
mov rax, qword [rsi]
mov r8, rdi
lea rdx, str.keyContainer
mov rcx, rsi
call qword [rax + 0x58]
mov r8d, r14d
lea rdx, str.verifyContext
mov rcx, rsi
call fcn.1400717d0
mov r8d, r13d
lea rdx, str.machineKeyset
mov rcx, rsi
call fcn.1400717d0
xor edx, edx
mov r8d, 0x90
lea rcx, [rbp]
call fcn.14016c710
lea rcx, [rbp]
call fcn.14002b840
nop
mov rdx, rbx
lea rcx, [rbp]
call fcn.14002bc30
lea rcx, [rbp]
call fcn.140031880
xor edx, edx
mov r8d, 0x90
lea rcx, [rsp + 0x70]
call fcn.14016c710
lea rcx, [rsp + 0x70]
call fcn.14002b840
nop
mov rdx, rdi
lea rcx, [rsp + 0x70]
call fcn.14002bc30
lea rcx, [rsp + 0x70]
call fcn.140031880
xor ebx, ebx
mov r15d, ebx
mov r12d, ebx
lea rcx, [rbp]
call fcn.14002ed00
test eax, eax
je 0x140165155
lea rcx, [rbp]
call fcn.14002ed10
mov r15, rax
lea rcx, [rsp + 0x70]
call fcn.14002ed00
test eax, eax
je 0x140165170
lea rcx, [rsp + 0x70]
call fcn.14002ed10
mov r12, rax
mov qword [rsp + 0x48], rbx
mov r14d, 1
test r15, r15
je 0x140165190
cmp byte [r15], bl
je 0x140165190
mov rcx, r15
call fcn.1401653b0
mov r14d, eax
mov r8d, r14d
lea rdx, str.providerType
mov rcx, rsi
call fcn.140071f70
neg r13b
sbb edi, edi
and edi, 0x20
cmp byte [rsp + 0x30], bl
je 0x1401651b9
or edi, 0xf0000000
mov r12, rbx
mov dword [rsp + 0x20], edi
mov r9d, r14d
mov r8, r15
mov rdx, r12
lea rcx, [rsp + 0x48]
call sub.ADVAPI32.dll_CryptAcquireContextA
test eax, eax
je 0x140165232
cmp qword [rsp + 0x48], rbx
je 0x1401652de
mov ecx, 0x148
call fcn.140169164
mov rdi, rax
mov qword [rsp + 0x38], rax
test rax, rax
je 0x140165216
xor edx, edx
mov r8d, 0x148
mov rcx, rax
call fcn.14016c710
mov rdx, qword [rsp + 0x48]
mov rcx, rdi
call fcn.140164e20
mov rbx, rax
mov dword [rbx + 0x138], r14d
mov rax, qword [rsi]
lea rdx, str.Success
mov rcx, rsi
call qword [rax + 0x30]
jmp 0x140165302
call qword [sym.imp.KERNEL32.dll_GetLastError]
mov r13d, eax
mov rcx, rsi
call fcn.1400720b0
cmp r13d, 0x80090016
je 0x140165259
cmp r13d, 0x80090019
jne 0x1401652f0
or edi, 8
mov rax, qword [rsi]
lea rdx, str.Retry_with_new_keyset...
mov rcx, rsi
call qword [rax + 0x30]
mov dword [rsp + 0x20], edi
mov r9d, r14d
mov r8, r15
mov rdx, r12
lea rcx, [rsp + 0x48]
call sub.ADVAPI32.dll_CryptAcquireContextA
test eax, eax
je 0x1401652f0
cmp qword [rsp + 0x48], rbx
je 0x1401652de
mov ecx, 0x148
call fcn.140169164
mov rdi, rax
mov qword [rsp + 0x38], rax
test rax, rax
je 0x1401652c5
xor edx, edx
mov r8d, 0x148
mov rcx, rax
call fcn.14016c710
mov rdx, qword [rsp + 0x48]
mov rcx, rdi
call fcn.140164e20
mov rbx, rax
mov dword [rbx + 0x138], r14d
mov rax, qword [rsi]
lea rdx, str.Success
mov rcx, rsi
call qword [rax + 0x30]
jmp 0x140165302
mov rax, qword [rsi]
lea rdx, str.Failed.
mov rcx, rsi
call qword [rax + 0x28]
jmp 0x140165302
mov r8, qword [rsi]
lea rdx, str.Failed
mov rcx, rsi
call qword [r8 + 0x28]
nop
lea rcx, [rsp + 0x70]
call fcn.14002b890
nop
lea rcx, [rbp]
call fcn.14002b890
nop
lea rcx, [rsp + 0x50]
call fcn.140071380
mov rax, rbx
mov rcx, qword [rbp + 0x90]
xor rcx, rsp
call fcn.140168e10
add rsp, 0x1a8
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret