Function at 0x5fcea47d
Capabilities:
Generate random numbers via winapi
Hash data using sha1
Hash data using sha1 via wincrypt
Hash data via wincrypt
Initialize hashing via wincrypt

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
xor esi, esi
cmp dword [ebp + 8], esi
push edi
je 0x5fcea640
cmp dword [ebp + 0xc], esi
je 0x5fcea640
mov edi, dword [ebp + 0x14]
cmp edi, esi
je 0x5fcea640
cmp dword [ebp + 0x10], esi
je 0x5fcea640
push dword [ebp + 8]
mov ebx, dword [sym.imp.KERNEL32.dll_lstrlenW]
call ebx
cmp eax, 0x100
jle 0x5fcea4cc
mov eax, 0x80070057
jmp 0x5fcea645
push 0xf0000000
push 1
push esi
push esi
lea eax, [ebp + 0x14]
push eax
mov dword [ebp + 0x14], esi
mov dword [ebp - 4], esi
mov dword [ebp - 0xc], esi
mov dword [ebp - 8], esi
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
test eax, eax
je 0x5fcea618
cmp dword [ebp + 0x18], esi
je 0x5fcea52a
lea eax, [ebp - 0xc]
push eax
push 4
push dword [ebp + 0x14]
call dword [sym.imp.ADVAPI32.dll_CryptGenRandom]
test eax, eax
jne 0x5fcea523
cmp dword [ebp + 0x14], esi
je 0x5fcea618
push esi
push dword [ebp + 0x14]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
jmp 0x5fcea618
mov eax, dword [ebp - 0xc]
mov dword [edi], eax
jmp 0x5fcea52f
mov eax, dword [edi]
mov dword [ebp - 0xc], eax
lea eax, [ebp - 4]
push eax
push esi
push esi
push 0x8004
push dword [ebp + 0x14]
call dword [sym.imp.ADVAPI32.dll_CryptCreateHash]
test eax, eax
jne 0x5fcea56d
cmp dword [ebp + 0x14], esi
je 0x5fcea556
push esi
push dword [ebp + 0x14]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
cmp dword [ebp - 4], esi
je 0x5fcea618
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
jmp 0x5fcea618
push esi
push dword [ebp + 8]
call ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_CryptHashData]
shl eax, 1
push eax
push dword [ebp + 8]
push dword [ebp - 4]
call ebx
test eax, eax
je 0x5fcea547
push esi
push 4
lea eax, [ebp - 0xc]
push eax
push dword [ebp - 4]
call ebx
test eax, eax
je 0x5fcea547
mov ebx, dword [sym.imp.ADVAPI32.dll_CryptGetHashParam]
push esi
lea eax, [ebp - 8]
push eax
push esi
push 2
push dword [ebp - 4]
call ebx
test eax, eax
je 0x5fcea547
push dword [ebp - 8]
call sub.msvcrt.dll_void____cdecl_operator_new_unsigned_int_
mov edx, eax
mov eax, dword [ebp + 0xc]
pop ecx
mov ecx, dword [ebp - 8]
mov dword [eax], edx
mov edi, edx
mov edx, ecx
shr ecx, 2
xor eax, eax
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov eax, dword [ebp - 8]
mov ecx, dword [ebp + 0x10]
mov edi, dword [ebp + 0xc]
push esi
mov dword [ecx], eax
lea eax, [ebp - 8]
push eax
push dword [edi]
push 2
push dword [ebp - 4]
call ebx
test eax, eax
jne 0x5fcea61f
cmp dword [ebp + 0x14], esi
je 0x5fcea600
push esi
push dword [ebp + 0x14]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
cmp dword [ebp - 4], esi
je 0x5fcea60e
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
push dword [edi]
call sub.msvcrt.dll_void___cdecl_operator_delete_void__
pop ecx
mov dword [edi], esi
mov eax, 0x8000ffff
jmp 0x5fcea645
cmp dword [ebp + 0x14], esi
je 0x5fcea62e
push esi
push dword [ebp + 0x14]
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
cmp dword [ebp - 4], esi
je 0x5fcea63c
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
xor eax, eax
jmp 0x5fcea645
mov eax, 0x80004003
pop edi
pop esi
pop ebx
leave
ret 0x14