Function at 0x13181ab
Capabilities:
Create new key via cryptacquirecontext

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x1c
push ebx
push esi
xor esi, esi
push edi
mov ebx, ecx
mov dword [ebp - 0x10], esi
mov dword [ebp - 0x18], esi
mov dword [ebp - 4], esi
mov dword [ebp - 0x14], esi
mov dword [ebp - 0xc], esi
mov dword [ebp - 8], esi
cmp dword [ebp + 8], esi
jne 0x13181db
mov edi, 0x80070057
jmp 0x131844c
push dword [ebx + 0x14]
call fcn.0103e4a5
push dword [ebx + 0xc]
mov dword [ebx + 0x14], esi
call fcn.0103e4a5
mov eax, dword [ebx + 0x20]
pop ecx
pop ecx
mov dword [ebx + 0xc], esi
mov dword [ebx + 0x10], esi
cmp eax, esi
je 0x1318207
push eax
call dword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
mov dword [ebx + 0x20], esi
lea eax, [ebx + 0x24]
cmp dword [eax], esi
jne 0x1318235
push 0xf0000000
push 0x18
push esi
push esi
push eax
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
test eax, eax
jne 0x1318235
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, esi
jg 0x1318437
jmp 0x1318441
mov ecx, dword [ebp + 8]
mov eax, dword [ecx]
push esi
lea edx, [ebp - 8]
push edx
call dword [eax + 0x10]
mov edi, eax
test edi, edi
jne 0x131844c
mov eax, dword [ebp - 8]
xor ecx, ecx
push 2
pop edx
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0103e496
pop ecx
mov dword [ebp - 0x10], eax
test eax, eax
je 0x13183a6
mov ecx, dword [ebp + 8]
mov edx, dword [ecx]
push eax
lea eax, [ebp - 8]
push eax
call dword [edx + 0x10]
mov edi, eax
test edi, edi
jne 0x131844c
mov ecx, dword [ebp + 8]
mov eax, dword [ecx]
push edi
lea edx, [ebp - 0xc]
push edx
call dword [eax + 0x14]
mov edi, eax
test edi, edi
jne 0x131844c
mov eax, dword [ebp - 0xc]
xor ecx, ecx
push 2
pop edx
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0103e496
pop ecx
mov dword [ebp - 0x18], eax
test eax, eax
je 0x13183a6
mov ecx, dword [ebp + 8]
mov edx, dword [ecx]
push eax
lea eax, [ebp - 0xc]
push eax
call dword [edx + 0x14]
mov edi, eax
test edi, edi
jne 0x131844c
push eax
lea eax, [ebp - 4]
push eax
mov eax, dword [ebp - 0xc]
push dword [ebp - 0x18]
dec eax
push eax
call fcn.01293823
mov edi, eax
test edi, edi
jne 0x131844c
cmp dword [ebp - 4], 4
jbe 0x1318303
mov edi, 0x80049e2e
jmp 0x131844c
lea eax, [ebp - 0x10]
sub eax, dword [ebp - 4]
push eax
lea eax, [ebp - 4]
push eax
mov eax, dword [ebp - 0xc]
push dword [ebp - 0x18]
dec eax
push eax
call fcn.01293823
mov edi, eax
test edi, edi
jne 0x131844c
push 4
lea eax, [ebp - 0x14]
push eax
mov ecx, ebx
call fcn.01317bcc
mov edi, eax
test edi, edi
jne 0x131844c
mov eax, dword [ebp - 0x14]
mov dword [ebx + 0x1c], eax
push edi
lea eax, [ebp - 4]
push eax
mov eax, dword [ebp - 8]
push dword [ebp - 0x10]
dec eax
push eax
call fcn.01293823
mov edi, eax
test edi, edi
jne 0x131844c
push dword [ebp - 4]
call fcn.0103e496
pop ecx
mov dword [ebx + 0x14], eax
test eax, eax
je 0x13183a6
push eax
lea eax, [ebp - 4]
push eax
mov eax, dword [ebp - 8]
push dword [ebp - 0x10]
dec eax
push eax
call fcn.01293823
mov edi, eax
test edi, edi
jne 0x131844c
mov eax, dword [ebp - 4]
lea edi, [eax + 0x14]
push edi
mov dword [ebx + 0x18], eax
mov dword [ebp + 8], eax
mov dword [ebp - 0x1c], edi
call fcn.0103e496
mov esi, eax
pop ecx
test esi, esi
jne 0x13183b0
mov edi, 0x8007000e
jmp 0x131844c
push edi
push 0
push esi
call sub.msvcrt.dll_memset
xor ecx, ecx
mov word [esi + 2], cx
mov ecx, dword [ebp + 8]
add esp, 0xc
mov byte [esi], 6
mov byte [esi + 1], 2
mov dword [esi + 4], 0xa400
shl ecx, 3
lea eax, [esi + 0x14]
push eax
mov dword [esi + 8], 0x31415352
mov dword [esi + 0xc], ecx
mov ecx, dword [ebp - 0x14]
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x10]
mov dword [esi + 0x10], ecx
mov eax, dword [ebp - 8]
dec eax
push eax
call fcn.01293823
mov edi, eax
test edi, edi
jne 0x131844c
push dword [ebp + 8]
lea eax, [esi + 0x14]
push eax
mov ecx, ebx
call fcn.01317bcc
mov edi, eax
test edi, edi
jne 0x131844c
lea eax, [ebx + 0x20]
push eax
push 0x40
push edi
push dword [ebp - 0x1c]
push esi
push dword [ebx + 0x24]
call dword [sym.imp.ADVAPI32.dll_CryptImportKey]
test eax, eax
jne 0x1318445
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x1318441
and eax, 0xffff
or eax, 0x80070000
mov edi, eax
jmp 0x131844c
mov dword [ebx + 8], 5
push esi
call fcn.0103e4a5
push dword [ebp - 0x10]
call fcn.0103e4a5
push dword [ebp - 0x18]
call fcn.0103e4a5
add esp, 0xc
mov eax, edi
pop edi
pop esi
pop ebx
leave
ret 4