Function at 0x40ca40
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x42ee3b
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0x1b0
mov eax, dword [0x442014]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, edx
mov edi, ecx
cmp dword [esi + 0x14], 8
mov eax, esi
jb 0x40ca8f
mov eax, dword [esi]
xor ecx, ecx
mov dword [esi + 0x10], 0
mov word [eax], cx
mov eax, edi
cmp dword [edi + 0x14], 8
jb 0x40caa5
mov eax, dword [edi]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x40cc3c
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
jne 0x40cc3c
mov esi, dword [0x4440f4]
test esi, esi
je 0x40cae3
mov ecx, esi
call dword [0x4301a4]
call esi
cmp eax, 0x12c
jg 0x40cc32
push str.GetSimpleDisplayCertNameFromFile:_File__s_does_not_exist.
lea ecx, [ebp - 0x120]
call fcn.0040f2e0
mov dword [ebp - 4], 0
lea edx, [ebp - 0x74]
mov ecx, eax
mov dword [ebp - 0x74], edi
mov dword [ebp - 0x70], fcn.00405c20
mov dword [ebp - 0x6c], 0x40e890
call fcn.00405b00
mov edx, 0x12c
mov ecx, eax
call fcn.0040ef90
cmp byte [ebp - 0x90], 0
je 0x40cb64
mov edi, dword [ebp - 0x88]
test edi, edi
je 0x40cb5d
mov eax, dword [edi]
mov esi, dword [eax + 8]
mov ecx, esi
call dword [0x4301a4]
mov ecx, edi
call esi
mov edi, eax
test edi, edi
je 0x40cb5d
mov ecx, dword [edi]
push 1
mov esi, dword [ecx]
mov ecx, esi
call dword [0x4301a4]
mov ecx, edi
call esi
mov byte [ebp - 0x90], 0
lea ecx, [ebp - 0xd8]
call fcn.0040c1a0
mov ecx, dword [ebp - 0xe0]
cmp ecx, 8
jb 0x40cbaf
mov edx, dword [ebp - 0xf4]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x40cba5
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40cedd
push ecx
push edx
call fcn.00414533
add esp, 8
mov edx, dword [ebp - 0x114]
xor eax, eax
mov dword [ebp - 0xe4], 0
mov dword [ebp - 0xe0], 7
mov word [ebp - 0xf4], ax
test edx, edx
je 0x40cc27
mov ecx, dword [ebp - 0x10c]
mov eax, edx
sub ecx, edx
and ecx, 0xfffffffc
cmp ecx, 0x1000
jb 0x40cbff
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40cedd
push ecx
push edx
call fcn.00414533
add esp, 8
mov dword [ebp - 0x114], 0
mov dword [ebp - 0x110], 0
mov dword [ebp - 0x10c], 0
lea ecx, [ebp - 0x120]
call fcn.00405100
mov eax, 2
jmp 0x40cebf
cmp dword [edi + 0x14], 8
mov dword [ebp - 0x24], 0xaac56b
mov dword [ebp - 0x20], 0x11d0cd44
mov dword [ebp - 0x1c], 0xc000c28c
mov dword [ebp - 0x18], 0xee95c24f
mov dword [ebp - 0x64], 0x10
jb 0x40cc67
mov edi, dword [edi]
movzx eax, byte [ebx + 0xc]
mov ecx, 0x1212
cmp byte [ebx + 0x14], 0
mov dword [ebp - 0x60], edi
mov dword [ebp - 0x5c], 0
lea eax, [eax*2 + 2]
mov dword [ebp - 0x58], 0
mov dword [ebp - 0x48], eax
lea eax, [ebp - 0x64]
mov dword [ebp - 0x3c], eax
mov eax, 0x1012
cmovne eax, ecx
mov dword [ebp - 0x54], 0x30
mov dword [ebp - 0x2c], eax
lea eax, [ebp - 0x54]
push eax
lea eax, [ebp - 0x24]
mov dword [ebp - 0x50], 0
push eax
push 0xffffffffffffffff
mov dword [ebp - 0x4c], 0
mov dword [ebp - 0x44], 0
mov dword [ebp - 0x40], 1
mov dword [ebp - 0x38], 1
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x28], 0
call dword [sym.imp.WINTRUST.dll_WinVerifyTrust]
mov dword [ebp - 0x68], eax
test eax, eax
jne 0x40cea5
mov edx, dword [ebp - 0x34]
lea ecx, [ebp - 0x80]
call fcn.0040c730
mov edi, eax
cmp esi, edi
je 0x40cd35
mov ecx, esi
call fcn.00402040
movups xmm0, xmmword [edi]
xor eax, eax
movups xmmword [esi], xmm0
movq xmm0, qword [edi + 0x10]
movq qword [esi + 0x10], xmm0
mov dword [edi + 0x10], 0
mov dword [edi + 0x14], 7
mov word [edi], ax
lea ecx, [ebp - 0x80]
call fcn.00402040
mov edi, dword [0x4440f4]
test edi, edi
je 0x40cd5a
mov ecx, edi
call dword [0x4301a4]
call edi
cmp eax, 0x46
jg 0x40cea5
push str.GetSimpleDisplayCertNameFromFile:_Found_cert_name:__s.
lea ecx, [ebp - 0x1c0]
call fcn.0040f2e0
mov dword [ebp - 4], 1
lea edx, [ebp - 0x74]
mov ecx, eax
mov dword [ebp - 0x74], esi
mov dword [ebp - 0x70], fcn.00405c20
mov dword [ebp - 0x6c], 0x40e890
call fcn.00405b00
mov edx, 0x46
mov ecx, eax
call fcn.0040ef90
cmp byte [ebp - 0x130], 0
je 0x40cddb
mov edi, dword [ebp - 0x128]
test edi, edi
je 0x40cdd4
mov eax, dword [edi]
mov esi, dword [eax + 8]
mov ecx, esi
call dword [0x4301a4]
mov ecx, edi
call esi
mov edi, eax
test edi, edi
je 0x40cdd4
mov ecx, dword [edi]
push 1
mov esi, dword [ecx]
mov ecx, esi
call dword [0x4301a4]
mov ecx, edi
call esi
mov byte [ebp - 0x130], 0
lea ecx, [ebp - 0x178]
call fcn.0040c1a0
mov ecx, dword [ebp - 0x180]
cmp ecx, 8
jb 0x40ce26
mov edx, dword [ebp - 0x194]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x40ce1c
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40cee2
push ecx
push edx
call fcn.00414533
add esp, 8
mov edx, dword [ebp - 0x1b4]
xor eax, eax
mov dword [ebp - 0x184], 0
mov dword [ebp - 0x180], 7
mov word [ebp - 0x194], ax
test edx, edx
je 0x40ce9a
mov ecx, dword [ebp - 0x1ac]
mov eax, edx
sub ecx, edx
and ecx, 0xfffffffc
cmp ecx, 0x1000
jb 0x40ce72
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40cee2
push ecx
push edx
call fcn.00414533
add esp, 8
mov dword [ebp - 0x1b4], 0
mov dword [ebp - 0x1b0], 0
mov dword [ebp - 0x1ac], 0
lea ecx, [ebp - 0x1c0]
call fcn.00405100
lea eax, [ebp - 0x54]
mov dword [ebp - 0x38], 2
push eax
lea eax, [ebp - 0x24]
push eax
push 0xffffffffffffffff
call dword [sym.imp.WINTRUST.dll_WinVerifyTrust]
mov eax, dword [ebp - 0x68]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004144c6
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
call fcn.004192df
call fcn.004192df
int3