Function at 0x40d4f0
Capabilities:
Hash data via wincrypt
Hash data with md5
Initialize hashing via wincrypt

Disassembly:
sub esp, 0x38
mov eax, dword [0x421020]
xor eax, esp
mov dword [esp + 0x34], eax
mov edx, dword [0x41d248]
mov eax, dword [str.0123456789abcdef]
mov ecx, dword [0x41d244]
push ebx
push esi
mov esi, dword [esp + 0x44]
push edi
mov edi, dword [esp + 0x4c]
push 0xf0000000
xor ebx, ebx
push 1
push ebx
mov dword [esp + 0x30], edx
mov dword [esp + 0x28], eax
mov eax, dword [0x41d24c]
mov dword [esp + 0x2c], ecx
mov cl, byte [0x41d250]
push ebx
lea edx, [esp + 0x20]
push edx
mov dword [esp + 0x2c], edi
mov dword [esp + 0x24], ebx
mov dword [esp + 0x20], ebx
mov dword [esp + 0x28], ebx
mov dword [esp + 0x3c], eax
mov byte [esp + 0x40], cl
call dword [sym.imp.ADVAPI32.dll_CryptAcquireContextA]
test eax, eax
je 0x40d6c6
mov ecx, dword [esp + 0x10]
lea eax, [esp + 0xc]
push eax
push ebx
push ebx
push 0x8003
push ecx
call dword [sym.imp.ADVAPI32.dll_CryptCreateHash]
test eax, eax
jne 0x40d5aa
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edx, dword [esp + 0x10]
push ebx
push edx
mov esi, eax
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
pop edi
mov eax, esi
pop esi
pop ebx
mov ecx, dword [esp + 0x34]
xor ecx, esp
call fcn.0040faab
add esp, 0x38
ret
mov eax, esi
lea edx, [eax + 1]
nop
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x40d5b0
push ebx
sub eax, edx
push eax
mov eax, dword [esp + 0x14]
push esi
push eax
call dword [sym.imp.ADVAPI32.dll_CryptHashData]
test eax, eax
jne 0x40d5fe
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esp + 0x10]
push ebx
push ecx
mov esi, eax
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
mov edx, dword [esp + 0xc]
push edx
call dword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
pop edi
mov eax, esi
pop esi
pop ebx
mov ecx, dword [esp + 0x34]
xor ecx, esp
call fcn.0040faab
add esp, 0x38
ret
mov edx, dword [esp + 0xc]
push ebx
lea eax, [esp + 0x18]
push eax
lea ecx, [esp + 0x38]
push ecx
push 2
push edx
mov dword [esp + 0x28], 0x10
call dword [sym.imp.ADVAPI32.dll_CryptGetHashParam]
test eax, eax
je 0x40d6c6
push ebp
xor ebp, ebp
xor esi, esi
cmp dword [esp + 0x18], ebx
jbe 0x40d693
mov ebx, dword [sym.imp.USER32.dll_wsprintfA]
cmp esi, 4
je 0x40d64b
cmp esi, 6
je 0x40d64b
cmp esi, 8
je 0x40d64b
cmp esi, 0xa
jne 0x40d65c
push 0x2d
lea eax, [edi + ebp]
push 0x41d2b8
push eax
call ebx
add esp, 0xc
inc ebp
movzx eax, byte [esp + esi + 0x34]
mov ecx, eax
and ecx, 0xf
movsx edx, byte [esp + ecx + 0x20]
shr eax, 4
movsx eax, byte [esp + eax + 0x20]
push edx
push eax
lea ecx, [edi + ebp]
push str._c_c
push ecx
call ebx
inc esi
add esp, 0x10
add edi, 2
cmp esi, dword [esp + 0x18]
jb 0x40d637
mov edi, dword [esp + 0x1c]
xor ebx, ebx
mov eax, dword [esp + 0x10]
lea edx, [edi + esi*2]
push eax
mov byte [edx + ebp], 0
call dword [sym.imp.ADVAPI32.dll_CryptDestroyHash]
mov ecx, dword [esp + 0x14]
push ebx
push ecx
call dword [sym.imp.ADVAPI32.dll_CryptReleaseContext]
pop ebp
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [esp + 0x34]
xor ecx, esp
call fcn.0040faab
add esp, 0x38
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esp + 0x40]
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.0040faab
add esp, 0x38
ret