Function at 0x409bc0
Capabilities:
Copy file
Create directory
Delete file
Move file

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x258
mov eax, dword [0x43300c]
mov edi, edx
mov esi, ecx
xor eax, ebp
mov dword [ebp - 0x10], eax
push dword [edx + 4]
push dword [ecx + 4]
call dword [sym.imp.KERNEL32.dll_MoveFileW]
xor ebx, ebx
test eax, eax
je 0x409c03
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0040e0d1
mov eax, ebx
add esp, 0x258
pop esi
pop edi
pop ebx
pop ebp
ret
mov edx, esi
mov dword [ebp - 0x234], 2
mov dword [ebp - 0x230], 0xffffffff
mov dword [ebp - 0x22c], 0xffffffff
mov dword [ebp - 0x228], 0
mov dword [ebp - 0x224], 0
lea ecx, [ebp - 0x234]
push 0
call fcn.004096a0
add esp, 4
mov edx, dword [ebp - 0x230]
cmp edx, 0xffffffff
je 0x409c8f
mov eax, edx
and eax, 0x10
je 0x409c8f
mov eax, dword [ebp + 8]
mov dword [ebp - 0x260], edx
add eax, 0x80
push eax
push dword [edi + 4]
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x409d5f
call dword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
jmp 0x409d09
mov eax, dword [ebp - 0x22c]
lea ecx, [eax + 1]
cmp ecx, 2
jb 0x409ca8
push eax
mov ebx, edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edx, ebx
cmp edx, 0xffffffff
mov dword [ebp - 0x22c], 0xffffffff
setne al
xor ebx, ebx
cmp edx, 0xffffffff
je 0x409cfc
mov ecx, dword [ebp - 0x234]
cmp ecx, 2
je 0x409cfc
shr edx, 0xa
and dl, al
jne 0x409cfc
cmp ecx, 1
je 0x409cfc
push 1
push dword [edi + 4]
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_CopyFileW]
test eax, eax
jne 0x409cfc
call dword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
je 0x409d44
mov eax, dword [ebp - 0x224]
mov dword [ebp - 0x224], 0
test eax, eax
je 0x409d26
push eax
call fcn.0040d9b7
add esp, 4
mov eax, dword [ebp - 0x22c]
lea ecx, [eax + 1]
cmp ecx, 2
jb 0x409bec
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x409bec
push 4
push 0
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test ebx, ebx
js 0x409d09
test eax, eax
je 0x409c79
jmp 0x409d09
mov dword [ebp - 0x248], 2
mov dword [ebp - 0x244], 0xffffffff
mov dword [ebp - 0x240], 0xffffffff
mov dword [ebp - 0x23c], 0
mov dword [ebp - 0x238], 0
lea ecx, [ebp - 0x248]
mov edx, edi
push 0
call fcn.004096a0
add esp, 4
push 0x20a
call fcn.0040d9ae
add esp, 4
mov ebx, eax
add eax, 2
push 0x208
push 0
push eax
call fcn.0040fff0
add esp, 0xc
mov dword [ebp - 0x24c], ebx
mov dword [ebp - 0x250], 0
mov word [ebx], 0
push 0x20a
call fcn.0040d9ae
add esp, 4
mov ebx, eax
add eax, 2
push 0x208
push 0
push eax
call fcn.0040fff0
add esp, 0xc
cmp dword [ebp - 0x22c], 0xffffffff
mov dword [ebp - 0x254], ebx
mov word [ebx], 0
mov ebx, 0x80004005
mov dword [ebp - 0x258], 0
je 0x409e6c
cmp dword [ebp - 0x240], 0xffffffff
je 0x409e6c
mov eax, dword [ebp - 0x244]
cmp eax, 0xffffffff
je 0x409e6c
mov ecx, eax
and ecx, 0x10
je 0x409e6c
test eax, 0x400
jne 0x409e6c
mov eax, dword [ebp - 0x248]
dec eax
cmp eax, 2
mov eax, dword [ebp - 0x260]
jb 0x409e6c
xor ebx, ebx
test eax, 0x400
jne 0x409e6c
mov eax, dword [ebp - 0x234]
dec eax
cmp eax, 2
jae 0x409f1b
lea edx, [ebp - 0x234]
mov ecx, esi
call fcn.00409a70
test eax, eax
jns 0x409ea6
push 4
push 0
push dword [esi + 4]
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
test ebx, ebx
js 0x409ea6
test eax, eax
jne 0x409ea6
call dword [sym.imp.KERNEL32.dll_GetLastError]
movzx ebx, ax
or ebx, 0x80070000
test eax, eax
cmovle ebx, eax
mov eax, dword [ebp - 0x254]
mov dword [ebp - 0x254], 0
test eax, eax
je 0x409ec3
push eax
call fcn.0040d9b7
add esp, 4
mov eax, dword [ebp - 0x24c]
mov dword [ebp - 0x24c], 0
test eax, eax
je 0x409ee0
push eax
call fcn.0040d9b7
add esp, 4
mov eax, dword [ebp - 0x238]
mov dword [ebp - 0x238], 0
test eax, eax
je 0x409efd
push eax
call fcn.0040d9b7
add esp, 4
mov eax, dword [ebp - 0x240]
lea ecx, [eax + 1]
cmp ecx, 2
jb 0x409d09
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x409d09
lea ebx, [ebp - 0x220]
mov ecx, ebx
push dword [esi + 4]
call fcn.0040c230
call fcn.004141ec
mov dword [eax], 0
push ebx
call fcn.0040c290
add esp, 4
test eax, eax
je 0x40a074
mov edx, dword [ebp - 0x228]
mov ecx, dword [ebp - 0x224]
mov ebx, eax
mov dword [ebp - 0x25c], 0
mov dword [ebp - 0x260], edx
mov dword [ebp - 0x264], ecx
jmp 0x409fc2
push ebx
push dword [esi + 4]
push 0x42db74
push 0x105
lea eax, [ebp - 0x250]
push eax
call fcn.00409a30
add esp, 0x14
cmp dword [ebp - 0x250], 0
jne 0x40a00b
mov eax, dword [ebp - 0x25c]
mov ecx, 0x8007006f
test eax, eax
cmovns eax, ecx
mov dword [ebp - 0x25c], eax
lea eax, [ebp - 0x220]
push eax
call fcn.0040c290
add esp, 4
mov ebx, eax
test eax, eax
je 0x40a07e
push 0x42e014
push ebx
call fcn.00416a90
add esp, 8
test eax, eax
je 0x409fa9
push 0x42e012
push ebx
call fcn.00416a90
add esp, 8
test eax, eax
je 0x409fa9
cmp dword [ebp - 0x260], 0
je 0x409f6d
push dword [ebp - 0x264]
push ebx
call fcn.00416a90
add esp, 8
test eax, eax
je 0x409fa9
jmp 0x409f6d
push ebx
push dword [edi + 4]
push 0x42db74
push 0x105
lea eax, [ebp - 0x258]
push eax
call fcn.00409a30
add esp, 0x14
cmp dword [ebp - 0x258], 0
je 0x409f93
lea ecx, [ebp - 0x250]
lea edx, [ebp - 0x258]
push dword [ebp + 8]
call fcn.00409bc0
add esp, 4
mov edx, dword [ebp - 0x25c]
mov ecx, eax
test edx, edx
cmovs ecx, edx
test eax, eax
cmovs edx, ecx
mov dword [ebp - 0x25c], edx
call fcn.004141ec
mov dword [eax], 0
jmp 0x409fa9
mov dword [ebp - 0x25c], 0
call fcn.004141ec
cmp dword [eax], 0
mov eax, dword [ebp - 0x25c]
mov ebx, 0x80004005
cmove ebx, eax
test eax, eax
cmovs ebx, eax
mov eax, dword [ebp - 0x220]
cmp eax, 0xffffffff
je 0x409e6c
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
jmp 0x409e6c