Function at 0x40dae0
Capabilities:
Encrypt or decrypt via wincrypt

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5d05c5
mov eax, dword fs:[0]
push eax
sub esp, 0x24
mov eax, dword [0x655140]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
cmp dword [ebx], 0
mov eax, dword [ebp + 8]
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x28], ecx
je 0x40dcf4
cmp dword [ebx + 4], 0
je 0x40dcf4
xorps xmm0, xmm0
mov dword [ebp - 0x18], 0
movq qword [ebp - 0x20], xmm0
mov dword [ebp - 0x20], vtable.CxAutoArray_unsigned_char_.0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0
mov dword [ebp - 4], 0
mov ecx, dword [eax + 4]
test ecx, ecx
je 0x40db72
mov esi, dword [eax + 8]
test esi, esi
jne 0x40db74
push ecx
call fcn.004c9902
add esp, 4
mov esi, eax
jmp 0x40db74
xor esi, esi
xor eax, eax
mov ecx, esi
shld eax, ecx, 1
add ecx, ecx
mov dword [ebp - 0x2c], eax
push ecx
call fcn.004b44b4
mov edi, eax
mov eax, dword [ebp - 0x24]
push esi
push dword [eax + 4]
push edi
call fcn.004b63f0
add esp, 0x10
mov dword [ebp - 0x14], esi
lea eax, [ebp - 0x14]
push eax
push edi
push 0
push 1
push 0
push dword [ebx + 4]
call dword [sym.imp.ADVAPI32.dll_CryptDecrypt]
test eax, eax
jne 0x40dbc6
push edi
call fcn.004b44af
add esp, 4
xor edi, edi
mov eax, edi
jmp 0x40dcf6
mov esi, dword [ebp - 0x14]
push esi
call fcn.004b44b4
push esi
mov ebx, eax
push 0
push ebx
mov dword [ebp - 0x1c], ebx
call fcn.004b69d0
push dword [ebp - 0x14]
mov dword [ebp - 0x18], esi
push edi
push ebx
call fcn.004b63f0
push edi
call fcn.004b44af
add esp, 0x20
test esi, esi
jne 0x40dc02
push ebx
call fcn.004c9902
add esp, 4
mov esi, eax
shr esi, 1
call fcn.00402de0
mov ecx, eax
test ecx, ecx
je 0x40dd14
mov eax, dword [ecx]
push 2
push esi
call dword [eax]
mov edi, eax
test edi, edi
je 0x40dd1e
lea ebx, [edi + 0x10]
mov dword [ebp - 0x2c], ebx
cmp esi, dword [ebx - 8]
jg 0x40dd23
mov dword [ebx - 0xc], esi
xor eax, eax
add esi, esi
mov word [esi + ebx], ax
test esi, esi
je 0x40dc56
test ebx, ebx
jne 0x40dcae
call fcn.004c0f54
mov dword [eax], 0x16
call fcn.004c0e56
mov esi, dword [ebp - 0x1c]
mov edx, dword [ebp - 0x28]
or eax, 0xffffffff
mov byte [ebp - 4], 1
mov ecx, dword [edx]
sub ecx, 0x10
mov dword [ebp - 0x14], ecx
cmp edi, ecx
je 0x40dccc
cmp dword [ecx + 0xc], 0
lea eax, [ecx + 0xc]
mov dword [ebp - 0x24], eax
jl 0x40dcbe
mov eax, dword [edi]
cmp eax, dword [ecx]
jne 0x40dcbe
mov ecx, edi
call fcn.00408e50
mov edx, dword [ebp - 0x24]
mov ebx, eax
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40dca4
mov eax, dword [ebp - 0x14]
push eax
mov ecx, dword [eax]
mov edx, dword [ecx]
call dword [edx + 4]
mov ecx, dword [ebp - 0x28]
lea eax, [ebx + 0x10]
mov dword [ecx], eax
jmp 0x40dcc9
push esi
mov esi, dword [ebp - 0x1c]
push esi
push ebx
call fcn.004b63f0
add esp, 0xc
jmp 0x40dc59
push dword [ebx - 0xc]
mov ecx, edx
push ebx
call fcn.00408fa0
or eax, 0xffffffff
mov byte [ebp - 4], 0
lock xadd dword [edi + 0xc], eax
dec eax
test eax, eax
jg 0x40dce2
mov ecx, dword [edi]
push edi
mov eax, dword [ecx]
call dword [eax + 4]
push esi
mov edi, 1
call fcn.004b44af
add esp, 4
mov eax, edi
jmp 0x40dcf6
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004b3f1a
mov esp, ebp
pop ebp
ret 8
push 0x80004005
call fcn.00402a80
call fcn.00408f90
push 0x80070057
call fcn.00402a80
int3