Function at 0x40680c
Capabilities:
Create new key via cryptacquirecontext
Hash data via wincrypt
Initialize hashing via wincrypt

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x1fc
mov edi, dword [ebp + 8]
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x64], 0
mov dword [ebp - 0x68], 0
mov dword [ebp - 0x6c], 0
mov dword [ebp - 0x70], 0
mov dword [ebp - 0x74], 0
mov dword [ebp - 0x78], 0
mov dword [ebp - 0x7c], 0
mov dword [ebp - 0x80], 0
lea eax, [ebp - 0x18]
mov dword [esp], eax
mov dword [esp + 0x10], 0xf0000000
mov dword [esp + 0xc], 0x18
mov dword [esp + 8], 0
mov dword [esp + 4], 0
call sub.ADVAPI32.DLL_CryptAcquireContextA
sub esp, 0x14
mov esi, eax
mov dword [ebp - 0x34], 0x43b004
mov dword [ebp - 0x30], 0x44070c
mov dword [ebp - 0x2c], ebp
mov dword [ebp - 0x24], esp
mov dword [ebp - 0x2c], 0x4070cc
lea ebx, [ebp - 0x50]
mov eax, ebx
call fcn.0043bc6d
test esi, esi
je 0x406a92
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x48], 0xffffffff
lea ecx, [ebp - 0x14]
mov dword [esp + 0x10], ecx
mov dword [esp], eax
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0x800c
call sub.ADVAPI32.DLL_CryptCreateHash
sub esp, 0x14
test eax, eax
je 0x406af4
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x48], 0xffffffff
mov dword [esp + 4], eax
lea eax, [ebp - 0x1e8]
mov dword [esp], eax
mov dword [esp + 0xc], 0x1b6
mov dword [esp + 8], 0x80
call fcn.0040235c
cmp dword [ebp - 0x190], 0
je 0x406ba7
nop word [eax + eax]
mov dword [ebp - 0x48], 9
lea eax, [ebp - 0x80]
mov dword [esp + 4], eax
lea eax, [ebp - 0x1e8]
mov dword [esp], eax
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0x20
call fcn.00407220
mov ecx, dword [eax]
mov ecx, dword [ecx - 0xc]
test byte [eax + ecx + 8], 6
jne 0x406cd8
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x48], 0xa
lea ecx, [ebp - 0x80]
mov dword [esp + 4], ecx
mov dword [esp], eax
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0x20
call sub.ADVAPI32.DLL_CryptHashData
sub esp, 0x10
test eax, eax
jne 0x40693c
mov dword [ebp - 0x48], 0xb
mov dword [esp + 4], str.Error_in_CryptHashData...
mov dword [esp], 0x446168
call fcn.0040167c
mov dword [ebp - 0x10], eax
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx]
mov eax, dword [eax - 0xc]
add eax, ecx
mov dword [ebp - 0x48], 0xc
mov dword [esp], eax
mov dword [esp + 4], 0xa
call fcn.00415f68
mov dword [ebp - 0x48], 0xd
movsx eax, al
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call fcn.00415d08
mov dword [ebp - 0x48], 0xe
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call fcn.004154a0
mov dword [ebp - 0x48], 0xf
lea eax, [ebp - 0x1e8]
mov dword [esp], eax
call fcn.00407538
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x48], 0x10
mov dword [esp], eax
call sub.ADVAPI32.DLL_CryptDestroyHash
sub esp, 4
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x48], 0x11
mov dword [esp], eax
mov dword [esp + 4], 0
call sub.ADVAPI32.DLL_CryptReleaseContext
sub esp, 8
mov eax, dword [ebp + 8]
mov dword [eax + 0x18], 0xf
mov dword [eax + 0x14], 0
mov byte [eax + 4], 0
mov dword [ebp - 0x48], 0x12
mov dword [esp], eax
mov dword [esp + 8], 0
mov dword [esp + 4], 0x43f969
call fcn.004144c4
jmp 0x406c8d
mov dword [ebp - 0x48], 0xffffffff
mov dword [esp + 4], str.Error_in_CryptAcquireContext...
mov dword [esp], 0x446168
call fcn.0040167c
mov esi, eax
mov eax, dword [esi]
mov eax, dword [eax - 0xc]
add eax, esi
mov dword [ebp - 0x48], 0xffffffff
mov dword [esp], eax
mov dword [esp + 4], 0xa
call fcn.00415f68
mov dword [ebp - 0x48], 0xffffffff
movsx eax, al
mov dword [esp + 4], eax
mov dword [esp], esi
call fcn.00415d08
mov dword [ebp - 0x48], 0xffffffff
mov dword [esp], esi
call fcn.004154a0
jmp 0x406b71
mov dword [ebp - 0x48], 0xffffffff
mov dword [esp + 4], str.Error_in_CryptCreateHash...
mov dword [esp], 0x446168
call fcn.0040167c
mov esi, eax
mov eax, dword [esi]
mov eax, dword [eax - 0xc]
add eax, esi
mov dword [ebp - 0x48], 0xffffffff
mov dword [esp], eax
mov dword [esp + 4], 0xa
call fcn.00415f68
mov dword [ebp - 0x48], 0xffffffff
movsx eax, al
mov dword [esp + 4], eax
mov dword [esp], esi
call fcn.00415d08
mov dword [ebp - 0x48], 0xffffffff
mov dword [esp], esi
call fcn.004154a0
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x48], 0xffffffff
mov dword [esp], eax
mov dword [esp + 4], 0
call sub.ADVAPI32.DLL_CryptReleaseContext
sub esp, 8
mov dword [edi + 0x18], 0xf
mov dword [edi + 0x14], 0
mov byte [edi + 4], 0
mov dword [ebp - 0x48], 0xffffffff
mov dword [esp], edi
mov dword [esp + 8], 0
mov dword [esp + 4], 0x43f969
call fcn.004144c4
jmp 0x406cc3
mov dword [ebp - 0x48], 1
mov dword [esp + 4], str.Failed_to_open_file:
mov dword [esp], 0x446168
call fcn.0040167c
mov dword [ebp - 0x48], 2
mov ecx, dword [ebp + 0xc]
mov dword [esp + 4], ecx
mov dword [esp], eax
call fcn.004037cc
mov dword [ebp - 0x10], eax
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx]
mov eax, dword [eax - 0xc]
add eax, ecx
mov dword [ebp - 0x48], 3
mov dword [esp], eax
mov dword [esp + 4], 0xa
call fcn.00415f68
mov dword [ebp - 0x48], 4
movsx eax, al
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call fcn.00415d08
mov dword [ebp - 0x48], 5
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call fcn.004154a0
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x48], 6
mov dword [esp], eax
call sub.ADVAPI32.DLL_CryptDestroyHash
sub esp, 4
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x48], 7
mov dword [esp], eax
mov dword [esp + 4], 0
call sub.ADVAPI32.DLL_CryptReleaseContext
sub esp, 8
mov eax, dword [ebp + 8]
mov dword [eax + 0x18], 0xf
mov dword [eax + 0x14], 0
mov byte [eax + 4], 0
mov dword [ebp - 0x48], 8
mov dword [esp], eax
mov dword [esp + 8], 0
mov dword [esp + 4], 0x43f969
call fcn.004144c4
mov dword [ebp - 0x1e8], 0x41c9e0
lea esi, [ebp - 0x180]
mov dword [ebp - 0x180], 0x41c9f4
lea eax, [ebp - 0x1d8]
mov dword [esp], eax
call fcn.00417ff8
mov dword [esp], esi
call fcn.0041d008
mov edi, dword [ebp + 8]
lea ebx, [ebp - 0x50]
mov dword [esp], ebx
call fcn.0043bc8e
mov eax, edi
add esp, 0x1fc
pop esi
pop edi
pop ebx
pop ebp
ret
mov dword [ebp - 0x58], 0x20
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x48], 0x13
lea ecx, [ebp - 0x58]
mov dword [esp + 0xc], ecx
lea ecx, [ebp - 0x80]
mov dword [esp + 8], ecx
mov dword [esp], eax
mov dword [esp + 0x10], 0
mov dword [esp + 4], 2
call sub.ADVAPI32.DLL_CryptGetHashParam
sub esp, 0x14
test eax, eax
je 0x406f40
lea eax, [ebp - 0xd8]
mov dword [ebp - 0x5c], eax
mov dword [ebp - 0x128], 0x41ca44
lea eax, [ebp - 0x120]
mov dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x54]
mov dword [ebp - 0x138], 0x41ca6c
mov ecx, dword [ebp - 0x5c]
mov dword [ecx], 0x41ca80
mov dword [ebp - 0x12c], 0
mov dword [ebp - 0x130], 0
mov ecx, dword [ebp - 0x5c]
mov dword [ebp - 0x48], 0x1c
mov dword [esp + 4], eax
mov dword [esp], ecx
mov dword [esp + 8], 0
call fcn.004168fc
mov dword [ebp - 0x138], 0x41ca30
mov dword [ebp - 0xd8], 0x41ca58
mov dword [ebp - 0x128], 0x41ca44
mov eax, dword [ebp - 0x54]
mov dword [ebp - 0x48], 0x1d
mov dword [esp], eax
mov dword [esp + 4], 3
call fcn.00418d1c
cmp dword [ebp - 0x58], 0
je 0x406e93
lea eax, [ebp - 0x128]
mov dword [ebp - 0x60], eax
mov dword [ebp - 0x10], 0
nop word cs:[eax + eax]
mov eax, dword [ebp - 0x128]
mov eax, dword [eax - 0xc]
mov ecx, dword [ebp + eax - 0x118]
and ecx, 0xffffff8f
or ecx, 0x40
mov dword [ebp + eax - 0x118], ecx
mov dword [ebp - 0x48], 0x1f
lea eax, [ebp - 0x90]
mov dword [esp], eax
mov dword [esp + 8], 0
mov dword [esp + 4], 2
call fcn.0041cf90
mov eax, dword [ebp - 0x60]
mov ecx, dword [ebp - 0x128]
add eax, dword [ecx - 0xc]
mov ecx, dword [ebp - 0x90]
mov edx, dword [ebp - 0x88]
mov esi, dword [ebp - 0x84]
mov dword [ebp - 0x48], 0x20
mov dword [esp + 8], esi
mov dword [esp + 4], edx
mov dword [esp], eax
call ecx
mov eax, dword [ebp - 0x60]
mov ecx, dword [ebp - 0x128]
mov ecx, dword [ecx - 0xc]
mov byte [ebp + ecx - 0xe8], 0x30
mov ecx, dword [ebp - 0x10]
movzx ecx, byte [ebp + ecx - 0x80]
mov dword [ebp - 0x48], 0x21
mov dword [esp + 4], ecx
mov dword [esp], eax
call fcn.00407614
mov eax, dword [ebp - 0x10]
mov ecx, eax
inc ecx
mov eax, ecx
mov dword [ebp - 0x10], eax
cmp ecx, dword [ebp - 0x58]
jb 0x406ddc
mov dword [ebp - 0x48], 0x1e
lea eax, [ebp - 0x1e8]
mov dword [esp], eax
call fcn.00407538
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x48], 0x22
mov dword [esp], eax
call sub.ADVAPI32.DLL_CryptDestroyHash
sub esp, 4
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x48], 0x23
mov dword [esp], eax
mov dword [esp + 4], 0
call sub.ADVAPI32.DLL_CryptReleaseContext
sub esp, 8
mov ecx, dword [ebp - 0xe4]
test cl, 2
jne 0x40702a
mov eax, dword [ebp - 0x100]
mov eax, dword [eax]
test eax, eax
je 0x40702a
mov ecx, dword [ebp - 0x110]
mov edx, dword [ebp - 0xe8]
mov ecx, dword [ecx]
cmp edx, eax
jb 0x406f0d
mov eax, edx
sub eax, ecx
mov edx, dword [ebp + 8]
mov dword [edx + 0x18], 0xf
mov dword [edx + 0x14], 0
mov byte [edx + 4], 0
mov dword [ebp - 0x48], 0x24
mov dword [esp + 8], eax
mov dword [esp + 4], ecx
mov dword [esp], edx
call fcn.004144c4
jmp 0x407090
mov dword [ebp - 0x48], 0x14
mov dword [esp + 4], str.Error_in_CryptGetHashParam...
mov dword [esp], 0x446168
call fcn.0040167c
mov dword [ebp - 0x10], eax
mov ecx, dword [ebp - 0x10]
mov eax, dword [ecx]
mov eax, dword [eax - 0xc]
add eax, ecx
mov dword [ebp - 0x48], 0x15
mov dword [esp], eax
mov dword [esp + 4], 0xa
call fcn.00415f68
mov dword [ebp - 0x48], 0x16
movsx eax, al
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call fcn.00415d08
mov dword [ebp - 0x48], 0x17
mov eax, dword [ebp - 0x10]
mov dword [esp], eax
call fcn.004154a0
mov dword [ebp - 0x48], 0x18
lea eax, [ebp - 0x1e8]
mov dword [esp], eax
call fcn.00407538
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x48], 0x19
mov dword [esp], eax
call sub.ADVAPI32.DLL_CryptDestroyHash
sub esp, 4
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x48], 0x1a
mov dword [esp], eax
mov dword [esp + 4], 0
call sub.ADVAPI32.DLL_CryptReleaseContext
sub esp, 8
mov eax, dword [ebp + 8]
mov dword [eax + 0x18], 0xf
mov dword [eax + 0x14], 0
mov byte [eax + 4], 0
mov dword [ebp - 0x48], 0x1b
mov dword [esp], eax
mov dword [esp + 8], 0
mov dword [esp + 4], 0x43f969
call fcn.004144c4
jmp 0x406c8d
test cl, 4
jne 0x40707b
mov eax, dword [ebp - 0x104]
mov eax, dword [eax]
test eax, eax
je 0x40707b
mov ecx, dword [ebp - 0x114]
mov edx, dword [ebp - 0xf4]
mov ecx, dword [ecx]
add eax, dword [edx]
sub eax, ecx
mov edx, dword [ebp + 8]
mov dword [edx + 0x18], 0xf
mov dword [edx + 0x14], 0
mov byte [edx + 4], 0
mov dword [ebp - 0x48], 0x25
mov dword [esp + 8], eax
mov dword [esp + 4], ecx
mov dword [esp], edx
call fcn.004144c4
jmp 0x407090
mov eax, dword [ebp + 8]
mov dword [eax + 0x18], 0xf
mov dword [eax + 0x14], 0
mov byte [eax + 4], 0
mov dword [ebp - 0x138], 0x41ca30
mov dword [ebp - 0xd8], 0x41ca58
mov dword [ebp - 0x128], 0x41ca44
mov eax, dword [ebp - 0x54]
mov dword [esp], eax
call fcn.00419004
lea eax, [ebp - 0xd8]
mov dword [esp], eax
call fcn.0041d008
jmp 0x406c8d