Function at 0x1005e540
Capabilities:
Encrypt data using dpapi

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x100e7b38
mov eax, dword fs:[0]
push eax
sub esp, 0x90
push ebx
push esi
push edi
mov eax, dword [0x1013d0b0]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov esi, dword [ebp + 8]
push 0xcaa1001a
push esi
call fcn.1003c680
push 2
push 0x100ffa04
push esi
call fcn.1001311a
add esp, 0x14
test eax, eax
jne 0x1005e882
lea eax, [esi + 4]
push eax
lea ecx, [ebp - 0x30]
call fcn.1005e290
mov eax, dword [ebp - 0x30]
mov dword [ebp - 4], 0
mov eax, dword [eax - 0xc]
mov dword [ebp - 0x40], eax
test eax, eax
je 0x1005e89d
lea ecx, [ebp - 0x29]
push ecx
push eax
lea ecx, [ebp - 0x54]
call fcn.1005e4a0
mov esi, dword [ebp - 0x30]
mov edi, dword [ebp - 0x54]
mov ecx, edi
mov byte [ebp - 4], 1
mov dword [ebp - 0x34], edi
mov eax, dword [esi - 0xc]
mov dword [ebp - 0x38], ecx
test esi, esi
je 0x1005e861
xor edx, edx
add eax, esi
xor ebx, ebx
mov dword [ebp - 0x3c], eax
test ecx, ecx
mov dword [ebp - 0x1c], ebx
sete dl
mov dword [ebp - 0x18], edx
cmp esi, eax
jae 0x1005e6e8
nop
cmp byte [esi], 0
je 0x1005e6e5
xor edi, edi
xor ebx, ebx
xor edx, edx
nop
cmp esi, eax
jae 0x1005e66d
movsx eax, byte [esi]
lea ecx, [eax - 0x41]
cmp ecx, 0x19
ja 0x1005e627
lea ecx, [eax - 0x41]
jmp 0x1005e72f
lea ecx, [eax - 0x61]
cmp ecx, 0x19
ja 0x1005e637
lea ecx, [eax - 0x47]
jmp 0x1005e72f
lea ecx, [eax - 0x30]
cmp ecx, 9
ja 0x1005e647
lea ecx, [eax + 4]
jmp 0x1005e72f
cmp eax, 0x2b
jne 0x1005e71f
mov ecx, 0x3e
inc esi
shl edi, 6
or edi, ecx
inc edx
lea eax, [ebx + 6]
cmp ecx, 0xffffffff
cmovne ebx, eax
mov eax, dword [ebp - 0x3c]
cmp edx, 4
jl 0x1005e610
mov edx, dword [ebp - 0x18]
mov dword [ebp - 0x14], esi
test edx, edx
jne 0x1005e696
mov eax, ebx
test eax, eax
jns 0x1005e680
add eax, 7
sar eax, 3
mov ecx, dword [ebp - 0x1c]
add ecx, eax
mov eax, 1
cmp ecx, dword [ebp - 0x40]
cmovg edx, eax
mov dword [ebp - 0x18], edx
mov eax, ebx
mov ecx, 0x18
cdq
sub ecx, ebx
mov ebx, dword [ebp - 0x1c]
and edx, 7
shl edi, cl
lea ecx, [edx + eax]
mov edx, dword [ebp - 0x18]
sar ecx, 3
test ecx, ecx
jle 0x1005e6da
mov esi, dword [ebp - 0x38]
add ebx, ecx
mov dword [ebp - 0x1c], ebx
nop dword [eax]
test edx, edx
jne 0x1005e6cc
mov eax, edi
shr eax, 0x10
mov byte [esi], al
inc esi
shl edi, 8
sub ecx, 1
jne 0x1005e6c0
mov dword [ebp - 0x38], esi
mov esi, dword [ebp - 0x14]
mov eax, dword [ebp - 0x3c]
cmp esi, eax
jb 0x1005e600
mov edi, dword [ebp - 0x34]
test edx, edx
jne 0x1005e861
lea eax, [ebp - 0x28]
mov dword [ebp - 0x48], ebx
push eax
push 1
push edx
push edx
push 0x1013db78
push edx
lea eax, [ebp - 0x48]
mov dword [ebp - 0x44], edi
xorps xmm0, xmm0
push eax
movlpd qword [ebp - 0x28], xmm0
call sub.CRYPT32.dll_CryptUnprotectData
test eax, eax
je 0x1005e8b8
jmp 0x1005e73f
cmp eax, 0x2f
jne 0x1005e72c
lea ecx, [eax + 0x10]
jmp 0x1005e655
or ecx, 0xffffffff
inc esi
cmp ecx, 0xffffffff
jne 0x1005e656
dec edx
jmp 0x1005e65b
mov ecx, dword [ebp - 0x28]
mov byte [ebp - 4], 2
cmp ecx, 4
jb 0x1005e8d5
xor esi, esi
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x20], esi
mov eax, dword [ebp - 0x24]
mov byte [ebp - 4], 3
cmp dword [eax], 1
jne 0x1005e795
push ecx
push eax
lea eax, [ebp - 0x34]
push eax
call fcn.1005eb50
lea ecx, [ebp - 0x20]
add esp, 0xc
cmp ecx, eax
je 0x1005e787
mov esi, dword [eax]
mov dword [eax], 0
mov dword [ebp - 0x20], esi
lea ecx, [ebp - 0x34]
call fcn.10025e90
mov eax, dword [ebp - 0x24]
mov ecx, dword [ebp - 0x28]
test ecx, ecx
je 0x1005e7ae
nop dword [eax]
mov byte [eax], 0
lea eax, [eax + 1]
sub ecx, 1
jne 0x1005e7a0
mov eax, dword [ebp - 0x24]
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
test esi, esi
je 0x1005e8f6
lea ecx, [esi + 0x2c]
push esi
call fcn.10050a00
lea ecx, [ebp - 0x20]
mov dword [ebp - 0x20], 0
call fcn.10025e90
test edi, edi
je 0x1005e806
mov ecx, dword [ebp - 0x4c]
mov eax, edi
sub ecx, edi
cmp ecx, 0x1000
jb 0x1005e7fc
mov edi, dword [edi - 4]
add ecx, 0x23
sub eax, edi
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x1005e917
push ecx
push edi
call fcn.10005291
add esp, 8
mov ecx, dword [ebp - 0x30]
or eax, 0xffffffff
add ecx, 0xfffffff0
lock xadd dword [ecx + 0xc], eax
dec eax
test eax, eax
jg 0x1005e82d
mov ebx, dword [ecx]
push ecx
mov eax, dword [ebx]
mov edi, dword [eax + 4]
mov ecx, edi
call dword [0x100f4524]
mov ecx, ebx
call edi
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0xcaa40001
lea ecx, [ebp - 0x9c]
call fcn.100043d0
push 0x1012ad98
lea eax, [ebp - 0x9c]
push eax
call fcn.10006a50
push 0xcaa40001
lea ecx, [ebp - 0x60]
call fcn.100043d0
push 0x1012ad98
lea eax, [ebp - 0x60]
push eax
call fcn.10006a50
push 0xcaa40001
lea ecx, [ebp - 0x6c]
call fcn.100043d0
push 0x1012ad98
lea eax, [ebp - 0x6c]
push eax
call fcn.10006a50
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea ecx, [ebp - 0x78]
call fcn.10004b50
push 0x10126738
lea eax, [ebp - 0x78]
push eax
call fcn.10006a50
push 0xcaa40001
lea ecx, [ebp - 0x84]
call fcn.100043d0
push 0x1012ad98
lea eax, [ebp - 0x84]
push eax
call fcn.10006a50
push 0xcaa40001
lea ecx, [ebp - 0x90]
call fcn.100043d0
push 0x1012ad98
lea eax, [ebp - 0x90]
push eax
call fcn.10006a50
call fcn.1000e987
mov eax, dword [ebp - 0x24]
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
push 0
push 0
call fcn.10006a50
int3