Function at 0x407760
Capabilities:
Check if file exists
Delete file
Move file

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x46c720
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push esi
push edi
mov eax, dword [0x4860f0]
xor eax, esp
push eax
lea eax, [esp + 0x20]
mov dword fs:[0], eax
mov esi, ecx
push esi
call fcn.00407c80
test eax, eax
jne 0x4077bf
push str.Cannot_Kill_Running_Program__n
mov eax, 4
call fcn.00409bb0
add esp, 4
xor eax, eax
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [esi + 0x328]
lea edi, [esi + 0x328]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x40781a
mov eax, dword [edi]
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHCreateDirectory]
test eax, eax
je 0x407970
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
mov eax, dword [edi]
push eax
push str.Directory_Error_Path:_s_n
mov eax, 4
call fcn.00409bb0
add esp, 8
xor eax, eax
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
xor esi, esi
lea esp, [esp]
mov ebx, dword [esi + 0x47236c]
lea ecx, [esp + 0x10]
push edi
push ecx
call fcn.00405cd0
add esp, 8
mov dword [esp + 0x28], 0
mov edx, dword [esp + 0x10]
push edx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x4078d1
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
test eax, eax
jne 0x4078d1
lea ecx, [esp + 0x10]
push ecx
lea edx, [esp + 0x18]
push edx
mov ebx, 0x472c58
call fcn.00405cd0
add esp, 8
mov byte [esp + 0x28], 1
mov eax, dword [esp + 0x14]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x407894
mov ecx, dword [esp + 0x14]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x10]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
je 0x407988
mov byte [esp + 0x28], 0
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4078d1
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x28], 0xffffffff
mov eax, dword [esp + 0x10]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4078f9
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
add esi, 4
cmp esi, 0x3c
jb 0x407820
xor esi, esi
jmp 0x407910
mov ebx, dword [esi*4 + 0x472424]
lea ecx, [esp + 0x14]
push edi
push ecx
call fcn.00405cd0
mov dword [esp + 0x30], 2
mov eax, dword [eax]
push eax
call fcn.00407020
add esp, 0xc
test eax, eax
mov dword [esp + 0x28], 0xffffffff
mov eax, dword [esp + 0x14]
sete bl
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x407962
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
test bl, bl
jne 0x407a08
inc esi
cmp esi, 3
jb 0x407910
mov eax, 1
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, dword [esp + 0x10]
push eax
push ecx
push str.MoveFile_Error_File:_s_ErrCode:_d__n
mov eax, 4
call fcn.00409bb0
mov byte [esp + 0x34], 0
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
add esp, 0xc
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x4079cb
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x28], 0xffffffff
mov eax, dword [esp + 0x10]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4079f3
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor eax, eax
mov ecx, dword [esp + 0x20]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ebx, dword [esi*4 + 0x472424]
lea ecx, [esp + 0x18]
push edi
push ecx
call fcn.00405cd0
mov dword [esp + 0x30], 3
mov edx, dword [eax]
push edx
push str.Delete_Folder_Error_Path:_s__n
mov eax, 4
call fcn.00409bb0
mov dword [esp + 0x38], 0xffffffff
mov eax, dword [esp + 0x28]
add esp, 0x10
jmp 0x4079d7