Function at 0x4014c0
Capabilities:
Encrypt or decrypt via wincrypt

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, dword [0x41c008]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push 0xf0000000
push 1
push 0
push 0
lea eax, [ebp - 8]
push eax
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextA]
lea eax, [ebp - 0xc]
push eax
push 0x4000001
push 0xa400
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_CryptGenKey]
mov eax, dword [ebp - 0xc]
push 0xc00
mov dword [0x41d350], eax
call fcn.00403f74
add esp, 4
mov dword [ebp - 0x14], 0xc00
mov ebx, eax
lea eax, [ebp - 0x14]
mov dword [ebp - 0x20], ebx
push eax
push ebx
push 0
push 7
push 0
push dword [0x41d350]
call dword [sym.imp.ADVAPI32.dll_CryptExportKey]
test eax, eax
jne 0x401553
push ebx
call fcn.00403f7d
add esp, 4
xor al, al
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00403d68
mov esp, ebp
pop ebp
ret
push esi
push edi
mov edi, dword [ebp - 0x14]
shr edi, 2
push 0xc00
mov dword [ebp - 8], edi
call fcn.00403f74
add esp, 4
mov ebx, eax
mov eax, dword [ebp - 0x20]
xor esi, esi
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0xc], esi
mov dword [ebp - 0x18], eax
nop dword [eax + eax]
push 0xc00
mov dword [ebp - 0x10], edi
call fcn.00403f74
mov edx, dword [ebp - 8]
add esp, 4
mov edi, eax
test edx, edx
je 0x4015b1
mov ebx, dword [ebp - 0x18]
mov ecx, edi
sub ebx, edi
mov al, byte [ebx + ecx]
lea ecx, [ecx + 1]
mov byte [ecx - 1], al
sub edx, 1
jne 0x4015a0
mov ebx, dword [ebp - 0x1c]
push 0xc00
lea eax, [ebp - 0x10]
push eax
push edi
push 0
push 1
push 0
push dword [0x41d344]
call dword [sym.imp.ADVAPI32.dll_CryptEncrypt]
test eax, eax
je 0x4016f2
mov edx, dword [ebp - 0x10]
xor ecx, ecx
test edx, edx
je 0x4015ec
nop
mov al, byte [ecx + edi]
inc ecx
mov byte [esi + ebx], al
inc esi
cmp ecx, edx
jb 0x4015e0
push edi
call fcn.00403f7d
mov eax, dword [ebp - 0xc]
add esp, 4
mov edi, dword [ebp - 8]
inc eax
add dword [ebp - 0x18], edi
mov dword [ebp - 0xc], eax
cmp eax, 4
jl 0x401580
push dword [ebp - 0x20]
call fcn.00403f7d
lea eax, [esi + 1]
mov dword [0x41c880], esi
push eax
mov dword [ebp - 0x14], esi
call fcn.00403f74
mov edi, eax
add esp, 8
test edi, edi
je 0x401642
lea eax, [esi + 1]
push eax
push 0
push edi
call fcn.00405470
add esp, 0xc
mov byte [edi], 0
jmp 0x401644
xor edi, edi
test esi, esi
jle 0x401662
mov dword [ebp - 8], ebx
mov ecx, edi
sub ebx, edi
mov edx, esi
mov al, byte [ebx + ecx]
lea ecx, [ecx + 1]
mov byte [ecx - 1], al
sub edx, 1
jne 0x401651
mov ebx, dword [ebp - 0x1c]
mov byte [edi + esi], 0
mov ecx, ebx
mov edx, dword [ebp - 0x14]
push str.local_enc_private_key
mov dword [0x41d340], edi
call fcn.00401fa0
add esp, 4
test al, al
je 0x4016d6
lea eax, [ebp - 0x14]
mov dword [ebp - 0x14], 0xc00
push eax
push ebx
push 0
push 6
push 0
push dword [0x41d350]
call dword [sym.imp.ADVAPI32.dll_CryptExportKey]
test eax, eax
je 0x4016d6
mov edx, dword [ebp - 0x14]
mov ecx, ebx
push str.local_public_key
call fcn.00401fa0
push dword [ebp - 0x1c]
mov bl, al
call fcn.00403f7d
add esp, 8
test bl, bl
setne al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00403d68
mov esp, ebp
pop ebp
ret
push ebx
call fcn.00403f7d
add esp, 4
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00403d68
mov esp, ebp
pop ebp
ret
push dword [ebp - 0x20]
call fcn.00403f7d
push ebx
call fcn.00403f7d
push edi
call fcn.00403f7d
mov ecx, dword [ebp - 4]
add esp, 0xc
xor ecx, ebp
xor al, al
pop edi
pop esi
pop ebx
call fcn.00403d68
mov esp, ebp
pop ebp
ret