Function at 0x402f40
Capabilities:
Encrypt or decrypt via wincrypt

Disassembly:
push 0xffffffffffffffff
push 0x40e831
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x40
push ebx
push ebp
mov dword [esp + 0x14], 0
mov eax, dword [esp + 0x60]
push esi
push edi
mov ebp, ecx
lea edx, [eax + 1]
lea ecx, [ecx]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x402f70
sub eax, edx
mov esi, eax
push esi
mov dword [esp + 0x28], esi
call sub.MSVCR71.dll_void____cdecl_operator_new___unsigned_int_
add esp, 4
lea ecx, [esp + 0x30]
mov edi, eax
call fcn.0040dab0
push esi
mov ebx, 1
push edi
lea ecx, [esp + 0x38]
mov dword [esp + 0x60], ebx
call fcn.0040db40
mov ecx, dword [esp + 0x68]
lea eax, [esp + 0x24]
push eax
push edi
push esi
push ecx
call fcn.00401580
mov edx, dword [ebp + 0xc]
push edx
lea eax, [esp + 0x2c]
push eax
call fcn.00405890
add esp, 0x18
xor esi, esi
mov dword [esp + 0x10], esi
mov ecx, dword [esp + 0x18]
push 0x20
push ebx
push str.Microsoft_Enhanced_Cryptographic_Provider_v1.0
push ecx
lea edx, [esp + 0x20]
push edx
mov byte [esp + 0x6c], 3
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextA]
test eax, eax
jne 0x403009
mov esi, dword [esp + 0x60]
push 0x410480
mov ecx, esi
call fcn.00402b40
mov dword [esp + 0x1c], ebx
jmp 0x4031d9
mov dword [esp + 0x14], esi
mov ecx, dword [esp + 0x10]
lea eax, [esp + 0x14]
push eax
push ebx
push ecx
mov byte [esp + 0x64], 4
call dword [sym.imp.ADVAPI32.dll_CryptGetUserKey]
test eax, eax
jne 0x403040
mov esi, dword [esp + 0x60]
push 0x410480
mov ecx, esi
call fcn.00402b40
mov dword [esp + 0x1c], ebx
jmp 0x403128
mov dword [esp + 0x20], esi
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x24]
lea eax, [esp + 0x20]
push eax
mov eax, dword [esp + 0x14]
push esi
push ecx
push edx
push edi
push eax
mov byte [esp + 0x70], 5
call dword [sym.imp.ADVAPI32.dll_CryptImportKey]
test eax, eax
jne 0x403082
mov esi, dword [esp + 0x60]
push 0x410480
mov ecx, esi
call fcn.00402b40
mov dword [esp + 0x1c], ebx
jmp 0x4031bd
mov ebp, dword [esp + 0x64]
mov eax, ebp
lea edx, [eax + 1]
jmp 0x403090
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x403090
sub eax, edx
mov edi, eax
lea eax, [edi + 1]
push eax
mov dword [esp + 0x6c], edi
call sub.MSVCR71.dll_void____cdecl_operator_new___unsigned_int_
add esp, 4
lea ecx, [esp + 0x40]
mov esi, eax
call fcn.0040dab0
push edi
push esi
lea ecx, [esp + 0x48]
mov byte [esp + 0x60], 6
call fcn.0040db40
lea ecx, [esp + 0x68]
push ecx
push esi
push edi
push ebp
call fcn.00401580
mov ecx, dword [esp + 0x30]
mov edx, dword [esp + 0x78]
add esp, 0x10
lea eax, [esp + 0x28]
push eax
push esi
push 0
push ebx
push 0
push ecx
mov dword [esp + 0x40], edx
call dword [sym.imp.ADVAPI32.dll_CryptDecrypt]
test eax, eax
jne 0x403161
mov esi, dword [esp + 0x60]
push 0x410480
mov ecx, esi
call fcn.00402b40
lea ecx, [esp + 0x40]
mov dword [esp + 0x1c], ebx
mov byte [esp + 0x58], 5
call fcn.0040dad0
lea ecx, [esp + 0x20]
mov byte [esp + 0x58], 4
call fcn.0040d950
lea ecx, [esp + 0x14]
mov byte [esp + 0x58], 3
call fcn.0040d950
lea ecx, [esp + 0x10]
mov byte [esp + 0x58], 2
call fcn.0040d910
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
mov byte [esp + 0x58], bl
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jmp 0x4031ff
mov eax, dword [esp + 0x28]
push esi
lea ecx, [esp + 0x30]
mov byte [eax + esi], 0
call fcn.00402b40
mov esi, dword [esp + 0x60]
lea ecx, [esp + 0x2c]
push ecx
mov ecx, esi
mov byte [esp + 0x5c], 7
call fcn.00402410
mov eax, dword [esp + 0x2c]
add eax, 0xfffffff0
mov dword [esp + 0x1c], ebx
mov byte [esp + 0x58], 6
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x4031af
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea ecx, [esp + 0x40]
mov byte [esp + 0x58], 5
call fcn.0040dad0
lea ecx, [esp + 0x20]
mov byte [esp + 0x58], 4
call fcn.0040d950
lea ecx, [esp + 0x14]
mov byte [esp + 0x58], 3
call fcn.0040d950
lea ecx, [esp + 0x10]
mov byte [esp + 0x58], 2
call fcn.0040d910
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
mov byte [esp + 0x58], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x403209
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
call dword [edx + 4]
lea ecx, [esp + 0x30]
mov byte [esp + 0x58], 0
call fcn.0040dad0
mov ecx, dword [esp + 0x50]
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x4c
ret 0xc