Function at 0x4017e0
Capabilities:
Get file size
Hash data using sha1
Hash data using sha1 via wincrypt
Hash data via wincrypt
Initialize hashing via wincrypt
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
mov byte [ebp - 5], 0
mov dword [ebp - 4], 0
lea eax, [ebp - 4]
push eax
push 0
push 0
push 0x214
push 0x4067e8
mov ecx, dword [0x40a7a0]
push ecx
call dword [sym.imp.ADVAPI32.dll_CryptImportKey]
test eax, eax
je 0x4019f6
push 0
push 0
push 3
push 0
push 1
push 0xc0000000
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0xc], eax
cmp dword [ebp - 0xc], 0xffffffff
je 0x4019ec
push 0
mov eax, dword [ebp - 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
je 0x4019e2
push 0
push 0
push 0
push 4
push 0
mov ecx, dword [ebp - 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
je 0x4019be
push 0
push 0
push 0
push 6
mov edx, dword [ebp - 0x14]
push edx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0
je 0x4019b4
mov eax, dword [ebp - 0x18]
cmp dword [eax], 0x2153474e
jne 0x4019aa
mov ecx, dword [ebp - 0x18]
cmp dword [ecx + 4], 0
jbe 0x4019aa
mov edx, dword [ebp - 0x18]
mov eax, dword [edx + 4]
cmp eax, dword [ebp - 0x10]
jae 0x4019aa
lea ecx, [ebp - 0x1c]
push ecx
push 0
push 0
push RegSetValueExA
mov edx, dword [0x40a7a0]
push edx
call dword [sym.imp.ADVAPI32.dll_CryptCreateHash]
test eax, eax
je 0x4019aa
mov eax, dword [ebp - 0x18]
add eax, 8
mov dword [ebp - 0x20], eax
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x20]
add edx, dword [ecx + 4]
mov dword [ebp - 0x28], edx
mov eax, dword [ebp - 0x28]
sub eax, dword [ebp - 0x18]
mov ecx, dword [ebp - 0x10]
sub ecx, eax
mov dword [ebp - 0x10], ecx
mov edx, dword [ebp - 0x10]
push edx
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [ebp - 0x24], eax
cmp dword [ebp - 0x24], 0
je 0x4019aa
mov eax, dword [ebp - 0x18]
mov ecx, dword [eax + 4]
push ecx
mov edx, dword [ebp - 0x20]
push edx
mov eax, dword [ebp - 0x24]
push eax
mov ecx, dword [ebp - 0x10]
push ecx
mov edx, dword [ebp - 0x28]
push edx
call fcn.00401700
add esp, 0x14
push 0
mov eax, dword [ebp - 0x10]
push eax
mov ecx, dword [ebp - 0x24]
push ecx
mov edx, dword [ebp - 0x1c]
push edx
call dword [sym.imp.ADVAPI32.dll_CryptHashData]
test eax, eax
je 0x401997
push 0
push 0
mov eax, dword [ebp - 4]
push eax
mov ecx, dword [ebp - 0x18]
mov edx, dword [ecx + 4]
push edx
mov eax, dword [ebp - 0x20]
push eax
mov ecx, dword [ebp - 0x1c]
push ecx
call dword [sym.imp.ADVAPI32.dll_CryptVerifySignatureA]
test eax, eax
je 0x401997
mov byte [ebp - 5], 1
mov edx, dword [ebp - 0x10]
push edx
mov eax, dword [ebp - 0x24]
push eax
mov ecx, dword [ebp - 0x18]
push ecx
call sub.MSVCRT.dll_memcpy
add esp, 0xc
mov edx, dword [ebp - 0x24]
push edx
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov eax, dword [ebp - 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov ecx, dword [ebp - 0x14]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
movzx edx, byte [ebp - 5]
test edx, edx
je 0x4019e2
push 0
push 0
mov eax, dword [ebp - 0x10]
push eax
mov ecx, dword [ebp - 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov edx, dword [ebp - 0xc]
push edx
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov eax, dword [ebp - 0xc]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.ADVAPI32.dll_CryptDestroyKey]
mov al, byte [ebp - 5]
mov esp, ebp
pop ebp
ret