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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x42e05b
mov eax, dword fs:[0]
push eax
sub esp, 0x1ac
mov eax, dword [0x440018]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, edx
mov esi, ecx
cmp dword [edi + 0x14], 8
mov eax, edi
jb 0x40c5fc
mov eax, dword [edi]
xor ecx, ecx
mov dword [edi + 0x10], 0
mov word [eax], cx
mov eax, esi
cmp dword [esi + 0x14], 8
jb 0x40c612
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x40c7a6
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 2
jne 0x40c7a6
mov edi, dword [0x4420ac]
test edi, edi
je 0x40c650
mov ecx, edi
call dword [0x42f1a4]
call edi
cmp eax, 0x12c
jg 0x40c79c
push str.GetSimpleDisplayCertNameFromFile:_File__s_does_not_exist.
lea ecx, [ebp - 0x118]
call fcn.0040eed0
mov dword [ebp - 4], 0
lea edx, [ebp - 0x6c]
mov ecx, eax
mov dword [ebp - 0x6c], esi
mov dword [ebp - 0x68], fcn.00405a70
mov dword [ebp - 0x64], 0x40e490
call fcn.00405940
mov edx, 0x12c
mov ecx, eax
call fcn.0040eb80
cmp byte [ebp - 0x88], 0
je 0x40c6ce
mov edi, dword [ebp - 0x80]
test edi, edi
je 0x40c6c7
mov eax, dword [edi]
mov esi, dword [eax + 8]
mov ecx, esi
call dword [0x42f1a4]
mov ecx, edi
call esi
mov edi, eax
test edi, edi
je 0x40c6c7
mov ecx, dword [edi]
push 1
mov esi, dword [ecx]
mov ecx, esi
call dword [0x42f1a4]
mov ecx, edi
call esi
mov byte [ebp - 0x88], 0
lea ecx, [ebp - 0xd0]
call fcn.0040be00
mov edx, dword [ebp - 0xd8]
cmp edx, 8
jb 0x40c719
mov ecx, dword [ebp - 0xec]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40c70f
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40ca1b
push edx
push ecx
call fcn.00414006
add esp, 8
mov edx, dword [ebp - 0x10c]
xor eax, eax
mov dword [ebp - 0xdc], 0
mov dword [ebp - 0xd8], 7
mov word [ebp - 0xec], ax
test edx, edx
je 0x40c791
mov ecx, dword [ebp - 0x104]
mov eax, edx
sub ecx, edx
and ecx, 0xfffffffc
cmp ecx, 0x1000
jb 0x40c769
mov edx, dword [edx - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40ca1b
push ecx
push edx
call fcn.00414006
add esp, 8
mov dword [ebp - 0x10c], 0
mov dword [ebp - 0x108], 0
mov dword [ebp - 0x104], 0
lea ecx, [ebp - 0x118]
call fcn.00404f80
mov eax, 2
jmp 0x40c9ff
cmp dword [esi + 0x14], 8
mov dword [ebp - 0x20], 0xaac56b
mov dword [ebp - 0x1c], 0x11d0cd44
mov dword [ebp - 0x18], 0xc000c28c
mov dword [ebp - 0x14], 0xee95c24f
mov dword [ebp - 0x60], 0x10
jb 0x40c7d1
mov esi, dword [esi]
movzx eax, byte [ebp + 0xc]
mov ecx, 0x1212
cmp byte [ebp + 0x14], 0
mov dword [ebp - 0x5c], esi
mov dword [ebp - 0x58], 0
lea eax, [eax*2 + 2]
mov dword [ebp - 0x54], 0
mov dword [ebp - 0x44], eax
lea eax, [ebp - 0x60]
mov dword [ebp - 0x38], eax
mov eax, 0x1012
cmovne eax, ecx
mov dword [ebp - 0x50], 0x30
mov dword [ebp - 0x28], eax
lea eax, [ebp - 0x50]
push eax
lea eax, [ebp - 0x20]
mov dword [ebp - 0x4c], 0
push eax
push 0xffffffffffffffff
mov dword [ebp - 0x48], 0
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x3c], 1
mov dword [ebp - 0x34], 1
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x24], 0
call dword [sym.imp.WINTRUST.dll_WinVerifyTrust]
mov ebx, eax
test ebx, ebx
jne 0x40c9e6
mov edx, dword [ebp - 0x30]
lea ecx, [ebp - 0x78]
call fcn.0040c340
push eax
mov ecx, edi
call fcn.00408d70
lea ecx, [ebp - 0x78]
call fcn.00401fa0
mov esi, dword [0x4420ac]
test esi, esi
je 0x40c89b
mov ecx, esi
call dword [0x42f1a4]
call esi
cmp eax, 0x46
jg 0x40c9e6
push str.GetSimpleDisplayCertNameFromFile:_Found_cert_name:__s.
lea ecx, [ebp - 0x1b8]
call fcn.0040eed0
mov dword [ebp - 4], 1
lea edx, [ebp - 0x6c]
mov ecx, eax
mov dword [ebp - 0x6c], edi
mov dword [ebp - 0x68], fcn.00405a70
mov dword [ebp - 0x64], 0x40e490
call fcn.00405940
mov edx, 0x46
mov ecx, eax
call fcn.0040eb80
cmp byte [ebp - 0x128], 0
je 0x40c91c
mov edi, dword [ebp - 0x120]
test edi, edi
je 0x40c915
mov eax, dword [edi]
mov esi, dword [eax + 8]
mov ecx, esi
call dword [0x42f1a4]
mov ecx, edi
call esi
mov edi, eax
test edi, edi
je 0x40c915
mov ecx, dword [edi]
push 1
mov esi, dword [ecx]
mov ecx, esi
call dword [0x42f1a4]
mov ecx, edi
call esi
mov byte [ebp - 0x128], 0
lea ecx, [ebp - 0x170]
call fcn.0040be00
mov edx, dword [ebp - 0x178]
cmp edx, 8
jb 0x40c967
mov ecx, dword [ebp - 0x18c]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40c95d
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40ca20
push edx
push ecx
call fcn.00414006
add esp, 8
mov edx, dword [ebp - 0x1ac]
xor eax, eax
mov dword [ebp - 0x17c], 0
mov dword [ebp - 0x178], 7
mov word [ebp - 0x18c], ax
test edx, edx
je 0x40c9db
mov ecx, dword [ebp - 0x1a4]
mov eax, edx
sub ecx, edx
and ecx, 0xfffffffc
cmp ecx, 0x1000
jb 0x40c9b3
mov edx, dword [edx - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40ca20
push ecx
push edx
call fcn.00414006
add esp, 8
mov dword [ebp - 0x1ac], 0
mov dword [ebp - 0x1a8], 0
mov dword [ebp - 0x1a4], 0
lea ecx, [ebp - 0x1b8]
call fcn.00404f80
lea eax, [ebp - 0x50]
mov dword [ebp - 0x34], 2
push eax
lea eax, [ebp - 0x20]
push eax
push 0xffffffffffffffff
call dword [sym.imp.WINTRUST.dll_WinVerifyTrust]
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00413ff8
mov esp, ebp
pop ebp
ret
call fcn.0041861f
call fcn.0041861f
int3