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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x477e60
mov eax, dword fs:[0]
push eax
sub esp, 0x1c
mov eax, dword [0x49a324]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
push 0xf0000000
push 0x18
push 0
push 0
push edi
mov dword [ebp - 4], 1
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextA]
mov esi, eax
test esi, esi
je 0x402065
mov eax, dword [ebp + 0x38]
mov esi, 1
sub eax, 0x660e
je 0x402025
sub eax, esi
je 0x40201e
sub eax, esi
je 0x402017
xor esi, esi
jmp 0x40203d
mov eax, 0x20
jmp 0x40202a
mov eax, 0x18
jmp 0x40202a
mov eax, 0x10
mov ebx, dword [ebp + 0x18]
cmp ebx, eax
jb 0x402033
jbe 0x402040
push ecx
push eax
lea ecx, [ebp + 8]
call fcn.00401bb0
mov ebx, dword [ebp + 0x18]
test esi, esi
je 0x402065
xor eax, eax
mov byte [ebp - 0x16], 2
cmp dword [ebp + 0x1c], 0x10
mov dword [ebp - 0x1c], eax
lea eax, [ebp + 8]
cmovae eax, dword [ebp + 8]
xor esi, esi
mov dword [ebp - 0x24], eax
mov byte [ebp - 0x15], 8
test eax, eax
jne 0x4020d4
mov eax, dword [edi]
test eax, eax
je 0x40207a
push 0
push eax
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov dword [edi], 0
mov eax, dword [edi + 4]
test eax, eax
je 0x40208f
push eax
call dword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
mov dword [edi + 4], 0
mov dword [edi + 8], 0
mov dword [edi + 0xc], 0
mov edx, dword [ebp + 0x1c]
cmp edx, 0x10
jb 0x4021f4
mov ecx, dword [ebp + 8]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x4021ea
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x402256
jmp 0x4021ea
lea eax, [ebx + 0xc]
push 0xeb3c44
push eax
mov dword [ebp - 0x28], eax
call fcn.0045ed59
add esp, 8
mov dword [ebp - 0x20], eax
test eax, eax
je 0x402137
mov esi, dword [ebp - 0x20]
lea eax, [ebx + 0xc]
push eax
push 0
push esi
call fcn.004619b0
mov al, byte [ebp - 0x15]
mov byte [esi], al
mov al, byte [ebp - 0x16]
mov byte [esi + 1], al
xor eax, eax
mov word [esi + 2], ax
mov eax, dword [ebp + 0x38]
push ebx
push dword [ebp - 0x24]
mov dword [esi + 4], eax
lea eax, [esi + 0xc]
push eax
mov dword [esi + 8], ebx
call fcn.00460eb0
mov ecx, dword [ebp - 0x28]
mov eax, esi
add esp, 0x18
mov dword [ebp - 0x1c], eax
mov esi, 1
jmp 0x40213b
xor eax, eax
xor ecx, ecx
test esi, esi
je 0x402065
lea ebx, [edi + 4]
push ebx
push 1
push 0
push ecx
push eax
push dword [edi]
call dword [sym.imp.ADVAPI32.dll_CryptImportKey]
mov esi, eax
mov eax, dword [ebp - 0x1c]
test eax, eax
je 0x402167
push eax
call fcn.0045ed0d
add esp, 4
test esi, esi
je 0x402065
push 0
lea eax, [ebp + 0x3c]
push eax
push 4
push dword [ebx]
call dword [sym.imp.ADVAPI32.dll_CryptSetKeyParam]
mov esi, eax
test esi, esi
je 0x402065
push 0
lea ecx, [ebp - 0x14]
mov dword [ebp - 0x14], 4
push ecx
lea eax, [edi + 8]
push eax
push 8
push dword [ebx]
call dword [sym.imp.ADVAPI32.dll_CryptGetKeyParam]
mov esi, eax
test esi, esi
je 0x402065
shr dword [edi + 8], 3
cmp dword [ebp + 0x30], 0
je 0x4021da
cmp dword [ebp + 0x34], 0x10
lea eax, [ebp + 0x20]
push 0
cmovae eax, dword [ebp + 0x20]
push eax
push 1
push dword [ebx]
call dword [sym.imp.ADVAPI32.dll_CryptSetKeyParam]
mov esi, eax
test esi, esi
je 0x402065
mov eax, dword [ebp + 0x40]
mov esi, 1
mov dword [edi + 0xc], eax
jmp 0x40209d
push edx
push ecx
call fcn.0045ed42
add esp, 8
mov edx, dword [ebp + 0x34]
mov dword [ebp + 0x18], 0
mov dword [ebp + 0x1c], 0xf
mov byte [ebp + 8], 0
cmp edx, 0x10
jb 0x402236
mov ecx, dword [ebp + 0x20]
inc edx
mov eax, ecx
cmp edx, 0x1000
jb 0x40222c
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40225b
push edx
push ecx
call fcn.0045ed42
add esp, 8
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0045ecfc
mov esp, ebp
pop ebp
ret 0x3c
call fcn.00463aa9
call fcn.00463aa9
int3