Function at 0x41b920
Capabilities:
Encrypt or decrypt via wincrypt

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x78
push esi
push edi
lea edi, [ebp - 0x78]
mov ecx, 0x1e
mov eax, 0xcccccccc
rep stosd dword es:[edi], eax
mov dword [ebp - 8], 0
mov dword [ebp - 0x10], 0
push 0x98
call fcn.0040c404
add esp, 4
mov dword [ebp - 0x64], eax
mov eax, dword [ebp - 0x64]
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x24], 0x80
mov dword [ebp - 0x2c], 1
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x38], 0
mov edi, dword [ebp + 8]
lea esi, [ebp - 0x4c]
call fcn.00404c40
mov esi, esp
push 0
push 1
push 0
push 0
lea ecx, [ebp - 8]
push ecx
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextA]
cmp esi, esp
call fcn.0041f4fc
mov dword [ebp - 0x38], eax
cmp dword [ebp - 0x38], 0
jne 0x41b9d9
mov esi, esp
push 0xf0000008
push 1
push 0
push 0
lea edx, [ebp - 8]
push edx
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextA]
cmp esi, esp
call fcn.0041f4fc
mov dword [ebp - 0x38], eax
cmp dword [ebp - 0x38], 0
jne 0x41b9d9
jmp 0x41bb7a
mov eax, dword [ebp - 0x14]
mov byte [eax], 6
mov ecx, dword [ebp - 0x14]
mov byte [ecx + 1], 2
mov edx, dword [ebp - 0x14]
mov dword [edx + 4], 0xa400
xor eax, eax
mov ecx, dword [ebp - 0x14]
mov word [ecx + 2], ax
mov edx, dword [ebp - 0x14]
mov dword [edx + 0xc], 0x400
mov eax, dword [ebp - 0x14]
mov dword [eax + 8], 0x31415352
mov ecx, dword [ebp - 0x14]
mov dword [ecx + 0x10], 0x10001
push 0x80
mov edx, dword [ebp + 0xc]
mov eax, dword [edx]
mov esi, esp
mov ecx, dword [ebp + 0xc]
mov edx, dword [eax + 0x98]
call edx
cmp esi, esp
call fcn.0041f4fc
push eax
mov eax, dword [ebp - 0x14]
add eax, 0x14
push eax
call fcn.0040e410
add esp, 0xc
mov esi, esp
lea ecx, [ebp - 0x1c]
push ecx
push 0
push 0
push 0x98
mov edx, dword [ebp - 0x14]
push edx
mov eax, dword [ebp - 8]
push eax
call dword [sym.imp.ADVAPI32.dll_CryptImportKey]
cmp esi, esp
call fcn.0041f4fc
test eax, eax
jne 0x41ba72
jmp 0x41bb7a
mov esi, esp
push 0
lea ecx, [ebp - 0x2c]
push ecx
push 3
mov edx, dword [ebp - 0x1c]
push edx
call dword [sym.imp.ADVAPI32.dll_CryptSetKeyParam]
cmp esi, esp
call fcn.0041f4fc
test eax, eax
jne 0x41ba96
jmp 0x41bb7a
lea ecx, [ebp - 0x4c]
call fcn.00405eb0
push 0x100
call fcn.0040c404
add esp, 4
mov dword [ebp - 0x68], eax
mov eax, dword [ebp - 0x68]
mov dword [ebp - 0x54], eax
lea ecx, [ebp - 0x4c]
call fcn.00407600
push eax
lea ecx, [ebp - 0x4c]
call fcn.004075f0
push eax
mov ecx, dword [ebp - 0x54]
push ecx
call fcn.0040e410
add esp, 0xc
mov edx, dword [ebp + 8]
mov eax, dword [edx]
mov esi, esp
mov ecx, dword [ebp + 8]
mov edx, dword [eax + 0x9c]
call edx
cmp esi, esp
call fcn.0041f4fc
mov dword [ebp - 0x5c], eax
mov esi, esp
mov eax, dword [ebp - 0x24]
push eax
lea ecx, [ebp - 0x5c]
push ecx
mov edx, dword [ebp - 0x54]
push edx
push 0
push 1
push 0
mov eax, dword [ebp - 0x1c]
push eax
call dword [sym.imp.ADVAPI32.dll_CryptEncrypt]
cmp esi, esp
call fcn.0041f4fc
test eax, eax
jne 0x41bb2d
mov ecx, dword [ebp - 0x54]
mov dword [ebp - 0x6c], ecx
mov edx, dword [ebp - 0x6c]
push edx
call fcn.0040c1dc
add esp, 4
jmp 0x41bb7a
mov eax, dword [ebp + 0x10]
mov edx, dword [eax]
mov esi, esp
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x50]
call eax
cmp esi, esp
call fcn.0041f4fc
mov esi, esp
mov ecx, dword [ebp - 0x5c]
push ecx
mov edx, dword [ebp - 0x54]
push edx
mov eax, dword [ebp + 0x10]
mov edx, dword [eax]
mov ecx, dword [ebp + 0x10]
mov eax, dword [edx + 0x10]
call eax
cmp esi, esp
call fcn.0041f4fc
mov ecx, dword [ebp - 0x54]
mov dword [ebp - 0x70], ecx
mov edx, dword [ebp - 0x70]
push edx
call fcn.0040c1dc
add esp, 4
mov dword [ebp - 0x34], 1
cmp dword [ebp - 0x14], 0
je 0x41bb92
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x74], eax
mov ecx, dword [ebp - 0x74]
push ecx
call fcn.0040c1dc
add esp, 4
cmp dword [ebp - 0x1c], 0
je 0x41bbb2
mov esi, esp
mov edx, dword [ebp - 0x1c]
push edx
call dword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
cmp esi, esp
call fcn.0041f4fc
mov dword [ebp - 0x1c], 0
cmp dword [ebp - 8], 0
je 0x41bbd4
mov esi, esp
push 0
mov eax, dword [ebp - 8]
push eax
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
cmp esi, esp
call fcn.0041f4fc
mov dword [ebp - 8], 0
mov ecx, dword [ebp - 0x34]
mov dword [ebp - 0x78], ecx
lea ecx, [ebp - 0x4c]
call fcn.00404dd0
mov eax, dword [ebp - 0x78]
push edx
mov ecx, ebp
push eax
lea edx, [0x41bc08]
call fcn.0041f51f
pop eax
pop edx
pop edi
pop esi
add esp, 0x78
cmp ebp, esp
call fcn.0041f4fc
mov esp, ebp
pop ebp
ret