Function at 0x1276eee
Capabilities:
Create new key via cryptacquirecontext
Encrypt data using aes via winapi

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
push edi
xor edi, edi
xor ebx, ebx
mov esi, ecx
mov dword [ebp - 4], edi
cmp dword [ebp + 8], edi
je 0x1277143
cmp dword [ebp + 0x14], edi
je 0x1277143
push dword [esi + 0x14]
call fcn.010324e9
push dword [esi + 0xc]
mov dword [esi + 0x14], edi
call fcn.010324e9
lea eax, [esi + 0x20]
mov dword [ebp - 8], eax
mov eax, dword [eax]
pop ecx
pop ecx
mov dword [esi + 0xc], edi
mov dword [esi + 0x10], edi
cmp eax, edi
je 0x1276f47
push eax
call dword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
mov eax, dword [ebp - 8]
mov dword [eax], edi
lea eax, [esi + 0x24]
mov dword [ebp - 0xc], eax
cmp dword [eax], edi
jne 0x1276f81
push 0xf0000000
push 0x18
push edi
push edi
push eax
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
test eax, eax
jne 0x1276f81
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, edi
jle 0x1276f79
and eax, 0xffff
or eax, 0x80070000
mov dword [ebp - 4], eax
jmp 0x127714a
cmp dword [ebp + 0xc], edi
je 0x1276fdf
push dword [esi + 0xc]
call fcn.010324e9
mov eax, dword [ebp + 0xc]
pop ecx
mov dword [esi + 0xc], edi
lea ecx, [eax + 2]
mov dx, word [eax]
inc eax
inc eax
cmp dx, di
jne 0x1276f98
sub eax, ecx
sar eax, 1
mov dword [esi + 0x10], eax
xor ecx, ecx
push 2
inc eax
pop edx
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.010324da
pop ecx
mov dword [esi + 0xc], eax
cmp eax, edi
je 0x1276ff5
push dword [ebp + 0xc]
mov ecx, dword [esi + 0x10]
inc ecx
push ecx
push eax
call fcn.010399c4
mov dword [ebp - 4], eax
cmp eax, edi
jne 0x127714a
mov eax, dword [ebp + 0x10]
add eax, 0xc
push eax
mov dword [ebp + 0xc], eax
call fcn.010324da
mov ebx, eax
pop ecx
cmp ebx, edi
jne 0x1277001
mov dword [ebp - 4], 0x8007000e
jmp 0x127714a
xor eax, eax
cmp dword [ebp + 0x10], 0x10
mov byte [ebx], 8
mov byte [ebx + 1], 2
mov word [ebx + 2], ax
jne 0x1277062
mov eax, dword [ebp + 8]
mov ecx, 0x1021e20
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x1277042
cmp dx, di
je 0x127703e
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x1277042
add eax, 4
add ecx, 4
cmp dx, di
jne 0x127701c
xor eax, eax
jmp 0x1277047
sbb eax, eax
sbb eax, 0xffffffff
cmp eax, edi
jne 0x12770f0
mov dword [ebx + 4], 0x660e
mov dword [esi + 8], 1
jmp 0x1277107
cmp dword [ebp + 0x10], 0x18
jne 0x12770af
mov eax, dword [ebp + 8]
mov ecx, 0x1021dc8
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x1277096
cmp dx, di
je 0x1277092
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x1277096
add eax, 4
add ecx, 4
cmp dx, di
jne 0x1277070
xor eax, eax
jmp 0x127709b
sbb eax, eax
sbb eax, 0xffffffff
cmp eax, edi
jne 0x12770f0
mov dword [ebx + 4], 0x660f
mov dword [esi + 8], 2
jmp 0x1277107
cmp dword [ebp + 0x10], 0x20
jne 0x127713a
mov eax, dword [ebp + 8]
mov ecx, 0x1021d70
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x12770e7
cmp dx, di
je 0x12770e3
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x12770e7
add eax, 4
add ecx, 4
cmp dx, di
jne 0x12770c1
xor eax, eax
jmp 0x12770ec
sbb eax, eax
sbb eax, 0xffffffff
cmp eax, edi
je 0x12770f9
mov dword [ebp - 4], 0x80049e2f
jmp 0x127714a
mov dword [ebx + 4], 0x6610
mov dword [esi + 8], 3
mov eax, dword [ebp + 0x10]
push eax
push dword [ebp + 0x14]
mov dword [ebx + 8], eax
lea eax, [ebx + 0xc]
push eax
call sub.msvcrt.dll_memcpy
mov eax, dword [ebp - 0xc]
add esp, 0xc
push dword [ebp - 8]
push edi
push edi
push dword [ebp + 0xc]
push ebx
push dword [eax]
call dword [sym.imp.ADVAPI32.dll_CryptImportKey]
test eax, eax
jne 0x127714a
jmp 0x1276f65
mov dword [ebp - 4], 0x80049e2e
jmp 0x127714a
mov dword [ebp - 4], 0x80070057
push ebx
call fcn.010324e9
mov eax, dword [ebp - 4]
pop ecx
pop edi
pop esi
pop ebx
leave
ret 0x10