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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xd60
cmp dword [ebp + 8], 0
jne 0x4048a8
cmp dword [0x417168], 0
jne 0x4048a6
push 0x400
push 0x40
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov dword [0x417168], eax
cmp dword [0x417168], 0
je 0x4048a6
push 0
call fcn.00404390
add esp, 4
mov dword [ebp - 0xd14], eax
mov eax, dword [0x417168]
mov dword [ebp - 0xd18], eax
mov ecx, dword [ebp - 0xd18]
mov dword [ebp - 0xd1c], ecx
mov edx, dword [ebp - 0xd14]
mov al, byte [edx]
mov byte [ebp - 0xd1d], al
mov ecx, dword [ebp - 0xd18]
mov dl, byte [ebp - 0xd1d]
mov byte [ecx], dl
mov eax, dword [ebp - 0xd14]
add eax, 1
mov dword [ebp - 0xd14], eax
mov ecx, dword [ebp - 0xd18]
add ecx, 1
mov dword [ebp - 0xd18], ecx
cmp byte [ebp - 0xd1d], 0
jne 0x404486
mov edx, dword [0x417168]
mov dword [ebp - 0xd0c], edx
push 0x5c
mov eax, dword [ebp - 0xd0c]
push eax
call fcn.00407666
add esp, 8
mov dword [ebp - 0x404], eax
cmp dword [ebp - 0x404], 0
jne 0x404511
mov ecx, dword [0x417168]
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [0x417168], 0
jmp 0x4048a6
mov edx, dword [ebp - 0x404]
add edx, 1
mov dword [ebp - 0xd24], edx
lea eax, [ebp - 0x400]
mov dword [ebp - 0xd28], eax
mov ecx, dword [ebp - 0xd28]
mov dword [ebp - 0xd2c], ecx
mov edx, dword [ebp - 0xd24]
mov al, byte [edx]
mov byte [ebp - 0xd2d], al
mov ecx, dword [ebp - 0xd28]
mov dl, byte [ebp - 0xd2d]
mov byte [ecx], dl
mov eax, dword [ebp - 0xd24]
add eax, 1
mov dword [ebp - 0xd24], eax
mov ecx, dword [ebp - 0xd28]
add ecx, 1
mov dword [ebp - 0xd28], ecx
cmp byte [ebp - 0xd2d], 0
jne 0x404538
mov edx, dword [ebp - 0x404]
mov byte [edx], 0
mov eax, dword [0x417168]
mov dword [ebp - 0xd34], eax
lea ecx, [ebp - 0x808]
mov dword [ebp - 0xd38], ecx
mov edx, dword [ebp - 0xd38]
mov dword [ebp - 0xd3c], edx
mov eax, dword [ebp - 0xd34]
mov cl, byte [eax]
mov byte [ebp - 0xd3d], cl
mov edx, dword [ebp - 0xd38]
mov al, byte [ebp - 0xd3d]
mov byte [edx], al
mov ecx, dword [ebp - 0xd34]
add ecx, 1
mov dword [ebp - 0xd34], ecx
mov edx, dword [ebp - 0xd38]
add edx, 1
mov dword [ebp - 0xd38], edx
cmp byte [ebp - 0xd3d], 0
jne 0x4045a7
push 0x2e
lea eax, [ebp - 0x400]
push eax
call fcn.00407666
add esp, 8
mov dword [ebp - 0x404], eax
cmp dword [ebp - 0x404], 0
jne 0x404626
mov ecx, dword [0x417168]
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [0x417168], 0
jmp 0x4048a6
mov edx, dword [ebp - 0x404]
mov byte [edx], 0
cmp dword [0x417150], 0
je 0x4046b6
mov eax, dword [0x417150]
movsx ecx, byte [eax]
test ecx, ecx
je 0x4046b6
mov edx, dword [0x417150]
push edx
lea eax, [ebp - 0x400]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea ecx, [ebp - 0x400]
mov dword [ebp - 0xd44], ecx
mov edx, dword [ebp - 0xd44]
add edx, 1
mov dword [ebp - 0xd48], edx
mov eax, dword [ebp - 0xd44]
mov cl, byte [eax]
mov byte [ebp - 0xd49], cl
add dword [ebp - 0xd44], 1
cmp byte [ebp - 0xd49], 0
jne 0x404673
mov edx, dword [ebp - 0xd44]
sub edx, dword [ebp - 0xd48]
mov dword [ebp - 0xd50], edx
mov eax, dword [ebp - 0xd50]
lea ecx, [ebp + eax - 0x400]
mov dword [ebp - 0x404], ecx
mov edx, dword [ebp - 0x404]
sub edx, 1
mov dword [ebp - 0x404], edx
mov eax, dword [ebp - 0x404]
movsx ecx, byte [eax]
cmp ecx, 0x20
jne 0x4046de
mov edx, dword [ebp - 0x404]
mov byte [edx], 0
jmp 0x4046b6
cmp dword [0x417168], 0
je 0x4048a6
mov eax, dword [0x417168]
push eax
call fcn.004048d0
add esp, 4
test eax, eax
jne 0x404719
mov ecx, dword [0x417168]
push ecx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [0x417168], 0
jmp 0x4048a1
push 0
call fcn.00404420
add esp, 4
push eax
push 0
call fcn.00404390
add esp, 4
push eax
call fcn.00406e60
add esp, 8
test eax, eax
jne 0x404757
mov edx, dword [0x417168]
push edx
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [0x417168], 0
jmp 0x4048a6
cmp dword [0x41714c], 0
jne 0x40489f
push 4
push 0x413aac
push 0x413c34
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
cmp eax, 6
jne 0x40489f
mov eax, dword [0x417168]
mov dword [ebp - 0xd10], eax
push 0x5c
mov ecx, dword [ebp - 0xd10]
push ecx
call fcn.00407666
add esp, 8
mov dword [ebp - 0x404], eax
cmp dword [ebp - 0x404], 0
je 0x4047c6
mov edx, dword [ebp - 0x404]
movsx eax, byte [edx + 1]
cmp eax, 0x783030
jne 0x4047c6
mov ecx, dword [ebp - 0x404]
mov byte [ecx], 0
lea edx, [ebp - 0x400]
push edx
mov eax, dword [0x417168]
push eax
push str._s_s
mov ecx, dword [0x417168]
push ecx
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
mov edx, dword [0x417168]
push edx
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x404834
mov eax, dword [0x417168]
push eax
push 0x413bf8
lea ecx, [ebp - 0xd08]
push ecx
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
push 4
push 0x413aac
lea edx, [ebp - 0xd08]
push edx
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
cmp eax, 6
jne 0x404832
jmp 0x4048a6
jmp 0x404836
jmp 0x4048a6
lea eax, [ebp - 0x808]
mov dword [ebp - 0xd54], eax
mov ecx, dword [0x417168]
mov dword [ebp - 0xd58], ecx
mov edx, dword [ebp - 0xd58]
mov dword [ebp - 0xd5c], edx
mov eax, dword [ebp - 0xd54]
mov cl, byte [eax]
mov byte [ebp - 0xd5d], cl
mov edx, dword [ebp - 0xd58]
mov al, byte [ebp - 0xd5d]
mov byte [edx], al
mov ecx, dword [ebp - 0xd54]
add ecx, 1
mov dword [ebp - 0xd54], ecx
mov edx, dword [ebp - 0xd58]
add edx, 1
mov dword [ebp - 0xd58], edx
cmp byte [ebp - 0xd5d], 0
jne 0x40485a
jmp 0x4048a1
jmp 0x4048a6
jmp 0x4046de
jmp 0x4048c7
cmp dword [0x417168], 0
je 0x4048c7
mov eax, dword [0x417168]
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov dword [0x417168], 0
mov eax, dword [0x417168]
mov esp, ebp
pop ebp
ret