Function at 0x425450
Capabilities:
Encrypt or decrypt via wincrypt

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
push 0
lea eax, [ebp - 0x20]
mov dword [ebp - 8], 1
push eax
lea eax, [ebp - 8]
mov byte [ebp - 1], 1
push eax
mov ebx, ecx
mov dword [ebp - 0x20], 4
push 8
push ebx
mov esi, edx
mov dword [ebp - 0x14], ebx
call dword [sym.imp.ADVAPI32.dll_CryptGetKeyParam]
test eax, eax
jne 0x425492
xor al, al
mov byte [ebp - 1], al
jmp 0x425612
mov ecx, dword [ebp - 8]
shr ecx, 3
mov dword [ebp - 8], ecx
mov ebx, ecx
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x20], ecx
mov dword [ebp - 0x1c], ecx
push edi
mov edi, ecx
test ecx, ecx
jne 0x4254c6
mov ecx, 1
mov dword [ebp - 8], 1
mov dword [ebp - 0x18], ecx
mov edi, ecx
mov dword [ebp - 0x20], ecx
mov ebx, ecx
mov dword [ebp - 0x1c], ecx
mov eax, dword [esi + 0x10]
xor edx, edx
mov dword [ebp - 0xc], eax
div ecx
xor edx, edx
mov ecx, eax
mov eax, dword [ebp - 0xc]
div dword [ebp - 0x18]
test edx, edx
je 0x4254e1
inc ecx
test edx, edx
cmove ebx, dword [ebp - 0x1c]
test edx, edx
cmove edi, dword [ebp - 0x20]
cmp dword [esi + 0x14], 0xf
jbe 0x425506
mov eax, dword [esi]
lea edx, [esi + 0x10]
imul ecx, ebx
mov edi, eax
mov dword [ebp - 0x20], edx
sub ecx, dword [ebp - 0xc]
add eax, dword [ebp - 0xc]
jmp 0x425518
imul ecx, edi
lea eax, [esi + 0x10]
mov dword [ebp - 0x20], eax
mov edi, esi
mov eax, dword [ebp - 0xc]
sub ecx, eax
add eax, esi
push 0
push ecx
sub eax, edi
mov ecx, esi
push eax
call fcn.00426050
mov ecx, 0x3e8
xor edx, edx
mov eax, ecx
xor ebx, ebx
div dword [ebp - 8]
sub ecx, edx
xor edi, edi
mov dword [ebp - 0x10], ecx
nop word [eax + eax]
mov eax, dword [ebp - 0xc]
sub eax, edi
cmp eax, ecx
jg 0x425551
mov dword [ebp - 0x10], eax
mov ebx, 1
cmp byte [ebp + 8], 0
mov ecx, esi
mov eax, dword [esi + 0x14]
je 0x425583
cmp eax, 0xf
jbe 0x425563
mov ecx, dword [esi]
mov eax, dword [ebp - 0x20]
mov eax, dword [eax]
sub eax, edi
push eax
lea eax, [ebp - 0x10]
push eax
lea eax, [ecx + edi]
push eax
push 0
push ebx
push 0
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_CryptEncrypt]
jmp 0x4255a0
cmp eax, 0xf
jbe 0x42558a
mov ecx, dword [esi]
lea eax, [ebp - 0x10]
push eax
lea eax, [ecx + edi]
push eax
push 0
push ebx
push 0
push dword [ebp - 0x14]
call dword [sym.imp.ADVAPI32.dll_CryptDecrypt]
test eax, eax
je 0x4255af
mov ecx, dword [ebp - 0x10]
add edi, ecx
test ebx, ebx
je 0x425540
jmp 0x4255b4
xor al, al
mov byte [ebp - 1], al
mov ecx, dword [esi + 0x10]
cmp edi, ecx
ja 0x4255cc
mov dword [esi + 0x10], edi
cmp dword [esi + 0x14], 0xf
jbe 0x4255c6
mov esi, dword [esi]
mov byte [esi + edi], 0
jmp 0x42560b
mov edx, dword [esi + 0x14]
mov ebx, edi
mov eax, edx
sub ebx, ecx
sub eax, ecx
cmp ebx, eax
ja 0x4255f9
mov dword [esi + 0x10], edi
cmp edx, 0xf
jbe 0x4255e5
mov esi, dword [esi]
push ebx
add esi, ecx
push 0
push esi
call fcn.0048fce0
add esp, 0xc
mov byte [esi + ebx], 0
jmp 0x42560b
push 0
push ebx
mov byte [ebp - 0x20], 0
mov ecx, esi
push dword [ebp - 0x20]
push ebx
call fcn.00426430
mov ebx, dword [ebp - 0x14]
mov al, byte [ebp - 1]
pop edi
test ebx, ebx
je 0x425620
push ebx
call dword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
mov al, byte [ebp - 1]
pop esi
pop ebx
mov esp, ebp
pop ebp
ret