Function at 0x41f772
Capabilities:
Check if file exists
Enumerate files on windows
Enumerate files recursively
Get file attributes

Disassembly:
mov eax, 0x45cd40
call fcn.0045c170
sub esp, 0xacc
mov ax, word [0x45ec14]
push ebx
push esi
mov esi, dword [ebp + 0x10]
push edi
mov word [ebp - 0x8d0], ax
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x8ce]
mov dword [ebp - 0x10], esp
rep stosd dword es:[edi], eax
push esi
stosw word es:[edi], ax
call dword [sym.imp.USER32.dll_GetMenuItemCount]
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x68], eax
mov eax, dword [ebp + 0x18]
push 0xc
mov dword [ebp - 0x1c], eax
pop ecx
xor eax, eax
cmp dword [ebp + 0x24], 0xffffffff
lea edi, [ebp - 0x60]
rep stosd dword es:[edi], eax
mov dword [ebp - 0x60], 0x30
jne 0x41f7ec
lea eax, [ebp + 0x24]
push eax
lea eax, [ebp + 0x10]
push eax
call fcn.00426f94
mov eax, dword [ebp + 0x24]
pop ecx
cdq
idiv dword [ebp + 0x10]
pop ecx
mov dword [ebp + 0x24], eax
cmp dword [ebp + 0x20], 0xffffffff
mov dword [ebp - 0x64], esi
jne 0x41f7fc
mov dword [ebp + 0x20], 0x3501
mov al, byte [ebp + 0xb]
xor esi, esi
mov byte [ebp - 0x30], al
mov dword [ebp - 0x2c], esi
mov dword [ebp - 0x28], esi
mov dword [ebp - 0x24], esi
push 0x40ab14
lea eax, [ebp - 0x6c8]
push dword [ebp + 0x14]
mov dword [ebp - 4], esi
mov byte [ebp - 4], 1
push 0x40ab08
push 0x104
push eax
call dword [sym.imp.MSVCRT.dll__snwprintf]
add esp, 0x14
lea eax, [ebp - 0x2b8]
mov word [ebp - 0x4c2], si
push eax
lea eax, [ebp - 0x6c8]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov ebx, dword [ebp + 0xc]
cmp eax, 0xffffffff
mov dword [ebp + 0x18], eax
je 0x41fc65
mov edi, dword [sym.imp.MSVCRT.dll_wcscmp]
lea eax, [ebp - 0x28c]
push 0x40ab04
push eax
call edi
pop ecx
test eax, eax
pop ecx
je 0x41fc4d
lea eax, [ebp - 0x28c]
push 0x40aafc
push eax
call edi
pop ecx
test eax, eax
pop ecx
je 0x41fc4d
test byte [ebp - 0x2b8], 0x10
je 0x41fc4d
cmp dword [0x472870], esi
je 0x41f8b8
test byte [ebp - 0x2b8], 2
jne 0x41fc4d
lea eax, [ebp - 0x28c]
push eax
lea eax, [ebp - 0x4c0]
push dword [ebp + 0x14]
push 0x40ab2c
push 0x104
push eax
call dword [sym.imp.MSVCRT.dll__snwprintf]
add esp, 0x14
mov word [ebp - 0x2ba], si
call dword [sym.imp.USER32.dll_CreatePopupMenu]
push 0xc
mov dword [ebp + 0x10], eax
pop ecx
xor eax, eax
lea edi, [ebp - 0x60]
push 0x208
rep stosd dword es:[edi], eax
lea eax, [ebp - 0xad8]
mov dword [ebp - 0x60], 0x30
push eax
push 0xc9
push dword [0x531f10]
call dword [sym.imp.USER32.dll_LoadStringW]
mov eax, dword [ebx]
mov dword [ebp - 0x5c], 0x42
add eax, dword [ebp + 0x20]
mov dword [ebp - 0x58], esi
mov dword [ebp - 0x50], eax
lea eax, [ebp - 0xad8]
mov dword [ebp - 0x3c], eax
lea eax, [ebp - 0xad8]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
mov dword [ebp - 0x38], eax
push esi
push 0xffffffffffffffff
lea eax, [ebp - 0x60]
push esi
push eax
push 1
push esi
push dword [ebp + 0x10]
call fcn.004321a2
mov ecx, dword [ebp + 8]
add esp, 0x20
mov edx, dword [ecx + 4]
cmp edx, esi
jne 0x41f969
xor eax, eax
jmp 0x41f971
mov eax, dword [ecx + 8]
sub eax, edx
sar eax, 2
mov edx, dword [ebx]
cmp eax, edx
ja 0x41f98a
lea eax, [ebp - 0x18]
add edx, 0x1f4
push eax
push edx
mov dword [ebp - 0x18], esi
call fcn.004207fb
lea eax, [ebp - 0x4c0]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
mov ecx, dword [ebx]
lea esi, [eax + eax + 4]
mov eax, dword [ebp + 8]
push esi
mov eax, dword [eax + 4]
lea edi, [eax + ecx*4]
call dword [sym.imp.MSVCRT.dll_malloc]
pop ecx
mov dword [edi], eax
mov edx, dword [ebx]
pop ecx
mov ecx, dword [ebp + 8]
push 0xc
mov eax, dword [ecx + 4]
mov eax, dword [eax + edx*4]
mov dx, word [0x40ab28]
mov word [eax], dx
mov eax, dword [ecx + 4]
mov edx, dword [ebx]
lea ecx, [esi - 2]
lea esi, [ebp - 0x4c0]
mov edi, dword [eax + edx*4]
mov eax, ecx
inc edi
inc edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
inc dword [ebx]
pop ecx
lea edi, [ebp - 0x60]
push 0x208
rep stosd dword es:[edi], eax
lea eax, [ebp - 0xad8]
mov dword [ebp - 0x60], 0x30
push eax
push 0x96
push dword [0x531f10]
call dword [sym.imp.USER32.dll_LoadStringW]
mov eax, dword [ebx]
xor esi, esi
add eax, dword [ebp + 0x20]
mov dword [ebp - 0x5c], 0x42
mov dword [ebp - 0x58], esi
mov dword [ebp - 0x50], eax
lea eax, [ebp - 0xad8]
mov dword [ebp - 0x3c], eax
lea eax, [ebp - 0xad8]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
mov dword [ebp - 0x38], eax
push esi
push 0xffffffffffffffff
lea eax, [ebp - 0x60]
push esi
push eax
push 1
push 1
push dword [ebp + 0x10]
call fcn.004321a2
add esp, 0x20
xor eax, eax
lea edi, [ebp - 0x60]
push 0xc
pop ecx
push 0x30
pop esi
push eax
push 0xffffffffffffffff
rep stosd dword es:[edi], eax
push eax
mov dword [ebp - 0x60], esi
mov dword [ebp - 0x5c], 0x100
mov dword [ebp - 0x58], 0x800
lea eax, [ebp - 0x60]
push eax
push 1
push 2
push dword [ebp + 0x10]
call fcn.004321a2
add esp, 0x1c
xor eax, eax
cmp dword [0x472854], 0
lea edi, [ebp - 0x60]
push 0xc
pop ecx
rep stosd dword es:[edi], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x60], esi
mov dword [ebp - 0x5c], 0x167
mov dword [ebp - 0x4c], eax
jne 0x41fac5
mov eax, dword [ebp - 0x20]
cdq
idiv dword [ebp + 0x24]
test edx, edx
jne 0x41fac5
mov dword [ebp - 0x58], 0x20
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 4]
test edx, edx
jne 0x41fad3
xor eax, eax
jmp 0x41fadb
mov eax, dword [ecx + 8]
sub eax, edx
sar eax, 2
mov edx, dword [ebx]
cmp eax, edx
ja 0x41faf5
and dword [ebp - 0x18], 0
lea eax, [ebp - 0x18]
add edx, 0x1f4
push eax
push edx
call fcn.004207fb
lea eax, [ebp - 0x4c0]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
mov ecx, dword [ebx]
lea edi, [eax + eax + 2]
mov eax, dword [ebp + 8]
push edi
mov eax, dword [eax + 4]
lea esi, [eax + ecx*4]
call dword [sym.imp.MSVCRT.dll_malloc]
mov dword [esi], eax
mov eax, dword [ebp + 8]
mov edx, dword [ebx]
mov ecx, edi
mov eax, dword [eax + 4]
lea esi, [ebp - 0x4c0]
push 0x208
mov edi, dword [eax + edx*4]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
inc dword [ebx]
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
mov edi, dword [sym.imp.MSVCRT.dll__snwprintf]
add esp, 0xc
mov esi, eax
lea eax, [ebp - 0x28c]
push eax
push 0x40a36c
push 0x104
push esi
call edi
and word [esi + 0x206], 0
push 1
push dword [0x472850]
push esi
call fcn.0042631e
add esp, 0x1c
mov dword [ebp - 0x3c], eax
push esi
call dword [sym.imp.MSVCRT.dll_wcslen]
mov dword [ebp - 0x38], eax
mov eax, dword [ebx]
add eax, dword [ebp + 0x20]
pop ecx
mov dword [ebp - 0x50], eax
lea eax, [ebp - 0x28c]
push eax
lea eax, [ebp - 0x8d0]
push dword [ebp + 0x14]
push 0x40ab08
push 0x207
push eax
call edi
lea eax, [ebp - 0x8d0]
add esp, 0x14
test eax, eax
jne 0x41fbc3
xor esi, esi
jmp 0x41fbfc
lea eax, [ebp - 0x8d0]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea edi, [eax + eax + 2]
mov eax, edi
add eax, 3
and al, 0xfc
call fcn.0045c140
xor eax, eax
mov esi, esp
push eax
push eax
and byte [esi], 0
push edi
push esi
lea ecx, [ebp - 0x8d0]
push 0xffffffffffffffff
push ecx
push eax
push eax
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
push esi
call fcn.00457b3f
neg eax
sbb eax, eax
pop ecx
and eax, 6
lea ecx, [ebp - 0x30]
inc eax
inc eax
inc dword [ebx]
mov dword [ebp - 0x40], eax
lea eax, [ebp - 0x60]
push eax
call fcn.00420877
push dword [ebp + 0x24]
mov eax, dword [ebp + 0x1c]
inc eax
push dword [ebp + 0x20]
push eax
push dword [ebp + 0x10]
call dword [sym.imp.USER32.dll_GetMenuItemCount]
push eax
lea eax, [ebp - 0x4c0]
push eax
push dword [ebp + 0x10]
push ebx
push dword [ebp + 8]
call fcn.0041f772
add esp, 0x20
inc dword [ebp - 0x20]
xor esi, esi
lea eax, [ebp - 0x2b8]
push eax
push dword [ebp + 0x18]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x41f860
push dword [ebp + 0x18]
call dword [sym.imp.KERNEL32.dll_FindClose]
lea eax, [ebp - 0x30]
push eax
call fcn.0041f61e
cmp dword [ebp - 0x2c], esi
pop ecx
jne 0x41fc82
mov dword [ebp - 0x14], esi
jmp 0x41fc91
mov eax, dword [ebp - 0x28]
push 0x30
sub eax, dword [ebp - 0x2c]
pop ecx
cdq
idiv ecx
mov dword [ebp - 0x14], eax
mov dword [ebp + 0x10], esi
mov eax, dword [ebp - 0x14]
cmp dword [ebp + 0x10], eax
jge 0x41fcf0
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp - 0x2c]
push 0xc
lea edi, [ebp - 0x60]
lea eax, [eax + eax*2]
shl eax, 4
mov dword [ebp - 0x18], eax
lea esi, [eax + ecx]
pop ecx
push 0
lea eax, [ebp - 0x60]
rep movsd dword es:[edi], dword [esi]
push dword [ebp - 0x40]
push 0
push eax
push 1
push dword [ebp - 0x1c]
push dword [ebp - 0x64]
call fcn.004321a2
mov eax, dword [ebp - 0x18]
mov ecx, dword [ebp - 0x2c]
add esp, 0x1c
mov eax, dword [eax + ecx + 0x24]
test eax, eax
je 0x41fce6
push eax
call fcn.0045c12b
pop ecx
inc dword [ebp - 0x1c]
inc dword [ebp + 0x10]
xor esi, esi
jmp 0x41fc94
lea ecx, [ebp - 0x30]
call fcn.0042086b
push 0x40ab14
lea eax, [ebp - 0x6c8]
push dword [ebp + 0x14]
push 0x40ab08
push 0x104
push eax
call dword [sym.imp.MSVCRT.dll__snwprintf]
add esp, 0x14
lea eax, [ebp - 0x2b8]
mov word [ebp - 0x4c2], si
push eax
lea eax, [ebp - 0x6c8]
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
cmp eax, 0xffffffff
mov dword [ebp + 0x18], eax
je 0x41ffdf
mov edi, dword [sym.imp.MSVCRT.dll_wcscmp]
lea eax, [ebp - 0x28c]
push 0x40ab04
push eax
call edi
pop ecx
test eax, eax
pop ecx
je 0x41ffc7
lea eax, [ebp - 0x28c]
push 0x40aafc
push eax
call edi
pop ecx
test eax, eax
pop ecx
je 0x41ffc7
test byte [ebp - 0x2b8], 0x10
jne 0x41ffc7
cmp dword [0x472870], esi
je 0x41fd99
test byte [ebp - 0x2b8], 2
jne 0x41ffc7
lea eax, [ebp - 0x28c]
push eax
lea eax, [ebp - 0x4c0]
push dword [ebp + 0x14]
push 0x40ab08
push 0x104
push eax
call dword [sym.imp.MSVCRT.dll__snwprintf]
add esp, 0x14
lea eax, [ebp - 0x4c0]
mov word [ebp - 0x2ba], si
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x41fdde
test al, 2
jne 0x41ffc7
lea eax, [ebp - 0x4c0]
test eax, eax
jne 0x41fdec
xor edi, edi
jmp 0x41fe26
lea eax, [ebp - 0x4c0]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea eax, [eax + eax + 2]
mov dword [ebp + 0x10], eax
add eax, 3
and al, 0xfc
call fcn.0045c140
mov edi, esp
push esi
push esi
lea eax, [ebp - 0x4c0]
push dword [ebp + 0x10]
and byte [edi], 0
push edi
push 0xffffffffffffffff
push eax
push esi
push esi
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
push edi
call fcn.00457b3f
cmp eax, esi
pop ecx
lea eax, [ebp - 0x28c]
push eax
je 0x41fe69
call fcn.004267f1
cmp eax, esi
pop ecx
je 0x41fe4b
mov dword [ebp - 0x14], 7
jmp 0x41fe98
lea eax, [ebp - 0x28c]
push eax
call fcn.00426792
cmp eax, esi
pop ecx
je 0x41ffc7
mov dword [ebp - 0x14], 9
jmp 0x41fe98
call fcn.004267f1
cmp eax, esi
pop ecx
je 0x41fe7c
mov dword [ebp - 0x14], 3
jmp 0x41fe98
lea eax, [ebp - 0x28c]
push eax
call fcn.00426792
cmp eax, esi
pop ecx
je 0x41ffc7
mov dword [ebp - 0x14], 4
push 0x208
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
pop ecx
mov dword [ebp + 0x10], eax
mov edi, dword [ebp + 0x10]
mov ecx, 0x82
xor eax, eax
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x28c]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
sub eax, 4
push eax
lea eax, [ebp - 0x28c]
push eax
push dword [ebp + 0x10]
call dword [sym.imp.MSVCRT.dll_wcsncpy]
add esp, 0x10
xor eax, eax
cmp dword [0x472854], esi
lea edi, [ebp - 0x60]
push 0xc
pop ecx
rep stosd dword es:[edi], eax
mov dword [ebp - 0x60], 0x30
mov dword [ebp - 0x5c], 0x163
jne 0x41ff08
mov eax, dword [ebp - 0x20]
cdq
idiv dword [ebp + 0x24]
test edx, edx
jne 0x41ff08
mov dword [ebp - 0x58], 0x20
mov eax, dword [ebx]
mov ecx, dword [ebp + 0x20]
add ecx, eax
mov dword [ebp - 0x54], 8
mov dword [ebp - 0x50], ecx
mov ecx, dword [ebp + 8]
mov edi, dword [ecx + 4]
cmp edi, esi
jne 0x41ff27
xor edx, edx
jmp 0x41ff2f
mov edx, dword [ecx + 8]
sub edx, edi
sar edx, 2
cmp edx, eax
ja 0x41ff45
lea edx, [ebp - 0x18]
add eax, 0x1f4
push edx
push eax
mov dword [ebp - 0x18], esi
call fcn.004207fb
lea eax, [ebp - 0x4c0]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
mov ecx, dword [ebx]
lea edi, [eax + eax + 2]
mov eax, dword [ebp + 8]
push edi
mov eax, dword [eax + 4]
lea esi, [eax + ecx*4]
call dword [sym.imp.MSVCRT.dll_malloc]
mov dword [esi], eax
mov eax, dword [ebp + 8]
mov edx, dword [ebx]
mov ecx, edi
mov eax, dword [eax + 4]
lea esi, [ebp - 0x4c0]
push 1
mov edi, dword [eax + edx*4]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
push dword [0x472850]
push dword [ebp + 0x10]
call fcn.0042631e
add esp, 0x14
mov dword [ebp - 0x3c], eax
push dword [ebp + 0x10]
call dword [sym.imp.MSVCRT.dll_wcslen]
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x40], eax
pop ecx
lea eax, [ebp - 0x60]
lea ecx, [ebp - 0x30]
push eax
call fcn.00420877
inc dword [ebx]
inc dword [ebp - 0x20]
xor esi, esi
lea eax, [ebp - 0x2b8]
push eax
push dword [ebp + 0x18]
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x41fd41
push dword [ebp + 0x18]
call dword [sym.imp.KERNEL32.dll_FindClose]
or dword [ebp + 0x18], 0xffffffff
lea eax, [ebp - 0x30]
push eax
call fcn.0041f61e
cmp dword [ebp - 0x2c], esi
pop ecx
jne 0x420000
mov dword [ebp - 0x14], esi
jmp 0x42000f
mov eax, dword [ebp - 0x28]
push 0x30
sub eax, dword [ebp - 0x2c]
pop ecx
cdq
idiv ecx
mov dword [ebp - 0x14], eax
mov dword [ebp + 0x10], esi
mov eax, dword [ebp - 0x14]
cmp dword [ebp + 0x10], eax
jge 0x42006c
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp - 0x2c]
push 0xc
lea edi, [ebp - 0x60]
lea eax, [eax + eax*2]
shl eax, 4
mov dword [ebp - 0x18], eax
lea esi, [eax + ecx]
pop ecx
push 0
lea eax, [ebp - 0x60]
rep movsd dword es:[edi], dword [esi]
push dword [ebp - 0x40]
push 0
push eax
push 1
push dword [ebp - 0x1c]
push dword [ebp - 0x64]
call fcn.004321a2
mov eax, dword [ebp - 0x18]
mov ecx, dword [ebp - 0x2c]
add esp, 0x1c
mov eax, dword [eax + ecx + 0x24]
test eax, eax
je 0x420064
push eax
call fcn.0045c12b
pop ecx
inc dword [ebp - 0x1c]
inc dword [ebp + 0x10]
jmp 0x420012
lea ecx, [ebp - 0x30]
call fcn.0042086b
jmp 0x42008e
mov eax, dword [ebp - 0x20]
and dword [ebp - 4], 0
cmp eax, dword [ebp - 0x68]
mov esi, dword [ebp + 8]
jne 0x42015a
cmp dword [ebp + 0x1c], 1
je 0x42015a
lea eax, [ebp - 0x4c0]
push 0x208
push eax
push 0x95
push dword [0x531f10]
call dword [sym.imp.USER32.dll_LoadStringW]
push 0xc
xor eax, eax
pop ecx
lea edi, [ebp - 0x60]
rep stosd dword es:[edi], eax
mov eax, dword [ebx]
mov ecx, dword [ebp + 0x20]
add ecx, eax
mov dword [ebp - 0x60], 0x30
mov dword [ebp - 0x50], ecx
mov ecx, dword [esi + 4]
test ecx, ecx
mov dword [ebp - 0x5c], 0x43
mov dword [ebp - 0x54], 3
jne 0x4200fc
xor edx, edx
jmp 0x420104
mov edx, dword [esi + 8]
sub edx, ecx
sar edx, 2
cmp edx, eax
ja 0x42011d
and dword [ebp + 8], 0
lea ecx, [ebp + 8]
add eax, 0x1f4
push ecx
push eax
mov ecx, esi
call fcn.004207fb
mov esi, dword [esi + 4]
mov eax, dword [ebx]
xor edi, edi
mov dword [esi + eax*4], edi
lea eax, [ebp - 0x4c0]
mov dword [ebp - 0x3c], eax
lea eax, [ebp - 0x4c0]
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
mov dword [ebp - 0x38], eax
push edi
push 0xffffffffffffffff
lea eax, [ebp - 0x60]
push edi
push eax
push 1
push dword [ebp - 0x1c]
push dword [ebp - 0x64]
call fcn.004321a2
add esp, 0x20
inc dword [ebx]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x30]
call fcn.0042af29
mov ecx, dword [ebp - 0xc]
push 1
pop eax
mov dword fs:[0], ecx
lea esp, [ebp - 0xae4]
pop edi
pop esi
pop ebx
leave
ret