Function at 0x4059b8
Capabilities:
Copy file
Create directory
Delete file
Enumerate files on windows
Get common file path
Resolve function by parsing pe exports
Set current directory

Disassembly:
push ebx
sub esp, 0xb90
lea eax, [esp + 4]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
lea eax, [esp + 4]
push 0x41539c
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [esp + 4]
push 0x415340
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [esp + 0x108]
push str.C:Program_Files3d_analyzer
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [esp + 0x108]
push 0x41539c
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [esp + 0x108]
push 0x41502c
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [esp + 0x108]
lea edx, [esp + 4]
push 0
push edx
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileA]
lea eax, [esp + 4]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
lea eax, [esp + 4]
push 0x41539c
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [esp + 4]
push 0x41534c
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [esp + 0x108]
push str.C:Program_Files3d_analyzer
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [esp + 0x108]
push 0x41539c
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [esp + 0x108]
push 0x41502c
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [esp + 0x108]
lea edx, [esp + 4]
push 0
push edx
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileA]
lea eax, [esp + 0x20c]
xor edx, edx
mov dword [eax], edx
mov dword [eax + 4], edx
mov dword [eax + 8], edx
mov dword [eax + 0xc], edx
mov dword [eax + 0x10], edx
mov dword [eax + 0x14], edx
mov dword [eax + 0x18], edx
mov dword [eax + 0x1c], edx
mov dword [eax + 0x20], edx
mov dword [eax + 0x24], edx
mov dword [eax + 0x28], edx
mov dword [eax + 0x2c], edx
mov dword [eax + 0x30], edx
mov dword [eax + 0x34], edx
mov dword [eax + 0x38], edx
mov dword [eax + 0x3c], edx
mov dword [eax + 0x40], edx
mov dword [eax + 0x44], edx
mov dword [eax + 0x48], edx
mov dword [eax + 0x4c], edx
mov dword [eax + 0x50], edx
mov dword [eax + 0x54], edx
mov dword [eax + 0x58], edx
mov dword [eax + 0x5c], edx
mov dword [eax + 0x60], edx
mov dword [eax + 0x64], edx
mov dword [eax + 0x68], edx
mov dword [eax + 0x6c], edx
mov dword [eax + 0x70], edx
mov dword [eax + 0x74], edx
mov dword [eax + 0x78], edx
mov dword [eax + 0x7c], edx
mov dword [eax + 0x80], edx
mov dword [eax + 0x84], edx
mov dword [eax + 0x88], edx
mov dword [eax + 0x8c], edx
mov dword [eax + 0x90], edx
mov dword [eax + 0x94], edx
mov dword [eax + 0x98], edx
mov dword [eax + 0x9c], edx
mov dword [eax + 0xa0], edx
mov dword [eax + 0xa4], edx
mov dword [eax + 0xa8], edx
mov dword [eax + 0xac], edx
mov dword [eax + 0xb0], edx
mov dword [eax + 0xb4], edx
mov dword [eax + 0xb8], edx
mov dword [eax + 0xbc], edx
mov dword [eax + 0xc0], edx
mov dword [eax + 0xc4], edx
mov dword [eax + 0xc8], edx
mov dword [eax + 0xcc], edx
mov dword [eax + 0xd0], edx
mov dword [eax + 0xd4], edx
mov dword [eax + 0xd8], edx
mov dword [eax + 0xdc], edx
mov dword [eax + 0xe0], edx
mov dword [eax + 0xe4], edx
mov dword [eax + 0xe8], edx
mov dword [eax + 0xec], edx
mov dword [eax + 0xf0], edx
mov dword [eax + 0xf4], edx
mov dword [eax + 0xf8], edx
mov dword [eax + 0xfc], edx
mov dword [eax + 0x100], edx
mov dword [eax + 0x104], edx
mov dword [eax + 0x108], edx
mov dword [eax + 0x10c], edx
mov dword [eax + 0x110], edx
mov dword [eax + 0x114], edx
mov dword [eax + 0x118], edx
mov dword [eax + 0x11c], edx
mov dword [eax + 0x120], edx
mov dword [eax + 0x124], edx
mov dword [eax + 0x128], edx
mov dword [eax + 0x12c], edx
mov dword [eax + 0x130], edx
mov dword [eax + 0x134], edx
mov dword [eax + 0x138], edx
mov word [eax + 0x13c], dx
lea eax, [esp + 4]
push 0x411120
push 0x415370
push eax
call fcn.0040677c
add esp, 0xc
lea eax, [esp + 4]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
test eax, eax
jne 0x405e23
push 0x415340
push 0x411120
push 0x4150c8
push 0x411320
call fcn.0040677c
add esp, 0x10
push 0x411320
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push 0x41534c
push 0x411120
push 0x4150c8
push 0x411320
call fcn.0040677c
add esp, 0x10
push 0x411320
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push 0x415358
push 0x411120
push 0x4150c8
push 0x411320
call fcn.0040677c
add esp, 0x10
push 0x411320
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
push 0x415364
push 0x411120
push 0x4150c8
push 0x411320
call fcn.0040677c
add esp, 0x10
push 0x411320
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea eax, [esp + 0x34c]
push 0x411120
push 0x415370
push eax
call fcn.0040677c
add esp, 0xc
lea eax, [esp + 0x34c]
push eax
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
test eax, eax
je 0x405e16
lea eax, [esp + 0x34c]
push 0x411120
push 0x415380
push eax
call fcn.0040677c
add esp, 0xc
lea eax, [esp + 0x74c]
push eax
push 0x415384
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
je 0x405e16
mov ebx, eax
lea ecx, [esp + 0x88c]
lea edx, [esp + 0x34c]
push edx
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea ecx, [esp + 0x88c]
lea edx, [esp + 0x778]
push edx
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea ecx, [esp + 0x778]
lea edx, [esp + 0x88c]
push 0
push edx
push ecx
call dword [sym.imp.KERNEL32.dll_CopyFileA]
test eax, eax
je 0x405e16
lea edx, [esp + 0x778]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
lea edx, [esp + 0x74c]
push edx
push ebx
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x405d74
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x12
jne 0x405d74
mov eax, ebx
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
push str.C:Program_Files3d_analyzer
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
lea eax, [esp + 0x34c]
push 0x411120
push 0x41538c
push eax
call fcn.0040677c
add esp, 0xc
lea eax, [esp + 4]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
push 0x411120
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
lea eax, [esp + 0x20c]
push eax
push 0x415384
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
cmp eax, 0xffffffff
je 0x405f54
mov ebx, eax
lea ecx, [esp + 0x108]
lea edx, [esp + 4]
push edx
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea ecx, [esp + 0x108]
lea edx, [esp + 0x238]
push edx
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea ecx, [esp + 0x238]
lea edx, [esp + 0x108]
push 0
push edx
push ecx
call dword [sym.imp.KERNEL32.dll_CopyFileA]
test eax, eax
je 0x405f78
lea eax, [esp + 0x238]
call fcn.00405f98
movzx edx, al
test edx, edx
je 0x405f5c
lea edx, [esp + 0x20c]
push edx
push ebx
call dword [sym.imp.KERNEL32.dll_FindNextFileA]
test eax, eax
jne 0x405e4c
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x12
jne 0x405e4c
mov eax, ebx
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
push 0x415340
push 0x411120
push 0x4150c8
push 0x411320
call fcn.0040677c
push 0x41502c
push str.C:Program_Files3d_analyzer
push 0x4150c8
push 0x411b20
call fcn.0040677c
add esp, 0x20
push 0
push 0x411320
push 0x411b20
call dword [sym.imp.KERNEL32.dll_CopyFileA]
test eax, eax
jne 0x405f54
lea eax, [esp + 0x990]
push 0x411320
push 0x411b20
push 0x4153f0
push eax
call fcn.0040677c
add esp, 0x10
lea eax, [esp + 0x990]
push 0x10
push 0x40e040
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
add esp, 0xb90
pop ebx
ret
push 0x10
push 0x40e040
push 0x4153a0
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
add esp, 0xb90
pop ebx
ret
push 0x10
push 0x40e040
push 0x4153c0
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
add esp, 0xb90
pop ebx
ret