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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x234
mov eax, dword [0x42d0b4]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
push 0x104
lea eax, [ebp - 0x220]
mov dword [ebp - 0x22c], edx
mov esi, ecx
mov byte [ebp - 0x221], 0
push 0
push eax
mov dword [ebp - 0x228], esi
or ebx, 0xffffffff
mov dword [ebp - 0x18], 0
mov byte [ebp - 0x14], 1
mov dword [ebp - 0x10], 0x104
call sub.msvcrt.dll_memset
add esp, 0xc
cmp byte [ebp - 0x14], 0
je 0x41cb11
mov eax, 0x7fe7
push eax
lea ecx, [ebp - 0x220]
call fcn.0040fba0
test eax, eax
js 0x41cb1b
xor edi, edi
lea ecx, [ecx]
cmp edi, 0x7fe6
jae 0x40d054
mov eax, dword [esi + 0x38]
movzx esi, word [eax + edi*2]
xor al, al
cmp esi, 0x22
je 0x40d1ff
test si, si
je 0x40d054
mov cl, byte [ebp - 0x221]
test cl, cl
jne 0x40d020
test al, al
jne 0x40d020
push esi
push 0x402258
call dword [sym.imp.msvcrt.dll_wcschr]
add esp, 8
test eax, eax
jne 0x40d054
cmp ebx, 0xffffffff
jne 0x40d03c
push esi
push 0x402250
call dword [sym.imp.msvcrt.dll_wcschr]
add esp, 8
test eax, eax
jne 0x40d231
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x41cb25
mov word [eax + edi*2], si
inc edi
mov esi, dword [ebp - 0x228]
jmp 0x40cfe0
mov dword [ebp - 0x230], edi
test edi, edi
je 0x41cb30
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x41cb38
xor ecx, ecx
mov word [eax + edi*2], cx
cmp ebx, 0xffffffff
jne 0x40d245
mov ebx, dword [ebp - 0x18]
test ebx, ebx
je 0x41cb43
xor edi, edi
mov esi, 0x401600
mov dword [ebp - 0x234], edi
mov eax, dword [esi]
test eax, eax
je 0x40d0ad
push eax
push ebx
call dword [sym.imp.msvcrt.dll__wcsicmp]
add esp, 8
test eax, eax
je 0x40d13c
inc edi
add esi, 0x18
mov dword [ebp - 0x234], edi
cmp esi, 0x4019f0
jle 0x40d094
mov ecx, dword [ebp - 0x22c]
or edi, 0xffffffff
mov dword [0x42d0dc], 0xffffffff
mov dword [ebp - 0x234], edi
mov edx, dword [ebp - 0x18]
test edx, edx
je 0x41cb60
push ecx
mov ecx, 0x2d
call fcn.0040ced0
cmp eax, 0x2d
je 0x41cb6b
mov edi, dword [ebp - 0x228]
xor cl, cl
mov byte [ebp - 0x221], 0
xor ebx, ebx
jmp 0x40d110
mov eax, dword [edi + 0x38]
movzx esi, word [eax + ebx*2]
test si, si
je 0x40d1ee
mov al, byte [ebp - 0x221]
cmp esi, 0x22
je 0x40d219
test al, al
je 0x40d1bf
inc ebx
xor cl, cl
jmp 0x40d110
test byte [esi + 8], 4
jne 0x41cb4e
mov ecx, dword [ebp - 0x22c]
lea eax, [edi + edi*2]
mov ax, word [eax*8 + 0x401608]
mov dword [0x42d0dc], edi
mov word [ecx], ax
cmp edi, 0xffffffff
je 0x40d0d8
mov ecx, dword [ebp - 0x228]
mov ebx, dword [ebp - 0x230]
cmp edi, 0x14
je 0x40d1b6
mov ecx, dword [ecx + 0x38]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x40d180
sub ecx, edx
sar ecx, 1
cmp ebx, ecx
jne 0x41cb75
push dword [ebp - 0x18]
call dword [sym.imp.msvcrt.dll_void___cdecl_operator_delete___void__]
mov ecx, dword [ebp - 4]
add esp, 4
mov eax, edi
xor ecx, ebp
pop edi
pop esi
pop ebx
call fcn.00416ce0
mov esp, ebp
pop ebp
ret
mov dword [ecx + 0x40], 1
jmp 0x40d17a
test cl, cl
jne 0x40d137
push esi
call dword [sym.imp.msvcrt.dll_iswspace]
add esp, 4
test eax, eax
jne 0x40d1ee
mov edx, esi
mov ecx, 0x4022a4
call fcn.004115ed
test eax, eax
jne 0x40d1ee
cmp esi, 0x2f
jne 0x40d137
mov edi, dword [ebp - 0x234]
mov ecx, dword [ebp - 0x228]
jmp 0x40d17a
mov al, byte [ebp - 0x221]
test al, al
sete cl
mov byte [ebp - 0x221], cl
test al, al
jne 0x40d270
jmp 0x40d005
test al, al
sete dl
test al, al
mov al, dl
mov byte [ebp - 0x221], al
je 0x40d277
mov cl, 1
jmp 0x40d12f
cmp byte [0x443cd9], 0
je 0x40d054
mov ebx, edi
jmp 0x40d03c
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x40d288
push eax
call dword [sym.imp.api_ms_win_core_file_l1_2_1.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x40d27e
mov eax, dword [ebp - 0x18]
mov dword [ebp - 0x230], ebx
test eax, eax
je 0x40d290
xor ecx, ecx
mov word [eax + ebx*2], cx
jmp 0x40d07c
mov al, 1
jmp 0x40d005
xor cl, cl
jmp 0x40d12f
test al, 0x10
je 0x40d07c
jmp 0x40d258
lea eax, [ebp - 0x220]
jmp 0x40d24c
lea eax, [ebp - 0x220]
jmp 0x40d265
mov eax, 0x104
jmp 0x40cfc7
mov edi, 0xfffffffe
jmp 0x40d197
lea eax, [ebp - 0x220]
jmp 0x40d047
or edi, 0xffffffff
jmp 0x40d197
lea eax, [ebp - 0x220]
jmp 0x40d06d
lea ebx, [ebp - 0x220]
jmp 0x40d087
cmp byte [0x443cd9], 0
jne 0x40d146
jmp 0x40d0ad
lea edx, [ebp - 0x220]
jmp 0x40d0e3
mov edi, 0x2d
jmp 0x40d197
mov eax, dword [ebp - 0x228]
lea esi, [ecx + 1]
mov ecx, dword [eax + 0x3c]
test ecx, ecx
je 0x41cb99
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x41cb88
sub ecx, edx
sar ecx, 1
add esi, ecx
lea ecx, [esi + esi]
call fcn.0040f4e0
mov ecx, eax
mov dword [ebp - 0x22c], ecx
test ecx, ecx
jne 0x41cbbf
call fcn.0042904e
push 1
push 0x43b8c8
call dword [sym.imp.msvcrt.dll_longjmp]
mov eax, dword [ebp - 0x228]
add ebx, ebx
mov edx, esi
mov eax, dword [eax + 0x38]
add eax, ebx
push eax
call fcn.00410820
mov ecx, dword [ebp - 0x228]
mov eax, dword [ecx + 0x3c]
test eax, eax
je 0x41cbf3
mov edx, esi
mov esi, dword [ebp - 0x22c]
push eax
mov ecx, esi
call fcn.00410770
jmp 0x41cbf9
mov esi, dword [ebp - 0x22c]
mov eax, dword [ebp - 0x228]
xor ecx, ecx
mov dword [eax + 0x3c], esi
mov eax, dword [eax + 0x38]
mov word [ebx + eax], cx
jmp 0x40d197