Function at 0x100024e0
Capabilities:
Create new key via cryptacquirecontext
Encrypt data using aes via winapi
Encrypt or decrypt via wincrypt

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x98
mov eax, dword [0x10034110]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov byte [ebp - 5], 0
mov dword [ebp - 0xc], 0
mov dword [ebp - 0x10], 0
mov dword [ebp - 0x14], 0
push 0xf0000000
push 0x18
push 0
push 0
lea eax, [ebp - 0x10]
push eax
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextA]
test eax, eax
jne 0x10002532
jmp 0x1000274c
mov byte [ebp - 0x40], 8
mov byte [ebp - 0x3f], 2
xor eax, eax
mov word [ebp - 0x3e], ax
mov dword [ebp - 0x3c], 0x6610
mov dword [ebp - 0x38], 0x20
push 0x20
push 0
lea eax, [ebp - 0x34]
push eax
call fcn.1000c980
add esp, 0xc
mov eax, dword [ebp + 0x14]
cmp dword [eax], 0x20
jae 0x10002573
mov ecx, dword [ebp + 0x14]
mov edx, dword [ecx]
mov dword [ebp - 0x98], edx
jmp 0x1000257d
mov dword [ebp - 0x98], 0x20
mov eax, dword [ebp - 0x98]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
lea edx, [ebp - 0x34]
push edx
call fcn.1000c610
add esp, 0xc
lea eax, [ebp - 0xc]
push eax
push 1
push 0
push 0x2c
lea ecx, [ebp - 0x40]
push ecx
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.ADVAPI32.dll_CryptImportKey]
test eax, eax
jne 0x100025bf
jmp 0x1000273a
mov dword [ebp - 0x44], 1
push 0
lea eax, [ebp - 0x44]
push eax
push 4
mov ecx, dword [ebp - 0xc]
push ecx
call dword [sym.imp.ADVAPI32.dll_CryptSetKeyParam]
test eax, eax
jne 0x100025e6
jmp 0x1000272a
mov dword [ebp - 0x48], 0
mov dword [ebp - 0x4c], 4
push 0
lea eax, [ebp - 0x4c]
push eax
lea ecx, [ebp - 0x48]
push ecx
push 8
mov edx, dword [ebp - 0xc]
push edx
call dword [sym.imp.ADVAPI32.dll_CryptGetKeyParam]
test eax, eax
jne 0x10002618
jmp 0x1000272a
mov eax, dword [ebp - 0x48]
shr eax, 3
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x50], 0
mov eax, dword [ebp - 0x48]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov dword [ebp - 0x50], eax
cmp dword [ebp - 0x50], 0
jne 0x10002647
jmp 0x1000272a
mov eax, dword [ebp - 0x48]
push eax
push 0
mov ecx, dword [ebp - 0x50]
push ecx
call fcn.1000c980
add esp, 0xc
push 0
mov eax, dword [ebp - 0x50]
push eax
push 1
mov ecx, dword [ebp - 0xc]
push ecx
call dword [sym.imp.ADVAPI32.dll_CryptSetKeyParam]
test eax, eax
jne 0x10002683
mov eax, dword [ebp - 0x50]
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x1000272a
mov eax, dword [ebp - 0x50]
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov eax, dword [ebp + 0x1c]
mov ecx, dword [ebp + 0xc]
mov edx, dword [eax]
cmp edx, dword [ecx]
jae 0x100026a6
mov eax, dword [ebp + 0x1c]
mov ecx, dword [eax]
mov dword [ebp - 0x98], ecx
jmp 0x100026b1
mov edx, dword [ebp + 0xc]
mov eax, dword [edx]
mov dword [ebp - 0x98], eax
mov ecx, dword [ebp - 0x98]
push ecx
mov edx, dword [ebp + 8]
push edx
mov eax, dword [ebp + 0x18]
push eax
call fcn.1000c610
add esp, 0xc
mov eax, dword [ebp + 0x1c]
mov ecx, dword [ebp + 0xc]
mov edx, dword [ecx]
mov dword [eax], edx
mov eax, dword [ebp + 0x1c]
push eax
mov ecx, dword [ebp + 0x18]
push ecx
push 0
push 0
push 0
mov edx, dword [ebp - 0xc]
push edx
call dword [sym.imp.ADVAPI32.dll_CryptDecrypt]
test eax, eax
jne 0x100026fd
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x54], eax
jmp 0x1000272a
mov eax, dword [ebp + 0x1c]
mov ecx, dword [eax]
sub ecx, 0x10
push ecx
mov edx, dword [ebp + 0x18]
add edx, 0x10
push edx
mov eax, dword [ebp + 0x18]
push eax
call fcn.1000c2a0
add esp, 0xc
mov eax, dword [ebp + 0x1c]
mov ecx, dword [eax]
sub ecx, 0x10
mov edx, dword [ebp + 0x1c]
mov dword [edx], ecx
mov byte [ebp - 5], 1
cmp dword [ebp - 0xc], 0
je 0x1000273a
mov eax, dword [ebp - 0xc]
push eax
call dword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
cmp dword [ebp - 0x10], 0
je 0x1000274c
push 0
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov al, byte [ebp - 5]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1000b5d6
mov esp, ebp
pop ebp
ret