Function at 0x408520
Capabilities:
Enumerate files on windows
Get common file path

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x43d379
push eax
mov eax, dword [esp + 0x10]
mov dword fs:[0], esp
sub esp, 0x6bc
push ebx
push ebp
push esi
mov esi, ecx
xor ebx, ebx
cmp eax, ebx
mov dword [esi + 0x30], eax
jne 0x408554
xor eax, eax
jmp 0x4087de
push 1
lea eax, [esp + 0x24]
push 0x1a
push eax
push ebx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
jge 0x40856f
xor eax, eax
jmp 0x4087de
mov ebp, dword [sym.imp.MSVCRT.dll_wcscat]
lea ecx, [esp + 0x20]
push str.ArcSoftOnlinePrint_
push ecx
call ebp
lea edx, [esp + 0x28]
push edx
call dword [sym.imp.MSVCRT.dll_wcslen]
lea ecx, [esp + 0x2c]
lea eax, [esp + eax*2 + 0x2c]
push 0x445614
push ecx
mov dword [esp + 0x2c], eax
call ebp
add esp, 0x14
lea edx, [esp + 0x228]
lea eax, [esp + 0x20]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
cmp eax, 0xffffffff
mov dword [esp + 0x10], eax
jne 0x4085c6
xor eax, eax
jmp 0x4087de
mov ecx, esi
call fcn.004088b0
lea ecx, [esi + 4]
cmp ecx, ebx
mov dword [esp + 0x14], ecx
je 0x4085dd
call fcn.00404790
push edi
mov dword [esp + 0x6d4], ebx
mov edi, dword [sym.imp.MSVCRT.dll_wcscmp]
lea ecx, [esp + 0x258]
push 0x445610
push ecx
call edi
add esp, 8
test eax, eax
je 0x40879d
lea edx, [esp + 0x258]
push 0x445608
push edx
call edi
add esp, 8
test eax, eax
je 0x40879d
test byte [esp + 0x22c], 0x10
je 0x40879d
mov eax, dword [esp + 0x1c]
lea ecx, [esp + 0x258]
lea edx, [esp + 0x24]
push ecx
push edx
mov word [eax], bx
call ebp
lea eax, [esp + 0x2c]
push 0x445600
push eax
call ebp
add esp, 0x10
lea ecx, [esp + 0x47c]
lea edx, [esp + 0x24]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x40879d
lea eax, [esp + 0x4a8]
push 0x445610
push eax
call dword [sym.imp.MSVCRT.dll_wcscmp]
add esp, 8
test eax, eax
je 0x40877f
lea ecx, [esp + 0x4a8]
push 0x445608
push ecx
call dword [sym.imp.MSVCRT.dll_wcscmp]
add esp, 8
test eax, eax
je 0x40877f
test byte [esp + 0x47c], 0x10
je 0x40877f
push 0x728
call sub.MSVCRT.dll_void____cdecl_operator_new_unsigned_int_
add esp, 4
mov dword [esp + 0x20], eax
cmp eax, ebx
mov byte [esp + 0x6d4], 1
je 0x4086e1
push esi
mov ecx, eax
call fcn.00404830
jmp 0x4086e3
xor eax, eax
lea edx, [esp + 0x4a8]
push str.history
push edx
mov byte [esp + 0x6dc], bl
mov dword [esp + 0x18], eax
call dword [sym.imp.MSVCRT.dll__wcsicmp]
add esp, 8
test eax, eax
jne 0x40873b
mov ecx, dword [esp + 0x10]
lea eax, [esp + 0x258]
push 0x44dc60
push eax
call fcn.00404980
test eax, eax
je 0x408771
mov eax, dword [esi + 0x10]
lea ecx, [esi + 8]
lea edx, [esp + 0x10]
push edx
push 1
push eax
call fcn.00408ac0
mov dword [esp + 0x10], ebx
jmp 0x40877f
lea ecx, [esp + 0x4a8]
lea edx, [esp + 0x258]
push ecx
mov ecx, dword [esp + 0x14]
push edx
call fcn.00404980
test eax, eax
je 0x408771
mov edx, dword [esi + 0x10]
lea ecx, [esi + 8]
lea eax, [esp + 0x10]
push eax
push 1
push edx
call fcn.00408ac0
mov dword [esp + 0x10], ebx
jmp 0x40877f
mov ecx, dword [esp + 0x10]
cmp ecx, ebx
je 0x40877f
mov eax, dword [ecx]
push 1
call dword [eax]
lea ecx, [esp + 0x47c]
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x408670
push edi
call dword [sym.imp.KERNEL32.dll_FindClose]
mov eax, dword [esp + 0x14]
lea edx, [esp + 0x22c]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
jne 0x4085e5
mov ecx, dword [esp + 0x14]
push ecx
call dword [sym.imp.KERNEL32.dll_FindClose]
mov ecx, dword [esp + 0x18]
pop edi
cmp ecx, ebx
je 0x4087d1
call fcn.004047b0
lea ecx, [esi + 0x18]
call fcn.00407e30
mov eax, 1
mov ecx, dword [esp + 0x6c8]
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x6c8
ret 4