Function at 0x140251708
Capabilities:
Hash data using sha1 via wincrypt
Hash data via wincrypt
Initialize hashing via wincrypt

Disassembly:
push rbp
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0xf]
sub rsp, 0xf8
mov rax, qword [0x14031fcd0]
xor rax, rsp
mov qword [rbp - 9], rax
mov r13, qword [rbp + 0x77]
mov r12, r8
mov r15, qword [rbp + 0x7f]
xor r8d, r8d
mov qword [rsp + 0x48], r8
mov r14, r9
mov qword [rsp + 0x50], r8
mov ebx, r8d
mov qword [rsp + 0x40], r8
mov sil, r8b
mov dword [rsp + 0x38], r8d
test r13, r13
je 0x140251765
cmp dword [r15], 0x14
jae 0x140251771
mov dword [r15], SafeArrayGetElement
mov ebx, 0x80070057
mov dword [rsp + 0x30], SHFlushSFCache
mov dword [rsp + 0x34], 0x6602
test ebx, ebx
js 0x140251951
mov rax, qword [rsp + 0x30]
mov qword [rbp - 0x69], rax
mov dword [rbp - 0x61], edx
test rdx, rdx
jne 0x14025179f
mov edi, r8d
jmp 0x1402517f4
test rcx, rcx
je 0x1402517be
cmp rdx, 0x10
ja 0x1402517be
mov r8, rdx
mov rdx, rcx
lea rcx, [rbp - 0x5d]
call fcn.1400b43a0
xor r8d, r8d
jmp 0x14025179a
xorps xmm0, xmm0
movups xmmword [rbp - 0x5d], xmm0
test rcx, rcx
jne 0x1402517dd
call fcn.1400c88a8
mov edi, SafeArrayGetElement
mov dword [rax], edi
call fcn.1400c6528
jmp 0x1402517f4
cmp rdx, 0x10
jbe 0x1402517ef
call fcn.1400c88a8
mov edi, 0x22
jmp 0x1402517d4
mov edi, SafeArrayGetElement
mov ebx, edi
or ebx, 0x80070000
test edi, edi
cmove ebx, edi
test ebx, ebx
js 0x140251951
mov r9d, 1
mov dword [rsp + 0x20], 0xf0000000
xor r8d, r8d
lea rcx, [rsp + 0x48]
xor edx, edx
call qword [sym.imp.ADVAPI32.dll_CryptAcquireContextW]
xor r8d, r8d
test eax, eax
je 0x140251838
mov ebx, r8d
mov edi, 0x80070000
jmp 0x140251850
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
mov edi, 0x80070000
or ebx, edi
xor r8d, r8d
test eax, eax
cmovle ebx, eax
mov esi, ebx
shr esi, 0x1f
xor sil, 1
test ebx, ebx
js 0x140251951
mov rcx, qword [rsp + 0x48]
lea rax, [rsp + 0x50]
xor r9d, r9d
mov qword [rsp + 0x28], rax
mov dword [rsp + 0x20], r8d
lea rdx, [rbp - 0x69]
lea r8d, [r9 + 0x1c]
call qword [sym.imp.ADVAPI32.dll_CryptImportKey]
test eax, eax
jne 0x1402518a2
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
or ebx, edi
test eax, eax
cmovle ebx, eax
test ebx, ebx
js 0x140251951
mov r8, qword [rsp + 0x50]
lea rax, [rsp + 0x40]
mov rcx, qword [rsp + 0x48]
xor r9d, r9d
mov edx, 0x8009
mov qword [rsp + 0x20], rax
call qword [sym.imp.ADVAPI32.dll_CryptCreateHash]
test eax, eax
jne 0x1402518dc
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
or ebx, edi
test eax, eax
cmovle ebx, eax
test ebx, ebx
js 0x140251951
mov rcx, qword [rsp + 0x40]
lea r8, [rsp + 0x58]
xor eax, eax
xorps xmm0, xmm0
movups xmmword [rsp + 0x58], xmm0
xor r9d, r9d
mov qword [rbp - 0x71], rax
movups xmmword [rsp + 0x68], xmm0
lea edx, [rax + 5]
mov dword [rsp + 0x58], 0x8004
call qword [sym.imp.ADVAPI32.dll_CryptSetHashParam]
test eax, eax
jne 0x140251925
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
or ebx, edi
test eax, eax
cmovle ebx, eax
test ebx, ebx
js 0x140251951
mov rcx, qword [rsp + 0x40]
xor r9d, r9d
mov r8d, r14d
mov rdx, r12
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
test eax, eax
je 0x140251941
xor ebx, ebx
jmp 0x140251951
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
or ebx, edi
test eax, eax
cmovle ebx, eax
mov edi, r14d
test ebx, ebx
js 0x1402519fc
test r14b, 0x3f
je 0x1402519ab
mov ebx, 0x40
lea rcx, [rbp - 0x49]
mov r8d, ebx
xor edx, edx
call fcn.1400b4a50
mov rcx, qword [rsp + 0x40]
lea rdx, [rbp - 0x49]
and edi, 0x3f
xor r9d, r9d
sub ebx, edi
mov r8d, ebx
call qword [sym.imp.ADVAPI32.dll_CryptHashData]
test eax, eax
jne 0x1402519ab
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
test ebx, ebx
js 0x1402519fc
mov eax, dword [r15]
lea r9, [rsp + 0x38]
mov rcx, qword [rsp + 0x40]
mov r8, r13
and dword [rsp + 0x20], 0
mov edx, 2
mov dword [rsp + 0x38], eax
call qword [sym.imp.ADVAPI32.dll_CryptGetHashParam]
test eax, eax
jne 0x1402519eb
call qword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
test ebx, ebx
js 0x1402519fc
mov eax, dword [rsp + 0x38]
sub eax, 0x14
neg eax
sbb ebx, ebx
and ebx, 0x80004005
mov rcx, qword [rsp + 0x40]
test rcx, rcx
je 0x140251a0c
call qword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
mov rcx, qword [rsp + 0x50]
test rcx, rcx
je 0x140251a1c
call qword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
test sil, sil
je 0x140251a2e
mov rcx, qword [rsp + 0x48]
xor edx, edx
call qword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov eax, ebx
mov rcx, qword [rbp - 9]
xor rcx, rsp
call fcn.1400b1670
add rsp, 0xf8
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret