Function at 0x43cc40
Capabilities:
Encrypt or decrypt via wincrypt
Reference public rsa key

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x48
cmp dword [ebp + 8], 0
je 0x43cc52
cmp dword [ebp + 0xc], 0
ja 0x43cc59
xor eax, eax
jmp 0x43ce75
mov dword [ebp - 8], 0
call fcn.00431500
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
je 0x43ce72
mov dword [ebp - 0xc], 0
cmp dword [ebp + 0x14], 0
je 0x43cc85
cmp dword [ebp + 0x18], 0
jne 0x43cc93
mov dword [ebp + 0x14], 0x4d9568
mov dword [ebp + 0x18], 0x94
lea eax, [ebp - 0xc]
push eax
push 0
push 0
mov ecx, dword [ebp + 0x18]
push ecx
mov edx, dword [ebp + 0x14]
push edx
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.ADVAPI32.dll_CryptImportKey]
test eax, eax
je 0x43ce66
xor ecx, ecx
jne 0x43ccb5
mov edx, dword [ebp - 0xc]
push edx
call fcn.0043cc00
add esp, 4
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x20]
sub eax, 0xb
mov dword [ebp - 0x24], eax
mov eax, dword [ebp + 0xc]
sub eax, 1
xor edx, edx
div dword [ebp - 0x24]
add eax, 1
imul eax, dword [ebp - 0x20]
mov dword [ebp - 0x14], eax
mov ecx, dword [ebp - 0x14]
push ecx
call fcn.00498670
add esp, 4
mov dword [ebp - 0x38], eax
mov edx, dword [ebp - 0x38]
mov dword [ebp - 8], edx
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0
mov eax, dword [ebp - 0x20]
push eax
call fcn.00498670
add esp, 4
mov dword [ebp - 0x3c], eax
mov ecx, dword [ebp - 0x3c]
mov dword [ebp - 0x10], ecx
mov edx, 1
test edx, edx
je 0x43cdee
mov eax, dword [ebp + 0xc]
sub eax, dword [ebp - 0x1c]
cmp dword [ebp - 0x24], eax
sbb ecx, ecx
add ecx, 1
mov byte [ebp - 0x29], cl
movzx edx, byte [ebp - 0x29]
test edx, edx
je 0x43cd4f
mov eax, dword [ebp + 0xc]
sub eax, dword [ebp - 0x1c]
mov dword [ebp - 0x48], eax
jmp 0x43cd55
mov ecx, dword [ebp - 0x24]
mov dword [ebp - 0x48], ecx
mov edx, dword [ebp - 0x48]
mov dword [ebp - 0x28], edx
mov eax, dword [ebp - 0x28]
push eax
mov ecx, dword [ebp + 8]
add ecx, dword [ebp - 0x1c]
push ecx
mov edx, dword [ebp - 0x10]
push edx
call fcn.0049c670
add esp, 0xc
mov eax, dword [ebp - 0x1c]
add eax, dword [ebp - 0x28]
mov dword [ebp - 0x1c], eax
mov ecx, dword [ebp - 0x20]
push ecx
lea edx, [ebp - 0x28]
push edx
mov eax, dword [ebp - 0x10]
push eax
push 0
movzx ecx, byte [ebp - 0x29]
push ecx
push 0
mov edx, dword [ebp - 0xc]
push edx
call dword [sym.imp.ADVAPI32.dll_CryptEncrypt]
test eax, eax
je 0x43cdc4
mov eax, dword [ebp - 0x28]
push eax
mov ecx, dword [ebp - 0x10]
push ecx
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0x18]
push edx
call fcn.0049c670
add esp, 0xc
mov eax, dword [ebp - 0x18]
add eax, dword [ebp - 0x28]
mov dword [ebp - 0x18], eax
xor ecx, ecx
jne 0x43cdbe
jmp 0x43cddf
mov edx, dword [ebp - 8]
mov dword [ebp - 0x40], edx
mov eax, dword [ebp - 0x40]
push eax
call fcn.00498355
add esp, 4
mov dword [ebp - 8], 0
jmp 0x43cdee
movzx ecx, byte [ebp - 0x29]
test ecx, ecx
je 0x43cde9
jmp 0x43cdee
jmp 0x43cd1e
mov edx, dword [ebp - 0x10]
mov dword [ebp - 0x44], edx
mov eax, dword [ebp - 0x44]
push eax
call fcn.00498355
add esp, 4
cmp dword [ebp - 8], 0
je 0x43ce5c
mov ecx, dword [ebp + 0x10]
mov edx, dword [ebp - 0x18]
mov dword [ecx], edx
mov dword [ebp - 0x30], 0
jmp 0x43ce20
mov eax, dword [ebp - 0x30]
add eax, 1
mov dword [ebp - 0x30], eax
mov ecx, dword [ebp - 0x18]
shr ecx, 1
cmp dword [ebp - 0x30], ecx
jae 0x43ce5c
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0x30]
mov al, byte [edx]
mov byte [ebp - 0x31], al
mov ecx, dword [ebp - 0x18]
sub ecx, dword [ebp - 0x30]
mov edx, dword [ebp - 8]
add edx, dword [ebp - 0x30]
mov eax, dword [ebp - 8]
mov cl, byte [eax + ecx - 1]
mov byte [edx], cl
mov edx, dword [ebp - 0x18]
sub edx, dword [ebp - 0x30]
mov eax, dword [ebp - 8]
mov cl, byte [ebp - 0x31]
mov byte [eax + edx - 1], cl
jmp 0x43ce17
mov edx, dword [ebp - 0xc]
push edx
call dword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
push 0
mov eax, dword [ebp - 4]
push eax
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov eax, dword [ebp - 8]
mov esp, ebp
pop ebp
ret