Function at 0x405c50
Capabilities:
Check if file exists
Enumerate files on windows

Disassembly:
push 0xffffffffffffffff
push 0x4de783
mov eax, dword fs:[0]
push eax
sub esp, 0x374
mov eax, dword [0x526a28]
xor eax, esp
mov dword [esp + 0x370], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x526a28]
xor eax, esp
push eax
lea eax, [esp + 0x388]
mov dword fs:[0], eax
mov esi, ecx
xor ebp, ebp
push esi
mov dword [esp + 0x38], ebp
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x406067
xor eax, eax
mov word [esp + 0xc8], ax
mov edi, 7
mov eax, esi
mov dword [esp + 0xdc], edi
mov dword [esp + 0xd8], ebp
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, bp
jne 0x405cc4
sub eax, edx
sar eax, 1
push eax
mov eax, esi
lea esi, [esp + 0xc8]
call fcn.004095e0
mov dword [esp + 0x390], ebp
xor ecx, ecx
mov eax, str.C:Documents_and_SettingsAll_Users_
mov dword [esp + 0xc0], edi
mov dword [esp + 0xbc], ebp
mov word [esp + 0xac], cx
lea edx, [eax + 2]
lea esp, [esp]
mov cx, word [eax]
add eax, 2
cmp cx, bp
jne 0x405d10
sub eax, edx
sar eax, 1
push eax
mov eax, str.C:Documents_and_SettingsAll_Users_
lea esi, [esp + 0xac]
call fcn.004095e0
xor edx, edx
mov dword [esp + 0x130], edi
mov dword [esp + 0x12c], ebp
mov word [esp + 0x11c], dx
mov byte [esp + 0x390], 2
mov eax, dword [esp + 0xd8]
lea esi, [eax - 1]
cmp eax, esi
ja 0x405d6b
call fcn.00474929
mov eax, dword [esp + 0xd8]
cmp dword [esp + 0xdc], 8
mov ecx, dword [esp + 0xc8]
jae 0x405d83
lea ecx, [esp + 0xc8]
mov edx, 0x5c
cmp dx, word [ecx + esi*2]
lea esi, [esp + 0x18]
jne 0x405e31
lea edx, [eax - 1]
lea eax, [esp + 0xc4]
push eax
call fcn.00408f40
push eax
mov ebx, 0x5192d8
lea esi, [esp + 0xe4]
mov byte [esp + 0x394], 3
call fcn.00409f80
add esp, 4
push 0xffffffffffffffff
push ebp
lea ecx, [esp + 0x120]
mov byte [esp + 0x398], 4
call fcn.004091e0
mov ebx, 8
cmp dword [esp + 0xf8], ebx
jb 0x405df8
mov ecx, dword [esp + 0xe4]
push ecx
call fcn.0040b651
add esp, 4
xor edx, edx
mov byte [esp + 0x390], 2
mov dword [esp + 0xf8], 7
mov dword [esp + 0xf4], ebp
mov word [esp + 0xe4], dx
cmp dword [esp + 0x30], ebx
jb 0x405e7e
mov eax, dword [esp + 0x1c]
push eax
call fcn.0040b651
add esp, 4
jmp 0x405e7e
lea ecx, [esp + 0xc4]
push ecx
mov ebx, 0x5192d8
call fcn.00409f80
add esp, 4
push 0xffffffffffffffff
push ebp
lea ecx, [esp + 0x120]
mov byte [esp + 0x398], 5
call fcn.004091e0
mov byte [esp + 0x390], 2
cmp dword [esp + 0x30], 8
jb 0x405e79
mov edx, dword [esp + 0x1c]
push edx
call fcn.0040b651
add esp, 4
mov ebx, 8
mov eax, dword [esp + 0xbc]
lea esi, [eax - 1]
cmp eax, esi
ja 0x405e98
call fcn.00474929
mov eax, dword [esp + 0xbc]
mov ecx, dword [esp + 0xac]
cmp dword [esp + 0xc0], ebx
jae 0x405eaf
lea ecx, [esp + 0xac]
mov edx, 0x5c
cmp dx, word [ecx + esi*2]
jne 0x405f02
lea edx, [eax - 1]
lea eax, [esp + 0xa8]
push eax
lea esi, [esp + 0x1c]
call fcn.00408f40
push 0xffffffffffffffff
push ebp
lea ecx, [esp + 0xb0]
mov byte [esp + 0x398], 6
call fcn.004091e0
mov byte [esp + 0x390], 2
cmp dword [esp + 0x30], ebx
jb 0x405f13
mov ecx, dword [esp + 0x1c]
push ecx
call fcn.0040b651
add esp, 4
jmp 0x405f13
push 0xffffffffffffffff
lea eax, [esp + 0xac]
push ebp
mov ecx, eax
call fcn.004091e0
push 4
call fcn.0040b622
add esp, 4
cmp eax, ebp
je 0x405f29
lea edx, [esp + 0x58]
mov dword [eax], edx
jmp 0x405f2b
xor eax, eax
mov dword [esp + 0x58], eax
mov dword [esp + 0x68], ebp
mov dword [esp + 0x6c], ebp
mov dword [esp + 0x70], ebp
mov dword [esp + 0x74], ebp
push 4
mov byte [esp + 0x394], 7
call fcn.0040b622
add esp, 4
cmp eax, ebp
je 0x405f5d
lea ecx, [esp + 0x78]
mov dword [eax], ecx
jmp 0x405f5f
xor eax, eax
mov dword [esp + 0x78], eax
mov dword [esp + 0x88], ebp
mov dword [esp + 0x8c], ebp
mov dword [esp + 0x90], ebp
mov dword [esp + 0x94], ebp
mov byte [esp + 0x390], bl
mov eax, dword [esp + 0x11c]
cmp dword [esp + 0x130], ebx
jae 0x405f9d
lea eax, [esp + 0x11c]
lea edx, [esp + 0x134]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov edi, eax
mov dword [esp + 0x38], edi
cmp edi, 0xffffffff
jne 0x406070
lea esi, [esp + 0x78]
call fcn.00409290
mov eax, dword [esp + 0x78]
push eax
call fcn.0040b651
add esp, 4
lea esi, [esp + 0x58]
call fcn.00409290
mov ecx, dword [esp + 0x58]
push ecx
call fcn.0040b651
add esp, 4
cmp dword [esp + 0x130], ebx
jb 0x406000
mov edx, dword [esp + 0x11c]
push edx
call fcn.0040b651
add esp, 4
xor eax, eax
mov esi, 7
mov dword [esp + 0x130], esi
mov dword [esp + 0x12c], ebp
mov word [esp + 0x11c], ax
cmp dword [esp + 0xc0], ebx
jb 0x406036
mov ecx, dword [esp + 0xac]
push ecx
call fcn.0040b651
add esp, 4
xor edx, edx
mov dword [esp + 0xc0], esi
mov dword [esp + 0xbc], ebp
mov word [esp + 0xac], dx
cmp dword [esp + 0xdc], ebx
jb 0x406067
mov eax, dword [esp + 0xc8]
push eax
call fcn.0040b651
add esp, 4
xor eax, eax
jmp 0x4067d7
test byte [esp + 0x134], 0x10
je 0x40636e
cmp word [esp + 0x160], 0x2e
je 0x406670
mov eax, 7
xor ecx, ecx
mov dword [esp + 0xf8], eax
mov dword [esp + 0xf4], ebp
mov word [esp + 0xe4], cx
xor edx, edx
mov dword [esp + 0x114], eax
mov dword [esp + 0x110], ebp
mov word [esp + 0x100], dx
mov byte [esp + 0x390], 0xa
mov eax, dword [esp + 0xd8]
lea esi, [eax - 1]
cmp eax, esi
ja 0x4060dd
call fcn.00474929
mov eax, dword [esp + 0xc8]
cmp dword [esp + 0xdc], ebx
jae 0x4060f4
lea eax, [esp + 0xc8]
cmp word [eax + esi*2], 0x5c
lea esi, [esp + 0x3c]
je 0x40618b
lea eax, [esp + 0xc4]
push eax
mov ebx, 0x5192e4
call fcn.00409f80
add esp, 4
push eax
lea ebx, [esp + 0x164]
lea esi, [esp + 0x1c]
mov byte [esp + 0x394], 0xb
call fcn.00409f80
add esp, 4
push 0xffffffffffffffff
push ebp
lea ecx, [esp + 0xe8]
mov byte [esp + 0x398], 0xc
call fcn.004091e0
mov esi, 8
cmp dword [esp + 0x30], esi
jb 0x406163
mov ecx, dword [esp + 0x1c]
push ecx
call fcn.0040b651
add esp, 4
xor edx, edx
mov byte [esp + 0x390], 0xa
mov dword [esp + 0x30], 7
mov dword [esp + 0x2c], ebp
mov word [esp + 0x1c], dx
cmp dword [esp + 0x54], esi
jb 0x4061d5
mov eax, dword [esp + 0x40]
push eax
jmp 0x4061cd
lea ecx, [esp + 0xc4]
push ecx
lea ebx, [esp + 0x164]
call fcn.00409f80
add esp, 4
push 0xffffffffffffffff
push ebp
lea ecx, [esp + 0xe8]
mov byte [esp + 0x398], 0xd
call fcn.004091e0
mov byte [esp + 0x390], 0xa
cmp dword [esp + 0x54], 8
jb 0x4061d5
mov edx, dword [esp + 0x40]
push edx
call fcn.0040b651
add esp, 4
mov eax, dword [esp + 0xbc]
lea esi, [eax - 1]
cmp eax, esi
ja 0x4061e8
call fcn.00474929
cmp dword [esp + 0xc0], 8
mov eax, dword [esp + 0xac]
jae 0x406200
lea eax, [esp + 0xac]
cmp word [eax + esi*2], 0x5c
lea esi, [esp + 0x3c]
je 0x40629f
lea eax, [esp + 0xa8]
push eax
mov ebx, 0x5192e4
call fcn.00409f80
add esp, 4
push eax
lea ebx, [esp + 0x164]
lea esi, [esp + 0x1c]
mov byte [esp + 0x394], 0xe
call fcn.00409f80
add esp, 4
push 0xffffffffffffffff
push ebp
lea ecx, [esp + 0x104]
mov byte [esp + 0x398], 0xf
call fcn.004091e0
mov ebx, 8
cmp dword [esp + 0x30], ebx
jb 0x40626f
mov ecx, dword [esp + 0x1c]
push ecx
call fcn.0040b651
add esp, 4
xor edx, edx
mov byte [esp + 0x390], 0xa
mov dword [esp + 0x30], 7
mov dword [esp + 0x2c], ebp
mov word [esp + 0x1c], dx
cmp dword [esp + 0x54], ebx
jb 0x4062ee
mov eax, dword [esp + 0x40]
push eax
call fcn.0040b651
add esp, 4
jmp 0x4062ee
lea ecx, [esp + 0xa8]
push ecx
lea ebx, [esp + 0x164]
call fcn.00409f80
add esp, 4
push 0xffffffffffffffff
push ebp
lea ecx, [esp + 0x104]
mov byte [esp + 0x398], 0x10
call fcn.004091e0
mov byte [esp + 0x390], 0xa
cmp dword [esp + 0x54], 8
jb 0x4062e9
mov edx, dword [esp + 0x40]
push edx
call fcn.0040b651
add esp, 4
mov ebx, 8
lea eax, [esp + 0xe0]
push eax
lea eax, [esp + 0x5c]
call fcn.00409020
lea ecx, [esp + 0xfc]
push ecx
lea eax, [esp + 0x7c]
call fcn.00409020
cmp dword [esp + 0x114], ebx
jb 0x406329
mov edx, dword [esp + 0x100]
push edx
call fcn.0040b651
add esp, 4
xor eax, eax
mov byte [esp + 0x390], bl
mov dword [esp + 0x114], 7
mov dword [esp + 0x110], ebp
mov word [esp + 0x100], ax
cmp dword [esp + 0xf8], ebx
jb 0x406667
mov ecx, dword [esp + 0xe4]
push ecx
call fcn.0040b651
add esp, 4
jmp 0x40666b
mov eax, 7
xor edx, edx
mov dword [esp + 0xf8], eax
mov dword [esp + 0xf4], ebp
mov word [esp + 0xe4], dx
mov dword [esp + 0x114], eax
xor eax, eax
mov dword [esp + 0x110], ebp
mov word [esp + 0x100], ax
mov byte [esp + 0x390], 0x12
mov eax, dword [esp + 0xd8]
lea esi, [eax - 1]
cmp eax, esi
ja 0x4063be
call fcn.00474929
mov eax, dword [esp + 0xc8]
cmp dword [esp + 0xdc], ebx
jae 0x4063d5
lea eax, [esp + 0xc8]
cmp word [eax + esi*2], 0x5c
lea esi, [esp + 0x3c]
je 0x40646c
lea ecx, [esp + 0xc4]
push ecx
mov ebx, 0x5192e4
call fcn.00409f80
add esp, 4
push eax
lea ebx, [esp + 0x164]
lea esi, [esp + 0x1c]
mov byte [esp + 0x394], 0x13
call fcn.00409f80
add esp, 4
push 0xffffffffffffffff
push ebp
lea ecx, [esp + 0xe8]
mov byte [esp + 0x398], 0x14
call fcn.004091e0
mov esi, 8
cmp dword [esp + 0x30], esi
jb 0x406444
mov edx, dword [esp + 0x1c]
push edx
call fcn.0040b651
add esp, 4
xor eax, eax
mov byte [esp + 0x390], 0x12
mov dword [esp + 0x30], 7
mov dword [esp + 0x2c], ebp
mov word [esp + 0x1c], ax
cmp dword [esp + 0x54], esi
jb 0x4064b6
mov ecx, dword [esp + 0x40]
push ecx
jmp 0x4064ae
lea edx, [esp + 0xc4]
push edx
lea ebx, [esp + 0x164]
call fcn.00409f80
add esp, 4
push 0xffffffffffffffff
push ebp
lea ecx, [esp + 0xe8]
mov byte [esp + 0x398], 0x15
call fcn.004091e0
mov byte [esp + 0x390], 0x12
cmp dword [esp + 0x54], 8
jb 0x4064b6
mov eax, dword [esp + 0x40]
push eax
call fcn.0040b651
add esp, 4
mov eax, dword [esp + 0xbc]
lea esi, [eax - 1]
cmp eax, esi
ja 0x4064c9
call fcn.00474929
cmp dword [esp + 0xc0], 8
mov eax, dword [esp + 0xac]
jae 0x4064e1
lea eax, [esp + 0xac]
cmp word [eax + esi*2], 0x5c
lea esi, [esp + 0x3c]
je 0x406580
lea ecx, [esp + 0xa8]
push ecx
mov ebx, 0x5192e4
call fcn.00409f80
add esp, 4
push eax
lea ebx, [esp + 0x164]
lea esi, [esp + 0x1c]
mov byte [esp + 0x394], 0x16
call fcn.00409f80
add esp, 4
push 0xffffffffffffffff
push ebp
lea ecx, [esp + 0x104]
mov byte [esp + 0x398], 0x17
call fcn.004091e0
mov ebx, 8
cmp dword [esp + 0x30], ebx
jb 0x406550
mov edx, dword [esp + 0x1c]
push edx
call fcn.0040b651
add esp, 4
xor eax, eax
mov byte [esp + 0x390], 0x12
mov dword [esp + 0x30], 7
mov dword [esp + 0x2c], ebp
mov word [esp + 0x1c], ax
cmp dword [esp + 0x54], ebx
jb 0x4065cf
mov ecx, dword [esp + 0x40]
push ecx
call fcn.0040b651
add esp, 4
jmp 0x4065cf
lea edx, [esp + 0xa8]
push edx
lea ebx, [esp + 0x164]
call fcn.00409f80
add esp, 4
push 0xffffffffffffffff
push ebp
lea ecx, [esp + 0x104]
mov byte [esp + 0x398], 0x18
call fcn.004091e0
mov byte [esp + 0x390], 0x12
cmp dword [esp + 0x54], 8
jb 0x4065ca
mov eax, dword [esp + 0x40]
push eax
call fcn.0040b651
add esp, 4
mov ebx, 8
mov esi, dword [esp + 0x100]
cmp dword [esp + 0x114], ebx
jae 0x4065e6
lea esi, [esp + 0x100]
mov edi, dword [esp + 0xe4]
cmp dword [esp + 0xf8], ebx
jae 0x4065fd
lea edi, [esp + 0xe4]
call fcn.00405b50
test eax, eax
je 0x40660c
inc dword [esp + 0x34]
jmp 0x406612
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp dword [esp + 0x114], ebx
jb 0x40662b
mov ecx, dword [esp + 0x100]
push ecx
call fcn.0040b651
add esp, 4
xor edx, edx
mov byte [esp + 0x390], bl
mov dword [esp + 0x114], 7
mov dword [esp + 0x110], ebp
mov word [esp + 0x100], dx
cmp dword [esp + 0xf8], ebx
jb 0x406667
mov eax, dword [esp + 0xe4]
push eax
call fcn.0040b651
add esp, 4
mov edi, dword [esp + 0x38]
mov ebx, 8
lea ecx, [esp + 0x134]
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x406070
push edi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov eax, dword [esp + 0x74]
cmp eax, ebp
je 0x406783
mov esi, dword [esp + 0x70]
add eax, esi
cmp esi, eax
jbe 0x4066a9
call fcn.0043a94b
mov edx, dword [esp + 0x58]
mov dword [esp + 0xa4], esi
lea esi, [esp + 0xa0]
mov dword [esp + 0xa0], edx
call fcn.00409e30
push 0xffffffffffffffff
push ebp
lea ecx, [esp + 0x120]
call fcn.004091e0
push 0xffffffffffffffff
push ebp
lea ecx, [esp + 0xcc]
call fcn.004091e0
mov eax, dword [esp + 0x90]
mov ecx, dword [esp + 0x94]
add ecx, eax
mov esi, eax
cmp eax, ecx
jbe 0x406700
call fcn.0043a94b
mov edx, dword [esp + 0x78]
mov dword [esp + 0x9c], esi
lea esi, [esp + 0x98]
mov dword [esp + 0x98], edx
call fcn.00409e30
push 0xffffffffffffffff
push ebp
lea ecx, [esp + 0xb0]
call fcn.004091e0
push 4
mov eax, 0x5192d8
lea ecx, [esp + 0x11c]
call fcn.00409500
lea esi, [esp + 0x58]
call fcn.00409080
lea esi, [esp + 0x78]
call fcn.00409080
mov eax, dword [esp + 0x11c]
cmp dword [esp + 0x130], ebx
jae 0x406769
lea eax, [esp + 0x11c]
lea ecx, [esp + 0x134]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov edi, eax
mov dword [esp + 0x38], edi
jmp 0x406070
lea esi, [esp + 0x78]
call fcn.00409290
mov edx, dword [esp + 0x78]
push edx
call fcn.0040b651
add esp, 4
lea esi, [esp + 0x58]
call fcn.00409290
mov eax, dword [esp + 0x58]
push eax
call fcn.0040b651
add esp, 4
lea esi, [esp + 0x118]
call fcn.00408f10
lea esi, [esp + 0xa8]
call fcn.00408f10
lea esi, [esp + 0xc4]
call fcn.00408f10
mov eax, dword [esp + 0x34]
mov ecx, dword [esp + 0x388]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x370]
xor ecx, esp
call fcn.00431c7a
add esp, 0x380
ret