Function at 0x406340
Capabilities:
Copy file
Enumerate files on windows
Enumerate files recursively
Set file attributes

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4a9b39
mov eax, dword fs:[0]
push eax
sub esp, 0x2ec
mov eax, dword [0x4e06b8]
xor eax, ebp
mov dword [ebp - 0x10], eax
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 4], 0
mov ecx, dword [ebp + 8]
call fcn.004027c0
movzx eax, al
test eax, eax
jne 0x406390
lea ecx, [ebp + 0xc]
call fcn.004027c0
movzx ecx, al
test ecx, ecx
je 0x4063b1
mov byte [ebp - 0x2e1], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0xc]
call fcn.00404310
mov al, byte [ebp - 0x2e1]
jmp 0x406674
lea edx, [ebp + 0xc]
push edx
call fcn.00404ce0
add esp, 4
movzx eax, al
test eax, eax
jne 0x4063e5
mov byte [ebp - 0x2e2], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0xc]
call fcn.00404310
mov al, byte [ebp - 0x2e2]
jmp 0x406674
mov dword [ebp - 0x28c], 0
push 0x24c
push 0
lea ecx, [ebp - 0x288]
push ecx
call fcn.00487e90
add esp, 0xc
push 0x4c5760
mov edx, dword [ebp + 8]
push edx
lea eax, [ebp - 0x2c]
push eax
call fcn.00402ea0
add esp, 0xc
mov dword [ebp - 0x2f0], eax
lea ecx, [ebp - 0x28c]
push ecx
mov ecx, dword [ebp - 0x2f0]
call fcn.00404260
push eax
call dword [sym.imp.KERNEL32.dll_FindFirstFileW]
mov dword [ebp - 0x34], eax
lea ecx, [ebp - 0x2c]
call fcn.00404310
cmp dword [ebp - 0x34], 0xffffffff
jne 0x40646b
mov byte [ebp - 0x2e3], 0
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0xc]
call fcn.00404310
mov al, byte [ebp - 0x2e3]
jmp 0x406674
mov byte [ebp - 0x2d], 1
lea edx, [ebp - 0x28c]
push edx
mov eax, dword [ebp - 0x34]
push eax
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
setne cl
mov byte [ebp - 0x35], cl
movzx edx, byte [ebp - 0x35]
test edx, edx
je 0x40664c
lea eax, [ebp - 0x260]
push eax
lea ecx, [ebp - 0x2c4]
call fcn.00404bb0
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x2c4]
push ecx
push 0x4c5768
call fcn.00407080
add esp, 8
movzx edx, al
test edx, edx
jne 0x4064e0
lea eax, [ebp - 0x2c4]
push eax
push 0x4c576c
call fcn.00407080
add esp, 8
movzx ecx, al
test ecx, ecx
je 0x40650d
lea edx, [ebp - 0x28c]
push edx
mov eax, dword [ebp - 0x34]
push eax
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
setne cl
mov byte [ebp - 0x35], cl
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2c4]
call fcn.00404310
jmp 0x406488
push 0x4c5774
mov edx, dword [ebp + 8]
push edx
lea eax, [ebp - 0x2a8]
push eax
call fcn.00402ea0
add esp, 0xc
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x2c4]
push ecx
lea ecx, [ebp - 0x2a8]
call fcn.004026e0
push 0x4c5778
lea edx, [ebp + 0xc]
push edx
lea eax, [ebp - 0x2e0]
push eax
call fcn.00402ea0
add esp, 0xc
mov byte [ebp - 4], 3
lea ecx, [ebp - 0x2c4]
push ecx
lea ecx, [ebp - 0x2e0]
call fcn.004026e0
mov edx, dword [ebp - 0x28c]
and edx, 1
je 0x40658b
push 0x80
lea ecx, [ebp - 0x2a8]
call fcn.00404260
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
mov eax, dword [ebp - 0x28c]
and eax, 0x10
je 0x4065d9
sub esp, 0x1c
mov ecx, esp
mov dword [ebp - 0x2e8], esp
lea edx, [ebp - 0x2e0]
push edx
call fcn.00404280
mov dword [ebp - 0x2f4], eax
lea eax, [ebp - 0x2a8]
push eax
call fcn.00406340
add esp, 0x20
mov byte [ebp - 0x2f5], al
movzx ecx, byte [ebp - 0x2f5]
test ecx, ecx
jne 0x4065d7
mov byte [ebp - 0x2d], 0
jmp 0x406601
push 0
lea ecx, [ebp - 0x2e0]
call fcn.00404260
push eax
lea ecx, [ebp - 0x2a8]
call fcn.00404260
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
jne 0x406601
mov byte [ebp - 0x2d], 0
lea edx, [ebp - 0x28c]
push edx
mov eax, dword [ebp - 0x34]
push eax
call dword [sym.imp.KERNEL32.dll_FindNextFileW]
test eax, eax
setne cl
mov byte [ebp - 0x35], cl
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x2e0]
call fcn.00404310
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x2a8]
call fcn.00404310
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x2c4]
call fcn.00404310
jmp 0x406488
mov edx, dword [ebp - 0x34]
push edx
call dword [sym.imp.KERNEL32.dll_FindClose]
mov al, byte [ebp - 0x2d]
mov byte [ebp - 0x2e9], al
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0xc]
call fcn.00404310
mov al, byte [ebp - 0x2e9]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00482469
mov esp, ebp
pop ebp
ret