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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x489ec5
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push esi
push edi
mov eax, dword [0x4b0070]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [ebp - 0x18], ebx
call fcn.004105b0
test eax, eax
jne 0x410109
push str.Cannot_Kill_Running_Program__n
push 4
call fcn.00412480
add esp, 8
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push dword [ebx + 0x328]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x41015e
push dword [ebx + 0x328]
push eax
call dword [sym.imp.SHELL32.dll_SHCreateDirectory]
test eax, eax
je 0x41028a
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
push dword [ebx + 0x328]
push str.Directory_Error_Path:_s_n
push 4
call fcn.00412480
add esp, 0xc
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ebx, dword [sym.imp.KERNEL32.dll_DeleteFileW]
xor esi, esi
or edi, 0xffffffff
nop dword [eax]
mov edx, dword [ebp - 0x18]
lea ecx, [ebp - 0x10]
push dword [esi + 0x497d70]
lea edx, [edx + 0x328]
call fcn.0040ad50
add esp, 4
mov dword [ebp - 4], 0
push dword [ebp - 0x10]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x410202
push dword [ebp - 0x10]
call ebx
test eax, eax
jne 0x410202
push str..tmp
lea edx, [ebp - 0x10]
lea ecx, [ebp - 0x14]
call fcn.0040ad50
add esp, 4
mov byte [ebp - 4], 1
push dword [ebp - 0x14]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x4101d0
push dword [ebp - 0x14]
call ebx
push dword [ebp - 0x14]
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
je 0x4102a1
mov byte [ebp - 4], 0
mov eax, edi
mov edx, dword [ebp - 0x14]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x410202
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
mov eax, edi
mov edx, dword [ebp - 0x10]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x410223
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
add esi, 4
cmp esi, 0x7c
jb 0x410170
xor esi, esi
mov edx, dword [ebp - 0x18]
lea ecx, [ebp - 0x14]
push dword [esi*4 + 0x497d04]
lea edx, [edx + 0x328]
call fcn.0040ad50
add esp, 4
mov dword [ebp - 4], 2
mov ecx, dword [eax]
call fcn.0040fd10
test eax, eax
mov dword [ebp - 4], 0xffffffff
mov edx, dword [ebp - 0x14]
mov eax, edi
sete bl
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x410280
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
test bl, bl
jne 0x4102e4
inc esi
cmp esi, 7
jb 0x410231
mov eax, 1
mov ecx, dword [ebp - 0xc]
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]
push eax
push dword [ebp - 0x10]
push str.MoveFile_Error_File:_s_ErrCode:_d__n
push 4
call fcn.00412480
mov byte [ebp - 4], 0
add esp, 0x10
mov edx, dword [ebp - 0x14]
mov eax, edi
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x4102d8
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
mov edx, dword [ebp - 0x10]
jmp 0x41031e
mov edx, dword [ebp - 0x18]
lea ecx, [ebp - 0x1c]
push dword [esi*4 + 0x497d04]
lea edx, [edx + 0x328]
call fcn.0040ad50
mov dword [ebp - 4], 3
push dword [eax]
push str.Delete_Folder_Error_Path:_s__n
push 4
call fcn.00412480
mov dword [ebp - 4], 0xffffffff
add esp, 0x10
mov edx, dword [ebp - 0x1c]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], edi
dec edi
test edi, edi
jg 0x410333
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret