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

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x559aa0
mov eax, dword fs:[0]
push eax
push ebx
sub esp, 0x70
mov eax, dword [0x5c9ea4]
xor eax, ebp
mov dword [ebp - 0x14], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
cmp dword [0x5caa04], 8
lea esi, [edi + 0x18]
mov eax, 0x5ca9f0
mov ecx, esi
cmovae eax, dword [0x5ca9f0]
cmp dword [esi + 0x14], 8
jb 0x450ff0
mov ecx, dword [esi]
push dword [0x5caa00]
mov edx, dword [esi + 0x10]
push eax
push ecx
call fcn.00452b90
mov ecx, dword [esi + 0x10]
add esp, 0xc
sub ecx, dword [0x5caa00]
cmp eax, ecx
je 0x451017
xor al, al
jmp 0x4512ea
mov eax, dword [edi]
cmp eax, 0xffffffff
je 0x451033
push eax
call dword [sym.imp.KERNEL32.dll_FlushFileBuffers]
push dword [edi]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [edi], 0xffffffff
push esi
lea ecx, [ebp - 0x58]
call fcn.0044ba20
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x58]
cmp dword [0x5caa04], 8
mov eax, 0x5ca9f0
push dword [0x5caa00]
cmovae eax, dword [0x5ca9f0]
cmp dword [ebp - 0x44], 8
push eax
cmovae ecx, dword [ebp - 0x58]
mov eax, dword [ebp - 0x48]
mov edx, eax
push ecx
mov dword [ebp - 0x60], eax
call fcn.00452b90
add esp, 0xc
cmp eax, 0xffffffff
jne 0x451096
push 0x34
push str.No_self_extension_in_the_legacy_name__can_not_rename
lea ecx, [edi + 0x30]
call fcn.0044a140
mov byte [ebp - 0x59], 0
jmp 0x4512b1
test eax, eax
jne 0x4510b2
push 0x32
push str.Incorrect_legacy_name__starts_with_self_extension_
lea ecx, [edi + 0x30]
call fcn.0044a140
mov byte [ebp - 0x59], 0
jmp 0x4512b1
lea ecx, [eax - 1]
mov eax, dword [ebp - 0x60]
mov dword [ebp - 0x64], ecx
cmp eax, ecx
jb 0x451308
mov edx, dword [0x5caa00]
sub eax, ecx
inc edx
cmp eax, edx
cmovb edx, eax
cmp dword [ebp - 0x44], 8
lea eax, [ebp - 0x58]
cmovae eax, dword [ebp - 0x58]
lea ecx, [eax + ecx*2]
mov eax, dword [ebp - 0x60]
sub eax, edx
mov dword [ebp - 0x48], eax
sub eax, dword [ebp - 0x64]
lea eax, [eax*2 + 2]
push eax
lea eax, [ecx + edx*2]
push eax
push ecx
call fcn.0052ffb0
add esp, 0xc
lea eax, [ebp - 0x58]
cmp dword [ebp - 0x44], 8
cmovae eax, dword [ebp - 0x58]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x451130
cmp dword [ebp - 0x44], 8
lea eax, [ebp - 0x58]
cmovae eax, dword [ebp - 0x58]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
nop word [eax + eax]
cmp dword [ebp - 0x44], 8
lea eax, [ebp - 0x58]
cmovae eax, dword [ebp - 0x58]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x451157
push 1
push 0x5bd968
lea ecx, [ebp - 0x58]
call fcn.004517b0
jmp 0x451130
cmp dword [ebp - 0x44], 8
lea eax, [ebp - 0x58]
mov ecx, esi
cmovae eax, dword [ebp - 0x58]
cmp dword [esi + 0x14], 8
jb 0x45116c
mov ecx, dword [esi]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_MoveFileW]
test eax, eax
jne 0x451293
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ecx, eax
lea esi, [ebp - 0x16]
nop word [eax + eax]
mov eax, 0xcccccccd
sub esi, 2
mul ecx
shr edx, 3
lea eax, [edx + edx*4]
add eax, eax
sub ecx, eax
add ecx, 0x30
mov word [esi], cx
mov ecx, edx
test ecx, ecx
jne 0x451190
xor eax, eax
mov dword [ebp - 0x6c], edx
mov word [ebp - 0x7c], ax
lea eax, [ebp - 0x16]
mov dword [ebp - 0x68], 7
cmp esi, eax
je 0x4511d5
sub eax, esi
lea ecx, [ebp - 0x7c]
sar eax, 1
push eax
push esi
call fcn.0044a140
push 0x14
push str.Cannot_rename._Code
push ecx
lea ecx, [ebp - 0x7c]
mov byte [ebp - 4], 1
call fcn.00452ef0
xor ecx, ecx
movups xmm0, xmmword [eax]
movups xmmword [ebp - 0x30], xmm0
movq xmm0, qword [eax + 0x10]
mov dword [eax + 0x10], 0
mov dword [eax + 0x14], 7
mov word [eax], cx
lea eax, [ebp - 0x30]
push eax
lea ecx, [edi + 0x30]
movq qword [ebp - 0x20], xmm0
call fcn.00448e90
mov edx, dword [ebp - 0x1c]
cmp edx, 8
jb 0x451253
mov ecx, dword [ebp - 0x30]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x451249
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x45130d
push edx
push ecx
call fcn.00518414
add esp, 8
mov edx, dword [ebp - 0x68]
cmp edx, 8
jb 0x45128d
mov ecx, dword [ebp - 0x7c]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x451283
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x451312
push edx
push ecx
call fcn.00518414
add esp, 8
mov byte [ebp - 0x59], 0
jmp 0x4512b1
lea eax, [ebp - 0x58]
cmp esi, eax
je 0x4512ad
cmp dword [ebp - 0x44], 8
mov ecx, esi
push dword [ebp - 0x48]
cmovae eax, dword [ebp - 0x58]
push eax
call fcn.0044a140
mov byte [ebp - 0x59], 1
mov edx, dword [ebp - 0x44]
cmp edx, 8
jb 0x4512e7
mov ecx, dword [ebp - 0x58]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x4512dd
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x451317
push edx
push ecx
call fcn.00518414
add esp, 8
mov al, byte [ebp - 0x59]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.005181d3
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret
call fcn.0044a4e0
call fcn.00533a91
call fcn.00533a91
call fcn.00533a91
int3