Function at 0x4687c0
Capabilities:
Encrypt data using aes via winapi

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x579a08
mov eax, dword fs:[0]
push eax
sub esp, 0xac
mov eax, dword [0x5cc128]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov edi, ecx
mov eax, dword [edi + 8]
lea ebx, [edi + 8]
mov ecx, dword [ebp + 8]
mov dword [ebp - 0x4c], edi
mov dword [ebp - 0x48], ecx
test eax, eax
je 0x46881a
push eax
call dword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
mov ecx, dword [ebp - 0x48]
mov dword [ebx], 0
mov byte [edi + 0x10], 0
mov dword [ebp - 4], 0
cmp dword [edi + 4], 0
jne 0x468866
lea eax, [ebp - 0x54]
mov dword [ebp - 0x58], vtable.std::exception.0
push eax
lea eax, [ebp - 0x78]
mov dword [ebp - 0x78], str.SetKey:_Provider_is_not_valid
xorps xmm0, xmm0
mov byte [ebp - 0x74], 1
push eax
movq qword [ebp - 0x54], xmm0
call fcn.0051d791
add esp, 8
mov dword [ebp - 0x58], vtable.WinAESException.0
lea eax, [ebp - 0x58]
push 0x5c7ba8
push eax
call fcn.0051c7b4
test ecx, ecx
jne 0x4688a9
lea eax, [ebp - 0x60]
mov dword [ebp - 0x64], vtable.std::exception.0
push eax
lea eax, [ebp - 0x80]
mov dword [ebp - 0x80], str.SetKey:_Key_buffer_is_NULL
xorps xmm0, xmm0
mov byte [ebp - 0x7c], 1
push eax
movq qword [ebp - 0x60], xmm0
call fcn.0051d791
add esp, 8
mov dword [ebp - 0x64], vtable.WinAESException.0
lea eax, [ebp - 0x64]
push 0x5c7ba8
push eax
call fcn.0051c7b4
mov esi, dword [ebp + 0xc]
cmp esi, 0x10
je 0x4688dc
cmp esi, 0x18
je 0x4688dc
cmp esi, 0x20
je 0x4688dc
push str.SetKey:_Key_size_is_not_valid
lea ecx, [ebp - 0x94]
call fcn.00466bb0
push 0x5c7ba8
lea eax, [ebp - 0x94]
push eax
call fcn.0051c7b4
push 0x2c
lea eax, [ebp - 0x40]
push 0
push eax
call fcn.0051d210
add esp, 0xc
mov dword [ebp - 0x40], 0x208
mov byte [ebp - 4], 1
cmp esi, 0x10
je 0x468943
cmp esi, 0x18
je 0x468935
cmp esi, 0x20
je 0x468927
push str.SetKey:_Key_size_is_not_valid
lea ecx, [ebp - 0xa0]
call fcn.00466bb0
push 0x5c7ba8
lea eax, [ebp - 0xa0]
push eax
call fcn.0051c7b4
mov dword [ebp - 0x3c], 0x6610
mov edx, 0x20
jmp 0x46894f
mov dword [ebp - 0x3c], 0x660f
mov edx, 0x18
jmp 0x46894f
mov dword [ebp - 0x3c], 0x660e
mov edx, 0x10
push esi
push dword [ebp - 0x48]
lea ecx, [ebp - 0x34]
mov dword [ebp - 0x38], edx
call fcn.0046de40
add esp, 8
test eax, eax
je 0x4689ad
lea eax, [ebp - 0x6c]
mov dword [ebp - 0x70], vtable.std::exception.0
push eax
lea eax, [ebp - 0x88]
mov dword [ebp - 0x88], str.SetKey:_Unable_to_copy_key
xorps xmm0, xmm0
mov byte [ebp - 0x84], 1
push eax
movq qword [ebp - 0x6c], xmm0
call fcn.0051d791
add esp, 8
mov dword [ebp - 0x70], vtable.WinAESException.0
lea eax, [ebp - 0x70]
push 0x5c7ba8
push eax
call fcn.0051c7b4
push ebx
push 0
push 0
lea eax, [esi + 0xc]
push eax
lea eax, [ebp - 0x40]
push eax
push dword [edi + 4]
call dword [sym.imp.ADVAPI32.dll_CryptImportKey]
test eax, eax
jne 0x4689e8
push str.SetKey:_Import_key_failed
lea ecx, [ebp - 0xac]
call fcn.00466bb0
push 0x5c7ba8
lea eax, [ebp - 0xac]
push eax
call fcn.0051c7b4
push 0
lea eax, [ebp - 0x48]
mov dword [ebp - 0x48], 1
push eax
push 4
push dword [ebx]
call dword [sym.imp.ADVAPI32.dll_CryptSetKeyParam]
test eax, eax
jne 0x468a45
push str.SetKey:_Set_CBC_mode_failed
lea ecx, [ebp - 0xb8]
call fcn.00466bb0
push 0x5c7ba8
lea eax, [ebp - 0xb8]
push eax
call fcn.0051c7b4
mov eax, dword [ebp - 0x4c]
test byte [eax + 0x14], 0x10
je 0x468a36
push 0
push 0
call fcn.0051c7b4
mov byte [ebp - 0x41], 0
mov eax, 0x468a40
ret
mov al, 1
lea ecx, [ebp - 0x40]
mov edx, 4
nop
mov byte [ecx], 0
lea ecx, [ecx + 1]
sub edx, 1
jne 0x468a50
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004f88bd
mov esp, ebp
pop ebp
ret 8